Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Input Manager #977

Merged
merged 17 commits into from
Jun 24, 2024
Merged

Input Manager #977

merged 17 commits into from
Jun 24, 2024

Conversation

LucaHaverty
Copy link
Collaborator

@LucaHaverty LucaHaverty commented Jun 18, 2024

Description

An input management system that can control Synthesis using both keyboard and controller with customizable. Some controls are global and some are robot specific. The input manager works with new behavior scripts to move robots.

Objectives

  • Input management system
  • Ability to change inputs from the controls modal
  • Arcade drive behavior (JIRA Issue)
  • Generic arm behavior (JIRA Issue)
  • Generic elevator behavior (JIRA Issue)

(the wacky slider joint behavior is fixed in Elevator Bug)

JIRA Issue

@LucaHaverty LucaHaverty self-assigned this Jun 18, 2024
@BrandonPacewic BrandonPacewic added the gameplay Relating to the playability of Synthesis label Jun 19, 2024
@LucaHaverty LucaHaverty changed the title Haverty/1658/input manager Input Manager Jun 19, 2024
@LucaHaverty LucaHaverty marked this pull request as ready for review June 19, 2024 18:02
@LucaHaverty LucaHaverty requested a review from a team as a code owner June 19, 2024 18:02
@LucaHaverty LucaHaverty requested review from HunterBarclay, BrandonPacewic and PepperLola and removed request for a team June 19, 2024 18:02
Copy link
Member

@HunterBarclay HunterBarclay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

The joint inputs are appearing under the global section.

Copy link
Member

@PepperLola PepperLola left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It works pretty well (except for the slider I think). I think something about the keybind detection needs to change to work on Mac though. When doing Shift + 1 it instead registers as Shift + !, and with alt it becomes Alt + ¡ rather than detecting the base key (1) and the modifier (Shift). I can rebind the controls to Alt + ¡ and it'll work properly, although it seems that joint 2 on the default TMM 2018 robot doesn't do anything and joint 3 controls both stages of the elevator.

It also looks like either the joint inputs aren't updating (maybe since they're being categorized as global?) or they're being added to robots that shouldn't have them, because when only Dozer is loaded I still see the arm and slider joints from the TMM 2018 bot.

Copy link
Collaborator

@a-crowell a-crowell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other than the multibot issues (controlling all robots simultaneously and controls from other robots showing up) which sounds like it will be solved later--looks great!

Someday:

  • The stages of the 2471 elevator could have less impact on each other (they can move each other almost min to max), but the elevator fix commit was still a huge improvement and seems good enough for now.
  • Shift/alt/ctrl combos don't do anything. Easily fixed by not using them, so again, future problem.

062024_1658

Looking over this was super impressive. Great job!

Copy link
Member

@HunterBarclay HunterBarclay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Modifier keys still don't seem to work. Shift + 1 originally worked but after rebinding, no modifier keys responded (with or without)

@LucaHaverty
Copy link
Collaborator Author

Modifier keys still don't seem to work. Shift + 1 originally worked but after rebinding, no modifier keys responded (with or without)

Could you give me exact steps to recreate? I haven't been able to get modifier keys to not work, but Ayla seems to have found some issues with them too.

@LucaHaverty LucaHaverty mentioned this pull request Jun 21, 2024
5 tasks
if (this._accum) {
this._wheelRotationAccum += this._wheel.GetAngularVelocity() * deltaT;
this._wheelRotationAccum += 0;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why'd you remove this?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wasn't sure what it did and removed it while debugging wheel behavior, but I just now added it back in my most recent commit.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@LucaHaverty K, looks like when you added it back, you accidentally pasted in the entire line again. Fixed it just now.

Copy link
Member

@HunterBarclay HunterBarclay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great. Found a lot of little bugs with this one, so that's always good too.

@HunterBarclay HunterBarclay merged commit b6da23e into dev Jun 24, 2024
14 checks passed
@HunterBarclay HunterBarclay deleted the haverty/1658/input-manager branch June 24, 2024 16:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gameplay Relating to the playability of Synthesis
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants