|
|
Line 1: |
Line 1: |
| '''GMaps''' are files that contain information about how to links many single [[Level]] files (.nw) to a big [[Map]] that seems like one level in game. This makes it possible to have a map that displays all players who are in the same area, and removes restrictions on what NPCs can do caused by the separation of levels. | | '''IMPORANT MESSAGE TO UNIXMAD AND GRAALONLINE:''' |
| Earlier this was done through [[bigmap.txt|.txt files]] merely containing a list of [[Level]]s, and the [[Old GScript:setmap]] command, but this lacks many of the features the gmap way provides, and therefore is considered deprecated. Many [[Playerworld]]s still use the old way, but this is merely because of the difficulties that make it hard and error prone to convert a whole server to a new format.
| |
|
| |
|
| == Creation ==
| | Aslong as the Playerworld Administration Team and the Global Scripting Team is still around, we will continue to attack Graal. After reading several threads about the two it seems the players agree with us on how they both are not needed and only cause problems for playerworlds. So aslong as those two global staff groups remain and the people in them, Graal will face an endless war that will harm itself. |
| GMaps, if not handmade, are created by the [[Level generator]] that is installed
| |
| through [[Graal]]'s [[setup.exe]] along with the [[Delphi client|Windows version ]]of the game. Graal does not supply a GMap generator for any other platform.
| |
| GMaps can also hold height information that are used by the Graal engine to
| |
| display [[Level]]s in a three dimensional looking way. This is called [[Terrain]]. The height information is mainly created by the level editor and the [[Terrain Generator]] programs that allows creation of whole islands.
| |
|
| |
|
| == File Format ==
| | We have put both of those in our demands for unixmad that we upload everytime we attack a server. JellyFish has also told unixmad that he will only leave graal if he gets rid of those 2 groups. |
| GMaps are plain text files, and all GMaps as of now start with the string ''GRMAP001'', followed by a newline. Then, in each line, a 'command' is given, usually in capital letters. Parameters to those commands are put into the same line after a whitespace. Some commands are in fact lists, which have nothing in their line, but which treat all following lines as their parameters until they see themselves followed by 'END' without any whitespace again.
| |
|
| |
|
| To learn about all that, in addition to reading this article, it is recommended to
| | - The Anti-Unixmad.com Team |
| check your 'maps' subfolder, and have a look at some [[Playerworld]]s' GMaps.
| |
|
| |
|
| === WIDTH, and HEIGHT ===
| | www.anti-unixmad.com |
| followed by an integral number
| |
| Dimensions of the whole map, given in single levels. If given incorrectly, these can break the whole map, thus be careful.
| |
| === GENERATED ===
| |
| followed by a level name
| |
| Gives the last, or bottom right, level that was generated if the gmap was created along with a whole set of levels using a device such as the terrain generator.
| |
| === LEVELNAMES ===
| |
| followed by a list of levels, and terminated by '''LEVELNAMESEND'''
| |
| The list of levels that are part of this map. Each 'row' of levels goes into one line, seperated by commas. There is no comma at the end of a line.
| |
| === MAPIMG ===
| |
| followed by a [[PNG]] file name
| |
| The image file that is to be used as the map that players see if they press their Map key.
| |
| === MINIMAPIMG ===
| |
| followed by a PNG file name
| |
| The image file that is to be used as the mini map in the bottom left corner of one's screen.
| |
| === NOAUTOMAPPING ===
| |
| uses no param
| |
| Disables the assembly of automagical screenshots into a map that is drawn over the MAPIMG image.
| |
| === LOADFULLMAP ===
| |
| Stefan optmised gmap loading so parts are only loaded when they are needed, and afterwards they are removed from memory again. If you put this line, that will be disabled and the full map with all levels will be loaded at once.
| |
| === LOADATSTART ===
| |
| followed by a list of level names, terminated by '''LOADATSTARTEND'''
| |
| The level names given here are not subject to the optimisations described above.
| |
| | |
| === Terrain settings ===
| |
| '''GENEVENBORDERS''', followed by true/false
| |
| | |
| '''GENSEED''', followed by a big number used to seed randomness
| |
| | |
| '''GENBASE''', followed by a height value
| |
| | |
| '''GENHEIGHT''' and '''LEVHEIGHT''', followed by a height value
| |
| | |
| '''GENCHAOS''' and LEVCHAOS, followed by a number between 0 and 1, I think, exact to 1/20
| |
| | |
| '''HEIGHMAP''', followed by a list of height values for each level ordered similar to the '''LEVELNAMES''' list, terminated by '''HEIGHTMAPEND'''
| |
| | |
| '''RANDOMSEEDS''', followed by lots of big numbers, probably ordered similar to the '''LEVELNAMES''' list, terminated by '''RANDOMSEEDSEND'''
| |
| | |
| The random numbers generator is seeded with these to render the terrain in a three dimensional looking way. The borders of gmaps are defined by the global map attributes, but for map part heights a row of random numbers is used. The seeds are constant so the terrain looks the same all the time, and there are many of them so it is possible to take a small rectangle out of the map and still display it correctly, which would not be possible with one global seed.
| |
| | |
| | |
| Not all of these lines are needed.
| |
| | |
| == Deployment ==
| |
| | |
| Now, imagine you have a gmap and a set of levels and want to actually use it
| |
| on your [[Playerworld]].
| |
| | |
| The main thing is to load it by using the clienstide script command [[Old GScript:loadmap]], which takes the name of a GMap as a parameter, excluding the .gmap extension. This is usually done by a [[NPC weapon]] that every [[Player]] is supposed to have (for example something like -System, or -Initialization), and as [[Graal Kingdoms|GK]] loads all gmaps as soon as a [[Player]] connects to the server, it is suggested you do so as well.
| |
| | |
| This will only enable the engine to assign and connect levels the player enters or sees. [[Level]]s must still have [[Link]] areas to each other in order to move on the map.
| |
| | |
| As you are going to use the GMap on your [[Playerworld]], you need to make it available for [[Player]]s to download, by putting it inside the levels/ folder
| |
| hierarchy using the [[RC file manager]], and adding it to the [[Folder configuration]] as mere [[Level]]; level *.gmap, for example. It is neccessary to additionally register it as file in the folder configuration, but there is no gmap category to put it under.
| |
| | |
| To make the [[NPC Server]] aware of your gmaps, you need to list them in the [[Server options]] too. Add a new option gmaps= followed by a comma seperated list of names without the .gmap extension. If your line gets too stuffed, you can as well use multiple lines, as long as you prefix each one with gmaps=. The entries in each lines will be added, and not replace each other.
| |