• 🏆 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!

Help, "Moving Unit" Problem

Status
Not open for further replies.
Level 5
Joined
Feb 14, 2005
Messages
48
Can anyone tell me how to set up the "move" triggers so that the caster unit would go around the target unit.(Like Omnislash in dota) i need it to make a spell. Thank You in advance.
 
Level 2
Joined
Apr 24, 2005
Messages
11
I can give u the original Omnislash in JASS or some kinda Omnislash in GUI, but...thats map stealing, ask Daelin if i can post it here.
-Argante.
 
Level 11
Joined
Jul 20, 2004
Messages
2,760
Hacking? Who cares? If the guy protected the map and you could unprotect it... Even Darky himself mentioned that protection is useless and that he can hack any map. And he is not the only one... If you know JASS you can easily look upon the map as a text. Oh well, I can't see terrain but I can steal spells as well. That's not a problem..

So go ahead, send him the map. After all, its not the guy's property, its Blizzard's. But give him credits. If you don't, I might consider it stealing or just see you with bad eyes. That's all...

~Daelin
 
Level 2
Joined
Apr 24, 2005
Messages
11
That's an OK for me :lol: , I wanna give credits to Ginsoo for making this spell and let me give it to everybody. Sry cuz I only have all the triggers, I dont know spell's ID, but triggers are more important:

//===========================================================================
// Trigger: omnislash selection
//===========================================================================
function Trig_omnislash_selection_Conditions takes nothing returns boolean
if ( not ( GetUnitTypeId(GetTriggerUnit()) == 'Nbbc' ) ) then
return false
endif
return true
endfunction

function Trig_omnislash_selection_Actions takes nothing returns nothing
call SelectUnitRemoveForPlayer( GetTriggerUnit(), GetTriggerPlayer() )
endfunction

//===========================================================================
function InitTrig_omnislash_selection takes nothing returns nothing
set gg_trg_omnislash_selection = CreateTrigger( )
call DisableTrigger( gg_trg_omnislash_selection )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(1), true )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(2), true )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(3), true )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(4), true )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(5), true )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(7), true )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(8), true )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(9), true )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(10), true )
call TriggerRegisterPlayerSelectionEventBJ( gg_trg_omnislash_selection, Player(11), true )
call TriggerAddCondition( gg_trg_omnislash_selection, Condition( function Trig_omnislash_selection_Conditions ) )
call TriggerAddAction( gg_trg_omnislash_selection, function Trig_omnislash_selection_Actions )
endfunction

//===========================================================================
// Trigger: OmniSlashEffect
//===========================================================================
function Trig_OmniSlashEffect_Func005001003001001001001 takes nothing returns boolean
return ( IsUnitType(GetFilterUnit(), UNIT_TYPE_STRUCTURE) == false )
endfunction

function Trig_OmniSlashEffect_Func005001003001001001002 takes nothing returns boolean
return ( GetUnitAbilityLevelSwapped('A04R', GetFilterUnit()) != 1 )
endfunction

function Trig_OmniSlashEffect_Func005001003001001001 takes nothing returns boolean
return GetBooleanAnd( Trig_OmniSlashEffect_Func005001003001001001001(), Trig_OmniSlashEffect_Func005001003001001001002() )
endfunction

function Trig_OmniSlashEffect_Func005001003001001002 takes nothing returns boolean
return ( IsUnitVisible(GetFilterUnit(), udg_BushidoOwner) == true )
endfunction

function Trig_OmniSlashEffect_Func005001003001001 takes nothing returns boolean
return GetBooleanAnd( Trig_OmniSlashEffect_Func005001003001001001(), Trig_OmniSlashEffect_Func005001003001001002() )
endfunction

function Trig_OmniSlashEffect_Func005001003001002 takes nothing returns boolean
return ( IsUnitEnemy(GetFilterUnit(), GetOwningPlayer(udg_BushidoBladeUnit)) == true )
endfunction

