Fleshed out simulator

This commit is contained in:
2020-06-10 11:33:38 -05:00
parent 8d2a9fb1eb
commit ca750c3b19
4 changed files with 140 additions and 34 deletions

View File

@@ -10,8 +10,13 @@ module TAC
end
def draw
Gosu.rotate(@angle, @position.x, @position.y) do
Gosu.draw_rect(@position.x - @width / 2, @position.y - @depth / 2, @width, @depth, Gosu::Color::GREEN)
Gosu.translate(@width / 2, @depth / 2) do
Gosu.rotate(@angle, @position.x, @position.y) do
Gosu.draw_rect(@position.x - @width / 2, @position.y - @depth / 2, @width, @depth, Gosu::Color::BLACK)
Gosu.draw_rect(@position.x - @width / 2 + 1, @position.y - @depth / 2 + 1, @width - 2, @depth - 2, Gosu::Color.new(0xff_808022))
Gosu.draw_arc(@position.x, @position.y, 6, 1.0, 32, 2, TAC::Palette::TIMECRAFTERS_PRIMARY)
Gosu.draw_circle(@position.x, @position.y - @depth * 0.25, 2, 3, TAC::Palette::TIMECRAFTERS_TERTIARY)
end
end
end