 Kingfu Guest |
Quote
|
| 2023-12-27 17:15:05 |
|
Hey I want to move my object by pressing w key as well as f key . which means I want to apply walk animation for both keys how can I apply
|
 kaelgodoy Registered User |
Quote
|
| 2023-12-29 01:15:09 |
|
You can try "ccbEmulateKey".
ccbEmulateKey(keyCode, pressedDown)
(According to the official documentation)
|
 guest Guest |
Quote
|
| 2023-12-29 21:12:03 |
|
or you can just say if a key is pressed +1 (variable), if (variable) is greater than 1 than play the animation when the keys are un-pressed -1 (variable) if (variable)=0 stop the animation
|