mirror of
https://github.com/cyberarm/i-mic-rts.git
synced 2025-12-15 15:52:34 +00:00
Added refinery and war_factory definitions
This commit is contained in:
20
lib/entities/buildings/refinery.rb
Normal file
20
lib/entities/buildings/refinery.rb
Normal file
@@ -0,0 +1,20 @@
|
||||
IMICRTS::Entity.define_entity(:refinery, :building, 1_400, "Generates credits") do |entity|
|
||||
entity.radius = 44
|
||||
entity.max_health = 100.0
|
||||
|
||||
entity.body_image = "buildings/refinery/refinery.png"
|
||||
entity.shell_image = "buildings/refinery/refinery_shell.png"
|
||||
entity.overlay_image = "buildings/refinery/refinery_overlay.png"
|
||||
|
||||
position = entity.position.clone
|
||||
position.z = IMICRTS::ZOrder::OVERLAY
|
||||
|
||||
p1 = position.clone
|
||||
p1.x += 2
|
||||
p1.y += 12
|
||||
|
||||
entity.particle_emitters << IMICRTS::SmokeEmitter.new(position: p1)
|
||||
|
||||
entity.on_tick do
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user