projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
rnd-20070114-1-src
[rocksndiamonds.git]
/
src
/
files.c
diff --git
a/src/files.c
b/src/files.c
index 87741c788b1fc42c6d76e02cfb5f2f2076428f63..66fbeec693f338686f54c703e7df3476beab2a6c 100644
(file)
--- a/
src/files.c
+++ b/
src/files.c
@@
-4252,7
+4252,7
@@
int getMappedElement_DC(int element)
break;
case 0x1437:
break;
case 0x1437:
- element = EL_SWITCHGATE_SWITCH_UP;
+ element = EL_
DC_
SWITCHGATE_SWITCH_UP;
break;
case 0x143a:
break;
case 0x143a:
@@
-4320,15
+4320,15
@@
int getMappedElement_DC(int element)
break;
case 0x14ce: /* growing steel wall (left/right) */
break;
case 0x14ce: /* growing steel wall (left/right) */
- element = EL_EXPANDABLE_WALL_HORIZONTAL;
+ element = EL_EXPANDABLE_
STEEL
WALL_HORIZONTAL;
break;
case 0x14df: /* growing steel wall (up/down) */
break;
case 0x14df: /* growing steel wall (up/down) */
- element = EL_EXPANDABLE_WALL_VERTICAL;
+ element = EL_EXPANDABLE_
STEEL
WALL_VERTICAL;
break;
case 0x14e8: /* growing steel wall (up/down/left/right) */
break;
case 0x14e8: /* growing steel wall (up/down/left/right) */
- element = EL_EXPANDABLE_WALL_ANY;
+ element = EL_EXPANDABLE_
STEEL
WALL_ANY;
break;
case 0x14e9:
break;
case 0x14e9:
@@
-4359,7
+4359,7
@@
int getMappedElement_DC(int element)
/* EL_SAND */
/* 0x1590 - 0x159f: */
/* EL_SAND */
/* 0x1590 - 0x159f: */
- /* EL_LANDMINE */
+ /* EL_
DC_
LANDMINE */
case 0x15a0:
element = EL_DYNAMITE;
case 0x15a0:
element = EL_DYNAMITE;
@@
-5310,7
+5310,7
@@
int getMappedElement_DC(int element)
break;
case 0x168d:
break;
case 0x168d:
- element = EL_TIMEGATE_SWITCH;
+ element = EL_
DC_
TIMEGATE_SWITCH;
break;
case 0x168e:
break;
case 0x168e:
@@
-5516,7
+5516,7
@@
int getMappedElement_DC(int element)
else if (element >= 0x157c && element <= 0x158b)
element = EL_SAND;
else if (element >= 0x1590 && element <= 0x159f)
else if (element >= 0x157c && element <= 0x158b)
element = EL_SAND;
else if (element >= 0x1590 && element <= 0x159f)
- element = EL_LANDMINE;
+ element = EL_
DC_
LANDMINE;
else if (element >= 0x16bc && element <= 0x16cb)
element = EL_INVISIBLE_SAND;
else
else if (element >= 0x16bc && element <= 0x16cb)
element = EL_INVISIBLE_SAND;
else
@@
-5696,9
+5696,16
@@
static void LoadLevelFromFileInfo_DC(struct LevelInfo *level,
fclose(file);
fclose(file);
+ /* Diamond Caves has the same (strange) behaviour as Emerald Mine that gems
+ can slip down from flat walls, like normal walls and steel walls */
+ level->em_slippery_gems = TRUE;
+
+#if 0
/* Diamond Caves II levels are always surrounded by indestructible wall, but
not necessarily in a rectangular way -- fill with invisible steel wall */
/* Diamond Caves II levels are always surrounded by indestructible wall, but
not necessarily in a rectangular way -- fill with invisible steel wall */
+ /* !!! not always true !!! keep level and set BorderElement instead !!! */
+
for (y = 0; y < level->fieldy; y++) for (x = 0; x < level->fieldx; x++)
{
#if 1
for (y = 0; y < level->fieldy; y++) for (x = 0; x < level->fieldx; x++)
{
#if 1
@@
-5714,6
+5721,7
@@
static void LoadLevelFromFileInfo_DC(struct LevelInfo *level,
level->field, level->fieldx, level->fieldy);
#endif
}
level->field, level->fieldx, level->fieldy);
#endif
}
+#endif
}
}
@@
-6077,7
+6085,10
@@
static void LoadLevel_InitPlayfield(struct LevelInfo *level, char *filename)
lev_fieldy = level->fieldy;
/* determine border element for this level */
lev_fieldy = level->fieldy;
/* determine border element for this level */
- SetBorderElement();
+ if (level->file_info.type == LEVEL_FILE_TYPE_DC)
+ BorderElement = EL_EMPTY; /* (in editor, SetBorderElement() is used) */
+ else
+ SetBorderElement();
}
static void LoadLevel_InitNativeEngines(struct LevelInfo *level,char *filename)
}
static void LoadLevel_InitNativeEngines(struct LevelInfo *level,char *filename)