I am interested in the arcs you used, what is the formula you used or the way you implemented it?
XY-arc:
For the XY-arc I've used the "basic angle" (the normal angle would depend on the position of the caster compared to the position of the targetted unit), but since I've used the cosinus, it would bug (I have to divide 12 with the cosinus, cos(90º) = 0, so in that case I had to divide something with zero).
First I will show an image which might clear up a few things ^^
A triangle... a right-angled triangle, this is the basis.
On the drawing:
A = Angle that the missile has to make every loop
c = Offset the missile needs to be moved every loop
b = Offset the missile moves towards the caster (= 12.00, this never changes... I want it to move smoothly towards the target)
The arc formula is:
Set Sloc[2] = (Sloc[1] offset by (12.00 / (Cos(SReal[5]))) towards SReal[1] degrees)
That doesn't say much I guess?
I'll try to explain this
The initial angle of the missile is defined by another formula (actually 3, since it's different for positive/negative angles and 0º), but I won't show that... all you need to know is that it's a pre-defined angle.
Then I have divided that angle by 12.00 (the same as b), this new number will become the amount of degrees the original angle will change every loop.
In the arc-formula, I move the missile
(if you don't know why, it comes from the formula
"Cos(A) = b/c"
Since I already know b (which is 12.00) and A (which changes every loop, but I decide the amount it changes, so I also know A).
the formula becomes:
"c = b/Cos(A)"
OR: c = 12.00/Cos(A)
Let's say A = 60º
c = 12/Cos(60º) = 12/0.5 => c = 24
Which means I need to move the missile with an offset of 24 towards 60º.
This value will get smaller and smaller, until it reaches c = 12 and will then increase again (the angle will become negative).
Z-arc:
(height)
This is a lot easier, since all missiles have the same Z-angle (65º I believe)
We'll need the drawing again...
This time, I want to calculate 'a' (which is the height, obviously).
Since the formula is
"tan(A) = a/b"
We know A, it's a pre-defined angle (and it decreases by 6º every loop).
We also know b
We need to know a, so this becomes:
"a = tan(A) x b".
if A = 30º: a = tan(30º) x 12.00 => a = 6.93
The value will decrease as the angle becomes negative, thus the missile descends.
ehhh, I'm not the best teacher... this is really simple once you know how to do it, though ><
Kingzz said:
Lol, MUI means "Multi-Unit Instanceable", or: multiple units can use this spell at the same time, so every unit on the map can cast it once at the same moment.
You are creating something new, probably something like "MCI" (Multi-Cast Instanceable): it doesn't matter who casts it and when, it will always work - this cannot be done with hashtables (or perhaps it can, but a long way around).
And I think I have proven that it is half-MCI and completely MUI (the small missiles will not bug with the shockwave while existing at the same time, casted by the same unit, but when there are multiple shockwaves, it will bug indeed).]
Funny, since it's absolutely pointless to have multiple shockwaves runnig at the same time.
King said:
If you can't spam it mindlessly it ain't MUI by my book
Lol xD
it
is MUI, though...
Yeah, indexing ftw, but I like hashtables because they're really easy to use and I'm just way too lazy xD
King said:
If you can, merge the 2 triggers(periodic ones).
Perhaps I can, but then the overall stress increases according to me.
The shockwave-trigger will turn off when it's done and then the small missiles turn on.
If you pour it all into 1 trigger, it loops the entire, huge thing until the entire spell is done.