Made select_runner() an RPC call #27
Not able to test, but it probably fixes #27.
This commit is contained in:
parent
3361aca4b1
commit
0f2be1b8a8
1 changed files with 2 additions and 1 deletions
|
@ -35,7 +35,7 @@ func _process(delta):
|
|||
if Global.gamemode == "Runner":
|
||||
if runnerSelected == false:
|
||||
runnerSelected = true
|
||||
select_runner(Global.connectedPlayers, Global.connectedPlayersByPeerID)
|
||||
rpc("select_runner", Global.connectedPlayers, Global.connectedPlayersByPeerID)
|
||||
if Global.runnerDead == true:
|
||||
print("RUNNER IS DEAD")
|
||||
rpc("runner_dead", Global.chosenRunner)
|
||||
|
@ -74,6 +74,7 @@ func fill_scores_with_zeros(num_of_players):
|
|||
for i in num_of_players:
|
||||
scores[i] = 0
|
||||
|
||||
@rpc("authority", "reliable", "run_local")
|
||||
func select_runner(players, playersID):
|
||||
var numOfPlayers = players.size()
|
||||
var getIndexSize = numOfPlayers - 1
|
||||
|
|
Loading…
Reference in a new issue