updateboard x,y,width,height; | makes level board modifies visible - If the board has been modified (by a NPC) this will make the modification visible to the player (sort of like "refresh). |
if (playertouchsme){ updateboard x,y,2,2; } |
This will update the board at the NPC's x,y with a width and height of 2. |
loadmap string |
loads a map - This sets the game terrain to whatever
*.gmap is specified in "string". |
if (playerenters) { loadmap MyWorld; } |
When a player enters this level, the
NPC will set the player's level set to "MyWorld". There needs to
be a *.gmap file named "MyWorld" as well as a bunch of levels named
MyWorlda1.nw - MyWorld#X.nw |
updateterrain |
makes terrain modifications visible
- This will update .gmaps if the
terrain has been changed. |
if (actiondig){ Dig(); updateterrain; } |
This NPC will update the terrain of the
set *.gmap after the action "dig" has been triggered. |
putobject objectname,x,y; | puts an object onto the board - This will put the object of specified name at the specified x,y cordinates. Object names can be found in the level editor. |
if (exploded){ putobject Bush,x,y; } |
This will put a Bush at the NPC's x,y. |
putbomb power,x,y; | puts a bomb on the board - Puts a bomb at x,y the power specifies the type of bome (1=normal, 2=superbomb, 3=jolt bomb). |
if (playertouchsme){ putbomb 2,playerx,playery; } |
If the player touches the NPC, a superbomb will be put at the player's x,y. |
putexplosion radius,x,y; | puts an explosion on the board - Places and explosions on the board with the specified size and at the specified location. |
if (playertouchsme){ putexplosion 3,playerx,playery; } |
This will put an explosion with a radius of 3 at the player's x,y. |
putexplosion2 power,radius,x,y; | puts an explosion on the board - Puts an explosion at x,y with the specified radius using the specified fire type (1 regular, or 3 is jolt fire). |
if (washit){ putexplosion2 3,1,x,y; } |
When the npc is hit it will put a jolt explosion with a radius of 1 at the the npc's x,y. |
putleaps leaptype,x,y; | procduces an object 'explosion' (0-bush,1-swamp,2-stone,3-sign,4-ball,5-water) - This will put a "leap" at the specified location. An example of a leap is when you cut a bush, and those leaves shoot out, or when you jump in water and theres those splashes... both of those are leaps. And NPC can put these for graphical effect. |
if (weaponfired){ putleaps 2,playerx,playery; } |
When the NPC Weapon is fired, it'll put the stone leaps at the player's x,y. |
puthorse imgname,x,y; | puts a horse (or boat) on the board - This puts a horse on the level for the player to ride. If the x,y cordinates are in deep water, then the "horse" is considered a "boat" and can not be taken out of deep water. |
if (playerenters){ puthorse ride.gif,x,y; } |
Puts the horse "ride.gif" at the NPC's x,y. |
setletters filename; | signs will be displayed using the specified image instead of letters.png - Changes the letters displayed when a player reads a sign to those contained in the file specified. |
if (created){ setletters aceletters.gif; } |
This will set the letters of signs in the level to aceletters.gif. |
setmap imgname,levelnamesfile,x,y; | changes the map, the player will be placed on (x,y) - Changes the image displayed when the player pushes "M". Use this when making your own levels. The text file is a list of the levels included on the map. |
if (created){ setmap acemap.gif,acemap.txt,playerx,playery; } |
Sets the map information to acemap.gif, and acemap.txt. |
setminimap imgname,levelnamesfile,x,y; | changes the minimap, the player will be placed on (x,y) - This will change the mini-map to whatever you set here. Also useful when making your own levels. |
if (created){ setminimap aceminimap.gif,aceminimap.txt,playerx,playery; } |
Sets the mini-map info to aceminimap.gif and aceminimap.txt. |
seteffect red,green,blue,alpha | This changes the overlay color of the game. By adjusting "alpha" you can make the game darker or lighter (0=dark, 1=light) |
if (playerenters){ seteffect 0,0,255,.5; } |
Will give the level a dark blue color. |
setfocus x,y; | sets the focus - This will make the camera "look at" the specified x,y cords instead of the player |
if (timeout&&!onwall(imgx,imgy)){ setfocus imgx,imgy; timeout=.05; imgx++; imgy++; } |
So long as this NPCs timeout is going, and there is no wall at imgx,imgy then the camera will point at imgx,imgy. |
resetfocus | resets the focus - Makes the camera follow the player once again |
else if (onwall(imgx,imgy)){ resetfocus; } |
Since there was a wall at imgx,imgy then the focus will be reset to the player. (This is how "remote missles" work) |
showstats bitflag; | shows/hides parts of the stats bar (1-ASD, 2-icons, 4-rupees, 8-bombs, 16-arrows, 32-hearts, 64-ap, 128-mp, 256-minimap, 512-inv, 1024-player) - Hides the specified stats if already showing, or shows them if not. 0 will hide everything., where as all the above values added together shows eveything. |
if (weaponfired){ showstats 0; } |
Hides all the stats when the weapon is fired. |
noplayerkilling; | disables hurting with sword/npc weapons - Stops anyone from being hurt. |
if (created){ noplayerkilling; } |
Makes it so no one can be killed on the level. |
removebomb index; | removes the bomb with the specified index - Destroys the bomb. |
for (i=0;i<bombscount;i++){ if (bombs[i].x==playerx){ removebomb i; } } |
Of all the bombs on the level, which ever ones share the x cordinate with the player, than it'll be removed. |
removearrow index; | removes the arrow with the specified index - Destroys the arrow. |
for (i=0;i<arrowscount;i++){ if (arrows[i].dir==0){ removearrow i; } } |
Of all the arrows on the level, which ever ones are moving up (dir=0) then they will be removed. |
removeitem index; | removes the item with the specified index - Destroys the item. |
for (i=0;i<itemscount;i++){ if (items[i].type==18){ removeitem i; } } |
Of all the items on the level, which ever ones are of type 18 (a full heart) they will be removed. |
removeexplo index; | removes the explosion with the specified index - Destroys the explosion. |
for (i=0;i<exploscount;i++){ if (explos[i].time<=1){ removeexplo i; } } |
Of all the explosions on the level, which ever ones have less than or equal to 1 second left to disapear, will be removed. |
removehorse index; | removes the horse with the specified index - Destroys the horse. |
for (i=0;i<horsescount;i++){ if (horses[i].type==1){ removehorse i; } } |
Of all the horses on the level, which ever ones are of type 1 (a boat) will be removed. |
explodebomb index; | explodes the bomb with the specified index - Causes the specified bomb to explode. |
for (i=0;i<bombscount;i++){ if (bombs[i].power==2){ explodebomb i; } } |
If any bombs on screen are super bombs, then they'll be exploded. |
reflectarrow index; | reflects the arrow with the specified index (like a mirror shield) - Makes the arrow (or ball) go back from where it came. |
for (i=0;i<arrowscount;i++){ if (arrows[i].type==1){ reflectarrow i; } } |
This will cause any arrows that are type 1 (a fireball) to reflect back. |
disableselectweapons | disables the weapon select screen - This will prevent the player from being able to select his weapon. |
if (playerenters){ disableselectweapons; message Ha! I bet you wish you had a better weapon!; } |
This will make the player be stuck with whatever weapon he had selected when he entered the level. |
enableselectweapons | enables the weapon select screen - This allows the player to select his weapon again. |
if (playerdies){ enableselectweapons; } |
In this case if the player dies, then he will be allowed to select his own weapons again. |
addtiledef image,levelstart,type | specifys the tiles images for all levels that start with 'levelstart' (0-standard type,1-new order) - Replaces all the default tiles in the levels that begin with "levelstart" with the image specified. |
if (created){ addtiledef mytileset.png,aceslevels,0; } |
This will make all levels the have a filename that begins with "aceslevels" have the tileset "mytileset". |
addtiledef2 image,levelstart,x,y; | replaces parts of the tiles image - Allows you to choose only specific parts of the tileset to replace. |
if (playerenters){ addtiledef2 flower.png,thislevel,0,1; } |
This will replace the flower tile on pics1.png (the flower tile at 0,1) with the image flower.png. |
removetiledefs levelstart | removes tile definitions for levels that start with 'levelstart' - This undoes all tile definitions specified by the user for the levels beginning with "levelstart". |
if (playerdies){ removetiledefs aceslevels; } |
When the player dies, all the original tiles will be restored. |
hitobjects power,x,y; | hurts all players/npcs/baddies on that position - This will damage anything. Kind of like hitplayer and hitbaddy rolled into one. |
if (timeout){ timeout=.05; hitobjects 2,x,y; x++; } |
This is the script for a NPC that every .05 seconds it moves a tile to the right, but as it does so, it will hit any player, baddy, and npc that gets in its way. |