2017-12-23 16:33:05 +00:00
|
|
|
# CTF Map
|
|
|
|
|
2019-02-24 05:11:16 +00:00
|
|
|
This mod handles creating and loading maps.
|
2017-12-27 17:36:45 +00:00
|
|
|
|
2019-03-17 14:43:31 +00:00
|
|
|
## Attributions
|
|
|
|
|
|
|
|
- Indestructible nodes adapted from various mods in `minetest_game`.
|
|
|
|
|
2019-02-24 05:11:16 +00:00
|
|
|
## Creating a new map
|
2017-12-27 17:36:45 +00:00
|
|
|
|
2019-02-24 05:11:16 +00:00
|
|
|
### 1. Dependencies
|
2017-12-27 17:36:45 +00:00
|
|
|
|
|
|
|
* Minetest 0.4.16 or later.
|
|
|
|
* Mods
|
2019-02-24 05:11:16 +00:00
|
|
|
* ctf_map (by copying the folder from this game to `minetest/mods`)
|
|
|
|
* worldedit and worldedit_commands.
|
2017-12-27 17:36:45 +00:00
|
|
|
|
2019-02-24 05:11:16 +00:00
|
|
|
### 2. Find an area
|
2017-12-27 17:36:45 +00:00
|
|
|
|
|
|
|
* Can use Minetest Game and any mapgen.
|
|
|
|
* It must be a cube, and the barrier will be in the exact center.
|
|
|
|
* It should be around 230x230 in surface area, but this can vary.
|
|
|
|
* Feel free to modify the area to your needs.
|
|
|
|
|
2019-02-24 05:11:16 +00:00
|
|
|
### 3. Select the area
|
2017-12-27 17:36:45 +00:00
|
|
|
|
|
|
|
There are multiple ways do this, this is the simplist in most cases.
|
|
|
|
|
|
|
|
* If you haven't modified the map at all, do the following to speed up barrier placement:
|
2019-02-24 05:11:16 +00:00
|
|
|
* Stop Minetest.
|
|
|
|
* Open up the world's world.mt
|
|
|
|
* Set backend to "dummy".
|
|
|
|
* Save.
|
2017-12-27 17:36:45 +00:00
|
|
|
* Using worldedit, select the area.
|
|
|
|
* Type /gui, and click "From WE" then "To WE".
|
|
|
|
* Check that the center location is the right place for the barrier to go.
|
|
|
|
* Check that the bounds extend far enough.
|
|
|
|
|
2019-02-24 05:11:16 +00:00
|
|
|
### 4. Place barriers
|
2017-12-27 17:36:45 +00:00
|
|
|
|
|
|
|
* Set the middle barrier direction. The barrier is a plane defined by a co-ordinate = 0.
|
|
|
|
If the barrier is X=0, then it will placed with every node of the barrier having X=0.
|
|
|
|
If the barrier is Z=0, then it will placed with every node of the barrier having Z=0.
|
|
|
|
* Click "place barrier". Note that this command does not have an undo.
|
|
|
|
|
2019-02-24 05:11:16 +00:00
|
|
|
### 5. Meta data
|
2017-12-27 17:36:45 +00:00
|
|
|
|
|
|
|
* Set the meta data
|
|
|
|
|
2019-02-24 05:11:16 +00:00
|
|
|
### 6. Export
|
2017-12-27 17:36:45 +00:00
|
|
|
|
|
|
|
* Click export, and wait until completion.
|
2019-02-24 05:11:16 +00:00
|
|
|
* Copy the two files from `worlddir/schems/` to `ctf_map/maps/`.
|
2017-12-27 17:36:45 +00:00
|
|
|
* Rename the files so the two prefixed numbers are consistent to existing maps.
|
|
|
|
* Profit!
|
2019-02-24 05:11:16 +00:00
|
|
|
|
|
|
|
## Documentation
|
|
|
|
|
|
|
|
### Map meta
|
|
|
|
|
|
|
|
Each map's metadata is stored in an accompanying .conf file containing the following data:
|
|
|
|
|
|
|
|
* `name`: Name of map.
|
|
|
|
* `author`: Author of the map.
|
|
|
|
* `hint`: [Optional] Helpful hint or tip for unique maps, to help players understand the map.
|
|
|
|
* `rotation`: Rotation of the schem. [`x`|`z`]
|
2019-10-09 06:21:09 +00:00
|
|
|
* `screenshot`: File name of screenshot of the map; should include file extension.
|
|
|
|
* `license`: Name of the license of the map.
|
|
|
|
* `other`: [Optional] Misc. information about the map. This is displayed in the maps catalog.
|
2019-10-09 06:16:51 +00:00
|
|
|
* `base_node`: [Optional] Technical name of node to be used for the team base.
|
2019-02-24 05:11:16 +00:00
|
|
|
* `schematic`: Name of the map's schematic.
|
2019-03-17 14:43:31 +00:00
|
|
|
* `initial_stuff`: [Optional] Comma-separated list of itemstacks to be given to the player
|
|
|
|
on join and on respawn.
|
|
|
|
* `treasures`: [Optional] List of treasures to be registered for the map, in a serialized
|
|
|
|
format. Refer to the `treasures` sub-section for more details.
|
2019-02-24 05:11:16 +00:00
|
|
|
* `r`: Radius of the map.
|
|
|
|
* `h`: Height of the map.
|
|
|
|
* `team.i`: Name of team `i`.
|
|
|
|
* `team.i.color`: Color of team `i`.
|
|
|
|
* `team.i.pos`: Position of team `i`'s flag, relative to center of schem.
|
2019-03-17 14:43:31 +00:00
|
|
|
* `chests.i.from`, `chests.i.to`: [Optional] Positions of diagonal corners of custom chest
|
|
|
|
zone `i`, relative to the center of the schem.
|
2019-02-24 05:11:16 +00:00
|
|
|
* `chests.i.n`: [Optional] Number of chests to place in custom chest zone `i`.
|
|
|
|
|
|
|
|
#### `treasures`
|
|
|
|
|
|
|
|
`treasures` is a list of treasures to be registered for this map in serialized format.
|
|
|
|
|
|
|
|
An example `treasures` value that registers steel pick, shotgun, and grenade:
|
|
|
|
|
|
|
|
```lua
|
|
|
|
treasures = default:pick_steel,0.5,5,1,10;shooter:shotgun,0.04,2,1;shooter:grenade,0.08,2,1
|
|
|
|
```
|
|
|
|
|
|
|
|
(See [here](../../other/treasurer/README.md) to understand the magic numbers)
|
2019-03-17 14:43:31 +00:00
|
|
|
|
|
|
|
## Indestructible nodes
|
|
|
|
|
|
|
|
- `ctf_map` provides indestructible nodes for most nodes from default, and all nodes from
|
|
|
|
stairs.
|
|
|
|
|
|
|
|
- All indestructible nodes have the same item name with the mod prefix being `ctf_map:`
|
|
|
|
instead of their original prefixes (e.g. `default:stone` -> `ctf_map:stone` and
|
|
|
|
`stairs:stair_stone` -> `ctf_map:stair_stone`) with the exception of wool, whose
|
|
|
|
indestructible nodes have slightly different names from the original node names -
|
|
|
|
`ctf_map:wool_<color>`. This is because the original nomenclature becomes meaningless
|
|
|
|
if the modname prefix is changed.
|