View Single Post
Old 04-17-2009, 11:24 AM   #7
akolyt0r
In Flames
 
akolyt0r's Avatar
 
Join Date: Jan 2006
Posts: 1,154

Submissions (3)

akolyt0r has a spectacular aura about (120)

Default

Quote:
Originally Posted by JonNny
Do you mean using 0.017453 instead of bj_DEGTORAD) ?
no, just use radians directly...
example:
Collapse JASS:
local real angstep = 2*bj_PI / I2R(EssencesAmount) //2*PI (radians) == 360 (degrees)
//...
    loop 
            exitwhen a > EssencesAmount
            // Creating the missiles here
            set angle = angstep * I2R(a)
            set Essences.Data[Essences.Index-1].angle[a] = angle
            set Essences.Data[Essences.Index-1].EssenceDummy[a] = CreateUnit(GetOwningPlayer(caster), DummyID , x + ReleaseDistance * Cos(angle),y + ReleaseDistance * Sin(angle) , angle)
            set Essences.Data[Essences.Index-1].DamagedUnits[a] = CreateGroup()
            set Essences.Data[Essences.Index-1].MissileScale[a] = MissileStartScale
            set a = a + 1
    endloop
of course you have to change the rest of the code (callback function) aswell, to get rid of all those bj_DEGTORAD
__________________
akolyt0r is offline   Reply With Quote