[WIP] S1 Ending. Reajustat el codi i eliminat el modul live_scene
This commit is contained in:
+23
-11
@@ -1,13 +1,18 @@
|
||||
stage1_ending ={
|
||||
time = 0,
|
||||
batvio_vx = 1
|
||||
batvio_vx = 1,
|
||||
update = function(self)
|
||||
stage1_ending:update_scene()
|
||||
end
|
||||
}
|
||||
|
||||
function stage1_ending:update_scene ()
|
||||
function stage1_ending.update_scene(self)
|
||||
print("UPDATING "..self.time)
|
||||
|
||||
-- primera escena - batman escapa
|
||||
if self.time<120 then
|
||||
if self.time==0 then
|
||||
start_scene(scenes.stage1_ending, nil, false)
|
||||
-- segona escena - batman escapa
|
||||
elseif self.time<120 then
|
||||
batvio.x = batvio.x - self.batvio_vx
|
||||
if self.time % 6 == 0 then
|
||||
self.batvio_vx= self.batvio_vx+1
|
||||
@@ -18,12 +23,14 @@ function stage1_ending:update_scene ()
|
||||
premiere.stage1_ending_init()
|
||||
elalien.stage1_ending_init()
|
||||
elseif self.time<250 then
|
||||
-- tercera escena - Aparició de elalien i premiere
|
||||
-- elalien 9,1,3 -> 8,6,3
|
||||
-- premiere 7,6,3 -> 8,1,3
|
||||
premiere.update()
|
||||
elalien.update()
|
||||
-- segona escena - Aparició de elalien i premiere
|
||||
-- elalien 9,0,3 -> 8,6,3
|
||||
-- premiere 7,6,3 -> 8,1,3
|
||||
elseif self.time<300 then
|
||||
elseif self.time==250 then
|
||||
start_scene(scenes.stage1_ending_2, nil, false)
|
||||
elseif self.time<400 then
|
||||
|
||||
end
|
||||
|
||||
@@ -35,12 +42,17 @@ function stage1_ending:update_scene ()
|
||||
self.time = self.time + 1
|
||||
|
||||
-- Acabar ending
|
||||
if self.time>=250 then
|
||||
if self.time>=350 then
|
||||
flow:next()
|
||||
end
|
||||
end
|
||||
|
||||
function stage1_ending:end_scene()
|
||||
function stage1_ending.end_scene()
|
||||
print("END")
|
||||
flow:finish()
|
||||
end
|
||||
end
|
||||
|
||||
flow:registrar("stage1_ending",{
|
||||
stage1_ending.update,
|
||||
stage1_ending.end_scene
|
||||
})
|
||||
Reference in New Issue
Block a user