actor DarkSniperBoss : BaseMM8BDMWep_CBM
{
dropitem "DarkShieldWepCDropped"
Weapon.AmmoUse 4
Weapon.AmmoGive 28
Weapon.SlotNumber 1
Obituary "$OB_DARK3SNIPE"
Inventory.Pickupmessage "maybe"
weapon.ammotype "DarkSniperAmmo"
+WEAPON.NOAUTOAIM
States
{
Spawn:
C_05 K 1
loop
Ready:
DKC3 B 0 ACS_ExecuteAlways(998,0,810)
DKC3 A 0 A_JumpIfInventory("DarkSniperAmmo",4,"Ready2")
DKC3 A 3 A_WeaponReady(WRF_NOPRIMARY)
DKC3 A 0 A_GiveInventory("DarkSniperAmmo",1)
Goto Ready+1
Ready2:
DKC3 A 3 A_WeaponReady
DKC3 A 0 A_GiveInventory("DarkSniperAmmo",1)
loop
Deselect:
TNT1 AAAAAAAAAAAAAAAAAAAAAA 0 A_Lower
DKC3 A 1 A_Lower
Loop
Select:
TNT1 AAAAAAAAAAAAAAAAAAAAAA 0 A_Raise
DKC3 A 1 A_Raise
Loop
Fire:
DKC3 A 0 A_JumpIfNoAmmo("NoAmmo")
DKC3 A 0 A_PlaySoundEx("weapon/dark3shot","Weapon")
DKC3 A 0 A_GiveInventory("Darkman3Main_CI",1)
DKC3 BCB 2
DKC3 A 13
DKC3 A 0 A_Refire
Goto Ready+1
AltFire:
//DKC3 A 0 A_JumpIfNoAmmo("NoAmmo")
DKC3 D 6
DKC3 D 0 A_PlaySoundEx("weapon/sparkalt","Weapon")
DKC3 D 0 A_GiveInventory("Darkman3Alt_CI",1)

DKC3 D 0 A_JumpIfHealthLower(2,"AFire11")
DKC3 D 0 A_JumpIfHealthLower(10,"AFire10")
DKC3 D 0 A_JumpIfHealthLower(18,"AFire10")//11
DKC3 D 0 A_JumpIfHealthLower(26,"AFire9")//21
DKC3 D 0 A_JumpIfHealthLower(34,"AFire8")//31
DKC3 D 0 A_JumpIfHealthLower(42,"AFire7")//41
DKC3 D 0 A_JumpIfHealthLower(50,"AFire6")//51
DKC3 D 0 A_JumpIfHealthLower(58,"AFire5")//61
DKC3 D 0 A_JumpIfHealthLower(66,"AFire4")//71
DKC3 D 0 A_JumpIfHealthLower(74,"AFire3")//81
DKC3 D 0 A_JumpIfHealthLower(82,"AFire2")//91

DKC3 E 8 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 14 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFireEnd:
DKC3 A 0 A_Refire
goto Ready+1

AFire2:
DKC3 E 8 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 13 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire3:
DKC3 E 8 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 12 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire4:
DKC3 E 7 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 12 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire5:
DKC3 E 7 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 11 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire6:
DKC3 E 7 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 10 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire7:
DKC3 E 6 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 10 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire8:
DKC3 E 6 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 9 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire9:
DKC3 E 6 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 8 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire10:
DKC3 E 5 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 8 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire11:
DKC3 E 5 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 7 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd
AFire12:
DKC3 E 5 A_GiveInventory("DarkSniperAmmo",1)
DKC3 D 6 A_GiveInventory("DarkSniperAmmo",1)
goto AFireEnd

NoAmmo:
DKC3 A 0
Goto Ready+1
}
}

actor DarkSniperAmmo : Ammo
{
+INVENTORY.IGNORESKILL
inventory.amount 1
inventory.maxamount 28
}

