The Cathedral of Attnam

Changes

Jump to navigation Jump to search
m
no edit summary
| <code>AttachedDungeon</code>
| <code>DEFINED_VALUE</code>
| This is the <code>#define</code> set in <code>define.dat</code> that is used to link the user-specified dungeon in the data file to its over-world terrain.
|-
| <code>AttachedArea</code>
| <code>0, 1, 2, ...</code>
| This sets the initial level that the player will appear in upon entering the dungeon. Normally set this to zero.|-| <code>NativeGTerrainType</code>| <code>DEFINED_VALUE</code>| MUST be non-zero. Can select from <code>DESERT</code>, <code>JUNGLE</code>, <code>STEPPE</code>, <code>LEAFY_FOREST</code>, <code>EVERGREEN_FOREST</code>, <code>TUNDRA</code>, <code>GLACIER</code>. Note that the tundra type produces the familiar snow terrain.
|-
| <code>RevealEnvironmentInitially</code>
| <code>true</code> or <code>false</code>
| This determines whether to reveal the dungeon on the world map initially by uncovering the darkness, a la Attnam, or whether the player will need to discover it by using the field of view, a la underwater tunnel exit. Note that this differs from the way gloomy caves is hidden, and then revealed once you talk to Petrus.|-| <code>HideLocationInitially</code>| <code>true</code> or <code>false</code>| This tells the game whether to show the location on the world map or not. If it is set to true, then the location will be undiscoverable unless some internal condition within the game is met, that triggers the location to be revealed. If it is set to false, then the location will be accessible from the beginning of the game.
|-
| <code>NativeGTerrainTypeCanBeOnAnyTerrain</code>| <code>DEFINED_VALUEtrue</code>| MUST be non-zero. Can select from or <code>DESERTfalse</code>| If set to true, <code>JUNGLE</code>this forces the world map generator to ignore the requirement to place the location in its exact native terrain type. It places these locations in the first available spot from Attnam outwards. This is necessary sometimes, <code>STEPPE</code>to more or less guarantee the location to be accessible to the player. If it is set to false, <code>LEAFY_FOREST</code>, <code>EVERGREEN_FOREST</code>, <code>TUNDRA</code>, <code>GLACIER</code>. Note that the tundra type produces there is a high chance the familiar snow terrainlocation will spawn on another continent.
|}
== A worked example ==
=== A Dungeon data file ===By following these three easy steps you can create and add new dungeons to your local copy of IVAN, without needing to know how to code!
(Attachement)=== Step 1: A basic dungeon data file ===
Copypaste this into your favorite text editor and save under <code>Script/dungeons</code> as "House.dat": <code> /* * * Iter Vehemens ad Necem (IVAN) * Copyright (C) Timo Kiviluoto * Released under the GNU General * Public License * * See LICENSING which should be included * along with this file for more details * */ /* * NOTICE!!! * * This file contains SPOILERS, which might ruin your IVAN experience * totally. Also, editing anything can DESTROY GAME BALANCE or CAUSE * OBSCURE BUGS if you don't know what you're doing. So from here on, * proceed at your own risk! */ Dungeon HOUSE_ON_THE_STEPPE; { Levels =1; Description ="House"; ShortDescription = In "HS"; Level 0; { FillSquare = solidterrain(GRASS_TERRAIN), 0; Size = 42, 26; GenerateMonsters = false; Rooms = 1; Items = 0; IsOnGround = true; TeamDefault = MONSTER_TEAM; LOSModifier = 48; IgnoreDefaultSpecialSquares = false; AutoReveal = true; CanGenerateBone = false; DifficultyBase = 50; DifficultyDelta = 0; EnchantmentMinusChanceBase = -15; EnchantmentMinusChanceDelta = 0; EnchantmentPlusChanceBase = 0; EnchantmentPlusChanceDelta = 0; BackGroundType = GREEN_FRACTAL; EarthquakesAffectTunnels = true; AudioPlayList = { 1, "Empty.mid"; } RoomDefault { Pos = 2:40,2:24; Size = 4:6,4:6; AltarPossible = false; WallSquare = solidterrain(GRASS_TERRAIN), wall(BRICK_PRIMITIVE); FloorSquare = solidterrain(GRASS_TERRAIN), 0; DoorSquare = solidterrain(GRASS_TERRAIN), BALSA_WOOD door; GenerateDoor = true; DivineMaster = 0; GenerateTunnel = false; GenerateLanterns = false; Type = ROOM_NORMAL; GenerateFountains = false; AllowLockedDoors = false; AllowBoobyTrappedDoors = false; Shape = ROUND_CORNERS; IsInside = true; GenerateWindows = true; UseFillSquareWalls = false; Flags = 0; } } }</code> === Step 2: Add the new dungeon definition to define.dat ===
{| class="wikitable"
#define UNDER_WATER_TUNNEL 4
#define EMPTY_AREA 5
#define XINROCH_TOMB 6
#define UNDER_WATER_TUNNEL_EXIT 128
#define UNDER_WATER_TUNNEL 4
#define EMPTY_AREA 5
#define XINROCH_TOMB 6 <span style="background:palegreen">#define HOUSE_ON_THE_STEPPE 67</span>
#define UNDER_WATER_TUNNEL_EXIT 128
</tt>
|}
=== In Step 3: Add the new location to the worldmap with owterra.dat ===
{| class="wikitable"
<tt>locationAA
{
BitmapPos = <span style="background:pink">0</span>, 64;
NameStem = "<span style="background:pink">empty area</span>";
UsesLongArticle = <span style="background:pink">true</span>;
<tt>locationAA
{
BitmapPos = 0<span style="background:palegreen">64</span>, 64;
NameStem = "<span style="background:palegreen">house on the steppe</span>";
UsesLongArticle = <span style="background:palegreen">false</span>;
AttachedDungeon = <span style="background:palegreen">EMPTY_AREAHOUSE_ON_THE_STEPPE</span>;
AttachedArea = 0;
CanBeGenerated = <span style="background:palegreen">true</span>;
NativeGTerrainType = <span style="background:palegreen">STEPPE</span>;
}</tt>
| [[File:ShopBareSteppes.png|160px]]
|}
== Known limitations ==
 
=== Distribution of ground terrain types ===
 
{| class="wikitable"
! Terrain type
! Picture
! Percentage of global tiles (averaged over 8 PDS sampling trials)
|-
| Desert
| [[File:Desert.png]]
| 7.1 %
|-
| Jungle
| [[File:Jungle.png]]
| 14.0 %
|-
| Steppe
| [[File:Steppe.png]]
| 13.7 %
|-
| Leafy forest
| [[File:Leafyforest.png]]
| 15.9 %
|-
| Evergreen forest
| [[File:Evergreenforest.png]]
| 6.0 %
|-
| Tundra
| [[File:Tundra.png]]
| 33.4 %
|-
| Glacier
| [[File:Glacier.png]]
| 9.9 %
|}
 
As of <code>0.50.6</code>, the number of slots is <code>32</code>.
Population distribution of terrain types collected by the sampling algorithm.
 
[[Category:Modding]]
Moderator
1,400

edits

Navigation menu