This commit is contained in:
PfandBoss
2022-12-10 22:31:14 +01:00
parent d303e8ba89
commit 12f26032aa
6 changed files with 37 additions and 11 deletions

View File

@@ -38,7 +38,8 @@ func _ready():
p2_train.is_P1 = false
p1_train.hit.connect(_on_hit_player)
p2_train.hit.connect(_on_hit_player)
p1_train.current_speed = 3
p1_train.current_speed = 6
p2_train.current_speed = 6
func getMapSize(node, is_start):
if node == StartNode && not is_start:
@@ -101,7 +102,7 @@ func mapSimulation(delta):
func fightSimulation():
#FIGHT SIMULATION
print(p1_train.current_distance - p2_train.current_distance)
#print(p1_train.current_distance - p2_train.current_distance)
if(p1_node == p2_node && abs(p1_train.current_distance - p2_train.current_distance) < 0.5):
if(fight_state == CHILL):
fight_state = FIGHTING