Many ux and api improvements

This commit is contained in:
2026-05-02 18:20:17 -05:00
parent cd5bd51a02
commit 8e7c6f8a19
15 changed files with 147 additions and 51 deletions

View File

@@ -56,12 +56,18 @@ module CyberarmEngine
end
def value=(path_or_image, retro: false, tileable: false)
old_value = self.value
@path = path_or_image if path_or_image.is_a?(String)
@image = Gosu::Image.new(path_or_image, retro: retro, tileable: tileable) if @path
@image = path_or_image unless @path
recalculate
publish(:changed, @image) if old_value != self.value
self.value
end
def path