Mapa adaptat per a mantindre'l fidel a l'original però que se puga recorrer ja que ara no hi ha canvi d'habitació
This commit is contained in:
@@ -45,6 +45,7 @@ function game_init(menu)
|
||||
table.insert( actors, zombie.new(73, 3, 3,false) )
|
||||
|
||||
local abad_x, abad_y = arc_mapa_get_coords ( 10, 4, 3 )
|
||||
local abad_x, abad_y = arc_mapa_get_coords ( 40, 3, 3 )
|
||||
abad:move(abad_x, abad_y)
|
||||
abad_make_safe( true )
|
||||
|
||||
@@ -112,11 +113,20 @@ function update_game()
|
||||
load_tilemap( sf_mapa )
|
||||
|
||||
if key.press(key.N1) then
|
||||
local hab = math.random(0, 79)
|
||||
local hab_x = math.random(0, mapa_room_cols-1)
|
||||
local hab_y = math.random(0, mapa_room_rows-1)
|
||||
local hab = abad.hab-1
|
||||
if hab<0 then hab=0 end
|
||||
local hab_x = 4
|
||||
local hab_y = 3
|
||||
local abad_x, abad_y = arc_mapa_get_coords ( hab, hab_x, hab_y)
|
||||
abad:move(abad_x, abad_y)
|
||||
local scr_ax, scr_ay = viewp:screen_coords(abad_x, abad_y)
|
||||
end
|
||||
if key.press(key.N2) then
|
||||
local hab = abad.hab+1
|
||||
if hab<0 then hab=0 end
|
||||
local hab_x = 4
|
||||
local hab_y = 3
|
||||
local abad_x, abad_y = arc_mapa_get_coords ( hab, hab_x, hab_y)
|
||||
print(abad_x..", "..abad_y)
|
||||
abad:move(abad_x, abad_y)
|
||||
local scr_ax, scr_ay = viewp:screen_coords(abad_x, abad_y)
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user