0

I am using panda3d for a game, however, I am having some difficulties with accept:

 def acceptKeys(self):



    base.accept("arrowLeft", self.setKeys, ["arrowLeft",1])
    base.accept("arrowRight", self.setKeys, ["arrowRight",1])
    base.accept("arrowUp", self.setKeys, ["arrowUp",1])
    base.accept("arrowDown", self.setKeys, ["arrowDown",1])
    base.accept("space", self.setKeys, ["space",1])

The thing is, it works absolutely fine for space. It does NOT work for any of the othe keys, and I have tried it with charakter keys (such as w a s d), too!

Just nothing seems to happen when a key is pressed.

I did use the keynames that are given in the manual for panda3d. Any ideas?

newnewbie
  • 993
  • 2
  • 11
  • 26

1 Answers1

2

The manual states that you should use:

   arrow_left
   arrow_right
   arrow_up
   arrow_down

Maybe it's that simple?

jgr
  • 3,914
  • 2
  • 24
  • 28
  • It WAS that simple. So sorry. I am heartily ashamed of that -.- Look, I would LOVE to vote you up, but as yet I have no reputation, so I just accept your answer. – newnewbie Jan 13 '13 at 12:27