Thread: Thunder Whirl
View Single Post
Old 11-27-2007, 11:14 PM   #18
moyack
Evil Emoticon
 
moyack's Avatar


Respected User
Project Leader: PoC
 
Join Date: Jan 2006
Posts: 3,279

Submissions (17)

moyack is a splendid one to behold (666)moyack is a splendid one to behold (666)moyack is a splendid one to behold (666)moyack is a splendid one to behold (666)

AI Tournament #2 - 2nd PlaceHero Contest - Second place

Send a message via MSN to moyack
Default

Ok, I've checked your spell, and I liked how you solved the integer(Data) :)

Some minor things easy to solve:
  • You use in the tree detection a constant value which should be part of the constant globals, in this line:
    Collapse JASS:
    call SetRect(TreeRect,x2-96,y2-96,x2+96,y2+96) // make the values a constant global variable
  • You can make the spell structs private, at the end they shouldn't be accessible to other functions and we ensure they don't mess with other popular knockback structs in other maps.
  • You do this calculation:
    Collapse JASS:
    set twdat.speed = StartCircleSpeed*bj_PI/180.0
    set twdat.increament = DecreaseCircleSpeed (level)*bj_PI/180.0
    Collapse JASS:
    call SetUnitFacing(twdat.target,twdat.angle*(180/3.1415))
    call SetUnitFacing(twdat.caster,twdat.angle*(180/3.1415))

    You can replace bj_PI/180.0 by bj_DEGTORAD and 180/3.1415 by bj_RADTODEG

Please fix that and I'll approve this spell.
moyack is offline   Reply With Quote