Whenever I create a new keyboard condition in function, the Add condition menu available in two options only(Key code is down / Key is down). But when I add it outside the function, it appears as normal again.
This is a newbie question, please read the wiki or search the board.
The difference is outside of functions and so you can create events inside of events you just can create conditions.
I try to explain it short:
Events getting fired as soon as a condition is true and they normaly just get fired once while the condition is true.
Events images including mostly a little green arrow and their names starting with "On ...."
If it would be possible to create an event in a function it would never work cause no player could press a key in the same tick like your function get called.
You need to phrase it like :
On Key Pressed > Call Function X
Function X > Do Action
Develop games in your browser. Powerful, performant & highly capable.
Thanks for the answer.