britzl / defold-input

Simplify input related operations such as gesture detection, input mapping and clicking/dragging game objects
MIT License
111 stars 26 forks source link

No description about input_bindings in README #13

Closed wsjscss closed 3 years ago

wsjscss commented 3 years ago

I spent about 1 hour to detect why I can't get the message_id == cursor.CLICKED The reason was - different game.input_bindings configuration. In my project I set Mouse trigger -> Button 1: click and it break cursor.CLICKED message with no warnings or any help to detect what error. After changing Mouse trigger -> Button 1: touch - everything works.

I suggest to add some instructions how to configure game.input_bindings, or add some warnings in library core like "You have no touch events in input config file. CLICK events won't wok"

Thank you =)

britzl commented 3 years ago

I added an extra note about this in the readme for the cursor script:

https://github.com/britzl/defold-input/blob/master/in/cursor.md

There was already documentation about the action_id script property.