function Trig_OmniSlashEffect_Func005001003001 takes nothing returns boolean
return GetBooleanAnd( Trig_OmniSlashEffect_Func005001003001001(), Trig_OmniSlashEffect_Func005001003001002() )
endfunction

function Trig_OmniSlashEffect_Func005001003002001 takes nothing returns boolean
return ( IsUnitAliveBJ(GetFilterUnit()) == true )
endfunction

function Trig_OmniSlashEffect_Func005001003002002001 takes nothing returns boolean
return ( GetUnitTypeId(GetFilterUnit()) != 'e00C' )
endfunction

function Trig_OmniSlashEffect_Func005001003002002002 takes nothing returns boolean
return ( GetUnitTypeId(GetFilterUnit()) != 'o003' )
endfunction

function Trig_OmniSlashEffect_Func005001003002002 takes nothing returns boolean
return GetBooleanAnd( Trig_OmniSlashEffect_Func005001003002002001(), Trig_OmniSlashEffect_Func005001003002002002() )
endfunction

function Trig_OmniSlashEffect_Func005001003002 takes nothing returns boolean
return GetBooleanAnd( Trig_OmniSlashEffect_Func005001003002001(), Trig_OmniSlashEffect_Func005001003002002() )
endfunction

function Trig_OmniSlashEffect_Func005001003 takes nothing returns boolean
return GetBooleanAnd( Trig_OmniSlashEffect_Func005001003001(), Trig_OmniSlashEffect_Func005001003002() )
endfunction

function Trig_OmniSlashEffect_Func005A takes nothing returns nothing
call GroupAddUnitSimple( GetEnumUnit(), udg_BushidoGroup )
endfunction

function Trig_OmniSlashEffect_Func006C takes nothing returns boolean
if ( not ( udg_Omni1 == false ) ) then
return false
endif
return true
endfunction

function Trig_OmniSlashEffect_Func007Func001C takes nothing returns boolean
if ( ( IsUnitDeadBJ(udg_BushidoBladeUnit) == true ) ) then
return true
endif
if ( ( IsUnitGroupEmptyBJ(udg_BushidoGroup) == true ) ) then
return true
endif
return false
endfunction

function Trig_OmniSlashEffect_Func007C takes nothing returns boolean
if ( not Trig_OmniSlashEffect_Func007Func001C() ) then
return false
endif
return true
endfunction

function Trig_OmniSlashEffect_Actions takes nothing returns nothing
set bj_wantDestroyGroup = true
call AddSpecialEffectTargetUnitBJ( "chest", udg_BushidoBladeUnit, "Abilities\\Spells\\NightElf\\Blink\\BlinkCaster.mdl" )
set udg_BushidoRandomNumber = GetRandomInt(150, 250)
call GroupClear( udg_BushidoGroup )
call ForGroupBJ( GetUnitsInRangeOfLocMatching(550.00, GetUnitLoc(udg_RandPer), Condition(function Trig_OmniSlashEffect_Func005001003)), function Trig_OmniSlashEffect_Func005A )
if ( Trig_OmniSlashEffect_Func006C() ) then
set udg_RandPer = GroupPickRandomUnit(udg_BushidoGroup)
else
call DoNothing( )
endif
if ( Trig_OmniSlashEffect_Func007C() ) then
call DoNothing( )
else
call SetUnitPositionLocFacingBJ( udg_BushidoBladeUnit, PolarProjectionBJ(GetUnitLoc(udg_RandPer), 50.00, GetRandomDirectionDeg()), AngleBetweenPoints(GetUnitLoc(udg_BushidoBladeUnit), GetUnitLoc(udg_RandPer)) )
call SetUnitAnimation( udg_BushidoBladeUnit, "Attack" )
call UnitDamageTargetBJ( udg_BushidoBladeUnit, udg_RandPer, I2R(udg_BushidoRandomNumber), ATTACK_TYPE_HERO, DAMAGE_TYPE_NORMAL )
call AddSpecialEffectTargetUnitBJ( "chest", udg_BushidoBladeUnit, "Abilities\\Spells\\NightElf\\Blink\\BlinkCaster.mdl" )
endif
endfunction

