Fixed round resetting
This commit is contained in:
parent
f024c3f2ef
commit
b8e42872f7
2 changed files with 10 additions and 5 deletions
|
@ -25,11 +25,12 @@ func _process(delta):
|
|||
$startLabel.text = Global.HUDStartLabelText
|
||||
$Fatigue.value = Global.fatigue
|
||||
$Health.value = Global.playerHealth
|
||||
if not Global.roundInSession:
|
||||
if Input.is_action_just_pressed("start_game"):
|
||||
if Global.teddyAuthorityID == 1:
|
||||
restart_round()
|
||||
rpc("restart_round")
|
||||
#if not Global.roundInSession:
|
||||
if Input.is_action_just_pressed("start_game"):
|
||||
print("Player with authority ID of " + str(Global.teddyAuthorityID) + " attempted to restart the round!")
|
||||
if Global.teddyAuthorityID == 1:
|
||||
restart_round()
|
||||
rpc("restart_round")
|
||||
if Global.mapName == "Tutorial":
|
||||
if not Global.playerDisable:
|
||||
tutorial()
|
||||
|
|
|
@ -1,8 +1,12 @@
|
|||
extends Node
|
||||
|
||||
@onready var mapNode = get_node("/root/tutorial")
|
||||
var mapPath = "res://scenes/tutorial.tscn"
|
||||
var audio_stream_player = AudioStreamPlayer.new()
|
||||
|
||||
func _ready():
|
||||
Global.currentMapNode = mapNode
|
||||
Global.currentMapPath = mapPath
|
||||
Global.playerHealth = 100
|
||||
Global.fatigue = 100
|
||||
Global.roundTimer = 90.0
|
||||
|
|
Loading…
Reference in a new issue