[FIX] Requreix mini 1.5.2

This commit is contained in:
2026-05-01 21:49:04 +02:00
parent 20646e9c64
commit f071c4b359
7 changed files with 19 additions and 10 deletions

View File

@@ -201,7 +201,7 @@ function abad_jump()
local tile1_hit_type= arc_check_tile(x1_check, y_check ) local tile1_hit_type= arc_check_tile(x1_check, y_check )
local tile2_hit_type= arc_check_tile(x2_check, y_check) local tile2_hit_type= arc_check_tile(x2_check, y_check)
local not_block_tile = tile1_hit_type ~= tiletype.block and tile2_hit_type ~= tiletype.block local not_block_tile = tile1_hit_type ~= tiletype.block and tile2_hit_type ~= tiletype.block
-- local switch_tile = tile1_hit_type == tiletype.switch or tile2_hit_type == tiletype.switch local switch_tile = tile1_hit_type == tiletype.switch or tile2_hit_type == tiletype.switch
-- print("JUMP > "..x1_check..", "..x2_check..", "..y_check) -- print("JUMP > "..x1_check..", "..x2_check..", "..y_check)
-- print("T1= "..tile1_hit_type.." / T2= "..tile2_hit_type.." / SW= "..tiletype.switch) -- print("T1= "..tile1_hit_type.." / T2= "..tile2_hit_type.." / SW= "..tiletype.switch)
-- local msg = "BLOCK TILE HITTED" -- local msg = "BLOCK TILE HITTED"
@@ -220,7 +220,16 @@ function abad_jump()
--else --else
-- abad.y=abad.y-vspace -- abad.y=abad.y-vspace
--end --end
abad.y=abad.y-vspace if switch_tile then
-- Si la posició actual no es dins del tile, avançar per a colisionar
if (arc_check_tile(x1_check, abad.y)~= tiletype.switch and
arc_check_tile(x2_check, abad.y)~= tiletype.switch)
then
abad.y=abad.y-vspace
end
else
abad.y=abad.y-vspace
end
else else
local tile1_hit = arc_get_tile(x1_check, y_check ) local tile1_hit = arc_get_tile(x1_check, y_check )
local tile2_hit = arc_get_tile(x2_check, y_check) local tile2_hit = arc_get_tile(x2_check, y_check)

View File

@@ -70,8 +70,8 @@ function elalien.draw()
end end
if elalien.step==0 then if elalien.step==0 then
draw.line(scr_x+xoff0, scr_y+6, scr_x+xoff0, scr_y+11, 11) draw.line(scr_x+xoff0, scr_y+6, scr_x+xoff0, scr_y+11, 11)
surf.pixel(scr_x+xoff1, scr_y+11, 11) draw.pixel(scr_x+xoff1, scr_y+11, 11)
surf.pixel(scr_x+xoff1, scr_y+7, 11) draw.pixel(scr_x+xoff1, scr_y+7, 11)
elseif elalien.step<3 then elseif elalien.step<3 then
draw.line(scr_x+xoff0, scr_y+6, scr_x+xoff0, scr_y+11, 11) draw.line(scr_x+xoff0, scr_y+6, scr_x+xoff0, scr_y+11, 11)
draw.line(scr_x+xoff1, scr_y+7, scr_x+xoff1, scr_y+11, 11) draw.line(scr_x+xoff1, scr_y+7, scr_x+xoff1, scr_y+11, 11)

View File

@@ -461,7 +461,7 @@ function special_keys()
end end
function debug_info() function debug_info()
fps_print() -- fps_print()
-- if true then return end -- if true then return end
font.current(font_default) font.current(font_default)
-- viewp:print() -- viewp:print()

View File

@@ -112,7 +112,7 @@ function gota:draw_falling()
local gota_x, gota_y = viewp:screen_coords( self.x, self.y ) local gota_x, gota_y = viewp:screen_coords( self.x, self.y )
draw.circf( gota_x+4, gota_y+12, 4, 16) draw.circf( gota_x+4, gota_y+12, 4, 16)
draw.circf( gota_x+5, gota_y+13, 3, 11) draw.circf( gota_x+5, gota_y+13, 3, 11)
surf.pixel( gota_x+3, gota_y+13, 2) draw.pixel( gota_x+3, gota_y+13, 2)
end end
function gota:draw_drop( x, y ) function gota:draw_drop( x, y )

View File

@@ -105,8 +105,8 @@ function mini.update()
if (game_update) then game_update() end if (game_update) then game_update() end
-- Pausa per a que vaja be en mini 1.5.1 -- Pausa per a que vaja be en mini 1.5.1
local t0 = os.clock() -- local t0 = os.clock()
while os.clock()-t0<0.01 do end -- while os.clock()-t0<0.01 do end
draw.text(sys.fps(),0,15,2) draw.text(sys.fps(),0,15,2)
end end

View File

@@ -178,7 +178,7 @@ function mapa_create_minimap()
print(x..","..y.."="..tile) print(x..","..y.."="..tile)
end end
if tile<64 then if tile<64 then
surf.pixel(x+(h%10)*12,y+math.floor(h/10)*6,pix[1+tile]) draw.pixel(x+(h%10)*12,y+math.floor(h/10)*6,pix[1+tile])
end end
end end
end end

View File

@@ -50,7 +50,7 @@ function trigger:draw()
if self.enabled then if self.enabled then
draw.surf(240,128,16,16,scr_x,scr_y,16,16) draw.surf(240,128,16,16,scr_x,scr_y,16,16)
else else
-- flipar i desactivar en gris -- "flipar" i desactivar en gris
pal.subpal(2,1) pal.subpal(2,1)
draw.surf(240,128,16,16,scr_x,scr_y,16,16,true) draw.surf(240,128,16,16,scr_x,scr_y,16,16,true)
pal.subpal(2) pal.subpal(2)