- [FIX] La rodeta mai tornava nombres negatius
- Completats els comentaris documentals de la unitat jinput - La unitat jinput ja es const correct
This commit is contained in:
@@ -25,17 +25,49 @@ namespace input
|
||||
/// @return Quina tecla està sent polsada
|
||||
const uint8_t whichKey();
|
||||
|
||||
/// @brief Torna el codi de la tecla que està sent polsada ara mateix
|
||||
/// @brief (nomes una vegada, com keypress)
|
||||
/// @return Quina tecla està sent polsada
|
||||
const uint8_t getKeyPressed();
|
||||
|
||||
void updateKey(uint8_t key);
|
||||
void updateKeypressed(uint8_t key);
|
||||
void updateClk(uint8_t btn);
|
||||
void updateWheel(uint8_t dy);
|
||||
/// @brief (US INTERN) Actualitza la tecla actualment polsada (keydown) desde jgame
|
||||
/// @param key tecla polsada
|
||||
void updateKey(const uint8_t key);
|
||||
|
||||
int mouseX();
|
||||
int mouseY();
|
||||
bool mouseBtn(int btn);
|
||||
bool mouseClk(int btn);
|
||||
int mouseWheel();
|
||||
/// @brief (US INTERN) Actualitza la tecla actualment polsada (keypress) desde jgame
|
||||
/// @param key tecla polsada
|
||||
void updateKeypressed(const uint8_t key);
|
||||
|
||||
/// @brief (US INTERN) Actualitza el botó del ratolí actualment polsat desde jgame
|
||||
/// @param btn botó polsat
|
||||
void updateClk(const uint8_t btn);
|
||||
|
||||
/// @brief (US INTERN) Actualitza el valor de la roda del ratolí actual desde jgame
|
||||
/// @param dy desplaçament de la rodeta
|
||||
void updateWheel(const int dy);
|
||||
|
||||
/// @brief Torna la posició X actual del ratolí
|
||||
/// @return valor de la coordenada X del ratolí
|
||||
const int mouseX();
|
||||
|
||||
/// @brief Torna la posició Y actual del ratolí
|
||||
/// @return valor de la coordenada Y del ratolí
|
||||
const int mouseY();
|
||||
|
||||
/// @brief Determina si el botó del ratolí especificat està sent polsada ara mateix
|
||||
/// @brief (Equivalent a keydown en tecles)
|
||||
/// @param btn botó a consultar
|
||||
/// @return true si està polsat, false si no
|
||||
const bool mouseBtn(const int btn);
|
||||
|
||||
/// @brief Determina si el botó especificat ha sigut polsat, pero no tornarà a ser true fins
|
||||
/// @brief que no se solte el botó i se torne a polsar (Equivalent a keypress en tecles).
|
||||
/// @param btn botó a consultar
|
||||
/// @return true si està polsat, false si no
|
||||
const bool mouseClk(const int btn);
|
||||
|
||||
/// @brief Obté el valor actual de la rodeta del ratolí
|
||||
/// @return 0 si no es mou, positiu si roda cap amunt, negatiu si roda cap avall
|
||||
const int mouseWheel();
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user