Skip to content

Commit

Permalink
- fix arti teleport and arti teleother not respecting useplayerstartz…
Browse files Browse the repository at this point in the history
… mapflag
  • Loading branch information
madame-rachelle committed Aug 26, 2022
1 parent 8c0ad50 commit 8468f71
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
1 change: 1 addition & 0 deletions src/scripting/vmthunks.cpp
Expand Up @@ -2732,6 +2732,7 @@ DEFINE_FIELD_BIT(FLevelLocals, flags, noinventorybar, LEVEL_NOINVENTORYBAR)
DEFINE_FIELD_BIT(FLevelLocals, flags, monsterstelefrag, LEVEL_MONSTERSTELEFRAG)
DEFINE_FIELD_BIT(FLevelLocals, flags, actownspecial, LEVEL_ACTOWNSPECIAL)
DEFINE_FIELD_BIT(FLevelLocals, flags, sndseqtotalctrl, LEVEL_SNDSEQTOTALCTRL)
DEFINE_FIELD_BIT(FLevelLocals, flags, useplayerstartz, LEVEL_USEPLAYERSTARTZ)
DEFINE_FIELD_BIT(FLevelLocals, flags2, allmap, LEVEL2_ALLMAP)
DEFINE_FIELD_BIT(FLevelLocals, flags2, missilesactivateimpact, LEVEL2_MISSILESACTIVATEIMPACT)
DEFINE_FIELD_BIT(FLevelLocals, flags2, monsterfallingdamage, LEVEL2_MONSTERFALLINGDAMAGE)
Expand Down
5 changes: 3 additions & 2 deletions wadsrc/static/zscript/actors/hexen/teleportother.zs
Expand Up @@ -163,8 +163,9 @@ class TelOtherFX1 : Actor
double destAngle;

[dest, destAngle] = level.PickPlayerStart(0, PPS_FORCERANDOM | PPS_NOBLOCKINGCHECK);
dest.Z = ONFLOORZ;
victim.Teleport ((dest.xy, ONFLOORZ), destangle, TELF_SOURCEFOG | TELF_DESTFOG);
if (!level.useplayerstartz)
dest.Z = ONFLOORZ;
victim.Teleport (dest, destangle, TELF_SOURCEFOG | TELF_DESTFOG);
}

//===========================================================================
Expand Down
3 changes: 2 additions & 1 deletion wadsrc/static/zscript/actors/raven/artitele.zs
Expand Up @@ -36,7 +36,8 @@ class ArtiTeleport : Inventory
{
[dest, destAngle] = level.PickPlayerStart(Owner.PlayerNumber());
}
dest.Z = ONFLOORZ;
if (!level.useplayerstartz)
dest.Z = ONFLOORZ;
Owner.Teleport (dest, destAngle, TELF_SOURCEFOG | TELF_DESTFOG);
bool canlaugh = true;
Playerinfo p = Owner.player;
Expand Down
1 change: 1 addition & 0 deletions wadsrc/static/zscript/doombase.zs
Expand Up @@ -437,6 +437,7 @@ struct LevelLocals native
native readonly bool no_dlg_freeze;
native readonly bool keepfullinventory;
native readonly bool removeitems;
native readonly bool useplayerstartz;
native readonly int fogdensity;
native readonly int outsidefogdensity;
native readonly int skyfog;
Expand Down

0 comments on commit 8468f71

Please sign in to comment.