Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   Level Design (https://forums.graalonline.com/forums/forumdisplay.php?f=6)
-   -   Level editing FAQ's (https://forums.graalonline.com/forums/showthread.php?t=35370)

Graal2001_LAT 08-08-2002 10:24 AM

Level editing FAQ's
 
Okay, I have constructed a Level Editing FAQ. Please read this through before posting a new thread, because your answer could be here.


I will start with commands in the editor. (Training and then F4)

alt 0: Creates a log, which also shows people logging on / off
alt 1 : Takes a snapshot of the full level, not showing tiledefs, seteffects, or light effects.
alt 2: Takes a snapshot of the current screen, showing everything.
alt 3: Toggles the minimap on/off
alt 4: Toggles bitrate on/off [Only works online]
alt 5: Takes a snapshot of the level in .graal or .nw format.
alt 6: Records the players movements for scripting. [Does not work online.]
alt 7: Stops recording player movements and creates a recordpos.txt under the /levels directory. [Does not work online.]
alt 8: Zoom in.
alt 9: Zoom out.


For you people who are trying to add your own tileset you made, or add some custom tiles to the current tileset, look here.

addtiledef - This command replaces the whole tileset image with a brand new one. (remember the image has to be 256 colours (8 bit)) The code is this:
NPC Code:
addtiledef tilesetimage,0,0;


The first 0 meaning levelstart, so that say you have a world with level names myworld_1-100. You would put 'addtiledef tilesetimage,myworld_,0;' so that all your levels will have the new tileset. The second 0 is type, 0=normal pics1.png and 1=a newworld type tileset order.


addtiledef2 - This command just replaces part of the tileset image, sort of like putting an image on top of the base image. The code is:
NPC Code:
addtiledef2 tilesetimage,level name,x,y;


The x,y specifies where you want your image to go over the tileset.

Map tutorial

-The text file
You will need a text file with the levels ordered in it.
For example, name the file "bigmap.txt"
So, you open it, and write levels in it. You have a 4x4 map (4 by 4 levels). The levels are listed like this:
-----------------------------------
"mylevel_a-1.nw","mylevel_b-1.nw"
"mylevel_a-2.nw","mylevel_b-2.nw"
-----------------------------------
With the quotations.
That tells the graal.exe how to read your levels when you choose to generate a map.

-The Levels
Okay! We've written the text file, now to make the levels (and link them [not explained... I hope you have enough sense to figure it out!])
Make four levels, and name them

mylevel_a-1.nw
mylevel_b-1.nw
mylevel_a-2.nw
mylevel_b-2.nw

and place them in the same folder as the text file.
link them as needed.

Now, in Level-editting mode (f4) open the first level on your map press "M" and it will ask you if you want to generate a map. Select "yes" or "ok" or whatever, and it will eventually finish with an image asking to be named, sort of. Go to the folder that your levels and .txt are in, and save it. Boom, you have a map image.

To get your map and all the levels to link together, put the script
NPC Code:
setmap mapname.png,bigmap.txt,30,60;

in an NPC in the "starting" level.

Minimap: If you want a minimap just simply follow this: Anyway just take your map and resize it much smaller so that it looks appealing to you in the bottom left hand corner. From there add this code to your previous map script:
NPC Code:
setminimap mapname.png,bigmap.txt,playerx,playery;





If you do not understand any of this, post here and I will answer your question. Special thanks to Torankusu and Zakur for their contributions.

zell12 08-08-2002 10:28 AM

Spiffy Idea :)

Andor_RC14 08-08-2002 07:38 PM

Very very well put Mmmmkay. One thing about the map though, you don't have to create a blank .png img in there before the rest of it. I find that harder since I cant make a .png that is just 8bit

Torankusu 08-08-2002 10:51 PM

Quote:

Originally posted by Andor_RC14
Very very well put Mmmmkay. One thing about the map though, you don't have to create a blank .png img in there before the rest of it. I find that harder since I cant make a .png that is just 8bit
Uh, you have to or the script won't work and generate a map. There has to be an existing image, preferrably in 256 colors/8-bit.

zell12 08-08-2002 11:14 PM

When generating a map, it all you need is the levels in one folder and then press "m" in the editor, and it creates everything for you -_-

Graal2001_LAT 08-09-2002 03:17 AM

Quote:

Originally posted by Andor_RC14
Very very well put Mmmmkay. One thing about the map though, you don't have to create a blank .png img in there before the rest of it. I find that harder since I cant make a .png that is just 8bit
Torankusu made the map, I will edit it later to how I do it, which seems easier.

Torankusu 08-09-2002 03:22 AM

Quote:

Originally posted by zell12
When generating a map, it all you need is the levels in one folder and then press "m" in the editor, and it creates everything for you -_-
a text file is also needed, as well as an image. Or else you get an error in the NPC when you "test" it, thus, not allowing it to work.

Redwizard 08-10-2002 10:20 PM

1 Attachment(s)
My map is glitchy, I have no idea why... can somebody explain to me why it has glitches and stuff in stripes like my map here? It is sooooo ***, and if i look really closely it looks like millions of tilesets shrunk really small

Torankusu 08-11-2002 04:02 PM

Quote:

Originally posted by Redwizard
My map is glitchy, I have no idea why... can somebody explain to me why it has glitches and stuff in stripes like my map here? It is sooooo ***, and if i look really closely it looks like millions of tilesets shrunk really small
That happens some times, and it's not the way the map was generated. One of the computers at my grandparents does that, but the levels don't have that on them.

SingleChance 08-12-2002 08:14 PM

Happend to me when i was making a good level but it actually shoed up on the levels=/

Graal2001_LAT 08-20-2002 12:36 PM

Quote:

Originally posted by Androk2k1
So How exactly do I make levels? I think that's what Level Editing is about...
That is a question without a definite answer, so I cannot write you something which gives you mad ability. (Oh, I believe the 'new' icon in the editor makes a level ;))

You have to make levels with your knowledge, and then study what you did. See where you can improve, possibly look at other level techniques and adapt your own. Level making takes time, the saying "practice makes pefect" is meaningful.

Cid_Night 08-21-2002 01:13 AM

1 Attachment(s)
wow, thanks mmmmkay, this taught me how to make maps, now i am able to make large scale projects much easier, look at the map ima workin on...

Graal2001_LAT 08-23-2002 02:22 AM

Quote:

Originally posted by Androk2k1
What about mini map? What size should it be? How does it work?
Quote:

Originally posted by Graal2001_LAT
Minimap: If you want a minimap just simply follow this: Anyway just take your map and resize it much smaller so that it looks appealing to you in the bottom left hand corner. From there add this code to your previous map script:
NPC Code:
setminimap mapname.png,bigmap.txt,playerx,playery;




Graal2001_LAT 08-25-2002 11:58 PM

Quote:

Originally posted by zell12
not working >=(
Be more specific...

zell12 08-26-2002 12:00 AM

The map was all black :O I fiexed it though, I had to regenerate the levels and overwrite the old .png img


All times are GMT +2. The time now is 01:05 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.