Compare commits

...

20 Commits

Author SHA1 Message Date
7767e81c88 - [NEW] El actors ja poden usar descriptors de jailmojis per a crear-se 2025-11-11 13:15:38 +01:00
ed5acc7f50 - [FIX] view.origin() estaba invertit
- [FIX] Al generar un jailmoji no s'actualitzava la cadena de generació
- [NEW] Al pulsar amb el botó de la dreta sobre un spin_button o color_button, se va cap arrere
2025-11-11 11:59:14 +01:00
5f05f6e568 - [NEW] Actualitzat per a usar l'última versió de mini (v1.3.10) 2025-11-11 11:23:21 +01:00
447f5bfdb7 - [NEW] Cheneraor de Jailmojis aleatoris 2025-06-04 22:46:12 +02:00
214cf3aa05 - [NEW] Editor de Jailmojis acabat 2025-06-04 12:56:39 +02:00
eff070d61e - [NEW] Base sprites per al jailmoji
- [NEW] Retocs en els monyos.
2025-06-03 22:17:25 +02:00
99f3648d08 - [NEW] Ara cada actor pot tindre la seua propia surface.
- [WRK] Treballant en el editor de jailmojis.
2025-06-03 14:01:39 +02:00
145d5b09d4 - [NEW] Treballant en els Jailmoji 2025-06-02 13:40:27 +02:00
9930dcac54 - Progrés... 2025-06-01 22:05:08 +02:00
e285bcd4fd - [NEW] Renombrat de una puta vegada el mapa "test" a "arq" (arquitectura), que es la zona que li toca
- [NEW] Nou menúi de debug durant el joc
- [NEW] Ara es pot pasar del joc al editor i viceversa in situ.
2025-06-01 00:04:30 +02:00
c2f7b470bf - [NEW] Convertit a mini v1.0 RC2 2025-05-31 14:29:29 +02:00
28f9851f00 - [NEW] Ara es pot seleccionar el mapa a editar de un llistat, en compte de tindre que escriure el nom de l'arxiu a mà
- [WRK] Treballant en La Vella
2025-05-30 13:50:49 +02:00
b15da3338e - Conectats els mapes de EUI i exterior amb la resta
- [FIX] La càmera no se resetjava al carregar un nou mapa en el editor
- [FIX] El joc no funcionava si venies de l'editor
2025-01-09 13:08:32 +01:00
56109ec776 - Seguim treballant en el mapa exterior 2025-01-08 07:15:26 +01:00
ce8c39bd78 - Treballant en el mapa exterior 2025-01-07 12:48:31 +01:00
9b6a8fab07 - [NEW] Comencem amb el mapa del exterior 2025-01-07 07:10:57 +01:00
2dd36562da - [FIX] Reajustada la numeració de tiles
- [NEW] Comencem a treballar en la EUI
2024-12-31 10:44:39 +01:00
f6ea65a822 - Continuem amb el mapa de La Vella 2024-02-20 14:02:40 +01:00
d41566e393 - [FIX] El layer frontal no se veïa (encara que no se si al final s'usarà) 2024-02-20 14:02:18 +01:00
297662de6f - [NEW] Escenari de La Vella 2024-02-16 13:17:31 +01:00
41 changed files with 1287 additions and 383 deletions

BIN
data/actor-bag.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 199 B

BIN
data/actor-base.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
data/actor-brows.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 145 B

BIN
data/actor-chin.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 279 B

BIN
data/actor-eyes.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 163 B

BIN
data/actor-hair.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1007 B

BIN
data/actor-nose.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 211 B

View File

@@ -3,14 +3,27 @@ actors={
updating=false,
main={},
under_cursor="",
surface=0,
should_free_surf=false,
init=function()
for i,actor in ipairs(actors.list) do
if actor.should_free_surf then
surf.free(actor.surface)
end
end
actors.list={}
actors.updating=false
end,
add=function(actor)
actor.dx,actor.dy=0,0
if actor.jailmoji then
actor.surface=jailmoji.get(actor.jailmoji)
actor.gfx={x=0,y=0}
else
actor.surface=surf.load("sprites.gif")
end
table.insert(actors.list, actor)
end,
@@ -45,7 +58,7 @@ actors={
actors.search(name).o = o
end,
draw=function()
display=function()
actors.under_cursor=""
for i,v in ipairs(actors.list) do
if v.o=='' then goto continue end
@@ -53,25 +66,26 @@ actors={
local x,y = v.x, v.y
if v.ox then x = x + v.ox end
if v.oy then y = y + v.oy end
local mousex,mousey=mouse()
local mousex,mousey=mouse.pos()
local mx = math.floor((mousex+game.cam.x)/8)
local my = math.floor((mousey+game.cam.y)/8)
if (mx==x or mx==x+1) and (my==y or my==y-1) then
actors.under_cursor=v.name
subpal(1,16,8)
pal.subpal(1,16,8)
end
surf.source(v.surface)
if v.o=='u' then
blit(v.gfx.x+frame,v.gfx.y+16,16,16,x*8+v.dx*2,y*8-12+v.dy*2,16,16,v.dy>1)
draw.surf(v.gfx.x+frame,v.gfx.y+16,16,16,x*8+v.dx*2,y*8-12+v.dy*2,16,16,v.dy>1)
elseif v.o=='d' then
blit(v.gfx.x+frame,v.gfx.y,16,16,x*8+v.dx*2,y*8-12+v.dy*2,16,16,-v.dy>2)
draw.surf(v.gfx.x+frame,v.gfx.y,16,16,x*8+v.dx*2,y*8-12+v.dy*2,16,16,-v.dy>2)
elseif v.o=='l' then
blit(v.gfx.x+frame,v.gfx.y+32,16,16,x*8+v.dx*2,y*8-12+v.dy*2,16,16)
draw.surf(v.gfx.x+frame,v.gfx.y+32,16,16,x*8+v.dx*2,y*8-12+v.dy*2,16,16)
elseif v.o=='r' then
blit(v.gfx.x+frame,v.gfx.y+32,16,16,x*8+v.dx*2,y*8-12+v.dy*2,16,16,true)
draw.surf(v.gfx.x+frame,v.gfx.y+32,16,16,x*8+v.dx*2,y*8-12+v.dy*2,16,16,true)
end
if not btn(KEY_LSHIFT) then subpal() end
if not key.down(key.LSHIFT) then pal.subpal() end
::continue::
end
end,

32
data/arq.map Normal file
View File

@@ -0,0 +1,32 @@
73
29
1
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,41,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,117,137,153,153,153,153,153,153,137,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,152,195,33,33,33,33,195,138,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,39,40,39,40,39,40,35,36,37,38,39,40,39,40,39,40,39,40,39,40,39,40,39,40,152,211,12,12,12,12,211,138,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,55,56,55,56,55,56,51,52,91,92,95,56,55,56,55,56,57,58,55,56,123,124,93,94,152,227,5,2,5,2,227,138,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,63,72,73,74,75,72,67,68,107,108,71,72,73,74,75,72,71,72,63,72,139,140,109,110,5,2,5,2,5,2,5,2,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,79,2,7,8,9,2,5,2,5,2,5,2,7,8,9,2,5,2,79,2,155,156,125,126,5,2,5,2,5,2,5,2,34,
116,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,117,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,
44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,
39,40,39,40,35,36,37,38,39,40,35,36,37,38,39,40,39,40,39,40,35,36,37,38,39,40,39,40,39,40,39,40,35,36,37,38,39,40,39,40,5,2,5,2,5,2,5,2,100,102,102,102,102,102,102,102,102,102,102,102,102,102,102,101,5,2,5,2,5,2,5,2,34,
55,56,55,56,51,52,53,54,95,56,51,52,53,54,95,56,55,56,57,58,51,52,91,92,95,56,55,56,55,56,57,58,51,52,53,54,95,56,55,56,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
71,72,73,74,75,68,69,70,71,72,67,68,69,70,71,72,63,72,71,72,67,68,107,108,71,72,73,74,75,63,71,72,67,68,69,70,71,72,63,72,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
5,2,7,8,9,2,5,2,5,2,5,2,5,2,5,2,79,2,5,2,5,2,5,2,5,2,7,8,9,79,5,2,5,2,5,2,5,2,79,2,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
100,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,101,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,5,2,5,2,5,2,5,2,34,
116,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,117,5,2,5,2,5,2,5,2,116,42,42,42,42,42,42,42,42,42,42,42,42,42,42,117,5,2,5,2,5,2,5,2,34,
44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,5,2,5,2,5,2,5,2,44,45,44,45,44,45,44,45,44,45,44,45,44,45,44,45,5,2,5,2,5,2,5,2,34,
39,40,39,40,39,40,35,36,37,38,39,40,39,40,39,40,39,40,35,36,37,38,39,40,39,40,39,40,39,40,35,36,37,38,39,40,39,40,39,40,5,2,5,2,5,2,5,2,39,40,39,40,39,40,35,36,37,38,39,40,39,40,39,40,5,2,5,2,5,2,5,2,34,
55,56,55,56,57,58,51,52,91,92,95,56,55,56,55,56,55,56,51,52,91,92,95,56,57,58,55,56,55,56,51,52,91,92,95,56,57,58,55,56,5,2,5,2,5,2,5,2,55,56,55,56,57,58,51,52,91,92,95,56,55,56,55,56,5,2,5,2,5,2,5,2,34,
71,72,71,72,71,72,67,68,107,108,71,72,63,72,73,74,75,72,67,68,107,108,71,72,71,72,73,74,75,72,67,68,107,108,71,72,71,72,63,72,5,2,5,2,5,2,5,2,73,74,75,72,71,72,63,68,107,108,71,72,73,74,75,72,5,2,5,2,5,2,5,2,34,
5,2,5,2,5,2,5,2,5,2,5,2,79,2,7,8,9,2,5,2,5,2,5,2,5,2,7,8,9,2,5,2,5,2,5,2,5,2,79,2,5,2,5,2,5,2,5,2,7,8,9,2,5,2,79,2,5,2,5,2,7,8,9,2,5,2,5,2,5,2,5,2,34,
5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,
5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,
49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,50,

View File

@@ -38,36 +38,36 @@ balloon={
if below==nil or below==false then
balloon.rect.y=balloon.rect.y-balloon.rect.h-16
local x,y,w,h=balloon.rect.x,balloon.rect.y,balloon.rect.w,balloon.rect.h
rectfill(x+1,y+1,x+w+1,y+h+1,5)
rectfill(x,y,x+w,y+h,8)
rect(x,y,x+w,y+h,6)
draw.rectf(x+1,y+1,w+1,h+1,5)
draw.rectf(x,y,w+1,h+1,8)
draw.rect(x,y,w+1,h+1,6)
if pos<80 then
for i=0,4 do rect(pos,y+h+(4-i),pos+i,y+h+(4-i),8) end
line(pos-1,y+h+1,pos-1,y+h+6,6)
line(pos+4,y+h+1,pos-1,y+h+6,6)
for i=0,4 do draw.rect(pos,y+h+(4-i),i+1,2,8) end
draw.line(pos-1,y+h+1,pos-1,y+h+6,6)
draw.line(pos+4,y+h+1,pos-1,y+h+6,6)
else
pos=pos-5
for i=0,4 do rect(pos+i,y+h+i,pos+4,y+h+i,8) end
line(pos+5,y+h+1,pos+5,y+h+6,6)
line(pos,y+h+1,pos+5,y+h+6,6)
for i=0,4 do draw.rect(pos+i,y+h+i,5-i,2,8) end
draw.line(pos+5,y+h+1,pos+5,y+h+6,6)
draw.line(pos,y+h+1,pos+5,y+h+6,6)
end
else
balloon.rect.y=balloon.rect.y+16
local x,y,w,h=balloon.rect.x,balloon.rect.y,balloon.rect.w,balloon.rect.h
rectfill(x+1,y+1,x+w+1,y+h+1,5)
rectfill(x,y,x+w,y+h,8)
rect(x,y,x+w,y+h,6)
draw.rectf(x+1,y+1,w+1,h+1,5)
draw.rectf(x,y,w+1,h+1,8)
draw.rect(x,y,w+1,h+1,6)
if pos<80 then
for i=0,4 do rect(pos,y-(4-i),pos+i,y-(4-i),8) end
line(pos-1,y,pos-1,y-6,6)
line(pos+5,y,pos-1,y-6,6)
for i=0,4 do draw.rect(pos,y-(4-i),i+1,2,8) end
draw.line(pos-1,y,pos-1,y-6,6)
draw.line(pos+5,y,pos-1,y-6,6)
else
pos=pos-5
for i=0,4 do rect(pos+i,y-i,pos+4,y-i,8) end
line(pos+5,y,pos+5,y-6,6)
line(pos-1,y,pos+5,y-6,6)
for i=0,4 do draw.rect(pos+i,y-i,5-i,2,8) end
draw.line(pos+5,y,pos+5,y-6,6)
draw.line(pos-1,y,pos+5,y-6,6)
end
end
@@ -87,15 +87,15 @@ balloon={
update=balloon.update
local x,y,w,h=balloon.rect.x,balloon.rect.y,balloon.rect.w,balloon.rect.h
rectfill(x+1,y+1,x+w+1,y+h+1,5)
rectfill(x,y,x+w,y+h,15)
rect(x,y,x+w,y+h,6)
draw.rectf(x+1,y+1,w+1,h+1,5)
draw.rectf(x,y,w+1,h+1,15)
draw.rect(x,y,w+1,h+1,6)
balloon.cursor={x=balloon.rect.x+12,y=balloon.rect.y+11}
end,
update=function()
if anykey() then
if key.any() then
if balloon.pos<0 then
update=balloon.old_update
update()
@@ -105,20 +105,20 @@ balloon={
end
end
if not beat() and not balloon.quick then return end
if not sys.beat() and not balloon.quick then return end
if balloon.pos<0 then
if balloon.obj then
setsource(objectes)
blit(balloon.obj.x,balloon.obj.y,16,16,balloon.rect.x+balloon.rect.w-28,balloon.rect.y+10)
surf.source(objectes)
draw.surf(balloon.obj.x,balloon.obj.y,16,16,balloon.rect.x+balloon.rect.w-28,balloon.rect.y+10)
end
local col=8
if math.floor(time()*4)%2==0 then col=10 end
if math.floor(sys.time()*4)%2==0 then col=10 end
local x,y=balloon.rect.x+balloon.rect.w-8, balloon.rect.y+balloon.rect.h-6
line(x,y,x+4,y,col)
line(x+1,y+1,x+3,y+1,col)
line(x+2,y+2,x+2,y+2,col)
if btnp(KEY_SPACE) then
draw.line(x,y,x+4,y,col)
draw.line(x+1,y+1,x+3,y+1,col)
draw.line(x+2,y+2,x+2,y+2,col)
if key.press(key.SPACE) then
update=balloon.old_update
end
else

View File

@@ -7,24 +7,24 @@ brymode = {
update=brymode.update
brymode.return_function=retfun
cls(0)
prnt("#include <stdio.h>",1,1,8)
prnt("int main(int argc, char *argv[])",1,1+6*2,8)
prnt("{",1,1+6*3,8)
prnt("SDL_Init(SDL_INIT_EVERYTHING);",21,1+6*4,8)
prnt("SDL_Window *win=",21,1+6*6,8)
prnt("SDL_CreateWindow('Title',320,240);",29,1+6*7,8)
prnt("SDL_Renderer *ren =",21,1+6*9,8)
prnt("SDL_CreateRenderer(win,-1,0);",29,1+6*10,8)
prnt("SDL_Quit();",21,1+6*12,8)
prnt("return 0;",21,1+6*13,8)
prnt("}",1,1+6*14,8)
surf.cls(0)
draw.text("#include <stdio.h>",1,1,8)
draw.text("int main(int argc, char *argv[])",1,1+6*2,8)
draw.text("{",1,1+6*3,8)
draw.text("SDL_Init(SDL_INIT_EVERYTHING);",21,1+6*4,8)
draw.text("SDL_Window *win=",21,1+6*6,8)
draw.text("SDL_CreateWindow('Title',320,240);",29,1+6*7,8)
draw.text("SDL_Renderer *ren =",21,1+6*9,8)
draw.text("SDL_CreateRenderer(win,-1,0);",29,1+6*10,8)
draw.text("SDL_Quit();",21,1+6*12,8)
draw.text("return 0;",21,1+6*13,8)
draw.text("}",1,1+6*14,8)
end,
update=function()
--cls(0)
if btnp(KEY_ESCAPE) then
if key.press(key.ESCAPE) then
if brymode.return_function then
update=brymode.old_update
brymode.return_function()

View File

@@ -1,6 +1,7 @@
require "menu"
require "mapa"
require "textbox"
require "fileselect"
editor={
paused=true,
@@ -8,6 +9,8 @@ editor={
--selected_tile=3,
brush={w=1,h=1,tiles={3}},
selection=nil,
cx=0,
cy=0,
init=function()
set_update(editor.update)
@@ -15,42 +18,62 @@ editor={
editor.new()
end,
editfrom=function()
game.paused = nil
set_update(editor.update)
--editor.show_menu()
editor.load(game.level .. ".map")
editor.cam.x = game.cam.x
editor.cam.y = game.cam.y
end,
show_menu=function()
menu.show({ {"NEW MAP", editor.new},
{"LOAD MAP", function() textbox.show("FILENAME TO LOAD:",editor.load, mapa.name) end},
{"LOAD MAP", function() fileselect.show("FILE TO LOAD:",editor.load, ".map") end},
{"SAVE MAP", function() if mapa.name~=nil then editor.save(mapa.name) else textbox.show("FILENAME TO SAVE:",editor.save, mapa.name) end end},
{mapa.front_layer and "DISABLE FRONT LAYER" or "ENABLE FRONT LAYER", editor.toggle_front_layer},
{editor.editing_front_layer and "DISABLE FRONT LAYER" or "ENABLE FRONT LAYER", editor.toggle_front_layer},
{"RESIZE MAP", editor.resize},
{"RELOAD TEXTURES", editor.reload_textures},
{"PLAY FROM HERE", editor.playfromhere},
{"EXIT", main_init},
}, function()editor.paused=false end)
end,
playfromhere=function()
game.startfromeditor(string.sub(mapa.name,1,-5), editor.cx, editor.cy)
end,
reload_textures=function()
freesurf(sprites)
freesurf(objectes)
freesurf(tiles)
sprites=loadsurf("sprites.gif")
objectes=loadsurf("objects.gif")
tiles=loadsurf("tiles.gif")
setsource(tiles)
local pal=loadpal("tiles.gif")
setpal(pal)
surf.free(sprites)
surf.free(objectes)
surf.free(tiles)
sprites=surf.load("sprites.gif")
objectes=surf.load("objects.gif")
tiles=surf.load("tiles.gif")
surf.source(tiles)
local p=pal.load("tiles.gif")
pal.set(p)
editor.paused=false
end,
toggle_front_layer=function()
if editor.editing_front_layer then
map.surf(mapa.surface)
editor.editing_front_layer=false;
else
if not mapa.front_layer then
mapa.front_layer=newsurf(mapa.w,mapa.h)
mapa.front_layer=surf.new(mapa.w,mapa.h)
editor.editing_front_layer=true
setmap(mapa.front_layer)
map.surf(mapa.front_layer)
for y=0,mapa.h-1 do
for x=0,mapa.w-1 do
mset(x,y,0)
map.tile(x,y,0)
end
end
else
mapa.front_layer=nil
editor.editing_front_layer=true
map.surf(mapa.front_layer)
end
end
editor.paused=false
end,
@@ -69,27 +92,27 @@ editor={
local old_surface= mapa.surface
mapa.w=tonumber(editor.new_w)
mapa.h=tonumber(editor.new_h)
mapa.surface=newsurf(mapa.w,mapa.h)
mapa.surface=surf.new(mapa.w,mapa.h)
for y=0,mapa.h-1 do
for x=0,mapa.w-1 do
setmap(old_surface)
local value=mget(x,y)
setmap(mapa.surface)
mset(x,y,value)
map.surf(old_surface)
local value=map.tile(x,y)
map.surf(mapa.surface)
map.tile(x,y,value)
end
end
freesurf(old_surface)
setmap(mapa.surface)
surf.free(old_surface)
map.surf(mapa.surface)
editor.paused=false
end,
floodfill=function(x,y,tile)
local t=mget(x,y)
mset(x,y,tile)
if x<mapa.w-1 and mget(x+1,y)==t then editor.floodfill(x+1,y,tile) end
if x>0 and mget(x-1,y)==t then editor.floodfill(x-1,y,tile) end
if y<mapa.h-1 and mget(x,y+1)==t then editor.floodfill(x,y+1,tile) end
if y>0 and mget(x,y-1)==t then editor.floodfill(x,y-1,tile) end
local t=map.tile(x,y)
map.tile(x,y,tile)
if x<mapa.w-1 and map.tile(x+1,y)==t then editor.floodfill(x+1,y,tile) end
if x>0 and map.tile(x-1,y)==t then editor.floodfill(x-1,y,tile) end
if y<mapa.h-1 and map.tile(x,y+1)==t then editor.floodfill(x,y+1,tile) end
if y>0 and map.tile(x,y-1)==t then editor.floodfill(x,y-1,tile) end
end,
create_stamp=function()
@@ -102,8 +125,8 @@ editor={
local p=1
for y=1,h do
for x=1,w do
editor.brush.tiles[p]=mget(tx1+x-1,ty1+y-1)
--mset(tx+x-1,ty+y-1,editor.brush.tiles[p])
editor.brush.tiles[p]=map.tile(tx1+x-1,ty1+y-1)
--map.tile(tx+x-1,ty+y-1,editor.brush.tiles[p])
p=p+1
end
end
@@ -115,7 +138,7 @@ editor={
local p=1
for y=1,h do
for x=1,w do
mset(tx+x-1,ty+y-1,editor.brush.tiles[p])
map.tile(tx+x-1,ty+y-1,editor.brush.tiles[p])
p=p+1
end
end
@@ -126,57 +149,58 @@ editor={
if dx>0 then
for y=0,h-1 do
for x=w-1,1,-1 do
mset(x,y,mget(x-1,y))
map.tile(x,y,map.tile(x-1,y))
end
end
elseif dx<0 then
for y=0,h-1 do
for x=0,w-2 do
mset(x,y,mget(x+1,y))
map.tile(x,y,map.tile(x+1,y))
end
end
elseif dy>0 then
for y=h-1,1,-1 do
for x=0,w-1 do
mset(x,y,mget(x,y-1))
map.tile(x,y,map.tile(x,y-1))
end
end
elseif dy<0 then
for y=0,h-2 do
for x=0,w-1 do
mset(x,y,mget(x,y+1))
map.tile(x,y,map.tile(x,y+1))
end
end
end
end,
update=function()
cls()
camera(editor.cam.x, editor.cam.y)
setsource(tiles)
setmap(mapa.surface)
map(0,0,0,0,mapa.w, mapa.h)
surf.cls()
view.origin(-editor.cam.x, -editor.cam.y)
surf.source(tiles)
map.surf(mapa.surface)
map.draw() --map(0,0,0,0,mapa.w, mapa.h)
if mapa.front_layer then
setmap(mapa.front_layer)
map(0,0,0,0,mapa.w, mapa.h)
map.surf(mapa.front_layer)
map.draw() --map(0,0,0,0,mapa.w, mapa.h)
end
if editor.editing_front_layer then
setmap(mapa.front_layer)
map.surf(mapa.front_layer)
text("EDITING FRONT LAYER",12,2,10)
else
setmap(mapa.surface)
map.surf(mapa.surface)
end
local mx,my=mouse()
local mx,my=mouse.pos()
local tx,ty=(mx+editor.cam.x)>>3,(my+editor.cam.y)>>3
editor.cx, editor.cy = tx, ty
local rx,ry=tx<<3,ty<<3
rect(rx-1, ry-1, rx+8, ry+8, 10)
draw.rect(rx-1, ry-1, 10, 10, 10)
if editor.selection then
local rx1,ry1,rx2,ry2=editor.selection.x1<<3,editor.selection.y1<<3,editor.selection.x2<<3,editor.selection.y2<<3
if rx1>rx2 then rx1,rx2=rx2,rx1 end
if ry1>ry2 then ry1,ry2=ry2,ry1 end
rect(rx1-1, ry1-1, rx2+8, ry2+8, 8)
draw.rect(rx1-1, ry1-1, rx2-rx1+10, ry2-ry1+10, 8)
end
camera(0,0)
view.origin(0,0)
if tx>=0 and
ty>=0 and
tx<mapa.w and
@@ -184,11 +208,11 @@ editor={
text(tx..","..ty,2,2,8)
end
if not editor.paused then
if mbtn(1) then
if mouse.down(mouse.LEFT) then
editor.stamp(tx,ty)
--mset(tx,ty,editor.brush.tiles[1])
--map.tile(tx,ty,editor.brush.tiles[1])
end
if mbtn(3) then
if mouse.down(mouse.RIGHT) then
if editor.selection then
editor.selection.x2=tx
editor.selection.y2=ty
@@ -206,55 +230,55 @@ editor={
end
end
if btn(KEY_LSHIFT) then
if btnp(KEY_RIGHT) then editor.displace(1,0) end
if btnp(KEY_LEFT) then editor.displace(-1,0) end
if btnp(KEY_UP) then editor.displace(0,-1) end
if btnp(KEY_DOWN) then editor.displace(0,1) end
if key.down(key.LSHIFT) then
if key.press(key.RIGHT) then editor.displace(1,0) end
if key.press(key.LEFT) then editor.displace(-1,0) end
if key.press(key.UP) then editor.displace(0,-1) end
if key.press(key.DOWN) then editor.displace(0,1) end
else
if btnp(KEY_RIGHT) then editor.cam.x=editor.cam.x+8 end
if btnp(KEY_LEFT) then editor.cam.x=editor.cam.x-8 end
if btnp(KEY_UP) then editor.cam.y=editor.cam.y-8 end
if btnp(KEY_DOWN) then editor.cam.y=editor.cam.y+8 end
if key.press(key.RIGHT) then editor.cam.x=editor.cam.x+8 end
if key.press(key.LEFT) then editor.cam.x=editor.cam.x-8 end
if key.press(key.UP) then editor.cam.y=editor.cam.y-8 end
if key.press(key.DOWN) then editor.cam.y=editor.cam.y+8 end
end
if btnp(KEY_F) then
if key.press(key.F) then
editor.floodfill(tx,ty,editor.brush.tiles[1])
end
if btnp(KEY_1) then
if key.press(key.N1) then
if editor.editing_front_layer then
editor.editing_front_layer=nil
else
editor.editing_front_layer=true
end
end
if btnp(KEY_RETURN) then
editor.brush.tiles[1]=mget(tx,ty)
if key.press(key.RETURN) then
editor.brush.tiles[1]=map.tile(tx,ty)
end
if btnp(KEY_ESCAPE) then
if key.press(key.ESCAPE) then
editor.paused=true
editor.show_menu()
end
if btnp(KEY_TAB) then
if key.press(key.TAB) then
update=editor.update_tileset
end
end
end,
update_tileset=function()
cls()
blit(0,0,128,128,0,0)
surf.cls()
draw.surf(0,0,128,128,0,0)
local mx,my=mouse()
local mx,my=mouse.pos()
local tx,ty=mx>>3,my>>3
local rx,ry=tx<<3,ty<<3
rect(rx-1, ry-1, rx+8, ry+8, 10)
draw.rect(rx-1, ry-1, 10, 10, 10)
if btnp(KEY_TAB) or btnp(KEY_ESCAPE) then
if key.press(key.TAB) or key.press(key.ESCAPE) then
update=editor.update
end
if mbtnp(1) then
if mouse.press(mouse.LEFT) then
if tx<16 and ty<16 then
editor.brush.w=1
editor.brush.h=1
@@ -280,5 +304,7 @@ editor={
mapa.load(filename)
editor.editing_front_layer=nil
editor.paused=false
editor.cam.x=0
editor.cam.y=0
end
}

45
data/eui.map Normal file
View File

@@ -0,0 +1,45 @@
86
42
1
41,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,43,
32,144,144,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,144,144,34,
32,137,137,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,137,137,34,
32,192,137,137,137,137,179,180,137,137,181,193,194,137,137,137,137,137,192,137,181,161,162,137,137,137,137,137,137,137,181,161,162,137,137,137,137,137,179,180,137,181,161,162,137,137,137,137,137,137,137,137,137,161,162,181,137,137,137,137,192,137,137,161,162,181,137,137,137,137,137,137,137,161,162,181,137,179,180,137,137,137,137,137,192,34,
32,208,141,143,142,153,153,153,153,153,153,209,210,153,153,73,74,75,208,153,153,177,178,153,153,73,74,75,153,153,153,177,178,153,153,73,74,75,153,153,153,153,177,178,153,153,153,73,74,75,153,153,153,177,178,153,153,73,74,75,208,153,153,177,178,153,153,73,74,75,153,153,153,177,178,153,153,153,153,153,141,143,142,153,208,34,
32,224,174,159,175,16,16,16,16,16,16,16,16,16,16,19,20,21,224,16,16,16,16,16,16,19,20,21,16,16,16,16,16,16,16,19,20,21,16,16,16,16,16,16,16,16,16,19,20,21,16,16,16,16,16,16,16,19,20,21,224,16,16,16,16,16,16,19,20,21,16,16,16,16,16,16,16,16,16,16,174,159,175,16,224,34,
32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,34,
32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,34,
32,246,16,16,16,16,245,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,246,16,16,16,16,245,34,
32,196,17,17,17,17,196,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,196,17,17,17,17,196,34,
32,196,17,17,17,17,196,100,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,101,196,17,17,17,17,196,34,
32,196,17,17,17,17,196,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,196,17,17,17,17,196,34,
32,196,18,18,18,18,196,116,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,117,196,18,18,18,18,196,34,
32,196,18,18,18,18,196,144,144,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,183,184,144,144,144,144,183,184,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,144,144,196,18,18,18,18,196,34,
32,196,17,17,17,17,196,137,137,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,145,146,137,137,137,137,145,146,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,137,137,196,17,17,17,17,196,34,
32,198,17,17,17,17,198,137,137,137,137,137,137,137,137,137,137,161,162,181,137,137,137,137,137,137,137,179,180,161,162,181,137,137,137,137,137,137,137,225,226,192,137,137,192,241,242,137,137,111,124,137,137,137,181,161,162,137,137,137,137,137,137,192,137,137,181,161,162,179,180,137,137,137,137,137,137,137,137,198,17,17,17,17,198,34,
32,214,17,17,17,17,214,153,153,73,74,75,153,153,153,160,153,177,178,153,153,153,153,73,74,75,153,153,153,177,178,153,153,153,153,153,153,153,153,177,178,208,153,153,208,177,178,153,153,127,140,160,153,153,153,177,178,153,153,153,73,74,75,208,153,153,153,177,178,153,153,153,73,74,75,153,153,153,153,214,17,17,17,17,214,34,
32,230,16,16,16,16,230,16,16,19,20,21,16,16,16,176,16,16,16,16,16,16,16,19,20,21,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,224,16,16,224,16,16,16,16,189,190,176,16,16,16,16,16,16,16,16,19,20,21,224,16,16,16,16,16,16,16,16,19,20,21,16,16,16,16,230,16,16,16,16,230,34,
32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,34,
32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,34,
32,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,246,16,16,16,16,245,246,16,16,16,16,245,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,244,244,244,228,34,
32,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,196,17,17,17,17,196,196,17,17,17,17,196,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,213,213,213,229,34,
148,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,196,17,17,17,17,196,196,17,17,17,17,196,100,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,149,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,196,17,17,17,17,196,196,17,17,17,17,196,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
41,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,196,18,18,18,18,196,196,18,18,18,18,196,116,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,43,
32,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,183,184,144,144,183,184,144,144,196,18,18,18,18,196,196,18,18,18,18,196,183,184,183,184,183,184,144,144,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,183,184,144,144,144,144,144,144,144,144,34,
32,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,145,146,137,137,145,146,137,137,196,17,17,17,17,196,196,17,17,17,17,196,145,146,145,146,145,146,137,137,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,145,146,137,137,137,137,137,137,137,137,34,
32,192,137,137,137,137,137,137,137,161,162,181,137,137,137,137,179,180,137,161,162,181,137,137,137,137,137,137,137,241,242,137,137,225,226,137,137,198,17,17,17,17,197,197,17,17,17,17,198,185,186,187,188,185,186,179,180,137,137,137,137,137,137,137,181,161,162,137,137,137,137,137,137,137,181,161,162,179,180,137,137,137,137,137,192,34,
32,208,73,74,75,153,153,153,160,177,178,153,153,73,74,75,153,153,153,177,178,153,153,73,74,75,153,153,153,177,178,153,160,177,178,153,153,214,17,17,17,17,213,213,17,17,17,17,214,153,153,153,153,153,153,153,153,153,73,74,75,153,153,153,153,177,178,153,153,73,74,75,153,153,153,177,178,153,153,73,74,75,153,153,208,34,
32,224,19,20,21,16,16,16,176,16,16,16,16,19,20,21,16,16,16,16,16,16,16,19,20,21,16,16,16,16,16,16,176,16,16,16,16,230,16,16,16,16,16,16,16,16,16,16,230,16,16,16,16,16,16,16,16,16,19,20,21,16,16,16,16,16,16,16,16,19,20,21,16,16,16,16,16,16,16,19,20,21,16,16,224,34,
32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,34,
32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,34,
148,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,101,16,16,16,16,29,30,16,16,16,16,29,30,16,16,16,16,100,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,149,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,16,16,16,16,132,133,16,16,16,16,132,133,16,16,16,16,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,16,16,16,16,132,133,16,16,16,16,132,133,16,16,16,16,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,16,16,16,16,132,133,16,16,16,16,132,133,16,16,16,16,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,16,16,16,16,132,133,16,16,16,16,132,133,16,16,16,16,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,16,16,16,16,174,175,16,16,16,16,174,175,16,16,16,16,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,48,49,49,49,49,64,16,16,16,16,16,16,65,49,49,49,49,50,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,

56
data/exterior.map Normal file
View File

@@ -0,0 +1,56 @@
63
53
1
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,41,42,42,42,42,42,42,42,42,42,42,42,42,42,42,43,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,232,233,196,232,233,232,233,232,233,232,233,196,232,233,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
41,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,117,49,49,196,49,49,49,49,49,49,49,49,196,49,49,116,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,43,33,
32,137,137,196,137,137,137,137,137,137,196,137,137,137,137,137,137,196,137,137,137,137,137,152,232,233,196,232,233,232,233,232,233,232,233,196,232,233,138,137,137,137,137,137,196,137,137,137,137,137,137,196,137,137,137,137,137,137,196,137,137,34,33,
32,137,137,196,137,137,137,137,137,137,196,137,137,137,137,137,137,196,137,137,137,137,137,152,231,231,196,231,231,231,0,0,231,231,231,196,231,231,138,137,137,137,137,137,196,137,137,137,137,137,137,196,137,137,137,137,137,137,196,137,137,34,33,
32,137,137,196,137,137,231,231,137,137,196,137,137,231,231,137,137,196,137,137,231,231,137,152,247,247,196,247,247,247,0,0,247,247,247,196,247,247,138,137,231,231,137,137,196,137,137,231,231,137,137,196,137,137,231,231,137,137,196,137,137,34,33,
32,137,137,196,137,137,247,247,137,137,196,137,137,247,247,137,137,196,137,137,247,247,137,152,22,22,22,22,22,22,22,22,22,22,22,22,22,22,138,137,247,247,137,137,196,137,137,247,247,137,137,196,137,137,247,247,137,137,196,137,137,34,33,
32,213,213,196,213,213,213,213,213,213,196,213,213,213,213,213,213,196,213,213,213,213,213,213,22,22,22,22,22,22,22,22,22,22,22,22,22,22,213,213,213,213,213,213,196,213,213,213,213,213,213,196,213,213,213,213,213,213,196,213,213,34,33,
32,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,34,33,
32,22,22,22,22,22,22,22,22,22,22,22,22,27,28,22,22,22,22,22,22,22,22,22,22,27,28,22,22,22,22,22,22,22,22,27,28,22,22,22,22,22,22,22,22,22,22,27,28,22,22,22,22,22,22,22,22,22,22,22,22,34,33,
32,22,22,22,22,22,22,22,22,22,22,22,22,236,237,22,22,22,22,22,22,22,22,22,22,236,237,22,22,22,22,22,22,22,22,236,237,22,22,22,22,22,22,22,22,22,22,236,237,22,22,22,22,22,22,22,22,22,22,22,22,34,33,
32,22,22,22,22,22,22,22,22,22,22,22,22,252,253,22,22,22,22,239,22,239,22,239,22,252,253,22,22,22,22,22,22,22,22,252,253,22,239,22,239,22,239,22,22,22,22,252,253,22,22,22,22,22,22,22,22,22,22,22,22,34,33,
32,22,22,22,22,22,22,22,22,22,22,22,22,222,223,22,22,22,22,255,22,255,22,255,22,222,223,22,22,22,22,22,22,22,22,222,223,22,255,22,255,22,255,22,22,22,22,222,223,22,22,22,22,22,22,22,22,22,22,22,22,34,33,
32,22,22,27,28,22,22,23,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,23,22,22,27,28,22,22,34,33,
32,22,22,236,237,22,22,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,23,22,22,236,237,22,22,34,33,
32,22,22,252,253,22,22,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,23,22,22,252,253,22,22,34,33,
32,22,22,222,223,22,22,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,23,22,22,222,223,22,22,34,33,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,
32,22,22,27,28,22,22,23,24,24,24,24,24,24,24,24,23,22,22,27,28,22,22,100,102,102,102,102,102,102,102,102,102,102,102,102,102,102,101,22,22,27,28,22,22,23,24,24,24,24,24,24,24,24,23,22,22,27,28,22,22,34,33,
32,22,22,236,237,22,22,23,24,24,24,24,24,24,24,24,23,22,22,236,237,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,236,237,22,22,23,24,24,24,24,24,24,24,24,23,22,22,236,237,22,22,34,33,
32,22,22,252,253,22,22,23,24,24,24,24,24,24,24,24,23,22,22,252,253,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,252,253,22,22,23,24,24,24,24,24,24,24,24,23,22,22,252,253,22,22,34,33,
32,22,22,222,223,22,22,23,24,24,24,24,24,24,24,24,23,22,22,222,223,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,222,223,22,22,23,24,24,24,24,24,24,24,24,23,22,22,222,223,22,22,34,33,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,
32,22,22,27,28,22,22,23,24,24,24,24,24,24,24,24,23,22,22,27,28,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,27,28,22,22,23,24,24,24,24,24,24,24,24,23,22,22,27,28,22,22,34,33,
32,22,22,236,237,22,22,23,24,24,24,24,24,24,24,24,23,22,22,236,237,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,236,237,22,22,23,24,24,24,24,24,24,24,24,23,22,22,236,237,22,22,34,33,
32,22,22,252,253,22,22,23,24,24,24,24,24,24,24,24,23,22,22,252,253,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,252,253,22,22,23,24,24,24,24,24,24,24,24,23,22,22,252,253,22,22,34,33,
32,22,22,222,223,22,22,23,24,24,24,24,24,24,24,24,23,22,22,222,223,22,22,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,22,22,222,223,22,22,23,24,24,24,24,24,24,24,24,23,22,22,222,223,22,22,116,42,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,116,42,42,42,42,42,42,42,42,42,42,42,42,42,42,117,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,55,56,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,196,232,233,232,233,232,233,232,233,232,233,232,233,232,233,196,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,55,56,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,196,232,233,232,233,232,233,232,233,232,233,232,233,232,233,196,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,55,56,
32,22,22,27,28,22,22,23,24,24,24,24,24,24,24,24,23,22,22,27,28,22,22,196,213,213,229,213,213,229,213,213,229,213,213,229,213,213,196,22,22,27,28,22,22,23,24,24,24,24,24,24,24,24,23,22,22,27,28,22,22,71,72,
32,22,22,236,237,22,22,23,24,24,24,24,24,24,24,24,23,22,22,236,237,22,22,196,213,213,229,213,213,231,0,0,231,213,213,229,213,213,196,22,22,236,237,22,22,23,24,24,24,24,24,24,24,24,23,22,22,236,237,22,22,22,22,
32,22,22,252,253,22,22,23,24,24,24,24,24,24,24,24,23,22,22,252,253,22,22,196,182,182,182,182,182,247,0,0,247,182,182,182,182,182,196,22,22,252,253,22,22,23,24,24,24,24,24,24,24,24,23,22,22,252,253,22,22,22,22,
32,22,22,222,223,22,22,23,24,24,24,24,24,24,24,24,23,22,22,222,223,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,222,223,22,22,23,24,24,24,24,24,24,24,24,23,22,22,222,223,22,22,22,22,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,100,102,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,239,22,239,22,239,22,239,22,22,22,22,22,22,22,22,22,22,22,22,22,22,239,22,239,22,239,22,239,23,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,34,33,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,23,255,22,255,22,255,22,255,22,22,22,22,22,22,22,22,22,22,22,22,22,22,255,22,255,22,255,22,255,23,24,24,24,24,24,24,24,24,23,239,22,22,22,22,22,34,33,
32,22,22,27,28,22,22,23,24,24,24,24,24,24,24,24,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,24,24,24,24,24,24,24,24,23,255,22,27,28,22,22,34,33,
32,22,22,236,237,22,22,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,23,22,22,236,237,22,22,34,33,
32,22,22,252,253,22,22,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,23,239,22,252,253,22,22,34,33,
32,22,22,222,223,22,22,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,23,255,22,222,223,22,22,116,42,
32,22,22,22,22,22,22,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,23,22,22,22,22,22,22,55,56,
32,22,22,22,22,22,22,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,25,22,22,22,22,22,22,55,56,
32,22,22,22,22,22,22,22,27,28,22,22,22,22,22,22,22,22,22,27,28,22,22,22,22,22,22,22,22,22,27,28,22,22,22,22,22,22,22,22,22,27,28,22,22,22,22,22,22,22,22,22,27,28,22,22,22,22,22,22,22,55,56,
32,22,22,22,22,22,22,22,236,237,22,22,22,22,22,22,22,22,22,236,237,22,22,22,22,22,22,22,22,22,236,237,22,22,22,22,22,22,22,22,22,236,237,22,22,22,22,22,22,22,22,22,236,237,22,22,22,22,22,22,22,71,72,
32,22,22,22,22,22,22,22,252,253,22,22,22,22,22,22,22,22,22,252,253,22,22,22,22,22,22,22,22,22,252,253,22,22,22,22,22,22,22,22,22,252,253,22,22,22,22,22,22,22,22,22,252,253,22,22,22,22,22,22,22,22,22,
32,22,22,22,22,22,22,22,222,223,22,22,22,22,22,22,22,22,22,222,223,22,22,22,22,22,22,22,22,22,222,223,22,22,22,22,22,22,22,22,22,222,223,22,22,22,22,22,22,22,22,22,222,223,22,22,22,22,22,22,22,22,22,
32,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,
148,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,

View File

@@ -9,7 +9,7 @@ fade={
init = function()
for i=1,16 do
local r,g,b=palcolor(i)
local r,g,b=pal.color(i)
fade.pal[i]={r,g,b}
end
end,
@@ -38,13 +38,13 @@ fade={
end,
update_fadeout=function()
if beat() then
if sys.beat() then
for i=1,16 do
local v=fade.getstep(i,fade.step)
if v==0 then
palcolor(i,0,0,0)
pal.color(i,0,0,0)
else
palcolor(i,fade.pal[v][1],fade.pal[v][2],fade.pal[v][3])
pal.color(i,fade.pal[v][1],fade.pal[v][2],fade.pal[v][3])
end
end
fade.step=fade.step+1
@@ -66,19 +66,19 @@ fade={
fade.old_update=update
update=fade.update_fadein
fade.step=6
for i=1,16 do palcolor(i,0,0,0) end
for i=1,16 do pal.color(i,0,0,0) end
end,
update_fadein=function()
fade.old_update()
if beat() then
if sys.beat() then
for i=1,16 do
local v=fade.getstep(i,fade.step)
if v==0 then
palcolor(i,0,0,0)
pal.color(i,0,0,0)
else
palcolor(i,fade.pal[v][1],fade.pal[v][2],fade.pal[v][3])
pal.color(i,fade.pal[v][1],fade.pal[v][2],fade.pal[v][3])
end
end
fade.step=fade.step-1

78
data/fileselect.lua Normal file
View File

@@ -0,0 +1,78 @@
fileselect={
file_list={},
selected=1,
title=nil,
old_update=nil,
return_function=nil,
old_mx=-1, old_my=-1,
show=function(title, retfun, extension)
fileselect.file_list = {}
for dir in io.popen([[ls data | grep ]] .. extension):lines() do
fileselect.file_list[#fileselect.file_list+1] = dir
end
fileselect.selected=1
fileselect.title=title
fileselect.old_update=update
update=fileselect.update
fileselect.return_function=retfun
if fileselect.value==nil then fileselect.value="" end
end,
update=function()
draw.rectf(10,10, 140, 120,5)
draw.rect(10,10, 140, 120,8)
if fileselect.title then draw.text(fileselect.title,20,13,8) end
draw.rectf(20,20, 120, 100,6)
local i = 22
for k,dir in pairs(fileselect.file_list) do
local color=8
if k==fileselect.selected then
draw.rectf(20,i-1, 120, 8,11)
color=15
end
draw.text(dir, 23, i, color)
i=i+7
end
draw.rect(20,20, 120, 100,8)
local mx,my=mouse.pos()
if (mx~=fileselect.old_mx or my~=fileselect.old_my) then
fileselect.old_mx,fileselect.old_my=mx,my
if mx>20 and mx<140 and my>20 and my<120 then
local y = math.floor((my-21)/7)+1
if (y<=#fileselect.file_list) then
fileselect.selected = y
end
end
end
if mouse.press(mouse.LEFT) then
if mx>20 and mx<140 and my>20 and my<120 then
local y = math.floor((my-21)/7)+1
if (y<=#fileselect.file_list) then
fileselect.selected = y
update=fileselect.old_update
fileselect.return_function(fileselect.file_list[fileselect.selected])
end
end
end
-- if textbox.value then
-- draw.text(textbox.value,43,73)
-- if (math.floor(time()*4)%2)==0 then
-- draw.text("_",43+#textbox.value*4,73)
-- end
-- end
--
local tecla=key.press()
if tecla==key.DOWN then
if fileselect.selected < #fileselect.file_list then fileselect.selected = fileselect.selected + 1 end
elseif tecla==key.UP then
if fileselect.selected > 1 then fileselect.selected = fileselect.selected - 1 end
-- elseif tecla==KEY_BACKSPACE then
-- textbox.value=string.sub(textbox.value,1,-2)
elseif tecla==key.RETURN then
update=fileselect.old_update
fileselect.return_function(fileselect.file_list[fileselect.selected])
end
end
}

View File

@@ -3,4 +3,3 @@ config=ja2
width=160
height=144
zoom=4
files=brymode.lua,fade.lua,objects.lua,wait.lua,switches.lua,scene.lua,balloon.lua,actors.lua,game.lua,mapa.lua,editor.lua,textbox.lua,menu.lua,m_arq.lua,m_prac3.lua,m_prac2.lua,m_prac1.lua,m_jail1.lua,main.lua

View File

@@ -14,14 +14,29 @@ require "m_prac1"
require "m_prac2"
require "m_prac3"
require "m_repro"
require "m_vella"
require "m_exterior"
require "m_eui"
game={
cam={x=0,y=0},
restart=function()
flags={}
objects.list={}
actors.main={name="jailer",x=9,y=14,o="u",gfx={x=32,y=0},level="repro"}
game.init("repro")
--actors.main={name="jailer",x=43,y=25,o="u",gfx={x=32,y=0},level="vella"}
--game.init("vella")
actors.main={name="jailer",x=12,y=12,o="r",jailmoji="AHDJONAAAAFAACFBBO",level="arq"}
game.init("arq")
end,
startfromeditor=function(s_level, s_x, s_y)
flags={}
objects.list={}
actors.main={name="jailer",x=s_x,y=s_y,o="d",jailmoji="AHDJONAAAAFAACFBBO",level=s_level}
game.init(s_level)
--actors.main={name="jailer",x=8,y=12,o="l",gfx={x=32,y=0},level="arq"}
--game.init("arq")
end,
init=function(levelname,f,objs)
@@ -33,17 +48,22 @@ game={
actors.init()
switches.reset()
if actors.main.level==levelname then
actors.add({name=actors.main.name,x=actors.main.x,y=actors.main.y,o=actors.main.o,gfx=actors.main.gfx})
actors.add({name=actors.main.name,x=actors.main.x,y=actors.main.y,o=actors.main.o,jailmoji=actors.main.jailmoji})
end
levels[game.level].load()
if game.paused then
game.resume()
else
if not game.paused then
update=game.update
end
game.resume()
actors.sort()
if levels[game.level].init_scene then
if not flags.escena_inicial then
game.update()
levels[game.level].init_scene()
end
end
fade.fadein()
end,
@@ -56,9 +76,17 @@ game={
}, game.resume)
end,
show_debug_menu=function()
game.pause()
menu.show({ {"EDIT FROM HERE", editor.editfrom},
{"CARREGAR PARTIDA", game.load},
{"EIXIR", main_init},
}, game.resume)
end,
save=function()
local i=1
file = io.open(configfolder().."slot"..i..".txt", "w")
file = io.open(config.folder().."slot"..i..".txt", "w")
if file then
io.output(file)
io.write("level="..game.level.."\n")
@@ -81,7 +109,7 @@ game={
load=function()
local i=1
file = io.open(configfolder().."slot"..i..".txt", "r")
file = io.open(config.folder().."slot"..i..".txt", "r")
local level_name = ""
local new_flags={}
local new_objects={}
@@ -92,7 +120,7 @@ game={
local k,v=getkeyval(io.read()) actors.main.x=tonumber(v)
local k,v=getkeyval(io.read()) actors.main.y=tonumber(v)
local k,v=getkeyval(io.read()) actors.main.o=v
io.read() -- ignore "[FLAGS]" line
local ignore = io.read() -- ignore "[FLAGS]" line
local line = io.read()
while line ~= "[OBJECTS]" do
local k,v=getkeyval(line)
@@ -115,17 +143,17 @@ game={
end,
draw=function()
cls(6)
camera(game.cam.x, game.cam.y)
setsource(tiles)
setmap(mapa.surface)
map(0,0,0,0,mapa.w, mapa.h)
surf.cls(6)
view.origin(-game.cam.x, -game.cam.y)
surf.source(tiles)
map.surf(mapa.surface)
map.draw()--map(0,0,0,0,mapa.w, mapa.h)
switches.draw();
setsource(sprites)
if btn(KEY_LSHIFT) then subpal(1,16,8) end
actors.draw()
subpal()
local mx,my=mouse()
surf.source(sprites)
if key.down(key.LSHIFT) then pal.subpal(1,16,8) end
actors.display()
pal.subpal()
local mx,my=mouse.pos()
if actors.under_cursor~="" then
if (mx<=80) then
text(actors.under_cursor,mx+game.cam.x+4,my+game.cam.y+4,9)
@@ -135,13 +163,13 @@ game={
end
end
if mapa.front_layer then
setsource(tiles)
setmap(mapa.front_layer)
map(0,0,0,0,mapa.w, mapa.h)
surf.source(tiles)
map.surf(mapa.front_layer)
map.draw() -- map(0,0,0,0,mapa.w, mapa.h)
end
setmap(mapa.surface)
camera(0,0)
for i=0,15 do rectfill(20+i*4,0,20+i*4+4,4,i) end
map.surf(mapa.surface)
view.origin(0,0)
for i=0,15 do draw.rectf(20+i*4,0,4,4,i) end
end,
update=function()
@@ -159,7 +187,7 @@ game={
game.draw()
local mx,my=mouse()
local mx,my=mouse.pos()
text(math.floor((mx+game.cam.x)/8)..","..math.floor((my+game.cam.y)/8),1,19,8)
text(game.cam.x..","..game.cam.y,1,1,8)
@@ -169,37 +197,39 @@ game={
text(game.level,1,13,8)
if not scene.script and hero and not hero.path and hero.dx+hero.dy==0 then
if btn(KEY_DOWN) then
if key.down(key.DOWN) then
hero.path={pos=0,route='d',keys=true}
elseif btn(KEY_UP) then
elseif key.down(key.UP) then
hero.path={pos=0,route='u',keys=true}
elseif btn(KEY_LEFT) then
elseif key.down(key.LEFT) then
hero.path={pos=0,route='l',keys=true}
elseif btn(KEY_RIGHT) then
elseif key.down(key.RIGHT) then
hero.path={pos=0,route='r',keys=true}
elseif btnp(KEY_SPACE) then
elseif key.press(key.SPACE) then
actors.interact(hero.x,hero.y,hero.o)
end
end
if btnp(KEY_ESCAPE) then
if key.press(key.ESCAPE) then
game.show_menu()
elseif key.press(key.TAB) then
game.show_debug_menu()
end
if beat() then actors.update() end
if sys.beat() then actors.update() end
end,
pause=function()
game.paused = true
rectfill(9,84, 150, 128,6)
rect(9,84, 150, 128,8)
rect(8,83, 151, 129,6)
draw.rectf(9,84, 141, 44,6)
draw.rect(9,84, 141, 44,8)
draw.rect(8,83, 143, 46,6)
text("OBJECTES:",14,82,8)
setsource(objectes)
surf.source(objectes)
local x,y=15,90
for i,name in ipairs(objects.list) do
local obj = object[name]
blit(obj.x,obj.y,16,16,x,y)
draw.surf(obj.x,obj.y,16,16,x,y)
x=x+19
if x==148 then x,y=15,y+19 end
end

View File

@@ -1,21 +1,21 @@
30
18
1
17,25,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,27,
17,16,23,24,23,24,23,24,23,24,23,24,23,24,23,24,23,24,30,23,24,23,24,23,24,23,24,23,24,18,
17,16,39,40,39,40,39,40,39,40,39,40,39,40,39,40,39,40,46,39,40,39,40,39,40,39,40,39,40,18,
17,16,55,56,55,56,55,56,55,56,55,56,55,56,55,56,55,56,62,55,56,55,56,55,56,55,56,55,56,18,
17,16,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,60,5,2,5,2,5,2,5,2,5,2,18,
17,16,87,88,89,90,5,2,87,88,89,90,5,2,87,88,89,90,60,87,88,89,90,5,2,87,88,89,90,18,
17,16,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,60,5,2,5,2,5,2,5,2,5,2,18,
17,16,87,88,89,90,5,2,87,88,89,90,5,2,64,65,66,65,67,87,88,89,90,5,2,87,88,89,90,18,
17,16,5,2,5,2,5,2,5,2,5,2,5,2,80,81,82,81,83,5,2,5,2,5,2,5,2,5,2,18,
17,16,87,88,89,90,5,2,87,88,89,90,5,2,112,68,69,70,113,87,88,89,90,5,2,87,88,89,90,18,
17,16,5,2,5,2,5,2,5,2,5,2,5,2,96,87,89,90,96,5,2,5,2,5,2,5,2,5,2,18,
17,16,87,88,89,90,5,2,87,88,89,90,5,2,5,2,5,2,5,5,2,5,2,5,2,87,88,89,90,18,
17,16,5,2,5,2,5,2,5,2,5,2,5,2,61,2,5,2,61,5,2,5,2,5,2,5,2,5,2,18,
17,16,87,88,89,90,5,2,87,88,89,90,5,2,60,2,5,2,60,5,2,5,2,5,2,87,88,89,90,18,
17,16,5,2,5,2,5,2,5,2,5,2,5,2,60,2,5,2,60,5,2,5,2,5,2,5,2,5,2,18,
17,32,33,33,33,48,5,2,49,33,33,48,5,2,49,33,33,33,33,33,48,5,2,49,33,33,33,33,33,34,
17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,
17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,
33,41,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,43,
33,32,39,40,39,40,39,40,39,40,39,40,39,40,39,40,39,40,46,39,40,39,40,39,40,39,40,39,40,34,
33,32,55,56,55,56,55,56,55,56,55,56,55,56,55,56,55,56,62,55,56,55,56,55,56,55,56,55,56,34,
33,32,71,72,71,72,71,72,71,72,71,72,71,72,71,72,71,72,78,71,72,71,72,71,72,71,72,71,72,34,
33,32,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,76,5,2,5,2,5,2,5,2,5,2,34,
33,32,103,104,105,106,5,2,103,104,105,106,5,2,103,104,105,106,76,103,104,105,106,5,2,103,104,105,106,34,
33,32,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,76,5,2,5,2,5,2,5,2,5,2,34,
33,32,103,104,105,106,5,2,103,104,105,106,5,2,80,81,82,81,83,103,104,105,106,5,2,103,104,105,106,34,
33,32,5,2,5,2,5,2,5,2,5,2,5,2,96,97,98,97,99,5,2,5,2,5,2,5,2,5,2,34,
33,32,103,104,105,106,5,2,103,104,105,106,5,2,128,84,85,86,129,103,104,105,106,5,2,103,104,105,106,34,
33,32,5,2,5,2,5,2,5,2,5,2,5,2,112,103,105,106,112,5,2,5,2,5,2,5,2,5,2,34,
33,32,103,104,105,106,5,2,103,104,105,106,5,2,5,2,5,2,5,5,2,5,2,5,2,103,104,105,106,34,
33,32,5,2,5,2,5,2,5,2,5,2,5,2,77,2,5,2,77,5,2,5,2,5,2,5,2,5,2,34,
33,32,103,104,105,106,5,2,103,104,105,106,5,2,76,2,5,2,76,5,2,5,2,5,2,103,104,105,106,34,
33,32,5,2,5,2,5,2,5,2,5,2,5,2,76,2,5,2,76,5,2,5,2,5,2,5,2,5,2,34,
33,48,49,49,49,64,5,2,65,49,49,64,5,2,65,49,49,49,49,49,64,5,2,65,49,49,49,49,49,50,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,

327
data/jailmoji.lua Normal file
View File

@@ -0,0 +1,327 @@
jailmoji={
MAX_COLOR=16,
MAX_BASE=3,
MAX_CHIN=8,
MAX_NOSE=9,
MAX_EARS=1,
MAX_EYES=7,
MAX_BROWS=4,
MAX_HAIR=11,
MAX_BAG=3,
surface=-1,
gendata={},
generate=function(genstring)
if genstring then
for i=1,#genstring do jailmoji.gendata[i]=genstring:byte(i)-65 end
end
local surf_base = surf.load("actor-base.gif")
local surf_hair = surf.load("actor-hair.gif")
local surf_chin = surf.load("actor-chin.gif")
local surf_nose = surf.load("actor-nose.gif")
local surf_eyes = surf.load("actor-eyes.gif")
local surf_brows = surf.load("actor-brows.gif")
local surf_bag = surf.load("actor-bag.gif")
if jailmoji.surface ~= -1 then surf.free(jailmoji.surface) end
jailmoji.surface = surf.new(32,48)
surf.target(jailmoji.surface)
pal.subpal(20,jailmoji.gendata[2]+1) -- vestit1
pal.subpal(21,jailmoji.gendata[3]+1) -- vestit2
pal.subpal(22,jailmoji.gendata[4]+1) -- sabates
pal.subpal(24,jailmoji.gendata[5]+1) -- pell1
pal.subpal(25,jailmoji.gendata[6]+1) -- pell2
pal.subpal(23,jailmoji.gendata[15]+1) -- monyo
pal.subpal(26,jailmoji.gendata[11]+1) -- ulls
pal.subpal(27,jailmoji.gendata[13]+1) -- celles
pal.subpal(28,jailmoji.gendata[17]+1) -- motxilla1
pal.subpal(29,jailmoji.gendata[18]+1) -- motxilla2
surf.source(surf_base)
local dx=jailmoji.gendata[1]*32
draw.surf(dx,0,32,48,0,0)
surf.source(surf_bag)
local dx=jailmoji.gendata[16]*6
draw.surf(dx,0,6,5,5,25)
draw.surf(dx,0,6,5,21,26)
draw.surf(dx,5,6,5,8,41)
draw.surf(dx+3,5,2,2,27,42)
surf.source(surf_hair)
local dx=jailmoji.gendata[14]*16
draw.surf(dx,0,16,48,0,0)
draw.surf(dx,0,16,48,16,1)
surf.source(surf_eyes)
local dx=jailmoji.gendata[10]*4
draw.surf(dx,0,4,2,4,7,4,2,true)
draw.surf(dx,0,4,2,8,7)
draw.surf(dx,0,4,2,20,8,4,2,true)
draw.surf(dx,0,4,2,24,8)
draw.surf(dx,0,4,2,4,38)
draw.surf(dx,0,4,2,20,39)
surf.source(surf_brows)
local dx=jailmoji.gendata[12]*2
draw.surf(dx,0,2,2,5,6,2,2,true)
draw.surf(dx,0,2,2,9,6)
draw.surf(dx,0,2,2,21,7,2,2,true)
draw.surf(dx,0,2,2,25,7)
draw.surf(dx,0,2,2,5,37)
draw.surf(dx,0,2,2,21,38)
surf.source(surf_chin)
local dx=jailmoji.gendata[7]*8
draw.surf(dx,0,8,4,4,9)
draw.surf(dx,0,8,4,20,10)
draw.surf(dx,4,8,4,1,40)
draw.surf(dx,4,8,4,17,41)
surf.source(surf_nose)
local dx=jailmoji.gendata[8]*4
draw.surf(dx,4,4,4,6,7)
draw.surf(dx,4,4,4,22,8)
draw.surf(dx,0,4,4,0,37)
draw.surf(dx,0,4,4,16,38)
pal.subpal()
surf.target(0)
end,
get=function(genstring)
jailmoji.generate(genstring)
local surf = jailmoji.surface
jailmoji.surface = -1
return surf
end,
update_text=function()
jailmoji.editor.str=""
for i=1,#jailmoji.gendata do jailmoji.editor.str = jailmoji.editor.str .. string.char(jailmoji.gendata[i]+65) end
end,
random=function()
local str=""
str = str .. string.char(math.random(jailmoji.MAX_BASE+1)+64)
str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
--str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
--str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
local pell = {{"O","N"}, {"N","J"}, {"J","J"}} local r = math.random(#pell)
str = str .. pell[r][1] .. pell[r][2]
str = str .. string.char(math.random(jailmoji.MAX_CHIN+1)+64)
str = str .. string.char(math.random(jailmoji.MAX_NOSE+1)+64)
str = str .. string.char(math.random(jailmoji.MAX_EARS+1)+64)
str = str .. string.char(math.random(jailmoji.MAX_EYES+1)+64)
--str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
local ulls = {"B","C","D","E","F","G","I","K","L"} r = math.random(#ulls)
str = str .. ulls[r]
str = str .. string.char(math.random(jailmoji.MAX_BROWS+1)+64)
--str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
local celles = {"E","F","G","H","J"} r = math.random(#celles)
str = str .. celles[r]
str = str .. string.char(math.random(jailmoji.MAX_HAIR+1)+64)
--str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
local monyo = {"D","E","F","G","H","J","N","O"} r = math.random(#monyo)
str = str .. monyo[r]
str = str .. string.char(math.random(jailmoji.MAX_BAG+1)+64)
str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
str = str .. string.char(math.random(jailmoji.MAX_COLOR+1)+64)
jailmoji.generate(str)
jailmoji.update_text()
end,
editor={
old_update=nil,
view=0,
animated=false,
changed=false,
str="",
show=function()
jailmoji.editor.old_update=update
update=jailmoji.editor.update
--jailmoji.surface = surf.load("actor-base.gif")
jailmoji.generate("AABJONAAAAEAAAEAAB")
end,
text_button=function(x, y, label, current_value, own_value)
local rect,color = draw.rect, 8
local mx,my = mouse.pos()
if current_value==own_value then rect,color = draw.rectf, 5 else rect,color = draw.rect, 8 end
rect(x,y,9,9,8)
draw.text(label,x+3,y+2,color)
if mx>=x and mx<x+9 and my>=y and my<y+9 and mouse.press(mouse.LEFT) then return own_value end
return current_value
end,
spin_button=function(x, y, current_value, max_value)
local rect,color = draw.rect, 8
local mx,my = mouse.pos() --mx,my = view.tolocal(mx,my)
local hover = mx>=x and mx<x+9 and my>=y and my<y+9
local clicked = hover and mouse.down(mouse.LEFT)
local label = string.char(current_value + 65)
if clicked then rect,color = draw.rectf, 5 else rect,color = draw.rect, 8 end
rect(x,y,9,9,8)
draw.text(label,x+3,y+2,color)
if hover then
if mouse.press(mouse.LEFT) then
jailmoji.editor.changed = true
if current_value+1 > max_value then
return 0
else
return current_value+1
end
elseif mouse.press(mouse.RIGHT) then
jailmoji.editor.changed = true
if current_value == 0 then
return max_value
else
return current_value-1
end
end
end
return current_value
end,
color_button=function(x, y, current_value)
local c1,c2,c3 = current_value+1,6,8
local mx,my = mouse.pos() --mx,my = view.tolocal(mx,my)
local hover = mx>=x and mx<x+9 and my>=y and my<y+9
local clicked = hover and mouse.down(mouse.LEFT)
if clicked then c1,c2,c3 = 6,6,8 end
draw.rectf(x,y,9,9,c1) draw.rect(x+1,y+1,7,7,c2) draw.rect(x,y,9,9,c3)
if hover then
if mouse.press(mouse.LEFT) then
jailmoji.editor.changed = true
if current_value+1 > 15 then
return 0
else
return current_value+1
end
elseif mouse.press(mouse.RIGHT) then
jailmoji.editor.changed = true
if current_value == 0 then
return 15
else
return current_value-1
end
end
end
return current_value
end,
update=function()
local self = jailmoji.editor
draw.rectf(10,10, 140, 100,5)
draw.rectf(10,10, 140, 10,9)
draw.rect(10,10, 140, 100,8)
draw.text("JAILMOJI EDITOR",14,13,8)
draw.rectf(19,23, 50, 50,7)
draw.rect(19,23, 50, 50,8)
surf.source(jailmoji.surface)
local vx = 0 if self.animated then vx = 16 end
local vy = self.view * 16
draw.surf(vx,vy,16,16,28,32,32,32)
local rect,color = draw.rect, 8
local mx,my = mouse.pos()
self.view=self.text_button(19,74,"F",self.view, 0)
self.view=self.text_button(29,74,"B",self.view, 1)
self.view=self.text_button(39,74,"S",self.view, 2)
self.animated=self.text_button(60,74,"A",self.animated, not self.animated)
view.origin(70,23)
draw.text("Vestit:",1,2,8)
jailmoji.gendata[1] = self.spin_button(28,0,jailmoji.gendata[1],jailmoji.MAX_BASE)
jailmoji.gendata[2] = self.color_button(38,0,jailmoji.gendata[2])
jailmoji.gendata[3] = self.color_button(48,0,jailmoji.gendata[3])
jailmoji.gendata[4] = self.color_button(58,0,jailmoji.gendata[4])
draw.text("Pell:",1,12,8)
jailmoji.gendata[5] = self.color_button(28,10,jailmoji.gendata[5])
jailmoji.gendata[6] = self.color_button(38,10,jailmoji.gendata[6])
draw.text("Cara:",1,22,8)
jailmoji.gendata[7] = self.spin_button(28,20,jailmoji.gendata[7],jailmoji.MAX_CHIN)
jailmoji.gendata[8] = self.spin_button(38,20,jailmoji.gendata[8],jailmoji.MAX_NOSE)
jailmoji.gendata[9] = self.spin_button(48,20,jailmoji.gendata[9],jailmoji.MAX_EARS)
draw.text("Ulls:",1,32,8)
jailmoji.gendata[10] = self.spin_button(28,30,jailmoji.gendata[10],jailmoji.MAX_EYES)
jailmoji.gendata[11] = self.color_button(38,30,jailmoji.gendata[11])
jailmoji.gendata[12] = self.spin_button(48,30,jailmoji.gendata[12],jailmoji.MAX_BROWS)
jailmoji.gendata[13] = self.color_button(58,30,jailmoji.gendata[13])
draw.text("Monyo:",1,42,8)
jailmoji.gendata[14] = self.spin_button(28,40,jailmoji.gendata[14],jailmoji.MAX_HAIR)
jailmoji.gendata[15] = self.color_button(38,40,jailmoji.gendata[15])
draw.text("Motxilla:",1,52,8)
jailmoji.gendata[16] = self.spin_button(38,50,jailmoji.gendata[16],jailmoji.MAX_BAG)
jailmoji.gendata[17] = self.color_button(48,50,jailmoji.gendata[17])
jailmoji.gendata[18] = self.color_button(58,50,jailmoji.gendata[18])
view.origin(0,0)
if jailmoji.editor.changed then
jailmoji.editor.changed = false
jailmoji.generate()
jailmoji.update_text()
--self.str=""
--for i=1,#jailmoji.gendata do self.str = self.str .. string.char(jailmoji.gendata[i]+65) end
end
draw.rectf(19,88, 122, 9,7)
draw.rect(19,88, 122, 9,8)
draw.text(self.str,21,90,8)
--local mx,my = mouse.pos() --mx,my = view.tolocal(mx,my)
-- 'COPY' button
draw.rectf(19,98, 24, 9,9)
draw.rect(19,98, 24, 9,8)
draw.text("COPY",23,100,8)
if mx>=19 and mx<19+24 and my>=98 and my<98+9 and mouse.press(mouse.LEFT) then
sys.clipboard(self.str)
end
-- 'RANDOM' button
draw.rectf(65,98, 31, 9,2)
draw.rect(65,98, 31, 9,8)
draw.text("RANDOM",69,100,8)
if mx>=65 and mx<65+32 and my>=98 and my<98+9 and mouse.press(mouse.LEFT) then
jailmoji.random()
end
-- 'EXIT' button
draw.rectf(116,98, 25, 9,10)
draw.rect(116,98, 25, 9,8)
draw.text("EIXIR",119,100,8)
if mx>=116 and mx<116+25 and my>=98 and my<98+9 and mouse.press(mouse.LEFT) then
if self.old_update then
update = self.old_update
else
surf.source(0)
surf.cls(0)
show_main_menu()
end
end
end,
},
}

View File

@@ -1,16 +1,16 @@
levels["arq"]={
load=function()
mapa.load("test.map")
mapa.load("arq.map")
actors.add({name="prohibit1",x=6,y=10,o="d",gfx={x=192,y=48},action=levels.arq.prohibit_action})
actors.add({name="prohibit2",x=12,y=10,o="d",gfx={x=192,y=48},action=levels.arq.prohibit_action})
actors.add({name="tallat1",x=0,y=11,o="d",gfx={x=208,y=48},action=levels.arq.tallat_action})
actors.add({name="tallat2",x=0,y=12,o="d",gfx={x=208,y=48},action=levels.arq.tallat_action})
actors.add({name="tallat3",x=0,y=13,o="d",gfx={x=208,y=48},action=levels.arq.tallat_action})
--actors.add({name="tallat1",x=0,y=11,o="d",gfx={x=208,y=48},action=levels.arq.tallat_action})
--actors.add({name="tallat2",x=0,y=12,o="d",gfx={x=208,y=48},action=levels.arq.tallat_action})
--actors.add({name="tallat3",x=0,y=13,o="d",gfx={x=208,y=48},action=levels.arq.tallat_action})
actors.add({name="estudiant1",x=18,y=11,o="r",gfx={x=0,y=48},action=levels.arq.estudiant1_action})
actors.add({name="estudiant2",x=16,y=12,o="l",gfx={x=128,y=0},action=levels.arq.estudiant2_action})
actors.add({name="estudiant2",x=14,y=12,o="l",gfx={x=128,y=0},action=levels.arq.estudiant2_action})
actors.add({name="estudiant3",x=34,y=25,o="r",gfx={x=128,y=48},action=levels.arq.estudiant3_action})
actors.add({name="estudiant4",x=27,y=25,o="d",gfx={x=0,y=64},action=levels.arq.estudiant4_action})
@@ -28,6 +28,9 @@ levels["arq"]={
actors.add({name="tablo_aula2",x=24,y=24,o="",action=levels.arq.tablo_aula2_action})
actors.add({name="tablo_aula3",x=4,y=24,o="",action=levels.arq.tablo_aula3_action})
actors.add({name="maquina_cafe",x=62,y=5,o="",action=levels.arq.maquina_cafe_action})
actors.add({name="maquina_exp",x=60,y=5,o="",action=levels.arq.maquina_exp_action})
if not flags.prac3 or not flags.prac2 or not flags.prac1 then
actors.add({name="alutablo1",x=3,y=25,o="d",gfx={x=32,y=64}})
actors.add({name="alutablo2",x=5,y=25,o="d",gfx={x=16,y=96},action=levels.arq.alutablo_action})
@@ -38,6 +41,42 @@ levels["arq"]={
actors.add({name="alutablo7",x=3,y=27,o="d",gfx={x=0,y=96}})
end
switches.add({x=0,y=11,w=1,h=3,action=
function()
local hero = actors.search(actors.main.name)
if hero.o=="l" then
game.paused = true
fade.fadeout()
actors.main.x=61
actors.main.y=36
actors.main.o="l"
actors.main.level="exterior"
game.init("exterior")
return true
else
return false
end
end
})
switches.add({x=0,y=25,w=1,h=3,action=
function()
local hero = actors.search(actors.main.name)
if hero.o=="l" then
game.paused = true
fade.fadeout()
actors.main.x=61
actors.main.y=50
actors.main.o="l"
actors.main.level="exterior"
game.init("exterior")
return true
else
return false
end
end
})
switches.add({x=32,y=25,w=1,h=1,action=
function()
local hero = actors.search(actors.main.name)
@@ -128,6 +167,24 @@ levels["arq"]={
end
})
switches.add({x=66,y=3,w=4,h=1,action=
function()
local hero = actors.search(actors.main.name)
if hero.o=="u" then
game.paused = true
fade.fadeout()
actors.main.x=6
actors.main.y=33
actors.main.o="u"
actors.main.level="vella"
game.init("vella")
return true
else
return false
end
end
})
switches.add({x=6,y=25,w=1,h=3,action=
function()
if not flags.prac3 or flags.prac3<2 then
@@ -141,23 +198,31 @@ levels["arq"]={
end
end
})
end,
prohibit_action=function()
if not flags.jail_tancada_llegit then
flags.jail_tancada_llegit=1
init_scene=function()
flags.escena_inicial=1
scene.start({
function() wait.start(1) end,
function() actors.face("estudiant2", "jailer") scene.cont() end,
function() balloon.show("QUE GANES DE SEGUIR\nAMB EL JAILGAME!",2,"jailer",false,{x=4,w=12,h=2}) end,
function() balloon.show("ME'L VAIG DEIXAR EN\nUN DISKITO EN UN\nCOMP DE LA JAIL",2,"jailer",false,{x=4,w=12,h=3}) end,
function() balloon.show("SEGUR QUE ENCARA ESTÀ!\nDINS DEL COMP",12,"estudiant2",false,{x=2,w=13,h=2}) end,
function() balloon.show("ANEM A ENTRAR\n A LA JAIL!",12,"estudiant2",false,{x=5,w=10,h=2}) end,
function() actors.search("estudiant2").o='u' scene.cont() end,
function() actors.moveto("jailer", 12, 11) end,
function() balloon.show("PERO QUÉ...",2,"jailer",false,{x=4,w=8,h=1}) end,
function() balloon.show("'JAIL CERRADA POR\nACTUALIZACIONES\n¡TU MISMO!'",2,"jailer",false,{x=2,w=10,h=3}) end,
function() balloon.show("AÇÒ ES COSA D'USUFONDO!\nSERÀ MAMÓ!",2,"jailer",false,{x=2,w=14,h=2}) end,
function() balloon.show("HE DE TROBAR LA\nFORMA D'ACONSEGUIR\nEL MEU DISKITO...",2,"jailer",false,{x=2,w=11,h=3}) end,
function() actors.search("estudiant2").o='l' scene.cont() end,
})
else
end,
prohibit_action=function()
scene.start({
function() balloon.show("LA JAIL 1\nCONTINUA TANCADA...",2,"jailer",false,{x=4,w=12,h=2}) end,
})
end
end,
tallat_action=function()
@@ -267,4 +332,42 @@ levels["arq"]={
function() balloon.show("AULA 1: CMC\nAULA 2: ALG\nAULA 3: TCO",2,"jailer",false,{x=3,w=8,h=3}) end,
})
end,
maquina_cafe_action=function()
if not objects.collected("moneda") then
scene.start({
function() balloon.show("EI!\nMÀQUINA DE CAFE!",2,"jailer",true,{x=6,w=10,h=2}) end,
function() balloon.show("ME ANE A FERME\nUN CORTAET...",2,"jailer",true,{x=6,w=9,h=2}) end,
function() balloon.show(" AAAAAAAAAAAAAH!!!",15,"jailer",true,{x=3,w=14,h=1}) end,
function() balloon.show("ESPERA UN MOMENT...",2,"jailer",true,{x=4,w=12,h=1}) end,
function() balloon.show("SI RESULTA QUE\nNO TINC SOLT!",2,"jailer",true,{x=6,w=9,h=2}) end,
function() balloon.show("MERDA DE MÁQUINA!",2,"jailer",true,{x=5,w=11,h=1}) end,
})
else
scene.start({
function() balloon.show("NO VAIG A USAR\nESTA MÀQUINA...",2,"jailer",true,{x=6,w=10,h=2}) end,
function() balloon.show("NO SOC UN\nDESAPRENSIU!!",2,"jailer",true,{x=6,w=9,h=2}) end,
})
end
end,
maquina_exp_action=function()
if not objects.collected("moneda") then
if not objects.collected("moneda2") then
scene.start({
function() balloon.show("NO DUC MONEDES...",2,"jailer",true,{x=5,w=11,h=1}) end,
})
else
scene.start({
function() objects.leave("moneda2") scene.cont() end,
function() objects.collect("rosquilletes") end,
})
end
else
scene.start({
function() balloon.show("PASSE...\nNOMÉS QUEDEN\nROSQUILLETES",2,"jailer",true,{x=6,w=9,h=3}) end,
})
end
end,
}

24
data/m_eui.lua Normal file
View File

@@ -0,0 +1,24 @@
levels["eui"]={
load=function()
mapa.load("eui.map")
switches.add({x=40,y=41,w=6,h=1,action=
function()
local hero = actors.search(actors.main.name)
if hero.o=="d" then
game.paused = true
fade.fadeout()
actors.main.x=30
actors.main.y=6
actors.main.o="d"
actors.main.level="exterior"
game.init("exterior")
return true
else
return false
end
end
})
end,
}

42
data/m_exterior.lua Normal file
View File

@@ -0,0 +1,42 @@
levels["exterior"]={
load=function()
mapa.load("exterior.map")
switches.add({x=61,y=35,w=1,h=3,action=
function()
local hero = actors.search(actors.main.name)
if hero.o=="r" then
game.paused = true
fade.fadeout()
actors.main.x=0
actors.main.y=12
actors.main.o="r"
actors.main.level="arq"
game.init("arq")
return true
else
return false
end
end
})
switches.add({x=30,y=6,w=1,h=1,action=
function()
local hero = actors.search(actors.main.name)
if hero.o=="u" then
game.paused = true
fade.fadeout()
actors.main.x=42
actors.main.y=41
actors.main.o="u"
actors.main.level="eui"
game.init("eui")
return true
else
return false
end
end
})
end,
}

View File

@@ -35,7 +35,7 @@ levels["repro"]={
switches.add({x=15,y=13,w=1,h=1,action=
function()
if not objects.collected("moneda") then table.insert(objects.list, "moneda") end
if not objects.collected("moneda2") then table.insert(objects.list, "moneda2") end
local hero = actors.search(actors.main.name)
if hero.o=="u" then
scene.start({
@@ -53,7 +53,7 @@ levels["repro"]={
currante1_action=function()
local hero = actors.search(actors.main.name)
flags.apuntes=1
--flags.apuntes=1
if not flags.apuntes then
scene.start({

81
data/m_vella.lua Normal file
View File

@@ -0,0 +1,81 @@
levels["vella"]={
load=function()
mapa.load("vella.map")
actors.add({name="taula1",x=7,y=13,o="d",gfx={x=224,y=48}})
actors.add({name="taula2",x=11,y=10,o="d",gfx={x=224,y=48}})
actors.add({name="taula3",x=9,y=6,o="d",gfx={x=224,y=48}})
actors.add({name="taula4",x=5,y=9,o="d",gfx={x=224,y=48}})
actors.add({name="taula5",x=19,y=7,o="d",gfx={x=224,y=48}})
actors.add({name="taula6",x=17,y=13,o="d",gfx={x=224,y=48}})
actors.add({name="taula7",x=13,y=28,o="d",gfx={x=224,y=48}})
actors.add({name="taula8",x=21,y=28,o="d",gfx={x=224,y=48}})
actors.add({name="taula_caixer",x=43,y=21,o="d",gfx={x=224,y=48},action=levels.vella.caixer_action})
actors.add({name="caixer",x=43,y=20,o="d",gfx={x=32,y=48}})
actors.add({name="comp_caixer",x=45,y=21,o="d",gfx={x=112,y=0}})
actors.add({name="alumne1",x=5,y=20,o="r",gfx={x=32,y=48},action=levels.vella.alumne1_action})
actors.add({name="alumne2",x=9,y=20,o="d",gfx={x=64,y=80},action=levels.vella.alumne1_action})
actors.add({name="alumne3",x=9,y=21,o="d",gfx={x=160,y=48},action=levels.vella.alumne1_action})
actors.add({name="alumne4",x=13,y=27,o="d",gfx={x=128,y=48},action=levels.vella.alumne1_action})
actors.add({name="alumne5",x=15,y=29,o="d",gfx={x=64,y=32},action=levels.vella.alumne1_action})
actors.add({name="alumne6",x=39,y=22,o="d",gfx={x=64,y=80},action=levels.vella.alumne1_action})
actors.add({name="alumne7",x=39,y=21,o="d",gfx={x=160,y=48},action=levels.vella.alumne1_action})
actors.add({name="alumne8",x=35,y=22,o="r",gfx={x=32,y=48},action=levels.vella.alumne1_action})
actors.add({name="cadira1",x=35,y=23,o="d",gfx={x=160,y=64}})
actors.add({name="cadira2",x=27,y=22,o="d",gfx={x=160,y=64}})
actors.add({name="alumne9",x=44,y=28,o="d",gfx={x=128,y=48}})
actors.add({name="alumne10",x=27,y=21,o="r",gfx={x=96,y=48},action=levels.vella.alumne1_action})
actors.add({name="alumne11",x=38,y=28,o="d",gfx={x=16,y=80}})
actors.add({name="alumne_cua1",x=27,y=25,o="d",gfx={x=16,y=64}})
actors.add({name="alumne_cua2",x=26,y=26,o="d",gfx={x=0,y=80}})
actors.add({name="alumne_cua3",x=26,y=27,o="d",gfx={x=0,y=64}})
switches.add({x=3,y=34,w=8,h=1,action=
function()
local hero = actors.search(actors.main.name)
if hero.o=="d" then
game.paused = true
fade.fadeout()
actors.main.x=67
actors.main.y=4
actors.main.o="d"
actors.main.level="arq"
game.init("arq")
return true
else
return false
end
end
})
end,
caixer_action=function()
--local hero = actors.search(actors.main.name)
--if hero.o~="d" then return end
scene.start({
function() balloon.show("BON DIA CARINYET!\nQUE VOLS MENJAR?",15,"caixer",false,{x=4,w=11,h=2}) end,
function() balloon.show("POS OBVIAMENT\nUN BOCADILL DE\nSOBRASADA PATA...",2,"jailer",true,{x=3,w=11,h=3}) end,
function() balloon.show("CLAR QUE SI,\nCARINYET!\nVAL UNA MONEDA!",15,"caixer",false,{x=4,w=11,h=3}) end,
function() balloon.show("NO DUC MONEDES...",2,"jailer",true,{x=3,w=11,h=1}) end,
function() balloon.show(" AH...",15,"caixer",false,{x=4,w=11,h=1}) end,
function() balloon.show("I PA QUE VENS\nA DEMANAR UN BOCATA\nSI NO DUS DINERS?",15,"caixer",false,{x=3,w=12,h=3}) end,
function() balloon.show("JO QUE SE...",2,"jailer",true,{x=3,w=11,h=1}) end,
function() balloon.show("ACÒ ES UNA AVENTURA,\nVAIG APRETANT-LI A TOT",2,"jailer",true,{x=3,w=13,h=2}) end,
function() balloon.show("AH, MOLT BE!\nPOS QUE TINGUES\nSORT, CARINYET!",15,"caixer",false,{x=4,w=10,h=3}) end,
})
end,
alumne1_action=function()
--local hero = actors.search(actors.main.name)
--if hero.o~="d" then return end
scene.start({
function() balloon.show("NO VAN ELS COMPS\nESTAN TOTS ACTUALITZANT",2,"jailer",true,{x=1,w=15,h=2}) end
})
end,
}

View File

@@ -2,42 +2,45 @@ require "fade"
require "game"
require "editor"
require "menu"
require "jailmoji"
function _init()
function mini.init()
menu_option=0
sprites=loadsurf("sprites.gif")
objectes=loadsurf("objects.gif")
tiles=loadsurf("tiles.gif")
setsource(tiles)
local pal=loadpal("tiles.gif")
setpal(pal)
beat(6)
objectes=surf.load("objects.gif")
tiles=surf.load("tiles.gif")
surf.source(tiles)
local p=pal.load("tiles.gif")
pal.set(p)
sprites=surf.load("sprites.gif")
sys.beat(6)
fade.init()
main_init()
end
function _update()
function mini.update()
update()
end
function text(txt,x,y,col)
color(6)
prnt(txt,x-1,y-1)
prnt(txt,x,y-1)
prnt(txt,x+1,y-1)
prnt(txt,x-1,y)
prnt(txt,x+1,y)
prnt(txt,x-1,y+1)
prnt(txt,x,y+1)
prnt(txt,x+1,y+1)
color(col)
prnt(txt,x,y)
draw.text(txt,x-1,y-1,6)
draw.text(txt,x,y-1,6)
draw.text(txt,x+1,y-1,6)
draw.text(txt,x-1,y,6)
draw.text(txt,x+1,y,6)
draw.text(txt,x-1,y+1,6)
draw.text(txt,x,y+1,6)
draw.text(txt,x+1,y+1,6)
draw.text(txt,x,y,col)
end
function main_init()
--set_update(menu_update)
second_menu = {{"PEIV", function() end},{"TORNAR",show_main_menu}}
main_menu = { {"JUGAR", game.restart}, {"EDITOR", editor.init}, {"EIXIR", quit}, {"TEST", function() menu.show(second_menu) end } }
main_menu = { {"JUGAR", game.restart},
{"EDITOR", editor.init},
{"JAILMOJI", jailmoji.editor.show},
{"EIXIR", sys.quit},
{"TEST", function() menu.show(second_menu) end } }
show_main_menu()
end
@@ -50,9 +53,8 @@ function set_update(new_update)
end
function menu_update()
cls()
color(1)
prnt("JAIL'S ADVENTURE 2",10,10)
surf.cls()
draw.text("JAIL'S ADVENTURE 2",10,10,1)
end
function getkeyval(str)

View File

@@ -2,19 +2,20 @@ mapa={
name=nil,
w=128,
h=128,
surface=nil,
surface=-1,
new = function(w,h)
mapa.name=nil
mapa.w,mapa.h=w,h
if mapa.surface~=nil then freesurf(mapa.surface) end
mapa.surface=newsurf(w,h)
setmap(mapa.surface)
if mapa.surface~=-1 then surf.free(mapa.surface) end
mapa.surface=surf.new(w,h)
map.surf(mapa.surface)
for y=0,127 do
for x=0,127 do
mset(x,y,0)
map.tile(x,y,0)
end
end
mapa.front_layer=nil
end,
load = function(filename)
@@ -31,25 +32,25 @@ mapa={
local line = io.read()
local x=0
for m in string.gmatch(line, "%d+") do
mset(x,y,m)
map.tile(x,y,m)
x=x+1
end
end
if num_layers==2 then
mapa.front_layer=newsurf(mapa.w,mapa.h)
setmap(mapa.front_layer)
mapa.front_layer=surf.new(mapa.w,mapa.h)
map.surf(mapa.front_layer)
for y=0,mapa.h-1 do
local line = io.read()
local x=0
for m in string.gmatch(line, "%d+") do
mset(x,y,m)
map.tile(x,y,m)
x=x+1
end
end
end
setmap(mapa.surface)
map.surf(mapa.surface)
io.close(file)
end
end,
@@ -62,18 +63,18 @@ mapa={
io.write(mapa.w.."\n")
io.write(mapa.h.."\n")
if mapa.front_layer then io.write("2\n") else io.write("1\n") end
setmap(mapa.surface)
map.surf(mapa.surface)
for y=0,mapa.h-1 do
for x=0,mapa.w-1 do
io.write(mget(x,y)..",")
io.write(map.tile(x,y)..",")
end
io.write("\n")
end
if mapa.front_layer then
setmap(mapa.front_layer)
map.surf(mapa.front_layer)
for y=0,mapa.h-1 do
for x=0,mapa.w-1 do
io.write(mget(x,y)..",")
io.write(map.tile(x,y)..",")
end
io.write("\n")
end
@@ -83,6 +84,6 @@ mapa={
end,
check_collision=function(x,y)
return mget(x,y) > 16 or mget(x+1,y) > 16
return map.tile(x,y) >= 32 or map.tile(x+1,y) >= 32
end
}

View File

@@ -15,35 +15,36 @@ menu = {
update=function()
--menu.old_update()
rectfill(9,20, 150, 34+#menu.options*10,6)
rect(9,20, 150, 34+#menu.options*10,8)
rect(8,19, 151, 35+#menu.options*10,6)
draw.rectf(9,20, 141, 14+#menu.options*10,6)
draw.rect(9,20, 141, 14+#menu.options*10,8)
draw.rect(8,19, 143, 16+#menu.options*10,6)
for i,v in ipairs(menu.options) do
color(4) if menu.selected==i then color(15) prnt(">",20,20+i*10) end
prnt(v[1],24,20+i*10)
local color=4
if menu.selected==i then color=15 draw.text(">",20,20+i*10,color) end
draw.text(v[1],24,20+i*10,color)
end
if btnp(KEY_DOWN) then menu.selected=menu.selected+1 end
if btnp(KEY_UP) then menu.selected=menu.selected-1 end
if key.press(key.DOWN) then menu.selected=menu.selected+1 end
if key.press(key.UP) then menu.selected=menu.selected-1 end
if menu.selected==0 then menu.selected=#menu.options end
if menu.selected>#menu.options then menu.selected=1 end
local mx,my=mouse()
local mx,my=mouse.pos()
if mx>=20 and mx<=140 and my>=28 and my<=(28+#menu.options*10) then
menu.selected=math.min(1+math.floor((my-28)/10),#menu.options)
if mbtnp(1) then
if mouse.press(mouse.LEFT) then
update=menu.old_update
menu.options[menu.selected][2]()
end
end
if btnp(KEY_RETURN) then
if key.press(key.RETURN) then
update=menu.old_update
menu.options[menu.selected][2]()
end
if btnp(KEY_ESCAPE) then
if key.press(key.ESCAPE) then
if menu.return_function then
update=menu.old_update
menu.return_function()

Binary file not shown.

Before

Width:  |  Height:  |  Size: 900 B

After

Width:  |  Height:  |  Size: 979 B

View File

@@ -37,5 +37,7 @@ object={
diskito_knunk={name="DISQUITO DE KNUNK",x=0,y=0},
diskito_usufondo={name="DISQUITO DE USUFONDO",x=16,y=0},
moneda={name="MONEDA",x=32,y=0},
moneda2={name="ALTRA MONEDA",x=32,y=0},
apuntes={name="APUNTES",x=48,y=0},
rosquilletes={name="ROSQUILLETES",x=64,y=0},
}

View File

@@ -1,21 +1,21 @@
20
18
1
17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,
17,17,17,25,26,26,26,26,26,26,26,26,26,26,26,26,27,17,17,17,
17,17,17,16,23,24,23,24,102,103,103,104,23,24,23,24,18,17,17,17,
17,17,17,16,39,40,39,40,118,119,119,120,39,40,39,40,18,17,17,17,
17,17,17,16,55,56,55,56,55,56,55,56,47,56,55,56,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,63,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,87,88,89,90,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,87,88,89,90,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,87,88,89,90,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,32,33,33,33,33,48,2,5,49,33,33,33,33,34,17,17,17,
17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,41,42,42,42,42,42,42,42,42,42,42,42,42,43,33,33,33,
33,33,33,32,39,40,39,40,118,119,119,120,39,40,39,40,34,33,33,33,
33,33,33,32,55,56,55,56,134,135,135,136,55,56,55,56,34,33,33,33,
33,33,33,32,71,72,71,72,71,72,71,72,63,72,71,72,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,79,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,103,104,105,106,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,103,104,105,106,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,103,104,105,106,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,48,49,49,49,49,64,2,5,65,49,49,49,49,50,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,

View File

@@ -1,21 +1,21 @@
20
18
1
17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,
17,17,17,25,26,26,26,26,26,26,26,26,26,26,26,26,27,17,17,17,
17,17,17,16,23,24,102,103,103,104,23,24,23,24,23,24,18,17,17,17,
17,17,17,16,39,40,118,119,119,120,39,40,39,40,39,40,18,17,17,17,
17,17,17,16,47,56,55,56,55,56,55,56,55,56,55,56,18,17,17,17,
17,17,17,16,63,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,87,88,89,90,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,87,88,89,90,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,87,88,89,90,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,87,88,89,90,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,32,33,33,33,33,33,33,33,48,2,5,49,33,34,17,17,17,
17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,41,42,42,42,42,42,42,42,42,42,42,42,42,43,33,33,33,
33,33,33,32,39,40,118,119,119,120,39,40,39,40,39,40,34,33,33,33,
33,33,33,32,55,56,134,135,135,136,55,56,55,56,55,56,34,33,33,33,
33,33,33,32,63,72,71,72,71,72,71,72,71,72,71,72,34,33,33,33,
33,33,33,32,79,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,103,104,105,106,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,103,104,105,106,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,103,104,105,106,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,103,104,105,106,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,48,49,49,49,49,49,49,49,64,2,5,65,49,50,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,

View File

@@ -1,21 +1,21 @@
20
18
1
17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,
17,17,17,25,26,26,26,26,26,26,26,26,26,26,26,26,27,17,17,17,
17,17,17,16,23,24,23,24,23,24,102,103,103,104,23,24,18,17,17,17,
17,17,17,16,39,40,39,40,39,40,118,119,119,120,39,40,18,17,17,17,
17,17,17,16,55,56,55,56,55,56,55,56,55,56,55,47,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,63,18,17,17,17,
17,17,17,16,5,2,87,88,89,90,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,87,88,89,90,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,87,88,89,90,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,87,88,89,90,5,2,5,2,87,88,89,90,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,
17,17,17,32,33,48,2,5,49,33,33,33,33,33,33,33,34,17,17,17,
17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,33,41,42,42,42,42,42,42,42,42,42,42,42,42,43,33,33,33,
33,33,33,32,39,40,39,40,39,40,118,119,119,120,39,40,34,33,33,33,
33,33,33,32,55,56,55,56,55,56,134,135,135,136,55,56,34,33,33,33,
33,33,33,32,71,72,71,72,71,72,71,72,71,72,71,63,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,79,34,33,33,33,
33,33,33,32,5,2,103,104,105,106,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,103,104,105,106,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,103,104,105,106,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,103,104,105,106,5,2,5,2,103,104,105,106,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,33,
33,33,33,48,49,64,2,5,65,49,49,49,49,49,49,49,50,33,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,

View File

@@ -1,21 +1,21 @@
20
18
1
17,17,25,26,26,26,26,26,26,26,26,26,26,26,26,26,26,27,17,17,
17,17,16,23,24,23,24,23,24,23,24,23,24,23,24,23,24,18,17,17,
17,17,16,41,42,39,40,39,40,99,99,79,40,99,99,79,40,18,17,17,
17,17,16,55,56,55,56,47,56,115,115,55,56,115,115,55,56,18,17,17,
17,17,16,5,2,5,2,63,2,99,99,5,2,99,99,5,2,18,17,17,
17,17,16,5,2,5,2,5,2,115,115,5,2,115,115,5,2,18,17,17,
17,17,16,87,88,89,90,5,2,99,99,5,2,99,99,5,2,18,17,17,
17,17,16,5,2,5,2,5,2,115,115,5,2,115,115,5,2,18,17,17,
17,17,16,14,15,105,106,5,2,131,131,5,2,131,131,5,2,18,17,17,
17,17,16,87,88,89,90,5,2,147,147,5,2,147,147,5,2,18,17,17,
17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,
17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,5,14,18,17,17,
17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,
17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,
17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,
17,17,16,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,
17,17,32,33,33,33,33,33,48,5,2,49,33,33,33,33,33,34,17,17,
17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,
33,33,41,42,42,42,42,42,42,42,42,42,42,42,42,42,42,43,33,33,
33,33,32,39,40,39,40,39,40,39,40,39,40,39,40,39,40,34,33,33,
33,33,32,57,58,55,56,55,56,115,115,95,56,115,115,95,56,34,33,33,
33,33,32,71,72,71,72,63,72,131,131,71,72,131,131,71,72,34,33,33,
33,33,32,5,2,5,2,79,2,115,115,5,2,115,115,5,2,34,33,33,
33,33,32,5,2,5,2,5,2,131,131,5,2,131,131,5,2,34,33,33,
33,33,32,103,104,105,106,5,2,115,115,5,2,115,115,5,2,34,33,33,
33,33,32,5,2,5,2,5,2,131,131,5,2,131,131,5,2,34,33,33,
33,33,32,14,15,121,122,5,2,147,147,5,2,147,147,5,2,34,33,33,
33,33,32,103,104,105,106,5,2,163,163,5,2,163,163,5,2,34,33,33,
33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,
33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,5,14,34,33,33,
33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,
33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,
33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,
33,33,32,5,2,5,2,5,2,5,2,5,2,5,2,5,2,34,33,33,
33,33,48,49,49,49,49,49,64,5,2,65,49,49,49,49,49,50,33,33,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.3 KiB

After

Width:  |  Height:  |  Size: 5.6 KiB

View File

@@ -25,7 +25,7 @@ switches={
text(#switches.list,1,25,8)
if switches.col<16 then
for i,v in ipairs(switches.list) do
rect(v.x*8, v.y*8, (v.x+v.w+1)*8-1, (v.y+v.h)*8-1, 8);
draw.rect(v.x*8, v.y*8, (v.w+1)*8, (v.h)*8, 8);
end
end
switches.col=(switches.col+1)%32

View File

@@ -1,32 +0,0 @@
73
29
1
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,25,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,101,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,23,24,23,24,23,24,19,20,21,22,23,24,23,24,23,24,23,24,23,24,23,24,23,24,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,39,40,39,40,39,40,35,36,75,76,79,40,39,40,39,40,41,42,39,40,107,108,77,78,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,47,56,57,58,59,56,51,52,91,92,55,56,57,58,59,56,55,56,47,56,123,124,93,94,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,63,2,7,8,9,2,5,2,5,2,5,2,7,8,9,2,5,2,63,2,139,140,109,110,5,2,5,2,5,2,5,2,18,
100,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,101,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,
28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,
23,24,23,24,19,20,21,22,23,24,19,20,21,22,23,24,23,24,23,24,19,20,21,22,23,24,23,24,23,24,23,24,19,20,21,22,23,24,23,24,5,2,5,2,5,2,5,2,84,86,86,86,86,86,86,86,86,86,86,86,86,86,86,85,5,2,5,2,5,2,5,2,18,
39,40,39,40,35,36,37,38,79,40,35,36,37,38,79,40,39,40,41,42,35,36,75,76,79,40,39,40,39,40,41,42,35,36,37,38,79,40,39,40,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
55,56,57,58,59,52,53,54,55,56,51,52,53,54,55,56,47,56,55,56,51,52,91,92,55,56,57,58,59,47,55,56,51,52,53,54,55,56,47,56,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
5,2,7,8,9,2,5,2,5,2,5,2,5,2,5,2,63,2,5,2,5,2,5,2,5,2,7,8,9,63,5,2,5,2,5,2,5,2,63,2,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
84,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,85,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,17,17,17,17,17,17,17,17,17,17,17,17,17,17,16,5,2,5,2,5,2,5,2,18,
100,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,26,101,5,2,5,2,5,2,5,2,100,26,26,26,26,26,26,26,26,26,26,26,26,26,26,101,5,2,5,2,5,2,5,2,18,
28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,5,2,5,2,5,2,5,2,28,29,28,29,28,29,28,29,28,29,28,29,28,29,28,29,5,2,5,2,5,2,5,2,18,
23,24,23,24,23,24,19,20,21,22,23,24,23,24,23,24,23,24,19,20,21,22,23,24,23,24,23,24,23,24,19,20,21,22,23,24,23,24,23,24,5,2,5,2,5,2,5,2,23,24,23,24,23,24,19,20,21,22,23,24,23,24,23,24,5,2,5,2,5,2,5,2,18,
39,40,39,40,41,42,35,36,75,76,79,40,39,40,39,40,39,40,35,36,75,76,79,40,41,42,39,40,39,40,35,36,75,76,79,40,41,42,39,40,5,2,5,2,5,2,5,2,39,40,39,40,41,42,35,36,75,76,79,40,39,40,39,40,5,2,5,2,5,2,5,2,18,
55,56,55,56,55,56,51,52,91,92,55,56,47,56,57,58,59,56,51,52,91,92,55,56,55,56,57,58,59,56,51,52,91,92,55,56,55,56,47,56,5,2,5,2,5,2,5,2,57,58,59,56,55,56,47,52,91,92,55,56,57,58,59,56,5,2,5,2,5,2,5,2,18,
5,2,5,2,5,2,5,2,5,2,5,2,63,2,7,8,9,2,5,2,5,2,5,2,5,2,7,8,9,2,5,2,5,2,5,2,5,2,63,2,5,2,5,2,5,2,5,2,7,8,9,2,5,2,63,2,5,2,5,2,7,8,9,2,5,2,5,2,5,2,5,2,18,
5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,
5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,5,2,18,
33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,34,

View File

@@ -15,25 +15,25 @@ textbox={
end,
update=function()
rectfill(20,50, 140, 90,6)
rect(20,50, 140, 90,8)
if textbox.title then prnt(textbox.title,30,55) end
rect(40,70, 120, 80,8)
draw.rectf(20,50, 120, 40,6)
draw.rect(20,50, 120, 40,8)
if textbox.title then draw.text(textbox.title,30,55,8) end
draw.rect(40,70, 80, 11,8)
if textbox.value then
prnt(textbox.value,43,73)
if (math.floor(time()*4)%2)==0 then
prnt("_",43+#textbox.value*4,73)
draw.text(textbox.value,43,73,8)
if (math.floor(sys.time()*4)%2)==0 then
draw.text("_",43+#textbox.value*4,73,8)
end
end
local tecla=btnp()
local tecla=key.press()
if tecla>=4 and tecla<=39 then
textbox.value=textbox.value..string.sub(keyvalues,tecla,tecla)
elseif tecla==KEY_PERIOD then
elseif tecla==key.PERIOD then
textbox.value=textbox.value.."."
elseif tecla==KEY_BACKSPACE then
elseif tecla==key.BACKSPACE then
textbox.value=string.sub(textbox.value,1,-2)
elseif tecla==KEY_RETURN then
elseif tecla==key.RETURN then
update=textbox.old_update
textbox.return_function(textbox.value)
end

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 4.3 KiB

73
data/vella.map Normal file
View File

@@ -0,0 +1,73 @@
52
35
2
33,33,41,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,43,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,153,153,153,153,153,153,153,153,153,153,153,153,153,153,153,153,153,153,153,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,10,11,157,158,10,11,10,11,10,11,10,11,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,157,158,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,157,158,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,10,11,10,11,157,158,10,11,10,11,10,11,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,157,158,10,11,10,11,10,11,10,11,157,158,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,148,102,102,102,102,102,102,102,101,10,11,10,11,100,102,102,102,102,102,102,149,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
33,33,41,42,42,42,42,42,42,42,117,10,11,10,11,116,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,42,43,
33,33,32,137,137,137,137,137,137,137,152,10,11,10,11,138,137,137,137,137,137,137,137,137,137,150,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,248,249,250,250,249,251,137,137,137,137,34,
33,33,32,137,137,137,137,137,137,137,152,10,11,10,11,138,137,137,137,137,137,137,137,91,92,150,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,111,124,179,180,179,180,137,137,137,137,34,
33,33,32,153,153,153,153,141,142,153,168,10,11,10,11,154,153,153,153,141,142,153,153,107,108,151,153,200,153,141,142,153,153,153,153,200,153,141,142,153,153,127,140,153,153,153,153,200,153,141,142,34,
33,33,32,10,11,10,11,132,133,10,11,10,11,10,11,10,11,10,11,132,133,10,11,10,11,169,11,217,218,132,133,10,11,10,11,217,218,132,133,10,11,189,190,10,11,141,142,217,218,132,133,34,
33,33,32,10,11,10,11,132,133,10,11,10,11,10,11,10,11,10,11,132,133,10,11,10,11,169,11,10,11,132,133,10,11,10,11,10,11,132,133,10,11,10,11,157,158,157,158,217,218,132,133,34,
33,33,32,10,11,10,11,132,133,10,11,10,11,10,11,10,11,10,11,132,133,10,11,10,11,170,11,10,11,132,133,10,11,10,11,10,11,132,133,10,11,10,11,10,11,10,11,217,218,132,133,34,
33,33,32,10,11,10,11,157,158,10,11,10,11,10,11,10,11,10,11,157,158,10,11,10,11,10,11,10,11,157,158,10,11,10,11,10,11,157,158,10,11,10,11,10,11,10,11,10,11,157,158,34,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,34,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,34,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,34,
33,33,32,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,34,
33,33,32,10,11,10,11,10,11,10,11,10,11,132,133,10,11,10,11,10,11,132,133,10,11,10,11,10,11,10,11,10,11,10,11,11,11,11,11,11,11,11,11,10,11,10,11,10,11,10,11,34,
33,33,32,10,11,10,11,10,11,10,11,10,11,132,133,10,11,10,11,10,11,132,133,10,11,150,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,34,
33,33,32,10,11,10,11,10,11,10,11,10,11,132,133,10,11,10,11,10,11,132,133,10,11,150,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,34,
33,33,32,10,11,10,11,10,11,10,11,10,11,132,133,10,11,10,11,10,11,132,133,10,11,150,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,10,11,34,
33,33,32,10,11,10,11,10,11,10,11,100,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,49,50,
33,33,32,10,11,10,11,10,11,10,11,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
33,33,32,10,11,10,11,10,11,10,11,34,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,167,0,0,0,0,0,0,0,0,164,0,0,0,0,0,0,0,167,0,0,0,0,0,0,0,0,0,0,0,164,167,0,
0,0,0,0,0,0,0,164,165,0,0,0,0,0,0,0,0,0,0,164,0,0,0,0,0,0,0,0,0,164,0,0,0,0,0,0,0,0,164,0,0,0,0,0,0,0,0,199,0,165,0,0,
0,0,0,0,0,0,0,0,167,0,0,0,0,0,0,0,0,0,0,164,0,0,0,0,0,0,0,0,0,166,167,0,0,0,0,0,0,164,165,0,0,0,0,0,0,0,0,199,0,164,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,234,235,234,235,234,235,234,235,234,235,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,166,165,0,0,0,0,0,0,0,0,0,0,150,243,243,243,243,243,243,243,243,243,243,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,164,0,0,0,0,0,0,167,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,166,166,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,164,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,

View File

@@ -7,12 +7,12 @@ wait={
wait.old_update=update
update=wait.update
wait.total_time=seconds
wait.start_time=time()
wait.start_time=sys.time()
end,
update=function()
wait.old_update()
if wait.total_time <= time()-wait.start_time then
if wait.total_time <= sys.time()-wait.start_time then
update=wait.old_update
scene.cont()
end