parent
998e98ae26
commit
e0cb4ec2bf
8
game.gd
8
game.gd
|
@ -75,6 +75,14 @@ func _check_win() -> String:
|
|||
#Generiert die Zufallszahl von 1-6
|
||||
func _roll_dice():
|
||||
var zahl = randi() % 6 + 1
|
||||
_update_dice_sprite(randi() % 6 + 1)
|
||||
await get_tree().create_timer(0.3).timeout
|
||||
_update_dice_sprite(randi() % 6 + 1)
|
||||
await get_tree().create_timer(0.3).timeout
|
||||
_update_dice_sprite(randi() % 6 + 1)
|
||||
await get_tree().create_timer(0.3).timeout
|
||||
_update_dice_sprite(randi() % 6 + 1)
|
||||
await get_tree().create_timer(0.3).timeout
|
||||
_update_dice_sprite(zahl)
|
||||
print(zahl) #Debug ausgabe, später löschen lol
|
||||
return zahl
|
||||
|
|
Loading…
Reference in New Issue