summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMittendrein Markus <maxmitti@gmx.net>2016-03-03 14:56:13 +0100
committerMittendrein Markus <maxmitti@gmx.net>2016-03-03 14:56:13 +0100
commit21c1fd36600dfb3edccbbf8df1075243002b2b90 (patch)
tree5c45ca82366ea6e9d30d3b2eccff44fa4dd442b4
parent7323a3f82f11b1101b45a498dc503a533069ed2c (diff)
downloadtempelschubsen-21c1fd36600dfb3edccbbf8df1075243002b2b90.tar.gz
tempelschubsen-21c1fd36600dfb3edccbbf8df1075243002b2b90.zip
Iceball explodes if the clonk is aiming longer than 180 frames
-rw-r--r--TemplePushing.c4s/System.c4g/IceBall.c22
1 files changed, 17 insertions, 5 deletions
diff --git a/TemplePushing.c4s/System.c4g/IceBall.c b/TemplePushing.c4s/System.c4g/IceBall.c
index c9b67ab..ba11967 100644
--- a/TemplePushing.c4s/System.c4g/IceBall.c
+++ b/TemplePushing.c4s/System.c4g/IceBall.c
@@ -1,6 +1,6 @@
/*-- Iceball --*/
-#strict
+#strict 2
#appendto ICEB
@@ -42,11 +42,23 @@ func FxIceStrikeFlightTimer(pTarget, iEffectNumber, iEffectTime)
// Ausrichtung nach Caster
if (!iLaunchFree && pCaster)
{
- var x=GetX(pCaster)+Sin(iAngle, 25), y=GetY(pCaster)-Cos(iAngle, 25);
- if (GetX()!=x || GetY()!=y)
+ if(iEffectTime > 180)
{
- DrawParticleLine("Snow", x-GetX(), y-GetY(), 0, 0, 5, 40, 16777215, 16777215, 0);
- SetPosition(x, y);
+ var aimer = LocalN("pAimer", pCaster) || LocalN("pAimer", LocalN("pAimingClonk", pCaster));
+ if(aimer)
+ {
+ aimer->ControlThrow();
+ }
+ return Hit();
+ }
+ else
+ {
+ var x=GetX(pCaster)+Sin(iAngle, 25), y=GetY(pCaster)-Cos(iAngle, 25);
+ if (GetX()!=x || GetY()!=y)
+ {
+ DrawParticleLine("Snow", x-GetX(), y-GetY(), 0, 0, 5, 40, 16777215, 16777215, 0);
+ SetPosition(x, y);
+ }
}
}