Im getting the error that “W = cont.sensors…” is calling for an object that is not callable, any help? im trying to learn python, by making examples. it is quite hard to get some good explanation on how the game engine works, thank god i understand how it works. sorta.
def move():
cont = GameLogic.getCurrentController() # this can be avoided, see run_2
W = cont.sensors('w_bla')
A = cont.sensors('a_bla')
speed = 120
force = [0.0, 0.0, 0.0, 0]
if w.positive:
force[1] += SPEED
if s.positive:
force[1] += (SPEED * -1)
if a.positive:
force[0] += (SPEED * -1)
if d.positive:
force[0] += SPEED
print force
any help would be appreciated, and yes this code is from nanoshooter.