- error handling missing terrains

- bugfix terrain-xml
This commit is contained in:
Enno Rehling 2005-12-31 13:45:10 +00:00
parent e30c171995
commit 80186ba627
3 changed files with 18 additions and 14 deletions

View File

@ -720,8 +720,8 @@ create_backup(char *file)
{
#ifdef HAVE_UNISTD_H
char bfile[MAX_PATH];
char command[MAX_PATH*2+10];
int c = 1;
do {
sprintf(bfile, "%s.backup%d", file, c);
c++;
@ -1301,6 +1301,10 @@ readregion(FILE * F, short x, short y)
char name[64];
rs(F, name);
terrain = get_terrain(name);
if (terrain==NULL) {
log_error(("Unknown terrain '%s'\n", name));
assert(!"unknown terrain");
}
}
r->terrain = terrain;
r->flags = (char) ri(F);

View File

@ -18,7 +18,7 @@
</text>
<text locale="de">
Dieses Abzeichen identifiziert die Partei seines Träger offiziell
als einen Bescuher der Botschafterregion 'Muschelplateau'.
als einen Besucher der Botschafterregion 'Muschelplateau'.
</text>
</string>
<string name="stardust">

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<terrains xmlns="http://tempuri.org/terrains.xsd">
<terrains>
<!-- defaults: walk="yes" sail="yes" fly="yes" shallow="yes" swim="no" forest="no" sea="no" land="yes" forbidden="no" arctic="no" cavalry="no" -->
<terrain name="ocean" size="100" shallow="no" walk="no" swim="yes" land="no" sea="yes" />
<terrain name="plain" size="10000" road="50" shallow="no" forest="yes" cavalry="yes" seed="3">