- [WIP] titles

This commit is contained in:
2026-04-15 17:32:57 +02:00
parent 3ca9f28021
commit 244a09c7ed
11 changed files with 112 additions and 5 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 302 B

BIN
data/gfx/titles/jgmummy.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 930 B

BIN
data/gfx/titles/logo.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

BIN
data/gfx/titles/pharao.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

View File

@@ -1,6 +1,7 @@
require "utils.app"
require "modules.score"
require "modules.rooms"
require "stages.titles"
require "stages.editor"
require "stages.game"
require "utils.palfade"
@@ -21,11 +22,12 @@ function mini.init()
rooms.init()
shader.init("lynx.glsl")
if sys.debug() then
editor.enable()
else
game.enable()
end
titles.enable()
--if sys.debug() then
-- editor.enable()
--else
-- game.enable()
--end
sprites.add_from_room(rooms.pos.x, rooms.pos.y)
end

BIN
data/snd/laugh.wav Normal file

Binary file not shown.

BIN
data/snd/thunder.wav Normal file

Binary file not shown.

105
data/stages/titles.lua Normal file
View File

@@ -0,0 +1,105 @@
titles = {
pharao = nil,
jailgames = nil,
jgmummy = nil,
}
local sndLaugh, sndThunder
function titles.lightning_step1()
pal.subpal(29,1)
pal.subpal(4,1)
pal.subpal(6,1)
pal.subpal(4,1)
pal.subpal(21,28)
pal.subpal(22,28)
pal.subpal(26,28)
surf.source(titles.pharao)
draw.surf(0,0,160,104,0,0)
pal.subpal()
surf.source(titles.jailgames)
draw.surf(0,0,98,14,31,49)
end
function titles.lightning_step2()
pal.subpal(29,28)
pal.subpal(4,28)
pal.subpal(6,28)
pal.subpal(4,28)
pal.subpal(1,28)
pal.subpal(21,1)
pal.subpal(22,1)
pal.subpal(26,1)
pal.subpal(28,1)
surf.source(titles.pharao)
draw.surf(0,0,160,104,0,0)
surf.source(titles.jailgames)
draw.surf(0,0,98,14,31,49)
pal.subpal()
end
local dt = 0
function titles.enable()
app.update = titles.update
titles.pharao = surf.load("gfx/titles/pharao.gif")
titles.jailgames = surf.load("gfx/titles/jailgames.gif")
titles.jgmummy = surf.load("gfx/titles/jgmummy.gif")
surf.target(surf.SCREEN)
sndLaugh = sound.load("snd/laugh.wav")
sndThunder = sound.load("snd/thunder.wav")
dt = sys.time()
end
function titles.update()
surf.source(titles.jailgames)
draw.surf(0,0,98,14,31,49)
if sys.time()-dt > 2 then
app.update = titles.step2
dt = sys.time()
sound.play(sndThunder)
sound.play(sndLaugh)
end
end
function titles.step2()
titles.lightning_step1()
if sys.time()-dt > 0.1 then
app.update = titles.step3
dt = sys.time()
end
end
function titles.step3()
surf.cls(28)
if sys.time()-dt > 0.1 then
app.update = titles.step4
dt = sys.time()
end
end
function titles.step4()
titles.lightning_step2()
if sys.time()-dt > 0.1 then
app.update = titles.step5
dt = sys.time()
end
end
function titles.step5()
surf.cls(28)
if sys.time()-dt > 0.1 then
app.update = titles.step6
dt = sys.time()
end
end
function titles.step6()
surf.source(titles.pharao)
draw.surf(0,0,160,104,0,0)
surf.source(titles.jgmummy)
draw.surf(0,0,112,22,24,45)
--titles.lightning_step1()
--app.update = titles.step7
end

BIN
drafts/cover.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 554 KiB

BIN
drafts/full_logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 MiB

Binary file not shown.