actor DarkSniperShot
{
var int user_POWER;
Translation "202:202=216:216"
PROJECTILE
radius 16
height 16
speed 60
scale 2.5
//damage (10)
Damage(10+user_POWER)
damagetype "DarkShot"
Obituary "$OB_DARK3SNIPE"
//MissileHeight
States
{
Spawn:
DSHO A 0
TROO G 0 A_JumpIf(user_POWER>=6,"Spawn2")
DSHO AA 1 A_SpawnItemEx("DarkSniperTrail1",0,0,0,0,0,0,0,1)
DSHO A 0 A_SetUserVar("user_POWER",user_POWER+3)
loop
Spawn2:
DSHO A 0
TROO G 0 A_JumpIf(user_POWER>=15,"Spawn3")
DSHO AA 1 A_SpawnItemEx("DarkSniperTrail2",0,0,0,0,0,0,0,1)
DSHO A 0 A_SetUserVar("user_POWER",user_POWER+3)
loop
Spawn3:
DSHO A 0
TROO G 0 A_JumpIf(user_POWER>=24,"Spawn4")
DSHO AA 1 A_SpawnItemEx("DarkSniperTrail3",0,0,0,0,0,0,0,1)
DSHO A 0 A_SetUserVar("user_POWER",user_POWER+3)
loop
Spawn4:
DSHO A 0
TROO G 0 A_JumpIf(user_POWER>=30,"SpawnDone")
DSHO AA 1 A_SpawnItemEx("DarkSniperTrail4",0,0,0,0,0,0,0,1)
DSHO A 0 A_SetUserVar("user_POWER",user_POWER+3)
loop
SpawnDone:
DSHO A 1 A_SpawnItemEx("DarkSniperTrail5",0,0,0,0,0,0,0,1)
loop
Death:
DSHO A 0
stop
}
}

actor DarkSniperShotB : DarkSniperShot{translation "202:202=205:205"}
actor DarkSniperShotR : DarkSniperShot{translation "202:202=171:171"}
actor DarkSniperShotO : DarkSniperShot{translation "202:202=104:104"}
actor DarkSniperShotP : DarkSniperShot{translation "202:202=229:229"}


actor DarkSniperTrail1
{
+NOINTERACTION
+NOGRAVITY
+CLIENTSIDEONLY
+FORCEXYBILLBOARD
-SOLID
scale 2.5
height 0
radius 0
ReactionTime 3
RenderStyle "translucent"
Alpha 0.90
States
{
Spawn:
DSHO A 1 A_CountDown
DSHO A 0 A_FadeOut
loop
}
}
actor DarkSniperTrail2 : DarkSniperTrail1{ReactionTime 4}
actor DarkSniperTrail3 : DarkSniperTrail1{ReactionTime 5}
actor DarkSniperTrail4 : DarkSniperTrail1{ReactionTime 6}
actor DarkSniperTrail5 : DarkSniperTrail1{ReactionTime 7}

actor DarkRing
{
Translation "202:202=216:216"
PROJECTILE
radius 14
height 14
speed 20
scale 2.5
damage (5)
damagetype "NeutralShock"
Obituary "$OB_DARK3RING"
States
{
Spawn:
DSHO BCBCBC 4
stop
Death:
TNT1 A 1
stop
}
}

actor DarkRingB : DarkRing{translation "202:202=205:205"}
actor DarkRingR : DarkRing{translation "202:202=171:171"}
actor DarkRingO : DarkRing{translation "202:202=104:104"}
actor DarkRingP : DarkRing{translation "202:202=229:229"}

actor Darkman3Main_CI : TeamColor_CI
{
states
{
FireX:
TNT1 A 0 A_FireCustomMissile("DarkSniperShot",0,1,8,0)
goto Done
FireB:
TNT1 A 0 A_FireCustomMissile("DarkSniperShotB",0,1,8,0)
goto Done
FireR:
TNT1 A 0 A_FireCustomMissile("DarkSniperShotR",0,1,8,0)
goto Done
FireO:
TNT1 A 0 A_FireCustomMissile("DarkSniperShotO",0,1,8,0)
goto Done
FireP:
TNT1 A 0 A_FireCustomMissile("DarkSniperShotP",0,1,8,0)
goto Done
}
}

actor Darkman3Alt_CI : TeamColor_CI
{
states
{
FireX:
TNT1 A 0 A_FireCustomMissile("DarkRing",0,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRing",25,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRing",-25,0,8,0)
goto Done
FireB:
TNT1 A 0 A_FireCustomMissile("DarkRingB",0,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRingB",25,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRingB",-25,0,8,0)
goto Done
FireR:
TNT1 A 0 A_FireCustomMissile("DarkRingR",0,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRingR",25,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRingR",-25,0,8,0)
goto Done
FireO:
TNT1 A 0 A_FireCustomMissile("DarkRingO",0,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRingO",25,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRingO",-25,0,8,0)
goto Done
FireP:
TNT1 A 0 A_FireCustomMissile("DarkRingP",0,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRingP",25,0,8,0)
TNT1 A 0 A_FireCustomMissile("DarkRingP",-25,0,8,0)
goto Done
}
}