//===========================================================================
function InitTrig_OmniSlashEffect takes nothing returns nothing
set gg_trg_OmniSlashEffect = CreateTrigger( )
call TriggerAddAction( gg_trg_OmniSlashEffect, function Trig_OmniSlashEffect_Actions )
endfunction

//===========================================================================
// Trigger: omnislash
//===========================================================================
function Trig_omnislash_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A066' ) ) then
return false
endif
return true
endfunction

function Trig_omnislash_Func020C takes nothing returns boolean
if ( not ( GetUnitAbilityLevelSwapped('A066', udg_BushidoBladeUnit) > 1 ) ) then
return false
endif
return true
endfunction

function Trig_omnislash_Func021C takes nothing returns boolean
if ( not ( GetUnitAbilityLevelSwapped('A066', udg_BushidoBladeUnit) > 2 ) ) then
return false
endif
return true
endfunction

function Trig_omnislash_Actions takes nothing returns nothing
call EnableTrigger( gg_trg_omnislash_selection )
set udg_BushidoOwner = GetOwningPlayer(GetTriggerUnit())
set udg_BushidoBladeUnit = GetTriggerUnit()
call SelectUnitRemoveForPlayer( udg_BushidoBladeUnit, udg_BushidoOwner )
call SetUnitVertexColorBJ( udg_BushidoBladeUnit, 100, 100, 100, 50.00 )
call SetUnitPathing( udg_BushidoBladeUnit, false )
call SetUnitInvulnerable( udg_BushidoBladeUnit, true )
set udg_RandPer = GetSpellTargetUnit()
set udg_Omni1 = true
call ConditionalTriggerExecute( gg_trg_OmniSlashEffect )
set udg_Omni1 = false
call PolledWait( 0.25 )
call ConditionalTriggerExecute( gg_trg_OmniSlashEffect )
call PolledWait( 0.25 )
call ConditionalTriggerExecute( gg_trg_OmniSlashEffect )
call PolledWait( 0.25 )
call ConditionalTriggerExecute( gg_trg_OmniSlashEffect )
call PolledWait( 0.25 )
if ( Trig_omnislash_Func020C() ) then
call ConditionalTriggerExecute( gg_trg_OmniSlashEffect )
call PolledWait( 0.25 )
call ConditionalTriggerExecute( gg_trg_OmniSlashEffect )
call PolledWait( 0.25 )
else
call DoNothing( )
endif
if ( Trig_omnislash_Func021C() ) then
call ConditionalTriggerExecute( gg_trg_OmniSlashEffect )
call PolledWait( 0.25 )
call ConditionalTriggerExecute( gg_trg_OmniSlashEffect )
call PolledWait( 0.25 )
call ConditionalTriggerExecute( gg_trg_OmniSlashEffect )
call PolledWait( 0.25 )
else
call DoNothing( )
endif
call GroupClear( udg_BushidoGroup )
call SetUnitPathing( udg_BushidoBladeUnit, true )
call SetUnitInvulnerable( udg_BushidoBladeUnit, false )
call SetUnitScalePercent( udg_BushidoBladeUnit, 100.00, 100.00, 100.00 )
call SetUnitVertexColorBJ( udg_BushidoBladeUnit, 100, 100, 100, 0.00 )
call SelectUnitAddForPlayer( udg_BushidoBladeUnit, udg_BushidoOwner )
call DisableTrigger( gg_trg_omnislash_selection )
endfunction

//===========================================================================
function InitTrig_omnislash takes nothing returns nothing
set gg_trg_omnislash = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_omnislash, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_omnislash, Condition( function Trig_omnislash_Conditions ) )
call TriggerAddAction( gg_trg_omnislash, function Trig_omnislash_Actions )
endfunction


Enjoy!
-Argante.
 
Level 1
Joined
Jun 4, 2005
Messages
4
argante can u post in the another form like..

Event
Condition
Action

i dun other stand jass,and btw how do u unprotect the map?
 
Status
Not open for further replies.
Top