Added last 2 units, added sidebar actions and build queue components, entities can now have their build actions put on the sidebar

This commit is contained in:
2019-11-21 14:04:33 -06:00
parent 902e48d53a
commit cec0c45932
12 changed files with 107 additions and 8 deletions

View File

@@ -0,0 +1,14 @@
class IMICRTS
class BuildQueue < Component
Item = Struct.new(:entity, :progress)
def initialize(parent:)
@parent = parent
@queue = []
end
def add(type)
@queue << Item.new(Entity.get(type), 0.0)
end
end
end