Skip to content

Commit

Permalink
Checked in some reference levels.
Browse files Browse the repository at this point in the history
This relates to issue #12.  I've assembled some reference levels that
can be used to verify the parser (at least for tile data).  This should
also help for adding support for the older ".graal" format.
  • Loading branch information
Aeva Palecek committed Dec 13, 2016
1 parent 080585d commit 63efbfb
Show file tree
Hide file tree
Showing 7 changed files with 226 additions and 0 deletions.
Binary file added reference_levels/blank.graal
Binary file not shown.
Binary file added reference_levels/blank2.graal
Binary file not shown.
Binary file added reference_levels/castlewarp.graal
Binary file not shown.
161 changes: 161 additions & 0 deletions reference_levels/castlewarp.nw
Original file line number Diff line number Diff line change
@@ -0,0 +1,161 @@
GLEVNW01
BOARD 0 0 64 0 J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4
BOARD 0 1 64 0 J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4
BOARD 0 2 64 0 J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4
BOARD 0 3 64 0 J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4
BOARD 0 4 64 0 J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J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4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4
BOARD 0 63 64 0 J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4J4
LINK fbathroom.graal 31 44 2 1 27.5 49
LINK staff1.graal 31 18 2 1 30.5 29
SIGN 0 0

---The Admin Tower---
SIGNEND
NPC - 34 28
// NPC made by <yourname>
if (playerenters) {
play dragonia.mid;
setbackpal pics1.png;
}
NPCEND
NPC - 30 31
// NPC made by Lunpa DaVinci
if (playerenters&&!lunpabeentoadmintower) {
set lunpabeentoadmintower;
say 0;
}
NPCEND
NPC servernpc.gif 1 2
// NPC made by Lunpa DaVinci
if (playerenters) {
putnpc nothing.gif,npcserver.txt,x,y;
hide;
}
NPCEND
NPC - 19 23
// NPC made by *Lunpa (DaVinci)
if (playerenters || wasthrown) {
// Initialize the this. variables
noplayerkilling;
dirgo = {0,-1,-1,0,0,1,1,0};
timeout = 0.05;
this.walkmode = 1;
if (wasthrown && this.walkmode>1) this.walkmode = 1;
this.x1 = 19;
this.x2 = 44;
this.y1 = 23;
this.y2 = 42;
this.speed = 0.3;
this.mode = 0;
sprite = 0;
this.runcounter = int(random(10,40));
}

// Walking stuff
if (timeout && this.mode==0) { // WALKING
playersprite = (playersprite%8)+1;
newx = playerx + dirgo[playerdir*2] * this.speed;
newy = playery + dirgo[playerdir*2+1] * this.speed;
this.runcounter--;
if (this.walkmode==1) { // RANDOM
if (this.runcounter>0) {
testx = newx + 1.5 + dirgo[playerdir*2];
testy = newy + 2+ dirgo[playerdir*2+1];
if (onwall(testx,testy)) {
playerdir = (playerdir+2)%4;
this.runcounter = int(random(0,60));
} else {
playerx = newx;
playery = newy;
}
} else {
this.runcounter = int(random(10,40));
playerdir = (playerdir+1+int(random(0,2))*2)%4;
}
} else if (this.walkmode==2) { // LEFTRIGHT
if (playerdir!=1 && playerdir!=3) playerdir = 3;
else {
playerx = newx;
playery = newy;
if ((playerdir==1 && x<=this.x1) || (playerdir==3 && x>=this.x2))
playerdir = (playerdir+2)%4;
}
} else if (this.walkmode==3) { // UPDOWN
if (playerdir!=0 && playerdir!=2) playerdir = 2;
else {
playerx = newx;
playery = newy;
if ((playerdir==0 && playery<=this.y1) || (playerdir==2 && playery>=this.y2))
playerdir = (playerdir+2)%4;
}
} else if (this.walkmode==4) { // RECTANGLE
playerx = newx;
playery = newy;
if ((playerdir==0 && playery<=this.y1) || (playerdir==1 && playerx<=this.x1) ||
(playerdir==2 && playery>=this.y2) || (playerdir==3 && playerx>=this.x2))
playerdir = (playerdir+3)%4;
}
if (this.walkmode>1 && this.runcounter<=0)
this.runcounter = 20;
message;
timeout = 0.05;
}
NPCEND
Binary file added reference_levels/castlewarp2.graal
Binary file not shown.
Binary file added reference_levels/test.graal
Binary file not shown.
Loading

0 comments on commit 63efbfb

Please sign in to comment.