- [CHG] Fa us de push i pop en surfaces

This commit is contained in:
2026-05-25 11:36:38 +02:00
parent b42989ceaa
commit af2c8fb68d
2 changed files with 5 additions and 5 deletions
+3 -3
View File
@@ -88,7 +88,7 @@ end
function sprites.update() function sprites.update()
--if not sys.beat() then return end --if not sys.beat() then return end
if sys.chrono() < 0.02 then return end if sys.chrono() < 0.020 then return end
sys.chrono(0) sys.chrono(0)
sprites.update_sprite(sprites.hero) sprites.update_sprite(sprites.hero)
@@ -171,9 +171,9 @@ end
function sprites.draw(ignore_selected) function sprites.draw(ignore_selected)
if app.update ~= editor.update then if app.update ~= editor.update then
surf.target(game.circ_buf) surf.target.push(game.circ_buf)
surf.cls() surf.cls()
surf.target(game.back_buf) surf.target.pop()
end end
editor.item_hovered = nil editor.item_hovered = nil
+2 -2
View File
@@ -131,13 +131,13 @@ game = {
end, end,
draw_light = function(x,y,size) draw_light = function(x,y,size)
surf.target(game.circ_buf) surf.target.push(game.circ_buf)
local s = size+(game.light_strobe_value/2) local s = size+(game.light_strobe_value/2)
draw.mode(draw.OR) draw.mode(draw.OR)
draw.circf(x,y,s,1) draw.circf(x,y,s,1)
draw.circf(x,y,2*(s/3),2) draw.circf(x,y,2*(s/3),2)
draw.mode(draw.NORMAL) draw.mode(draw.NORMAL)
surf.target(game.back_buf) surf.target.pop()
end, end,
apply_water = function() apply_water = function()