2016-10-14 18:08:41 +00:00
|
|
|
//===========================================================================
|
|
|
|
//
|
|
|
|
// Spider boss
|
|
|
|
//
|
|
|
|
//===========================================================================
|
|
|
|
class SpiderMastermind : Actor
|
|
|
|
{
|
|
|
|
Default
|
|
|
|
{
|
|
|
|
Health 3000;
|
|
|
|
Radius 128;
|
|
|
|
Height 100;
|
|
|
|
Mass 1000;
|
|
|
|
Speed 12;
|
|
|
|
PainChance 40;
|
|
|
|
Monster;
|
|
|
|
+BOSS
|
|
|
|
+MISSILEMORE
|
|
|
|
+FLOORCLIP
|
|
|
|
+NORADIUSDMG
|
|
|
|
+DONTMORPH
|
|
|
|
+BOSSDEATH
|
2021-06-29 19:08:58 +00:00
|
|
|
+E3M8BOSS
|
|
|
|
+E4M8BOSS
|
2016-10-14 18:08:41 +00:00
|
|
|
SeeSound "spider/sight";
|
|
|
|
AttackSound "spider/attack";
|
|
|
|
PainSound "spider/pain";
|
|
|
|
DeathSound "spider/death";
|
|
|
|
ActiveSound "spider/active";
|
|
|
|
Obituary "$OB_SPIDER";
|
2018-06-24 10:31:55 +00:00
|
|
|
Tag "$FN_SPIDER";
|
2016-10-14 18:08:41 +00:00
|
|
|
}
|
|
|
|
States
|
|
|
|
{
|
|
|
|
Spawn:
|
|
|
|
SPID AB 10 A_Look;
|
|
|
|
Loop;
|
|
|
|
See:
|
|
|
|
SPID A 3 A_Metal;
|
|
|
|
SPID ABB 3 A_Chase;
|
|
|
|
SPID C 3 A_Metal;
|
|
|
|
SPID CDD 3 A_Chase;
|
|
|
|
SPID E 3 A_Metal;
|
|
|
|
SPID EFF 3 A_Chase;
|
|
|
|
Loop;
|
|
|
|
Missile:
|
|
|
|
SPID A 20 BRIGHT A_FaceTarget;
|
|
|
|
SPID G 4 BRIGHT A_SPosAttackUseAtkSound;
|
|
|
|
SPID H 4 BRIGHT A_SposAttackUseAtkSound;
|
|
|
|
SPID H 1 BRIGHT A_SpidRefire;
|
|
|
|
Goto Missile+1;
|
|
|
|
Pain:
|
|
|
|
SPID I 3;
|
|
|
|
SPID I 3 A_Pain;
|
|
|
|
Goto See;
|
|
|
|
Death:
|
|
|
|
SPID J 20 A_Scream;
|
|
|
|
SPID K 10 A_NoBlocking;
|
|
|
|
SPID LMNOPQR 10;
|
|
|
|
SPID S 30;
|
|
|
|
SPID S -1 A_BossDeath;
|
|
|
|
Stop;
|
|
|
|
}
|
|
|
|
}
|
2016-10-26 15:21:25 +00:00
|
|
|
|
|
|
|
//===========================================================================
|
|
|
|
//
|
|
|
|
// Code (must be attached to Actor)
|
|
|
|
//
|
|
|
|
//===========================================================================
|
|
|
|
|
|
|
|
extend class Actor
|
|
|
|
{
|
|
|
|
void A_SpidRefire()
|
|
|
|
{
|
|
|
|
// keep firing unless target got out of sight
|
|
|
|
A_FaceTarget();
|
|
|
|
if (Random[CPosRefire](0, 255) >= 10)
|
|
|
|
{
|
|
|
|
if (!target
|
|
|
|
|| HitFriend()
|
|
|
|
|| target.health <= 0
|
|
|
|
|| !CheckSight(target, SF_SEEPASTBLOCKEVERYTHING|SF_SEEPASTSHOOTABLELINES))
|
|
|
|
{
|
|
|
|
SetState(SeeState);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
void A_Metal()
|
|
|
|
{
|
2020-01-04 13:15:32 +00:00
|
|
|
A_StartSound("spider/walk", CHAN_BODY, CHANF_DEFAULT, 1, ATTN_IDLE);
|
2016-10-26 15:21:25 +00:00
|
|
|
A_Chase();
|
|
|
|
}
|
|
|
|
}
|