This commit is contained in:
2022-12-10 17:13:28 +01:00
parent d896223fdf
commit a19d66f38c
2 changed files with 3 additions and 3 deletions

View File

@@ -29,7 +29,7 @@ _global_script_classes=[{
"language": &"GDScript", "language": &"GDScript",
"path": "res://scripts/Logic/MapNode.gd" "path": "res://scripts/Logic/MapNode.gd"
}, { }, {
"base": "StaticBody3D", "base": "Node",
"class": &"Module", "class": &"Module",
"language": &"GDScript", "language": &"GDScript",
"path": "res://scripts/Modules/Module.gd" "path": "res://scripts/Modules/Module.gd"

View File

@@ -32,7 +32,7 @@ func _ready():
p2_node = StartNode p2_node = StartNode
p2_train.get_node("CharacterBody3D").is_player1 = false p2_train.get_node("CharacterBody3D").is_player1 = false
p2_train.is_P1 = false p2_train.is_P1 = false
p1_train.current_speed = 10 p1_train.current_speed = 8
p1_train.hit.connect(_on_hit_player) p1_train.hit.connect(_on_hit_player)
p2_train.hit.connect(_on_hit_player) p2_train.hit.connect(_on_hit_player)
@@ -81,6 +81,7 @@ func _process(delta):
tween.tween_property($Control/VSlider2,"scale",Vector2(0,0),1) tween.tween_property($Control/VSlider2,"scale",Vector2(0,0),1)
p1_train.current_speed *= 0.5 p1_train.current_speed *= 0.5
p2_train.current_speed *= 0.5 p2_train.current_speed *= 0.5
elif(fight_state == FIGHTING): elif(fight_state == FIGHTING):
@@ -106,4 +107,3 @@ func _process(delta):
$Control/VSlider.value = p1_train.distance_from_start $Control/VSlider.value = p1_train.distance_from_start
$Control/VSlider2.value = p2_train.distance_from_start $Control/VSlider2.value = p2_train.distance_from_start