Fix implicit class pointer casting.

This commit is contained in:
Mari the Deer 2023-02-11 13:19:03 +01:00
commit 99c9bda6ea
3 changed files with 6 additions and 5 deletions

View file

@ -1,3 +1,3 @@
[default]
SWWM_MODVER="\cyDEMOLITIONIST \cw1.3pre r743 \cu(Sat 11 Feb 13:27:05 CET 2023)\c-";
SWWM_SHORTVER="\cw1.3pre r743 \cu(2023-02-11 13:27:05)\c-";
SWWM_MODVER="\cyDEMOLITIONIST \cw1.3pre r744 \cu(Sat 11 Feb 13:27:17 CET 2023)\c-";
SWWM_SHORTVER="\cw1.3pre r744 \cu(2023-02-11 13:27:17)\c-";

View file

@ -335,7 +335,7 @@ Class SWWMStaticHandler : StaticEventHandler
{
if ( !(cls is 'Thinker') || (cls is 'Actor') || (cls == 'Thinker') )
continue;
sdefs.Push(cls);
sdefs.Push((Class<Thinker>)(cls));
}
if ( !e.Args[0] )
{

View file

@ -124,13 +124,14 @@ extend Class Demolitionist
// add collectible to stats
if ( item is 'SWWMCollectible' )
{
let col = SWWMCollectible(item);
if ( !ingivecheat )
{
SWWMHandler.AddOneliner(SWWMCollectible(item).GetLine,2);
SWWMHandler.AddOneliner(col.GetLine,2);
facegrin = true;
}
if ( !mystats ) return;
let cls = item.GetClass();
let cls = col.GetClass();
if ( (mystats.ownedcollectibles.Size() > 0) && (mystats.ownedcollectibles.Find(cls) < mystats.ownedcollectibles.Size()) ) return;
mystats.ownedcollectibles.Push(cls);
}