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

Why this trigger doesn't work, not damage to units and not destroy doodads?

Status
Not open for further replies.
Level 6
Joined
Apr 5, 2018
Messages
116
Which thing I do wrong? I have other trigger for golden barrel of explosives with 6666 damage and BOOM variable.
  • Boom
    • Events
      • Destructible - A destructible within (Playable map area) dies
    • Conditions
      • (Destructible-type of (Dying destructible)) Equal to Barrel of Explosives
    • Actions
      • Set VariableSet BOOM = (Position of (Dying destructible))
      • Destructible - Pick every destructible within 250.00 of BOOM and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Destructible-type of (Picked destructible)) Equal to Barrel of Explosives
            • Then - Actions
              • Destructible - Kill (Picked destructible)
            • Else - Actions
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units within 250.00 of BOOM.) and do (Actions)
        • Loop - Actions
          • Unit - Cause (Picked unit) to damage (Picked unit), dealing 2000.00 damage of attack type Spells and damage type Normal
      • Custom script: call RemoveLocation(udg_BOOM)
Thank you very much for this post

It is possible triggers conflict? If I try this on other map it is work.

When the AI uses the ability it either doesn't use it at all, OR it uses it on it's own units (Thinking it's a heal) instead of targeting enemy units.
This is soft-locked into AI behavior. It cannot be altered.

You can try to get some complex system (I recall someone already wrote it, check Spell Section) to specify this additional behavior.
 
Level 21
Joined
Mar 29, 2020
Messages
1,237
like this:

  • Untitled Trigger 001
    • Events
    • Conditions
    • Actions
      • -------- stuff --------
      • Game - Display to (All players) the text: first part works
      • -------- other stuff --------
      • Game - Display to (All players) the text: second part works
      • -------- more stuff --------
      • Game - Display to (All players) the text: third part works
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,595
You can only register up to 64 Destructibles to that trigger. So only 64 of your Destructibles will cause that Event to run. You need to break the map up into regions and use those instead of (Playable map area). Just make sure that you don't have more than 64 Destructibles in each region.

Also, you will have recursion problems because you're causing the trigger to run again while it's still in action.

I attached a map with a working example using local variables (Jass).
 

Attachments

  • Boom Example 1.w3m
    18.3 KB · Views: 14
Last edited:
Status
Not open for further replies.
Top