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

Replace inputId by an input in UniversalInput #29

Open
bassetmatt opened this issue May 18, 2023 · 1 comment
Open

Replace inputId by an input in UniversalInput #29

bassetmatt opened this issue May 18, 2023 · 1 comment
Labels
good first issue Good for newcomers Priority : Low Work on this if nothing more important is available

Comments

@bassetmatt
Copy link
Member

In the file src/game/entity/dev/controllable.cpp, there are cases in a switch on the variable actionId from the field Keybind::action.inputId, and these cases are used on this variable but aren't really explicit:

These constants could be less obscure if they were replaced by members of an enum with self-explanatory names.

@gbrivady
Copy link
Member

gbrivady commented May 18, 2023

To give more insight: actions are intended to have stuff such as UNIVERSAL_UP, UNIVERSAL_DOWN, ... , SPECIAL_ACTION_1 etc, but since I did not know how many were needed, I wanted to wait for version 0.2 and the combat to fix stuff. So will be adressed in next update

Edit : see the struct UniversalInput within engine/input/input_handler.h. The member int actionId is the thing to edit.

@gbrivady gbrivady added good first issue Good for newcomers Priority : Low Work on this if nothing more important is available labels May 18, 2023
@gbrivady gbrivady added this to the Wiresmash 0.2 - Demo 2 milestone May 18, 2023
@gbrivady gbrivady changed the title Constants that could use naming in enum Replace inputId by an input in UniversalInput May 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers Priority : Low Work on this if nothing more important is available
Projects
Status: Not planned
Development

No branches or pull requests

2 participants