diff --git a/src/actionspecials.h b/src/actionspecials.h index 9b9c38cb97..3edb1671d3 100644 --- a/src/actionspecials.h +++ b/src/actionspecials.h @@ -258,5 +258,6 @@ DEFINE_SPECIAL(Ceiling_LowerByTexture, 269, 2, 4, 4) DEFINE_SPECIAL(Stairs_BuildDownDoom, 270, 5, 5, 5) DEFINE_SPECIAL(Stairs_BuildUpDoomSync, 271, 4, 4, 4) DEFINE_SPECIAL(Stairs_BuildDownDoomSync, 272, 4, 4, 4) +DEFINE_SPECIAL(Stairs_BuildUpDoomCrush, 273, 5, 5, 5) #undef DEFINE_SPECIAL diff --git a/src/c_dispatch.cpp b/src/c_dispatch.cpp index d112634d6a..296697ee76 100644 --- a/src/c_dispatch.cpp +++ b/src/c_dispatch.cpp @@ -1040,7 +1040,11 @@ FString BuildString (int argc, FString *argv) for (arg = 0; arg < argc; arg++) { - if (strchr(argv[arg], '"')) + if (argv[arg][0] == '\0') + { // It's an empty argument, we need to convert it to '""' + buf << "\"\" "; + } + else if (strchr(argv[arg], '"')) { // If it contains one or more quotes, we need to escape them. buf << '"'; long substr_start = 0, quotepos; diff --git a/src/dthinker.cpp b/src/dthinker.cpp index fd20a4e79a..11ba54dbc9 100644 --- a/src/dthinker.cpp +++ b/src/dthinker.cpp @@ -675,6 +675,9 @@ DThinker *FThinkerIterator::Next (bool exact) { return thinker; } + // This can actually happen when a Destroy call on 'thinker' happens to destroy 'm_CurrThinker'. + // In that case there is no chance to recover, we have to terminate the iteration of this list. + if (m_CurrThinker == nullptr) break; } } if ((m_SearchingFresh = !m_SearchingFresh)) diff --git a/src/g_inventory/a_pickups.cpp b/src/g_inventory/a_pickups.cpp index 3c1d32d420..438293d403 100644 --- a/src/g_inventory/a_pickups.cpp +++ b/src/g_inventory/a_pickups.cpp @@ -644,6 +644,8 @@ void AInventory::BecomeItem () RemoveFromHash (); flags &= ~MF_SPECIAL; ChangeStatNum(STAT_INVENTORY); + // stop all sounds this item is playing. + for(int i = 1;i<=7;i++) S_StopSound(this, i); SetState (FindState("Held")); } diff --git a/src/gi.cpp b/src/gi.cpp index 9d45d27242..c821288893 100644 --- a/src/gi.cpp +++ b/src/gi.cpp @@ -307,6 +307,9 @@ void FMapInfoParser::ParseGameInfo() GAMEINFOKEY_STRINGARRAY(finalePages, "finalePage", 8, true) GAMEINFOKEY_STRINGARRAY(infoPages, "addinfoPage", 8, false) GAMEINFOKEY_STRINGARRAY(infoPages, "infoPage", 8, true) + GAMEINFOKEY_STRINGARRAY(PrecachedClasses, "precacheclasses", 0, false) + GAMEINFOKEY_STRINGARRAY(PrecachedTextures, "precachetextures", 0, false) + GAMEINFOKEY_STRINGARRAY(PrecachedSounds, "precachesounds", 0, false) GAMEINFOKEY_STRING(PauseSign, "pausesign") GAMEINFOKEY_STRING(quitSound, "quitSound") GAMEINFOKEY_STRING(BorderFlat, "borderFlat") diff --git a/src/gi.h b/src/gi.h index c5b8f79cfd..d9e81bcf11 100644 --- a/src/gi.h +++ b/src/gi.h @@ -36,6 +36,7 @@ #include "basictypes.h" #include "zstring.h" +#include "s_sound.h" // Flags are not user configurable and only depend on the standard IWADs #define GI_MAPxx 0x00000001 @@ -120,6 +121,10 @@ struct gameinfo_t TArray DefaultWeaponSlots[10]; TArray PlayerClasses; + TArray PrecachedClasses; + TArray PrecachedTextures; + TArray PrecachedSounds; + FString titleMusic; int titleOrder; float titleTime; diff --git a/src/menu/playermenu.cpp b/src/menu/playermenu.cpp index 9f5196367a..ea22fdd71d 100644 --- a/src/menu/playermenu.cpp +++ b/src/menu/playermenu.cpp @@ -1108,6 +1108,9 @@ bool DPlayerMenu::MouseEvent(int type, int x, int y) SendNewColor (RPART(color), GPART(color), v); } break; + case NAME_Autoaim: + AutoaimChanged(li); + break; } } return res; diff --git a/src/p_effect.cpp b/src/p_effect.cpp index eb872edc1f..96295d6f53 100644 --- a/src/p_effect.cpp +++ b/src/p_effect.cpp @@ -272,7 +272,7 @@ void P_ThinkParticles () auto oldtrans = particle->alpha; particle->alpha -= particle->fadestep; particle->size += particle->sizestep; - if (oldtrans < particle->alpha || --particle->ttl <= 0 || (particle->size <= 0)) + if (particle->alpha <= 0 || oldtrans < particle->alpha || --particle->ttl <= 0 || (particle->size <= 0)) { // The particle has expired, so free it memset (particle, 0, sizeof(particle_t)); if (prev) @@ -763,7 +763,7 @@ void P_DrawRailTrail(AActor *source, TArray &portalhits, int color1, int spiralduration = (duration == 0) ? 35 : duration; p->alpha = 1.f; - p->ttl = duration; + p->ttl = spiralduration; p->fadestep = FADEFROMTTL(spiralduration); p->size = 3; p->bright = fullbright; diff --git a/src/p_floor.cpp b/src/p_floor.cpp index fbfa70f2e7..68602ab0ae 100644 --- a/src/p_floor.cpp +++ b/src/p_floor.cpp @@ -626,7 +626,7 @@ bool EV_BuildStairs (int tag, DFloor::EStair type, line_t *line, floor->m_PauseTime = 0; floor->m_StepTime = floor->m_PerStepTime = persteptime; - floor->m_Crush = (!(usespecials & DFloor::stairUseSpecials) && speed == 4) ? 10 : -1; //jff 2/27/98 fix uninitialized crush field + floor->m_Crush = (usespecials & DFloor::stairCrush) ? 10 : -1; //jff 2/27/98 fix uninitialized crush field floor->m_Hexencrush = false; floor->m_Speed = speed; diff --git a/src/p_lnspec.cpp b/src/p_lnspec.cpp index d368739e16..0ce41e1264 100644 --- a/src/p_lnspec.cpp +++ b/src/p_lnspec.cpp @@ -591,6 +591,13 @@ FUNC(LS_Stairs_BuildUpDoom) arg2, SPEED(arg1), TICS(arg3), arg4, 0, 0); } +FUNC(LS_Stairs_BuildUpDoomCrush) +// Stairs_BuildUpDoom (tag, speed, height, delay, reset) +{ + return EV_BuildStairs(arg0, DFloor::buildUp, ln, + arg2, SPEED(arg1), TICS(arg3), arg4, 0, DFloor::stairCrush); +} + FUNC(LS_Stairs_BuildDownDoom) // Stair_BuildDownDoom (tag, speed, height, delay, reset) { @@ -3582,6 +3589,7 @@ static lnSpecFunc LineSpecials[] = /* 270 */ LS_Stairs_BuildDownDoom, /* 271 */ LS_Stairs_BuildUpDoomSync, /* 272 */ LS_Stairs_BuildDownDoomSync, + /* 273 */ LS_Stairs_BuildUpDoomCrush, }; diff --git a/src/p_setup.cpp b/src/p_setup.cpp index 7a026e172e..6e2d7ed6d1 100644 --- a/src/p_setup.cpp +++ b/src/p_setup.cpp @@ -3383,6 +3383,11 @@ static void P_PrecacheLevel() actorhitlist[actor->GetClass()] = true; } + for (auto n : gameinfo.PrecachedClasses) + { + PClassActor *cls = PClass::FindActor(n); + if (cls != NULL) actorhitlist[cls] = true; + } for (unsigned i = 0; i < level.info->PrecacheClasses.Size(); i++) { // level.info can only store names, no class pointers. @@ -3419,6 +3424,11 @@ static void P_PrecacheLevel() hitlist[sky2texture.GetIndex()] |= FTextureManager::HIT_Sky; } + for (auto n : gameinfo.PrecachedTextures) + { + FTextureID tex = TexMan.CheckForTexture(n, FTexture::TEX_Wall, FTextureManager::TEXMAN_Overridable | FTextureManager::TEXMAN_TryAny | FTextureManager::TEXMAN_ReturnFirst); + if (tex.Exists()) hitlist[tex.GetIndex()] |= FTextureManager::HIT_Wall; + } for (unsigned i = 0; i < level.info->PrecacheTextures.Size(); i++) { FTextureID tex = TexMan.CheckForTexture(level.info->PrecacheTextures[i], FTexture::TEX_Wall, FTextureManager::TEXMAN_Overridable | FTextureManager::TEXMAN_TryAny | FTextureManager::TEXMAN_ReturnFirst); diff --git a/src/p_sight.cpp b/src/p_sight.cpp index df02e2ebbd..f00e59e8ff 100644 --- a/src/p_sight.cpp +++ b/src/p_sight.cpp @@ -116,6 +116,7 @@ class SightCheck sightend = t2->PosRelative(task->portalgroup); sightstart.Z += t1->Height * 0.75; + portalgroup = task->portalgroup; Startfrac = task->Frac; Trace = { sightstart.X, sightstart.Y, sightend.X - sightstart.X, sightend.Y - sightstart.Y }; Lastztop = Lastzbottom = sightstart.Z; @@ -790,6 +791,7 @@ sightcounts[2]++; bool traverseres = P_SightTraverseIntercepts ( ); if (itres == -1) return false; // if the iterator had an early out there was no line of sight. The traverser was only called to collect more portals. + if (seeingthing->Sector->PortalGroup != portalgroup) return false; // We are in a different group than the seeingthing, so this trace cannot determine visibility alone. return traverseres; } diff --git a/src/p_spec.h b/src/p_spec.h index ea98c82c14..a2fd0727ac 100644 --- a/src/p_spec.h +++ b/src/p_spec.h @@ -503,7 +503,8 @@ class DFloor : public DMovingFloor enum EStairType { stairUseSpecials = 1, - stairSync = 2 + stairSync = 2, + stairCrush = 4, }; DFloor (sector_t *sec); diff --git a/src/r_draw.cpp b/src/r_draw.cpp index 994d870952..730430b2a3 100644 --- a/src/r_draw.cpp +++ b/src/r_draw.cpp @@ -467,7 +467,7 @@ namespace swrenderer R_SetColorMapLight(basecolormap, 0, 0); } bool active_columnmethod = r_columnmethod && !r_swtruecolor; - return active_columnmethod ? DoDraw1 : DoDraw0; + return active_columnmethod ? DoDraw0; } fglevel = GetAlpha(style.SrcAlpha, alpha); @@ -501,7 +501,7 @@ namespace swrenderer return DontDraw; } bool active_columnmethod = r_columnmethod && !r_swtruecolor; - return active_columnmethod ? DoDraw1 : DoDraw0; + return active_columnmethod ? DoDraw0; } ESPSResult R_SetPatchStyle(FRenderStyle style, float alpha, int translation, uint32_t color) diff --git a/src/s_sound.cpp b/src/s_sound.cpp index be1b572f1c..1c7c5aea19 100644 --- a/src/s_sound.cpp +++ b/src/s_sound.cpp @@ -480,6 +480,10 @@ void S_PrecacheLevel () { actor->MarkPrecacheSounds(); } + for (auto i : gameinfo.PrecachedSounds) + { + level.info->PrecacheSounds[i].MarkUsed(); + } // Precache all extra sounds requested by this map. for (i = 0; i < level.info->PrecacheSounds.Size(); ++i) { diff --git a/src/scripting/zscript/zcc_compile.cpp b/src/scripting/zscript/zcc_compile.cpp index 9684ec9246..52cbc1d653 100644 --- a/src/scripting/zscript/zcc_compile.cpp +++ b/src/scripting/zscript/zcc_compile.cpp @@ -2336,6 +2336,7 @@ void ZCCCompiler::CompileFunction(ZCC_StructWork *c, ZCC_FuncDeclarator *f, bool sym->Variants[0].Implementation->DefaultArgs = std::move(argdefaults); } + PClass *clstype = static_cast(c->Type()); if (varflags & VARF_Virtual) { if (sym->Variants[0].Implementation == nullptr) @@ -2349,7 +2350,6 @@ void ZCCCompiler::CompileFunction(ZCC_StructWork *c, ZCC_FuncDeclarator *f, bool } if (forclass) { - PClass *clstype = static_cast(c->Type()); int vindex = clstype->FindVirtualIndex(sym->SymbolName, sym->Variants[0].Proto); // specifying 'override' is necessary to prevent one of the biggest problem spots with virtual inheritance: Mismatching argument types. if (varflags & VARF_Override) @@ -2383,6 +2383,14 @@ void ZCCCompiler::CompileFunction(ZCC_StructWork *c, ZCC_FuncDeclarator *f, bool Error(p, "Virtual functions can only be defined for classes"); } } + else if (forclass) + { + int vindex = clstype->FindVirtualIndex(sym->SymbolName, sym->Variants[0].Proto); + if (vindex != -1) + { + Error(f, "Function %s attempts to override parent function without 'override' qualifier", FName(f->Name).GetChars()); + } + } } } diff --git a/src/sound/oalsound.cpp b/src/sound/oalsound.cpp index 53c471a316..1b34583f94 100644 --- a/src/sound/oalsound.cpp +++ b/src/sound/oalsound.cpp @@ -407,7 +407,7 @@ class OpenALSoundStream : public SoundStream virtual FString GetStats() { FString stats; - size_t pos, len; + size_t pos = 0, len = 0; ALfloat volume; ALint offset; ALint processed; @@ -429,28 +429,34 @@ class OpenALSoundStream : public SoundStream return stats; } - pos = Decoder->getSampleOffset(); - len = Decoder->getSampleLength(); + if (Decoder != nullptr) + { + pos = Decoder->getSampleOffset(); + len = Decoder->getSampleLength(); + } lock.unlock(); stats = (state == AL_INITIAL) ? "Buffering" : (state == AL_STOPPED) ? "Underrun" : (state == AL_PLAYING || state == AL_PAUSED) ? "Ready" : "Unknown state"; - if(state == AL_STOPPED) - offset = BufferCount * (Data.Size()/FrameSize); - else - { - size_t rem = queued*(Data.Size()/FrameSize) - offset; - if(pos > rem) pos -= rem; - else if(len > 0) pos += len - rem; - else pos = 0; - } - pos = (size_t)(pos * 1000.0 / SampleRate); - len = (size_t)(len * 1000.0 / SampleRate); - stats.AppendFormat(",%3u%% buffered", 100 - 100*offset/(BufferCount*(Data.Size()/FrameSize))); - stats.AppendFormat(", %zu.%03zu", pos/1000, pos%1000); - if(len > 0) - stats.AppendFormat(" / %zu.%03zu", len/1000, len%1000); + if (Decoder != nullptr) + { + if (state == AL_STOPPED) + offset = BufferCount * (Data.Size() / FrameSize); + else + { + size_t rem = queued*(Data.Size() / FrameSize) - offset; + if (pos > rem) pos -= rem; + else if (len > 0) pos += len - rem; + else pos = 0; + } + pos = (size_t)(pos * 1000.0 / SampleRate); + len = (size_t)(len * 1000.0 / SampleRate); + stats.AppendFormat(",%3u%% buffered", 100 - 100 * offset / (BufferCount*(Data.Size() / FrameSize))); + stats.AppendFormat(", %zu.%03zu", pos / 1000, pos % 1000); + if (len > 0) + stats.AppendFormat(" / %zu.%03zu", len / 1000, len % 1000); + } if(state == AL_PAUSED) stats += ", paused"; if(state == AL_PLAYING) diff --git a/src/version.h b/src/version.h index cb15287634..98c523b9f4 100644 --- a/src/version.h +++ b/src/version.h @@ -41,12 +41,12 @@ const char *GetVersionString(); /** Lots of different version numbers **/ -#define VERSIONSTR "1.2.1" +#define VERSIONSTR "1.2.2" // The version as seen in the Windows resource -#define RC_FILEVERSION 1,2,1,0 -#define RC_PRODUCTVERSION 1,2,1,0 -#define RC_PRODUCTVERSION2 "1.2.1" +#define RC_FILEVERSION 1,2,2,0 +#define RC_PRODUCTVERSION 1,2,2,0 +#define RC_PRODUCTVERSION2 "1.2.2" // Version identifier for network games. // Bump it every time you do a release unless you're certain you diff --git a/src/win32/win32gliface.cpp b/src/win32/win32gliface.cpp index be8b52e042..1323787a96 100644 --- a/src/win32/win32gliface.cpp +++ b/src/win32/win32gliface.cpp @@ -354,6 +354,11 @@ DFrameBuffer *Win32GLVideo::CreateFrameBuffer(int width, int height, bool bgra, { Win32GLFrameBuffer *fb; + if (fs) + { + I_ClosestResolution(&width, &height, 32); + } + m_DisplayWidth = width; m_DisplayHeight = height; m_DisplayBits = 32; diff --git a/src/win32/win32video.cpp b/src/win32/win32video.cpp index e07ca36609..a39f3e65e7 100644 --- a/src/win32/win32video.cpp +++ b/src/win32/win32video.cpp @@ -641,6 +641,11 @@ DFrameBuffer *Win32Video::CreateFrameBuffer (int width, int height, bool bgra, b PalEntry flashColor; int flashAmount; + if (fullscreen) + { + I_ClosestResolution(&width, &height, D3D ? 32 : 8); + } + LOG4 ("CreateFB %d %d %d %p\n", width, height, fullscreen, old); if (old != NULL) diff --git a/wadsrc/static/language.enu b/wadsrc/static/language.enu index d03d19db2a..cd1586d587 100644 --- a/wadsrc/static/language.enu +++ b/wadsrc/static/language.enu @@ -1780,7 +1780,6 @@ DSPLYMNU_SCREENSIZE = "Screen size"; DSPLYMNU_BRIGHTNESS = "Brightness"; DSPLYMNU_VSYNC = "Vertical Sync"; DSPLYMNU_CAPFPS = "Rendering Interpolation"; -DSPLYMNU_COLUMNMETHOD = "Column render mode"; DSPLYMNU_WIPETYPE = "Screen wipe style"; DSPLYMNU_SHOWENDOOM = "Show ENDOOM screen"; DSPLYMNU_BLOODFADE = "Blood Flash Intensity"; diff --git a/wadsrc/static/menudef.txt b/wadsrc/static/menudef.txt index 29d3a1b10e..4db5d70517 100644 --- a/wadsrc/static/menudef.txt +++ b/wadsrc/static/menudef.txt @@ -595,12 +595,6 @@ OptionMenu "JoystickConfigMenu" // //------------------------------------------------------------------------------------------- -OptionValue ColumnMethods -{ - 0.0, "$OPTVAL_ORIGINAL" - 1.0, "$OPTVAL_OPTIMIZED" -} - OptionValue SkyModes { 0.0, "$OPTVAL_NORMAL" @@ -696,7 +690,6 @@ OptionMenu "VideoOptions" Slider "$DSPLYMNU_BLOODFADE", "blood_fade_scalar", 0.0, 1.0, 0.05, 2 Slider "$DSPLYMNU_PICKUPFADE", "pickup_fade_scalar", 0.0, 1.0, 0.05, 2 Slider "$DSPLYMNU_WATERFADE", "underwater_fade_scalar", 0.0, 1.0, 0.05, 2 - Option "$DSPLYMNU_COLUMNMETHOD", "r_columnmethod", "ColumnMethods" StaticText " " Option "$DSPLYMNU_WIPETYPE", "wipetype", "Wipes" diff --git a/wadsrc/static/xlat/base.txt b/wadsrc/static/xlat/base.txt index 8a99ba3183..0fc02739ef 100644 --- a/wadsrc/static/xlat/base.txt +++ b/wadsrc/static/xlat/base.txt @@ -99,7 +99,7 @@ include "xlat/defines.i" 97 = WALK|REP|MONST, Teleport (0, tag) 98 = WALK|REP, Floor_LowerToHighest (tag, F_FAST, 136) 99 = USE|REP, Door_LockedRaise (tag, D_FAST, 0, BCard | CardIsSkull) -100 = WALK, Stairs_BuildUpDoom (tag, ST_TURBO, 16, 0, 0) +100 = WALK, Stairs_BuildUpDoomCrush (tag, ST_TURBO, 16, 0, 0) 101 = USE, Floor_RaiseToLowestCeiling (tag, F_SLOW) 102 = USE, Floor_LowerToHighest (tag, F_SLOW, 128) 103 = USE, Door_Open (tag, D_SLOW) @@ -126,7 +126,7 @@ include "xlat/defines.i" 124 = WALK, Exit_Secret (0) 125 = MONWALK, Teleport (0, tag) 126 = MONWALK|REP, Teleport (0, tag) -127 = USE, Stairs_BuildUpDoom (tag, ST_TURBO, 16, 0, 0) +127 = USE, Stairs_BuildUpDoomCrush (tag, ST_TURBO, 16, 0, 0) 128 = WALK|REP, Floor_RaiseToNearest (tag, F_SLOW) 129 = WALK|REP, Floor_RaiseToNearest (tag, F_FAST) 130 = WALK, Floor_RaiseToNearest (tag, F_FAST) @@ -259,9 +259,9 @@ include "xlat/defines.i" 254 = 0, Scroll_Texture_Model (lineid, 0) 255 = 0, Scroll_Texture_Offsets () 256 = WALK|REP, Stairs_BuildUpDoom (tag, ST_SLOW, 8, 0, 0) -257 = WALK|REP, Stairs_BuildUpDoom (tag, ST_TURBO, 16, 0, 0) +257 = WALK|REP, Stairs_BuildUpDoomCrush (tag, ST_TURBO, 16, 0, 0) 258 = USE|REP, Stairs_BuildUpDoom (tag, ST_SLOW, 8, 0, 0) -259 = USE|REP, Stairs_BuildUpDoom (tag, ST_TURBO, 16, 0, 0) +259 = USE|REP, Stairs_BuildUpDoomCrush (tag, ST_TURBO, 16, 0, 0) 260 = 0, TranslucentLine (lineid, 168) // Changed to better reflect the BOOM default 261 = 0, Transfer_CeilingLight (tag) 262 = WALK|MONST, Teleport_Line (tag, tag, 1) diff --git a/wadsrc/static/xlat/strife.txt b/wadsrc/static/xlat/strife.txt index 50fcb2ff8e..e4ae8244f1 100644 --- a/wadsrc/static/xlat/strife.txt +++ b/wadsrc/static/xlat/strife.txt @@ -120,7 +120,7 @@ RetailOnly = 121 104 = WALK, Light_MinNeighbor (tag) 108 = WALK, Door_Raise (tag, D_FAST, VDOORWAIT) 109 = WALK, Door_Open (tag, D_FAST) -100 = WALK, Stairs_BuildUpDoom (tag, ST_TURBO, 16, 0, 0) +100 = WALK, Stairs_BuildUpDoomCrush (tag, ST_TURBO, 16, 0, 0) 197 = WALK|REP, ACS_ExecuteAlways (0, 0, 197, tag) 110 = WALK, Door_Close (tag, D_FAST) 119 = WALK, Floor_RaiseToNearest (tag, F_SLOW) @@ -255,7 +255,7 @@ RetailOnly = 121 112 = USE, Door_Open (tag, D_FAST) 113 = USE, Door_Close (tag, D_FAST) 122 = USE, Plat_DownWaitUpStayLip (tag, P_TURBO, PLATWAIT, 0) -127 = USE, Stairs_BuildUpDoom (tag, ST_TURBO, 16, 0, 0) +127 = USE, Stairs_BuildUpDoomCrush (tag, ST_TURBO, 16, 0, 0) 131 = USE, Floor_RaiseToNearest (tag, F_FAST) 133 = USE, Door_LockedRaise (tag, D_FAST, 0, 4) 135 = USE, Door_LockedRaise (tag, D_FAST, 0, 11) diff --git a/wadsrc/static/zscript/heretic/hereticartifacts.txt b/wadsrc/static/zscript/heretic/hereticartifacts.txt index 20f52a2c93..3b7f14ad82 100644 --- a/wadsrc/static/zscript/heretic/hereticartifacts.txt +++ b/wadsrc/static/zscript/heretic/hereticartifacts.txt @@ -66,7 +66,7 @@ Class ArtiTomeOfPower : PowerupGiver Loop; } - bool Use (bool pickup) + override bool Use (bool pickup) { Playerinfo p = Owner.player; if (p && p.morphTics && (p.MorphStyle & MRF_UNDOBYTOMEOFPOWER)) diff --git a/wadsrc/static/zscript/heretic/weaponblaster.txt b/wadsrc/static/zscript/heretic/weaponblaster.txt index 913abffdb6..e7e1e92b55 100644 --- a/wadsrc/static/zscript/heretic/weaponblaster.txt +++ b/wadsrc/static/zscript/heretic/weaponblaster.txt @@ -220,7 +220,7 @@ class Ripper : Actor Stop; } - int DoSpecialDamage (Actor target, int damage, Name damagetype) + override int DoSpecialDamage (Actor target, int damage, Name damagetype) { if (target is "Ironlich") { // Less damage to Ironlich bosses diff --git a/wadsrc/static/zscript/heretic/weaponphoenix.txt b/wadsrc/static/zscript/heretic/weaponphoenix.txt index eb75acb1dd..558a257cdd 100644 --- a/wadsrc/static/zscript/heretic/weaponphoenix.txt +++ b/wadsrc/static/zscript/heretic/weaponphoenix.txt @@ -311,7 +311,7 @@ class PhoenixFX2 : Actor } - int DoSpecialDamage (Actor target, int damage, Name damagetype) + override int DoSpecialDamage (Actor target, int damage, Name damagetype) { if (target.player && Random[PhoenixFX2]() < 128) { // Freeze player for a bit diff --git a/wadsrc/static/zscript/heretic/weaponskullrod.txt b/wadsrc/static/zscript/heretic/weaponskullrod.txt index a8d77e1d8c..da959f7ae7 100644 --- a/wadsrc/static/zscript/heretic/weaponskullrod.txt +++ b/wadsrc/static/zscript/heretic/weaponskullrod.txt @@ -402,7 +402,7 @@ class RainPillar : Actor // Rain pillar 1 ------------------------------------------------------------ - int DoSpecialDamage (Actor target, int damage, Name damagetype) + override int DoSpecialDamage (Actor target, int damage, Name damagetype) { if (target.bBoss) { // Decrease damage for bosses diff --git a/wadsrc/static/zscript/hexen/heresiarch.txt b/wadsrc/static/zscript/hexen/heresiarch.txt index db4860c349..f89d2fb839 100644 --- a/wadsrc/static/zscript/hexen/heresiarch.txt +++ b/wadsrc/static/zscript/hexen/heresiarch.txt @@ -112,7 +112,7 @@ class Heresiarch : Actor Stop; } - void Die (Actor source, Actor inflictor, int dmgflags) + override void Die (Actor source, Actor inflictor, int dmgflags) { // The heresiarch just executes a script instead of a special upon death int script = special; @@ -698,8 +698,8 @@ class SorcBall2 : SorcBall Actor parent = target; Actor mo = Spawn("SorcFX2", Pos + (0, 0, parent.Floorclip + Heresiarch.SORC_DEFENSE_HEIGHT), ALLOW_REPLACE); - bReflective = true; - bInvulnerable = true; + parent.bReflective = true; + parent.bInvulnerable = true; parent.args[0] = Heresiarch.SORC_DEFENSE_TIME; if (mo) mo.target = parent; } diff --git a/wadsrc/static/zscript/shared/setcolor.txt b/wadsrc/static/zscript/shared/setcolor.txt index 18105ef543..2d9d3be576 100644 --- a/wadsrc/static/zscript/shared/setcolor.txt +++ b/wadsrc/static/zscript/shared/setcolor.txt @@ -28,7 +28,7 @@ class FadeSetter : Actor RenderStyle "None"; } - void PostBeginPlay() + override void PostBeginPlay() { Super.PostBeginPlay(); CurSector.SetFade(color(args[0], args[1], args[2])); diff --git a/wadsrc/static/zscript/strife/weapongrenade.txt b/wadsrc/static/zscript/strife/weapongrenade.txt index 7a775c57ba..21e568313c 100644 --- a/wadsrc/static/zscript/strife/weapongrenade.txt +++ b/wadsrc/static/zscript/strife/weapongrenade.txt @@ -241,7 +241,7 @@ class PhosphorousFire : Actor Stop; } - int DoSpecialDamage (Actor target, int damage, Name damagetype) + override int DoSpecialDamage (Actor target, int damage, Name damagetype) { if (target.bNoBlood) {