• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

complicated bug on unit

Status
Not open for further replies.
Level 5
Joined
Jan 19, 2020
Messages
102
complicated bug on unit


i got a unit neutral enemy who is invulnerable.

he can cast abilities i need that for my RPG.

The trouble is now, if there is a unit in range not hero he unses his abilities random.

If its a hero its working fine.

Any idea, can i take out the unit of the ai so ai doesnt have influence?

or use a function to not cast a ability?
 
Level 5
Joined
Jan 19, 2020
Messages
102
yes, but then they cant do what they should
the best thing would be if i can could take them out of AI
 
Level 12
Joined
Feb 5, 2018
Messages
522
You can change the targets allowed in the object editor data for the spells that your RPG-boss uses.

Targets allowed; Enemy, Hero, Vulnerable

You could also base all your boss abilities with channel.
And use triggers to fire them.
 
Level 5
Joined
Jan 19, 2020
Messages
102
how i do that with channel?

ty object editor should work.

no didnt work, some abilitys they do even with no target _, and i got a lot of them,

like waterelemental they do it at cd if units are near, it has no target,

i changed target of units and spells.
 
Last edited:
Level 12
Joined
Feb 5, 2018
Messages
522
The one highlighted with the blue background is where you can edit the targets allowed field in Object Editor.

Stats - Targets Allowed
 

Attachments

  • ImageB.png
    ImageB.png
    129.8 KB · Views: 11
Level 12
Joined
Feb 5, 2018
Messages
522
Ok so if you already have a trigger for the water elemental for casting an ability when units are near you can add conditions for it.

  • x
    • Events
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • -------- Set your conditions above --------
          • -------- --> Set your actions here <--- --------
        • Else - Actions
 
Level 5
Joined
Jan 19, 2020
Messages
102
yes but i have like 50 of these abillitys would take long^^

i got mainly summon spells, but to much to make a trigger for each one
 
Last edited:
Level 12
Joined
Feb 5, 2018
Messages
522
  • X
    • Events
      • Unit - A unit comes within 500.00 of Archmage 0001 <gen>
    • Conditions
      • ((Triggering unit) is A Hero) Equal to True
    • Actions
      • -------- So here we check if the ability cooldown is on --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Ability Cooldown Remaining of Archmage 0001 <gen> for ability Test Spell ..) Greater than or equal to 0.01
        • Then - Actions
          • Game - Display to (All players) the text: ---Trigger Ended---
          • Skip remaining actions
        • Else - Actions
          • -------- If it's 0.00 then the boss uses his skill --------
          • Unit - Order Archmage 0001 <gen> to Orc Far Seer - Feral Spirit.
          • Game - Display to (All players) the text: ---Trigger Executed...
I added a testmap too, so you can see how you can use the channel ability.

Best of luck to you :)
 

Attachments

  • TestForJan.w3m
    17.3 KB · Views: 15
Status
Not open for further replies.
Top