forked from interstellar_development/freeftf
Milestone 3: Freezer
The freezer is now implemented, just as it worked in the original. There are also a few fixes here and there in preparation for Milestonr 4.
This commit is contained in:
parent
d40c3ce1ab
commit
a92202b536
14 changed files with 199 additions and 114 deletions
|
|
@ -19,7 +19,7 @@ func _ready():
|
|||
Game.computers += 1
|
||||
|
||||
func _on_computer_tick_timeout():
|
||||
if multiplayer.is_server():
|
||||
if Server.is_server:
|
||||
current += (pc_occupied[0] + pc_occupied[1] + pc_occupied[2])
|
||||
Server.sync_computers.rpc(name, current)
|
||||
if current >= TARGET:
|
||||
|
|
@ -32,19 +32,19 @@ func _on_computer_tick_timeout():
|
|||
|
||||
|
||||
func _on_pc_1_area_body_entered(body):
|
||||
if pc_occupied[0] == 0:
|
||||
if pc_occupied[0] == 0 and !body.beast:
|
||||
pc_occupied[0] = 1
|
||||
pc_body[0] = body
|
||||
|
||||
|
||||
func _on_pc_2_area_body_entered(body):
|
||||
if pc_occupied[1] == 0:
|
||||
if pc_occupied[1] == 0 and !body.beast:
|
||||
pc_occupied[1] = 1
|
||||
pc_body[1] = body
|
||||
|
||||
|
||||
func _on_pc_3_area_body_entered(body):
|
||||
if pc_occupied[2] == 0:
|
||||
if pc_occupied[2] == 0 and !body.beast:
|
||||
pc_occupied[2] = 1
|
||||
pc_body[2] = body
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue