mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-12-01 08:31:14 +00:00
- added UDMF LOcknumber property, submitted by Nightfall.
SVN r3331 (trunk)
This commit is contained in:
parent
3b8f5e0d39
commit
b1905c16ef
5 changed files with 75 additions and 57 deletions
|
@ -1916,6 +1916,7 @@ void AM_drawWalls (bool allmap)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
static mline_t l;
|
static mline_t l;
|
||||||
|
int lock, color;
|
||||||
|
|
||||||
for (i = 0; i < numlines; i++)
|
for (i = 0; i < numlines; i++)
|
||||||
{
|
{
|
||||||
|
@ -1951,8 +1952,16 @@ void AM_drawWalls (bool allmap)
|
||||||
AM_drawMline(&l, SecretWallColor);
|
AM_drawMline(&l, SecretWallColor);
|
||||||
else
|
else
|
||||||
AM_drawMline(&l, WallColor);
|
AM_drawMline(&l, WallColor);
|
||||||
}
|
} else if (lines[i].locknumber > 0) { // [Dusk] specials w/ locknumbers
|
||||||
else if ((lines[i].special == Teleport ||
|
lock = lines[i].locknumber;
|
||||||
|
color = P_GetMapColorForLock(lock);
|
||||||
|
|
||||||
|
AMColor c;
|
||||||
|
if (color >= 0) c.FromRGB(RPART(color), GPART(color), BPART(color));
|
||||||
|
else c = LockedColor;
|
||||||
|
|
||||||
|
AM_drawMline (&l, c);
|
||||||
|
} else if ((lines[i].special == Teleport ||
|
||||||
lines[i].special == Teleport_NoFog ||
|
lines[i].special == Teleport_NoFog ||
|
||||||
lines[i].special == Teleport_ZombieChanger ||
|
lines[i].special == Teleport_ZombieChanger ||
|
||||||
lines[i].special == Teleport_Line) &&
|
lines[i].special == Teleport_Line) &&
|
||||||
|
@ -1978,13 +1987,12 @@ void AM_drawWalls (bool allmap)
|
||||||
if (am_colorset == 0 || am_colorset == 3) // Raven games show door colors
|
if (am_colorset == 0 || am_colorset == 3) // Raven games show door colors
|
||||||
{
|
{
|
||||||
int P_GetMapColorForLock(int lock);
|
int P_GetMapColorForLock(int lock);
|
||||||
int lock;
|
|
||||||
|
|
||||||
if (lines[i].special==Door_LockedRaise || lines[i].special==Door_Animated)
|
if (lines[i].special==Door_LockedRaise || lines[i].special==Door_Animated)
|
||||||
lock=lines[i].args[3];
|
lock=lines[i].args[3];
|
||||||
else lock=lines[i].args[4];
|
else lock=lines[i].args[4];
|
||||||
|
|
||||||
int color = P_GetMapColorForLock(lock);
|
color = P_GetMapColorForLock(lock);
|
||||||
|
|
||||||
AMColor c;
|
AMColor c;
|
||||||
|
|
||||||
|
|
|
@ -382,6 +382,7 @@ xx(Transparent)
|
||||||
xx(Passuse)
|
xx(Passuse)
|
||||||
xx(Repeatspecial)
|
xx(Repeatspecial)
|
||||||
xx(Conversation)
|
xx(Conversation)
|
||||||
|
xx(Locknumber)
|
||||||
|
|
||||||
xx(Playercross)
|
xx(Playercross)
|
||||||
xx(Playeruse)
|
xx(Playeruse)
|
||||||
|
|
|
@ -60,6 +60,7 @@
|
||||||
#include "v_font.h"
|
#include "v_font.h"
|
||||||
#include "a_sharedglobal.h"
|
#include "a_sharedglobal.h"
|
||||||
#include "farchive.h"
|
#include "farchive.h"
|
||||||
|
#include "a_keys.h"
|
||||||
|
|
||||||
// State.
|
// State.
|
||||||
#include "r_state.h"
|
#include "r_state.h"
|
||||||
|
@ -235,6 +236,8 @@ bool P_ActivateLine (line_t *line, AActor *mo, int side, int activationType)
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
int remote = (line->special != 7 && line->special != 8 && (line->special < 11 || line->special > 14));
|
||||||
|
if (line->locknumber > 0 && !P_CheckKeys (mo, line->locknumber, remote)) return false;
|
||||||
lineActivation = line->activation;
|
lineActivation = line->activation;
|
||||||
repeat = line->flags & ML_REPEAT_SPECIAL;
|
repeat = line->flags & ML_REPEAT_SPECIAL;
|
||||||
buttonSuccess = false;
|
buttonSuccess = false;
|
||||||
|
|
|
@ -881,6 +881,11 @@ public:
|
||||||
Flag(ld->flags, ML_BLOCKSIGHT, key);
|
Flag(ld->flags, ML_BLOCKSIGHT, key);
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
// [Dusk] lock number
|
||||||
|
case NAME_Locknumber:
|
||||||
|
ld->locknumber = CheckInt(key);
|
||||||
|
continue;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -910,6 +910,7 @@ struct line_t
|
||||||
slopetype_t slopetype; // To aid move clipping.
|
slopetype_t slopetype; // To aid move clipping.
|
||||||
sector_t *frontsector, *backsector;
|
sector_t *frontsector, *backsector;
|
||||||
int validcount; // if == validcount, already checked
|
int validcount; // if == validcount, already checked
|
||||||
|
int locknumber; // [Dusk] lock number for special
|
||||||
};
|
};
|
||||||
|
|
||||||
// phares 3/14/98
|
// phares 3/14/98
|
||||||
|
|
Loading…
Reference in a new issue