1 ; *** WORM LEVELFILE ***
5 ;Sample levelfile with everything commented.
6 ;Teaches you everything to build your own level.
9 ;-----------------------------------------------------------------------------
11 ;Standard 128x57 FIELD:
13 ;(0,0)> |####(BORDER)#####|
19 ; |#################| <(127,56)
21 ;Drawable screen is (2,2)-(125,54); center is (63.5,28)
23 ;Screen will scroll with screensizes above 128x57 (max.256x256)
24 ;Example 256x80 FIELD (use 0,80):
25 ; +-----------------------------------+
26 ;(0,0)> |#############(BORDER)##############|
32 ; |#"""""""""""""""":""""""""""""""""#|
34 ; |###################################| <(255,255)
35 ; +-----------------------------------+
38 ;-----------------------------------------------------------------------------
40 ;DOUBLE CHECK THE FOLLOWING THINGS:
41 ; * correct name size at .org
42 ; * max. choosable level doesn't exeed actual levels present
43 ; * enough hiscore space (two bytes for each peaworm level!)
46 ;------------------------------- HEADER --------------------------------------
48 ;#include "asm86.h" ;use include files to make your own
49 ;#include "ti86asm.inc" ;singleplayer ending (just like normal asm)
52 .org $F3E3-10 ;$F3E3-[name size]
53 ;^^ <-MUST EQUAL NAME SIZE BELOW!!! If not, Worm will crash!
55 .db 'w',90 ;wormLevel header (version .90)
56 .db 10,"Example #1" ;name size (UPDATE .ORG!!!); level name
57 .dw hiscore-single ;leveldata size
62 .dw single ;points to singleplayer levels below
63 .dw peaworm ;...peaworm level
64 .dw deathmatch ;...deathmatch
65 .dw foodmatch ;...foodmatch
66 .dw linkmatch ;...linkmatch
68 .dw ctf ;...capture the flag
69 .dw domination ;...domination
71 ;note: use <.dw 0> if no levels present (empty level will be used).
73 .db 2,3,4,2 ;max. choosable level+1 for each gametype
74 .db 2,2,2,2 ;so: 2 = level 1 only; 4 = level 1 to 3 available
76 ;again .db 0 indicates no levels present.
79 ;------------------------------- LEVELS --------------------------------------
83 ; .db 5 ;nr. of peas in level
84 ; .db 4 ;delay (0=fastest, 4=normal)
85 ; .db 15 ;growth per pea
87 ; .db 4 ;sprite size (1-8; 0=use default sprite)
88 ; .db %01100000 ;the sprite
92 ; .db 2 ;bouncing balls (0-40)
93 ; .db 2 ;BALL #1: begin y-position
95 ; .db %00 ; direction (%00=right+down, %11=left+up)
96 ; .db 2,7,%00 ;BALL #2: y,x,direction
97 ; .db 0 ;your start direction (0=up,$40=right,$80=down,$C0=left)
98 ; .db 2 ;your y-position (2=at top)
99 ; .db 63 ;your x-position (63=center)
100 ; ;IN MULTIPLAYER LEVELS also set positions for worm 2-4:
101 ;(.db $C0,28,125 ) ;player 2 moves left
102 ;(.db $00, 2, 63 ) ;player 3 moves down
103 ;(.db $80,54, 63 ) ;player 4 moves up
105 ; .db 128,57 ;field size: width (128-255), height (57-255)
106 ; ; screen will SCROLL if size is more than 128,57
107 ; .db 2 ;number of lines:
108 ; .db 28,14,100,41 ;LINE #1 coordinates: (x1,y1)-(x2,y2)
109 ; .db 28,41,100,14 ;LINE #2: the same
110 ; .db 1 ;number of boxes:
111 ; .db 16,12,48,12 ;BOX #1: x1,y1,x2,ysize(y2-y1)
112 ;------------ ;THAT'S ALL; repeat for all levels
115 single: ;singleplayer levels start here
127 .db 0,0 ;no lines/boxes
133 .db 1 ;one horizontal line
137 .db 255 ;end marker: no more levels
139 ;Code to run when all levels are done:
140 ;Worm waits a second, then screen is cleared and this code will be run.
142 ret ;no end, quit and continue with stats-screen
144 ;This is a sample ending displaying "Congratulations!!" to use instead of RET:
146 ; call _puts ;display text
147 ; jp _getkey ;wait for a key and return (jp = call+ret)
149 ; .db " Congratulations!!",0
152 peaworm: ;peaworm levels (2)
171 deathmatch: ;deathmatch levels
173 .db $40,28,2 ;begin stats for each player
177 .db 128,57 ;field size
190 .db $40,30,2,$C0,30,125, $00,2,64,$80,54,64
197 .db $40,30,2,$C0,30,125, $00,2,64,$80,54,64
204 .db $40,3,2,$40,6,2, $40,9,2,$40,12,2
212 hiscore: ;space reserved to store hi-scores
213 .dw 0 ;singleplayer hiscore will be saved here
214 .dw 0,0 ;peaworm hiscore for each peaworm-level