Turn sources into circles

This commit is contained in:
Nikita Lisitsa 2024-08-20 17:45:41 +03:00
parent d384fe6acc
commit c526f14c44

View file

@ -1229,9 +1229,11 @@ namespace gmtk
else
shift = {0.f, -1.f};
auto box = v.location.bbox();
shift *= v.location.bbox()[0].length() * animation_factor(s.animate) / 12.f;
painter.rect(shift + v.location.bbox(-0.2f), gfx::black);
painter.rect(shift + v.location.bbox(-0.225f), color_of(s.type));
painter.circle(shift + box.center(), box[0].length() * 0.6f / 2.f, gfx::black, 72);
painter.circle(shift + box.center(), box[0].length() * 0.5f / 2.f, color_of(s.type), 72);
});
map.world->apply<vertex const, transformer const>([&](vertex const & v, transformer const & t)