- [NEW] Més tiles

- [FIX] L'heroi se clavaba en les pareds quan li pegaven
- [NEW] Alguns fondos enhancechats
- [FIX] Augmentada la velocitat de Nemesio
- [NEW] Shortcuts de teclat per a canviar de mode a l'editor
- [NEW] Habitacions al 40%
This commit is contained in:
2026-03-24 19:01:32 +01:00
parent c1f5f92dae
commit 4e7a50879e
7 changed files with 26 additions and 9 deletions

View File

@@ -52,19 +52,19 @@ function ia.update_hero()
-- Si li han pegat...
if sprites.hero.has_been_hit then
if sprites.hero.flipped then
local tx, ty = (sprites.hero.pos.x+3)>>3, (sprites.hero.pos.y+16)>>3
local tx, ty = (sprites.hero.pos.x+12)>>3, (sprites.hero.pos.y+16)>>3
if map.tile(tx,ty) < 16 and map.tile(tx,ty-1) < 16 then
if tx<rooms.pos.x then
game.change_room(-1,0)
if tx>rooms.pos.x+19 then
game.change_room(1,0)
else
sprites.hero.pos.x = sprites.hero.pos.x + 1
end
end
else
local tx, ty = (sprites.hero.pos.x+12)>>3, (sprites.hero.pos.y+16)>>3
local tx, ty = (sprites.hero.pos.x+3)>>3, (sprites.hero.pos.y+16)>>3
if map.tile(tx,ty) < 16 and map.tile(tx,ty-1) < 16 then
if tx>rooms.pos.x+19 then
game.change_room(1,0)
if tx<rooms.pos.x then
game.change_room(-1,0)
else
sprites.hero.pos.x = sprites.hero.pos.x - 1
end