Got this strange little issue: I've got a separate module, besides variables such as the player object and animation functions there is also the boolean variable for the W key.
w_active = bge.logic.KX_INPUT_ACTIVE == bge.logic.keyboard.events[bge.events.WKEY]
Now when I import it from the module to another script and go like:
if w_active: run_animation()
It won't play it but when I don't use the variable and write the
bge.logic.KX_INPUT_ACTIVE = bge.logic.keyboard.events(bge.events.WKEY) right after the
if it does work.
I also checked it out with
print(w_active) it seems the problem is that the boolean stays on
False even when I press the W key.