Closed javierfernandes closed 8 years ago
Like! :+1:
I think i'll move this issues to the main repo and creat a label for wgame El dic 12, 2015 1:43 AM, "Nahuel Palumbo" notifications@github.com escribió:
Reopened #29 https://github.com/ProyectoFinal2015/wollok/issues/29.
— Reply to this email directly or view it on GitHub https://github.com/ProyectoFinal2015/wollok/issues/29#event-490002177.
Ok, perfect!
I was thinking, if we have each key model as an object so we can do something like:
import wollok.game.keyboard.*
M.onPressDo [ granjero.plantaMaiz() ]
T.onPressDo [ granjero.plantaTrigo() ]
O.onPressDo [ granjero.plantaTomaco() ]
R.onPressDo [ granjero.rega() ]
C.onPressDo [ granjero.cosechaTodo() ]
And we don't need the keys
object.
What do you think?
Cool !
Created a new issue in wollok with a summarized version
I think we can avoid modeling keys as "strings" by using well-known objects.
Instead of this
Model it as
Which has the advantages of compile-time checks.
What do you think ?