• 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.

[Solved] Broken Map

Status
Not open for further replies.
Level 2
Joined
Apr 1, 2019
Messages
156
Alright so on a TD I've been working on for months with many backups saved.

I load backup #44 test it, it runs fine.

I then make a couple small changes to it, add a few spells, a few simple triggers, then save it as #45

I test #45 and the unit pathing makes no since, they can walk through doodads and other units but other areas of empty space they can't walk over. Also when I quit the map WC3 freezes.

So I figure it saved badly right? Cause no trigger or spell I added could cause this.

I then load #44 and repeat the process; then I get the same problem.

If I delete all triggers on #45 it runs fine, but again the only triggers I put a simple limit on the number of summons my one hero can have, so idk what's causing this.

I can send you the map privately, I don't want an unprotected version floating around.

EDIT: actually if I delete 10 or so triggers, #45 works
 
Last edited:
Level 2
Joined
Apr 1, 2019
Messages
156
Here's the two triggers I added, editing #44
  • Maraxus Summon Limit
    • Events
      • Unit - A unit Spawns a summoned unit
    • Conditions
      • Or - Any (Conditions) are true
        • Conditions
          • (Unit-type of (Summoned unit)) Equal to Raging Goblin (Level 1)
          • (Unit-type of (Summoned unit)) Equal to Raging Goblin (Level 2)
          • (Unit-type of (Summoned unit)) Equal to Goblin Hero (Level 3)
          • (Unit-type of (Summoned unit)) Equal to Goblin Sky Raider (Level 4)
          • (Unit-type of (Summoned unit)) Equal to Goblin King (Level 5)
          • (Unit-type of (Summoned unit)) Equal to Goblin King (Level 6)
          • (Unit-type of (Summoned unit)) Equal to Retromancer
          • (Unit-type of (Summoned unit)) Equal to Volcanic Dragon
          • (Unit-type of (Summoned unit)) Equal to Magma Giant
    • Actions
      • Set MaraxusIntLimit[(Player number of (Owner of (Triggering unit)))] = (MaraxusIntLimit[(Player number of (Owner of (Triggering unit)))] + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • MaraxusIntLimit[(Player number of (Owner of (Triggering unit)))] Greater than 4
        • Then - Actions
          • Unit - For (Summoning unit), Ability Raging Goblin , Disable ability: True, Hide UI: False
          • Unit - For (Summoning unit), Ability Volcanic Dragon , Disable ability: True, Hide UI: False
        • Else - Actions
  • Maraxus Summon Dies
    • Events
      • Unit - A unit Dies
    • Conditions
      • Or - Any (Conditions) are true
        • Conditions
          • (Unit-type of (Triggering unit)) Equal to Raging Goblin (Level 1)
          • (Unit-type of (Triggering unit)) Equal to Raging Goblin (Level 2)
          • (Unit-type of (Triggering unit)) Equal to Goblin Hero (Level 3)
          • (Unit-type of (Triggering unit)) Equal to Goblin Sky Raider (Level 4)
          • (Unit-type of (Triggering unit)) Equal to Goblin King (Level 5)
          • (Unit-type of (Triggering unit)) Equal to Goblin King (Level 6)
          • (Unit-type of (Triggering unit)) Equal to Retromancer
          • (Unit-type of (Triggering unit)) Equal to Volcanic Dragon
          • (Unit-type of (Triggering unit)) Equal to Magma Giant
    • Actions
      • Set MaraxusIntLimit[(Player number of (Owner of (Triggering unit)))] = (MaraxusIntLimit[(Player number of (Owner of (Triggering unit)))] - 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • MaraxusIntLimit[(Player number of (Owner of (Triggering unit)))] Less than 5
        • Then - Actions
          • Unit - For UnitMaraxus[(Player number of (Owner of (Triggering unit)))], Ability Raging Goblin , Disable ability: False, Hide UI: False
          • Unit - For UnitMaraxus[(Player number of (Owner of (Triggering unit)))], Ability Volcanic Dragon , Disable ability: False, Hide UI: False
        • Else - Actions
 
Last edited:
Level 2
Joined
Apr 1, 2019
Messages
156
Ok If I delete every exact trigger I added and the few events I added to other triggers it works, realized I added these triggers as well.
  • Maraxus Enter
    • Events
      • Unit - A unit enters (Entire map)
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Red Spell Book
    • Actions
      • Set UnitMaraxus[(Player number of (Owner of (Triggering unit)))] = (Triggering unit)
  • Set UnitMaraxus[1] = Red Spell Book 0037 <gen>
  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    • If - Conditions
      • (Unit-type of (Picked unit)) Equal to Raging Goblin (Level 1)
      • (Unit-type of (Picked unit)) Equal to Raging Goblin (Level 2)
      • (Unit-type of (Picked unit)) Equal to Goblin Hero (Level 3)
      • (Unit-type of (Picked unit)) Equal to Goblin Sky Raider (Level 4)
      • (Unit-type of (Picked unit)) Equal to Goblin King (Level 5)
      • (Unit-type of (Picked unit)) Equal to Goblin King (Level 6)
      • (Unit-type of (Picked unit)) Equal to Retromancer
      • (Unit-type of (Picked unit)) Equal to Volcanic Dragon
      • (Unit-type of (Picked unit)) Equal to Magma Giant
    • Then - Actions
      • Set MaraxusIntLimit[(Player number of (Owner of (Picked unit)))] = (MaraxusIntLimit[(Player number of (Owner of (Picked unit)))] - 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • MaraxusIntLimit[(Player number of (Owner of (Picked unit)))] Less than 5
        • Then - Actions
          • Unit - For UnitMaraxus[(Player number of (Owner of (Picked unit)))], Ability Raging Goblin , Disable ability: False, Hide UI: False
          • Unit - For UnitMaraxus[(Player number of (Owner of (Picked unit)))], Ability Volcanic Dragon , Disable ability: False, Hide UI: False
        • Else - Actions
    • Else - Actions

It doesn't really make since tho it seems any kinda trigger I add to #44 backup causes the map to screw up
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,287
It doesn't really make since tho it seems any kinda trigger I add to #44 backup causes the map to screw up
Makes perfect sense...
Unit - A unit enters (Entire map)
This is your problem. You are overloading the map with regions. Each time that event binding is referenced it creates a new region and adds every single cell in the Entire map to it.

If you place too may cells inside regions the path finder breaks in a catastrophic way. Units literally start acting as if they are drunk, walking into walls and failing to take even the most simple routes.

The solution is to use just 1 Unit - A unit enters (Entire map) event in the entire map. You can get the trigger it fires to run all other triggers which need the event. This keeps the number of cells inside regions reasonable and hence prevents the path finder from breaking.

An easy and maintainable way to do this is by setting a real variable to a specific value and back allowing the appropriate event to be fired in response, like how most GUI friendly damage detection systems work. Triggering values can be saved into global variables to be recalled by the executed triggers as needed to prevent such abstraction from losing track of them.
 
Level 45
Joined
Feb 27, 2007
Messages
5,578
An easy and maintainable way to do this is by setting a real variable to a specific value and back allowing the appropriate event to be fired in response, like how most GUI friendly damage detection systems work. Triggering values can be saved into global variables to be recalled by the executed triggers as needed to prevent such abstraction from losing track of them.
@BradPittlord He means this:
  • Events
    • Unit - A unit enters (Entire Map)
  • Conditions
  • Actions
    • Set EnteringUnitVar = (Entering Unit)
    • Set EnteringRealTrigger = 1.00
    • -------- all the triggers run now --------
    • Set EnteringRealTrigger = 0.00
  • Events
    • Game - EnteringRealTrigger becomes equal to 1.00
    • -------- Use this event for all your 'entering region' triggers --------
  • Conditions
    • (Unit type of EnteringUnitVar) equal to Knight
  • Actions
    • Unit - Explode EnteringUnitVar //or whatever
 
Status
Not open for further replies.
Top