Merge pull request #47 from justinclift/snake_key_v1

Use the key definition for P
This commit is contained in:
Milan Nikolic 2018-08-20 09:38:26 +02:00 committed by GitHub
commit 4e8abf93fb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -103,7 +103,7 @@ func (g *Game) Init() {
// Update - Update game // Update - Update game
func (g *Game) Update() { func (g *Game) Update() {
if !g.GameOver { if !g.GameOver {
if raylib.IsKeyPressed('P') { if raylib.IsKeyPressed(raylib.KeyP) {
g.Pause = !g.Pause g.Pause = !g.Pause
} }