marrub
/
Lithia
Archived
1
0
Fork 0
This repository has been archived on 2023-06-17. You can view files and clone it, but cannot push or open issues/pull-requests.
Lithia/pksrc/lscripts/Items/BlurSphere.dec

87 lines
1.7 KiB
Plaintext

actor Lith_HasBarrier : Powerup
{
Powerup.Duration -30
Powerup.Color "C3 DF E8", 0.1
}
actor Lith_BarrierFX
{
RenderStyle "Add"
Scale 0.3
+NOTIMEFREEZE
+NOINTERACTION
states
{
Spawn:
LBAR A 10 nodelay A_PlaySound("player/barrier", CHAN_NOPAUSE|CHAN_LISTENERZ)
SpawnLoop:
LBAR A 0 A_SetScale(scalex * 0.86)
LBAR A 1 A_FadeOut(0.25)
loop
}
}
actor Lith_BarrierProtection : Lith_CustomFunction
{
states
{
Pickup:
TNT1 A 0 A_JumpIf(damage >= 20 || damage == 0, "Nope")
TNT1 A 0 A_CheckFlag("MISSILE", "PickupOk")
goto Nope
PickupOk:
TNT1 A 0 A_JumpIf(!CallACS("Lith_BarrierCheck"), "Nope")
TNT1 A 0 A_Jump(64, "Nope")
TNT1 A 0 Thing_Remove(0)
TNT1 A 0 A_SpawnItemEx("Lith_BarrierFX")
stop
Nope:
TNT1 A 0 A_RailWait
stop
}
}
actor Lith_BarrierSpell : Lith_CustomFunction
{
states
{
Pickup:
TNT1 A 0 A_RadiusGive("Lith_BarrierProtection", 64, 0)
TNT1 A 0 A_RailWait
stop
}
}
actor Lith_BlurSphere : Lith_CustomInventory replaces BlurSphere
{
//$Category "Powerups"
Tag "Fragma"
Inventory.PickupSound "player/pickup/barrier"
+FLOATBOB
+COUNTITEM
+VISIBILITYPULSE
+INVENTORY.BIGPOWERUP
+INVENTORY.FANCYPICKUPSOUND
+INVENTORY.ALWAYSPICKUP
states
{
Spawn:
PINS ABCD 6 bright
loop
Pickup:
TNT1 A 0 ACS_NamedExecuteAlways("Lith_LogName", 0, msg_blursphere)
TNT1 A 0 ACS_NamedExecuteAlways("Lith_Barrier")
TNT1 A 0 A_TakeInventory("Lith_HasBarrier")
TNT1 A 0 A_GiveInventory("Lith_HasBarrier")
stop
}
}
// EOF