'matrixMulVector'
'vectorCross'
'vectorDot'
'vectorOrthoBasis'
What the heck do these do? I was messing around with vectors and found these.
Also:
for(%i=0;%i<%num;%i++) {
%r = 6.28318530;
%nvel = %vel;
%theta = mcos(getrandom(0, 1000)/1000 * %r);
%pitch = msin(getrandom(0, 1000)/1000 * %r);
%theta -= %pitch;
%sx = %spread * %theta;
%sy = %spread * msin(macos(%theta));
%sz = %spread * %pitch;
%nvel = vectorAdd(%nvel, %sx SPC %sy SPC %sz);
%obj.spawnProjectile(%proj,%nvel,%scale,%slot);
}
I assume i'm either doing something very wrong here or there's a much better way to do this.
Or both.
(all variables have been defined already if they're not defined here)