Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
lefo777 committed Oct 1, 2024
2 parents 7066d39 + e0c42a5 commit 8662412
Show file tree
Hide file tree
Showing 4 changed files with 1,287 additions and 4 deletions.
10 changes: 6 additions & 4 deletions dinoGame.wlk
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const velocidad = 250
object juego{

method configurar(){
game.width(12)
game.width(18)
game.height(8)
game.title("Dino Game")
game.boardGround("fondo.png")
Expand Down Expand Up @@ -73,16 +73,18 @@ object cactus {
var property position = self.posicionInicial()

method image() = "cactus.png"
method posicionInicial() = game.at(game.width()-1,suelo.position().y())
method posicionInicial() = game.at(11,suelo.position().y())

method iniciar(){
position = self.posicionInicial()
game.onTick(velocidad,"moverCactus",{self.mover()})
}

method mover(){
//COMPLETAR
}
position = position.left(1)
if (position.x() < 0)
position = game.at(11,suelo.position().y())
}

method chocar(){
//COMPLETAR
Expand Down
Loading

0 comments on commit 8662412

Please sign in to comment.