• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

GetConstructingStructure question

Status
Not open for further replies.
Level 7
Joined
Feb 14, 2008
Messages
289
Would this apply to the last constructing structure?

Here is my code
Code:
function Portal_Ability_Actions takes nothing returns nothing
        local real ax
        local real bx
        local real ay
        local real by
        local unit dummy
        local unit caster
        local unit a
        local unit b
    if(GetSpellAbilityId()=='A02D')then
        set ax = GetSpellTargetX()
        set ay = GetSpellTargetY()
        set bx = GetUnitX(GetTriggerUnit())
        set by = GetUnitY(GetTriggerUnit())
        set dummy = CreateUnit(GetTriggerPlayer, 'u001', ax, ay, 270)
        call IssuePointOrderById(dummy, 'h003', ax, ay)
        set a = GetConstructingStructure()
        set dummy = CreateUnit(GetTriggerPlayer, 'u001', bx, by, 270)
        call IssuePointOrderById(dummy, 'h003', bx, by)
        set b = GetConstructingStructure()
    else
        DoNothing()
    endif
    endfunction
 
Status
Not open for further replies.
Top