Game.gd 184 B

12345678910111213
  1. extends Node2D
  2. var cam
  3. var p1
  4. var p2
  5. func _ready():
  6. cam = $Grid/Camera1
  7. p1 = $Grid/Player1
  8. p2 = $Grid/Player2
  9. func _process(d):
  10. cam.position = 0.5 * (p1.position + p2.position)