jackall
You can change this now in User CP.
- Reaction score
- 37
JASS:
function Blink takes unit who returns nothing
local real maxX=GetRectMaxX(bj_mapInitialPlayableArea)
local real maxY=GetRectMaxY(bj_mapInitialPlayableArea)
local real minX=GetRectMinX(bj_mapInitialPlayableArea)
local real minY=GetRectMinY(bj_mapInitialPlayableArea)
local real newX=GetOrderPointX()
local real newY=GetOrderPointY()
local real oldX
local real oldY
local real angle
if newX>maxX then
set newX=maxX
endif
if newX<minX then
set newX=minX
endif
if newY>maxY then
set newY=maxY
endif
if newY<minY then
set newY=minY
endif
set angle=bj_RADTODEG*Atan2(newY-oldY,newX-oldX)
call SetUnitX(who,newX)
call SetUnitY(who,newY)
call DestroyEffect(AddSpecialEffect("Abilities\\Spells\\NightElf\\Blink\\BlinkCaster.mdl",newX,newY))
call IssueImmediateOrder(who,"stop")
call SetUnitFacing(who,angle)
call PanCameraTo(newX,newY)
call BJDebugMsg(R2S(newX))
call BJDebugMsg(R2S(newY))
endfunction
Code:
Builder Move
Events
Unit - A unit Is issued an order targeting a point
Conditions
(Unit-type of (Triggering unit)) Equal to Builder
Or - Any (Conditions) are true
Conditions
(String((Issued order))) Equal to move
(String((Issued order))) Equal to smart
Actions
Custom script: //local real x = GetOrderPointX()
Custom script: //local real y = GetOrderPointY()
Custom script: call Blink(GetTriggerUnit())
The Blink function doesn't get called...why not?
EDIT: nvm fixed