- added ML_BLOCKHITSCAN line flag.

This commit is contained in:
Christoph Oelckers 2013-08-09 20:35:10 +02:00
parent a78ad3188b
commit 6a07118ea4
6 changed files with 9 additions and 1 deletions

View file

@ -113,6 +113,7 @@ Note: All <bool> fields default to false unless mentioned otherwise.
blockprojectiles = <bool>;// Line blocks all projectiles blockprojectiles = <bool>;// Line blocks all projectiles
blockuse = <bool>; // Line blocks all use actions blockuse = <bool>; // Line blocks all use actions
blocksight = <bool>; // Line blocks monster line of sight blocksight = <bool>; // Line blocks monster line of sight
blockhitscan = <bool>; // Line blocks hitscan attacks
locknumber = <int>; // Line special is locked locknumber = <int>; // Line special is locked
arg0str = <string>; // Alternate string-based version of arg0 arg0str = <string>; // Alternate string-based version of arg0

View file

@ -153,6 +153,7 @@ enum ELineFlags
ML_BLOCKPROJECTILE = 0x01000000, ML_BLOCKPROJECTILE = 0x01000000,
ML_BLOCKUSE = 0x02000000, // blocks all use actions through this line ML_BLOCKUSE = 0x02000000, // blocks all use actions through this line
ML_BLOCKSIGHT = 0x04000000, // blocks monster line of sight ML_BLOCKSIGHT = 0x04000000, // blocks monster line of sight
ML_BLOCKHITSCAN = 0x08000000, // blocks hitscan attacks
}; };

View file

@ -465,6 +465,7 @@ xx(blockprojectiles)
xx(blockuse) xx(blockuse)
xx(hidden) xx(hidden)
xx(blocksight) xx(blocksight)
xx(blockhitscan)
xx(Renderstyle) xx(Renderstyle)

View file

@ -2545,6 +2545,7 @@ FUNC(LS_Line_SetBlocking)
ML_RAILING, ML_RAILING,
ML_BLOCKUSE, ML_BLOCKUSE,
ML_BLOCKSIGHT, ML_BLOCKSIGHT,
ML_BLOCKHITSCAN,
-1 -1
}; };

View file

@ -3563,7 +3563,7 @@ AActor *P_LineAttack (AActor *t1, angle_t angle, fixed_t distance,
else tflags = TRACE_NoSky|TRACE_Impact; else tflags = TRACE_NoSky|TRACE_Impact;
if (!Trace (t1->x, t1->y, shootz, t1->Sector, vx, vy, vz, distance, if (!Trace (t1->x, t1->y, shootz, t1->Sector, vx, vy, vz, distance,
MF_SHOOTABLE, ML_BLOCKEVERYTHING, t1, trace, MF_SHOOTABLE, ML_BLOCKEVERYTHING|ML_BLOCKHITSCAN, t1, trace,
tflags, hitGhosts ? CheckForGhost : CheckForSpectral)) tflags, hitGhosts ? CheckForGhost : CheckForSpectral))
{ // hit nothing { // hit nothing
if (puffDefaults == NULL) if (puffDefaults == NULL)

View file

@ -927,6 +927,10 @@ public:
Flag(ld->flags, ML_BLOCKSIGHT, key); Flag(ld->flags, ML_BLOCKSIGHT, key);
continue; continue;
case NAME_blockhitscan:
Flag(ld->flags, ML_BLOCKHITSCAN, key);
continue;
// [Dusk] lock number // [Dusk] lock number
case NAME_Locknumber: case NAME_Locknumber:
ld->locknumber = CheckInt(key); ld->locknumber = CheckInt(key);