• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

How do i put slide in my map? ;)

Status
Not open for further replies.
Level 5
Joined
Jul 14, 2008
Messages
81
can you go a bit further into details? :S




Have this ... can anyone tell me whats wrong?
JASS:
function Trig_Gjeit_Conditions takes nothing returns boolean
    if ( GetBooleanOr(  GetIssuedOrderIdBJ() == String2OrderIdBJ("smart") , GetIssuedOrderIdBJ() == String2OrderIdBJ("move") ) ) then
        return true
    endif
    return false
endfunction

function Trig_Gjeit_Actions takes nothing returns nothing
    local location p
    local location p2
    set p = GetUnitLoc(GetOrderedUnit())
    if ( GetTerrainTypeBJ(p) == 'Nice' ) then
        set p2 = GetOrderPointLoc()
        call SetUnitPositionLocFacingBJ( GetTriggerUnit(), PolarProjectionBJ(p, 1.00, DistanceBetweenPoints(p, p2)), AngleBetweenPoints(p, p2) )
        call RemoveLocation( p2 )
    endif
    call RemoveLocation( p )
endfunction

function InitTrig_Gjeit takes nothing returns nothing
    set gg_trg_Gjeit = CreateTrigger(  )
    call TriggerRegisterAnyUnitEventBJ( gg_trg_Gjeit, EVENT_PLAYER_UNIT_ISSUED_POINT_ORDER )
    call TriggerAddCondition( gg_trg_Gjeit, Condition( function Trig_Gjeit_Conditions ) )
    call TriggerAddAction( gg_trg_Gjeit, function Trig_Gjeit_Actions )
endfunction
 
Status
Not open for further replies.
Top