I have a zscript.txt file in my mod folder that imports my monster script:
I have my monster script in the exact folder as above:Code: Select all
#include "zscript/necros/cacodemonExt.zs"
I have this in my mapinfo:Code: Select all
//=========================================================================== // // Cacodemon // //=========================================================================== class CacodemonExt : Cacodemon { Default { //$Category CustomMonsters //$Title "CacodemonExt" Health 400; Radius 31; Height 56; Mass 400; Speed 8; PainChance 128; Monster; +FLOAT +NOGRAVITY SeeSound "caco/sight"; PainSound "caco/pain"; DeathSound "caco/death"; ActiveSound "caco/active"; Obituary "$OB_CACO"; HitObituary "$OB_CACOHIT"; Tag "$FN_CACO"; } States { Spawn: HEAD A 10 A_Look; Loop; See: HEAD A 3 CacodemonExtMove; Loop; Missile: HEAD B 5 A_FaceTarget; HEAD C 5 A_FaceTarget; HEAD D 5 BRIGHT A_HeadAttack; Goto See; Pain: HEAD E 3; HEAD E 3 A_Pain; HEAD F 6; Goto See; Death: HEAD G 8; HEAD H 8 A_Scream; HEAD I 8; HEAD J 8; HEAD K 8 A_NoBlocking; HEAD L -1 A_SetFloorClip; Stop; Raise: HEAD L 8 A_UnSetFloorClip; HEAD KJIHG 8; Goto See; } } //=========================================================================== // // Code (must be attached to Actor) // //=========================================================================== extend class CacodemonExt { void CacodemonExtMove() { //attenuate monster velocity over time when walking to remove momentum A_ScaleVelocity(0.95); A_Chase(); } }
This seems to work, since if I give an invalid classname, zdoom will stop with an error when loadingCode: Select all
spawnnums { 32011 = cacodemonExt }
Yet in my map, I see this: "Unknown type 32011 at (x, y)"
What part am I missing?
