Renamed a bunch of player stuff to pawn stuff and implemented extensive work on getting single-address 'netplay' code working. Not sure if I've created issues with single player but in theory it should all transfer across as if the player is simply always the host.
This commit is contained in:
@@ -6,9 +6,9 @@ var spawn_points : Array = []
|
||||
func _enter_tree() -> void:
|
||||
spawn_points = $SpawnPoints.get_children()
|
||||
|
||||
func add_player(player : MultiplayerPC, key) -> void:
|
||||
func add_pawn(player : PawnController, key) -> void:
|
||||
spawn_node.add_child(player)
|
||||
if key == 1: #Server
|
||||
if player.id == 1: #Host
|
||||
player.global_position = spawn_points[0].global_position
|
||||
else:
|
||||
player.global_position = spawn_points[1].global_position
|
||||
|
||||
Reference in New Issue
Block a user