1
0
mirror of https://github.com/JezuzLizard/BO2-Reimagined.git synced 2025-06-07 13:49:33 -05:00
BO2-Reimagined/scripts/zm/reimagined/_explosive_dart.csc
2024-04-19 16:09:11 -07:00

33 lines
676 B
Plaintext

main()
{
level._effect["dart_light"] = loadfx("weapon/titus/fx_titus_bolt_blink_os");
}
spawned(localclientnum)
{
player = getlocalplayer(localclientnum);
enemy = 0;
self.fxtagname = "tag_origin";
if (self.team != player.team)
enemy = 1;
self thread loop_local_sound(localclientnum, "wpn_titus_alert", 0.3, level._effect["dart_light"]);
}
loop_local_sound(localclientnum, alias, interval, fx)
{
self endon("entityshutdown");
while (true)
{
self playsound(localclientnum, alias);
n_id = playfxontag(localclientnum, fx, self, self.fxtagname);
wait(interval);
stopfx(localclientnum, n_id);
interval /= 1.2;
if (interval < 0.1)
interval = 0.1;
}
}