[WIP] Reestructurant codi abans de posar-me en el nivell 2
[NEW] Afegit music_player [NEW] Música de fons des de l'inici
This commit is contained in:
+13
-14
@@ -1,40 +1,39 @@
|
||||
stages = {}
|
||||
-- stages = {}
|
||||
|
||||
stages.actors={}
|
||||
stages.boss_loaded = false
|
||||
stages.boss_ready = false
|
||||
stages.boss_finished = false
|
||||
boss = nil
|
||||
-- stages.actors={}
|
||||
|
||||
function stages.stage2_init()
|
||||
-- stagemgr init
|
||||
stages.actors={}
|
||||
stages.boss_loaded = false
|
||||
stages.boss_ready = false
|
||||
stages.boss_finished = false
|
||||
boss = nil
|
||||
actors={}
|
||||
|
||||
-- mapa init
|
||||
mapa = stage2_mapa
|
||||
tiletype={void=0,nonpc=1,stair=2,switch=3,half=4,block=5}
|
||||
mapa.wait=0
|
||||
mapa.step=0
|
||||
|
||||
surf.free(sf_mapa)
|
||||
sf_mapa=surf.new(s2_mapa_room_cols*s2_mapa_rooms_per_piso,s2_mapa_room_rows*s2_mapa_pisos)
|
||||
load_tilemap( sf_mapa )
|
||||
|
||||
-- actors init
|
||||
batvio.init()
|
||||
table.insert(actors,batvio)
|
||||
|
||||
local abad_x, abad_y = coords.room_to_world ( 1, 4, 3 )
|
||||
|
||||
-- abad init
|
||||
local abad_x, abad_y = coords.room_to_world ( 1, 4, 3 )
|
||||
abad:move(abad_x, abad_y)
|
||||
abad_make_safe( true )
|
||||
|
||||
-- viewport init
|
||||
local scr_ax, scr_ay = viewp:screen_coords(abad_x, abad_y)
|
||||
|
||||
remote_view_init()
|
||||
|
||||
viewp:free_move()
|
||||
|
||||
stages.boss_ready = false
|
||||
stages.boss_loaded = false
|
||||
-- remote_view_init()
|
||||
end
|
||||
|
||||
function stages.stage2_update()
|
||||
|
||||
Reference in New Issue
Block a user