forked from interstellar_development/freeftf
Computer Fixing
This commit is contained in:
parent
10551189f9
commit
89ccda1523
3 changed files with 25 additions and 10 deletions
|
@ -1,6 +1,6 @@
|
|||
[preset.0]
|
||||
|
||||
name="Windows Desktop"
|
||||
name="Windows x86_64"
|
||||
platform="Windows Desktop"
|
||||
runnable=true
|
||||
dedicated_server=false
|
||||
|
@ -8,7 +8,7 @@ custom_features=""
|
|||
export_filter="all_resources"
|
||||
include_filter=""
|
||||
exclude_filter=""
|
||||
export_path="../Desktop/64.exe"
|
||||
export_path="../Desktop/Exports/win64/x86_64.exe"
|
||||
encryption_include_filters=""
|
||||
encryption_exclude_filters=""
|
||||
encrypt_pck=false
|
||||
|
@ -63,7 +63,7 @@ Remove-Item -Recurse -Force '{temp_dir}'"
|
|||
|
||||
[preset.1]
|
||||
|
||||
name="Windows Desktop 2"
|
||||
name="Windows x86_32"
|
||||
platform="Windows Desktop"
|
||||
runnable=false
|
||||
dedicated_server=false
|
||||
|
@ -71,7 +71,7 @@ custom_features=""
|
|||
export_filter="all_resources"
|
||||
include_filter=""
|
||||
exclude_filter=""
|
||||
export_path="../Desktop/32.exe"
|
||||
export_path="../Desktop/Exports/win32/x86_32.exe"
|
||||
encryption_include_filters=""
|
||||
encryption_exclude_filters=""
|
||||
encrypt_pck=false
|
||||
|
@ -126,7 +126,7 @@ Remove-Item -Recurse -Force '{temp_dir}'"
|
|||
|
||||
[preset.2]
|
||||
|
||||
name="Linux/X11"
|
||||
name="Linux/X11 x86_64"
|
||||
platform="Linux/X11"
|
||||
runnable=true
|
||||
dedicated_server=false
|
||||
|
@ -134,7 +134,7 @@ custom_features=""
|
|||
export_filter="all_resources"
|
||||
include_filter=""
|
||||
exclude_filter=""
|
||||
export_path="../Desktop/linux.x86_64"
|
||||
export_path="../Desktop/Exports/linux64/linux.x86_64"
|
||||
encryption_include_filters=""
|
||||
encryption_exclude_filters=""
|
||||
encrypt_pck=false
|
||||
|
@ -166,7 +166,7 @@ rm -rf \"{temp_dir}\""
|
|||
|
||||
[preset.3]
|
||||
|
||||
name="Linux/X11 2"
|
||||
name="Linux/X11 x86_32"
|
||||
platform="Linux/X11"
|
||||
runnable=false
|
||||
dedicated_server=false
|
||||
|
@ -174,7 +174,7 @@ custom_features=""
|
|||
export_filter="all_resources"
|
||||
include_filter=""
|
||||
exclude_filter=""
|
||||
export_path="../Desktop/linux.x86_32"
|
||||
export_path="../Desktop/Exports/linux32/linux.x86_32"
|
||||
encryption_include_filters=""
|
||||
encryption_exclude_filters=""
|
||||
encrypt_pck=false
|
||||
|
|
|
@ -11,7 +11,9 @@ func _ready():
|
|||
Game.computers += 1
|
||||
|
||||
func _on_computer_tick_timeout():
|
||||
if multiplayer.is_server():
|
||||
current += (pc_occupied[0] + pc_occupied[1] + pc_occupied[2])
|
||||
Server.sync_computers.rpc(name, current)
|
||||
if current >= TARGET:
|
||||
current = "Complete"
|
||||
$computer_tick.stop()
|
||||
|
|
|
@ -31,10 +31,17 @@ func create_game():
|
|||
@rpc("any_peer", "call_remote", "reliable")
|
||||
func send_playerinfo(name, id):
|
||||
if multiplayer.is_server():
|
||||
var done = 0
|
||||
players[id] = name
|
||||
label = get_tree().root.get_node("create/player_list/list")
|
||||
label.text = ""
|
||||
for w in players:
|
||||
if done == 1:
|
||||
label.text = str(label.text +"\n" + players[w])
|
||||
else:
|
||||
label.text = players[w]
|
||||
done = 1
|
||||
|
||||
|
||||
@rpc("authority", "call_local", "reliable")
|
||||
func start_game(server_players):
|
||||
|
@ -55,3 +62,9 @@ func sync_player(node_name, position, rotation):
|
|||
var current_character = get_tree().root.get_node("./"+node_name)
|
||||
current_character.position = position
|
||||
current_character.rotation = rotation
|
||||
|
||||
@rpc("authority", "call_local", "reliable")
|
||||
func sync_computers(node_name, current):
|
||||
var current_character = get_tree().root.get_node("./map/"+node_name)
|
||||
print(current_character)
|
||||
current_character.current = current
|
||||
|
|
Loading…
Reference in a new issue