Added initial tools support, minor refactor to sidebar actions

This commit is contained in:
2019-11-27 12:28:43 -06:00
parent 2b1ff35a34
commit 8869ddb3de
17 changed files with 193 additions and 116 deletions

View File

@@ -1,9 +1,10 @@
class IMICRTS
class Player
attr_reader :id, :name, :color, :team, :entities, :orders, :camera
attr_reader :id, :name, :color, :team, :entities, :orders, :camera, :spawnpoint
attr_reader :selected_entities
def initialize(id:, name: nil, color: Gosu::Color.rgb(rand(150..200), rand(100..200), rand(150..200)), team: nil)
def initialize(id:, spawnpoint:, name: nil, color: Gosu::Color.rgb(rand(150..200), rand(100..200), rand(150..200)), team: nil)
@id = id
@spawnpoint = spawnpoint
@name = name ? name : "Novice-#{id}"
@color = color
@team = team