ntasfi / PyGame-Learning-Environment

PyGame Learning Environment (PLE) -- Reinforcement Learning Environment in Python.
MIT License
1.02k stars 231 forks source link

in flappy bird game action takes a value of 119 #53

Closed adibyte95 closed 6 years ago

adibyte95 commented 6 years ago

p.act(action)

action takes a value of 119 to push the bird upwards 119 is ASCII number for w which is used in games for upward/forward movement.

but since this game has only two possible action it would be better if it is 0/1

ntasfi commented 6 years ago

@adibyte95 the library was built around pygame which exposes "keys" as constants. It felt natural write the games using these key constants. You can use the getActionSet() function to retrieve all the keys, this way you dont need to worry about what the actual underlying code is.