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

Check for leaks...

Status
Not open for further replies.
Level 5
Joined
Mar 17, 2005
Messages
135
Tell me if you guys see any leaks or anything. When the map gets down to higher levels, it starts lagging real bad untill most of the units are dead.

  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    • If - Conditions
      • Level Equal to 1
    • Then - Actions
      • Game - Display to (All players) the text: (|cffffcc00Round: |r + (String(Level)))
      • Sound - Play BattleNetTick <gen>
      • For each (Integer A) from 0 to 12, do (Actions)
        • Loop - Actions
          • Unit - Create Num_Players_Units units_level[0] for Player 12 (Brown) at Spawn_Points[(Integer A)] facing Default building facing degrees
    • Else - Actions
      • Do nothing
 
Level 5
Joined
Mar 17, 2005
Messages
135
  • Begins Levels
    • Events
      • Player - Player 12 (Brown)'s Food used becomes Less than or equal to 0.00
    • Conditions
    • Actions
      • Game - Display to (All players) the text: You have |cffffcc00...
      • Wait 20.00 seconds
      • Set Level = (Level + 1)
      • Leaderboard - Change the value for Neutral Passive in (Last created leaderboard) to Level
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Level Greater than 10
        • Then - Actions
          • Set Income = (Num_Players_Units + (Level / 2))
        • Else - Actions
          • Set Income = (Num_Players_Units + Level)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Level Equal to 1
        • Then - Actions
          • Game - Display to (All players) the text: (|cffffcc00Round: |r + (String(Level)))
          • Sound - Play BattleNetTick <gen>
          • For each (Integer A) from 0 to 12, do (Actions)
            • Loop - Actions
              • Unit - Create Num_Players_Units units_level[0] for Player 12 (Brown) at Spawn_Points[(Integer A)] facing Default building facing degrees
        • Else - Actions
      • Game - Display to (All players) for 15.00 seconds the text: (|cffffcc00Supplies have sold: |r+ + ((String(Income)) + Gold.))
      • Sound - Play AutoCastButtonClick1 <gen>
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Player - Add Income to (Picked player) Current gold
I removed all the other loops so the trigger won't be so long on here. The levels go from 1 to 30.
 
Level 8
Joined
Aug 1, 2008
Messages
420
I cant see any leaks.

I think
  • Player Group - Pick every player in (All Players)
leaks, but im not sure, you'll have to get a second opinion on that..
 
Level 5
Joined
Mar 17, 2005
Messages
135
Well could this be causing lag?

  • Magic Bolt
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Unit-type of (Attacking unit)) Equal to Magic Vault
    • Actions
      • Unit - Order (Attacking unit) to Human Mountain King - Storm Bolt (Attacked unit)
But then it only lags in later levels beginning around 14 and gradually getting worst.

Only other thing i can think of is that my level trigger is to long and it has to cycle through to many if/then/else statements before it finds the correct condition? I can't figure out why it lags so bad. It's like a huge lag where the screen pauses pretty much so It's not too much units in game.

I fixed every single leak in the map btw.
 
Level 11
Joined
Feb 14, 2009
Messages
884
Doesn't make sense. Even if it was a TD map or a map where multiple units are attacked simultaneously, it shouldn't lag. Can you post the map please so that we can have a look?
 
Level 5
Joined
Mar 17, 2005
Messages
135
Doesn't make sense. Even if it was a TD map or a map where multiple units are attacked simultaneously, it shouldn't lag. Can you post the map please so that we can have a look?

Just note this was supposed to be a fast, quick, fun project and it basically was untill now lol. I wish this damn problem didn't happen : ).

When we got to around level 18 I think with 8 people, the game paused up for a long time and it would jump here and there untill we lost and defeat came up.
 

Attachments

  • Protect The Farm v.06 BETA.w3x
    114.8 KB · Views: 43
Level 11
Joined
Feb 14, 2009
Messages
884
I've edited some of your triggers so that they are more efficient (Do Nothing is absolutely useless. Triggers that have been edited have an "e" in the beginning and I've written what I've done in the comments). I've also noticed that you use other towers' abilities in the same fashion that you use Storm Bolt. Do they cause lag or it's just this particular type of tower? Begin Levels leaks locations in the loops. Overall, your triggers look good though :)

(Doesn't lag for me ^^)
 

Attachments

  • Protect The Farm v.06 BETA.w3x
    115.1 KB · Views: 46
Level 5
Joined
Mar 17, 2005
Messages
135
Thank you very much. I'll let you know if it still lags. The ability towers don't really lag. It's just later points in the game it like freezes and makes it unbareable to play.

Edit: I like what you did with my don't attack triggers. I also protect my map with ExtProtect. But that should cause lag should it.
 
Level 5
Joined
Mar 17, 2005
Messages
135
Man, it still lags big time. Seems like it doesn't matter if it happens early or late. Right when the units come out attacking it lags really bad sometimes like I said, pauses the screen up. I think it may be those triggers that I posted above that when a unit is attack, attacking units is equal to (whatever), cast whatever spell. I have about 5 triggers that do that. Take note that the attackers/defender towers/defender heros are all attacking which is a lot of units being ran through 5 triggers. Could these triggers possible making it lag so much?
 
Level 12
Joined
Mar 10, 2008
Messages
869
  • Begins Levels
    • Events
      • Player - Player 12 (Brown)'s Food used becomes Less than or equal to 0.00
    • Conditions
    • Actions
      • Game - Display to (All players) the text: You have |cffffcc00...
      • Wait 20.00 seconds
      • Set Level = (Level + 1)
      • Leaderboard - Change the value for Neutral Passive in (Last created leaderboard) to Level
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Level Greater than 10
        • Then - Actions
          • Set Income = (Num_Players_Units + (Level / 2))
        • Else - Actions
          • Set Income = (Num_Players_Units + Level)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Level Equal to 1
        • Then - Actions
          • Game - Display to (All players) the text: (|cffffcc00Round: |r + (String(Level)))
          • Sound - Play BattleNetTick <gen>
          • For each (Integer A) from 0 to 12, do (Actions)
            • Loop - Actions
              • Unit - Create Num_Players_Units units_level[0] for Player 12 (Brown) at Spawn_Points[(Integer A)] facing Default building facing degrees
        • Else - Actions
      • Game - Display to (All players) for 15.00 seconds the text: (|cffffcc00Supplies have sold: |r+ + ((String(Income)) + Gold.))
      • Sound - Play AutoCastButtonClick1 <gen>
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Player - Add Income to (Picked player) Current gold
I removed all the other loops so the trigger won't be so long on here. The levels go from 1 to 30.

You guys, seriously can't see that position leak?

  • Leak
    • Events
    • Conditions
    • Actions
      • For each (Integer A) from 0 to 12, do (Actions)
        • Loop - Actions
          • Set RemovePoint = Spawn_Points[(Integer A)]
          • Unit - Create Num_Players_Units units_level[0] for Player 12 (Brown) at RemovePoint facing Default building facing degrees
          • Custom script: call RemoveLocation(udg_RemovePoint)
 
Level 5
Joined
Mar 17, 2005
Messages
135
You guys, seriously can't see that position leak?

  • Leak
    • Events
    • Conditions
    • Actions
      • For each (Integer A) from 0 to 12, do (Actions)
        • Loop - Actions
          • Set RemovePoint = Spawn_Points[(Integer A)]
          • Unit - Create Num_Players_Units units_level[0] for Player 12 (Brown) at RemovePoint facing Default building facing degrees
          • Custom script: call RemoveLocation(udg_RemovePoint)

I was told that it does not leak. I guess I'll try it, but what do others think?
 
Level 11
Joined
Feb 14, 2009
Messages
884
Oh, and Palermo1? Since towers don't have attack, why don't you just change their attack art and adjust their damage? For example, instead of throwing a magical hammer, change the attack animation to look like a hammer, adjust the damage and give it a 100% chance to bash for 0.2.
 
Level 5
Joined
Mar 17, 2005
Messages
135
Well, that would be a bunch of trouble for nothing in my opinion. It's not the tower causing lag. I have around 5 towers that casts abilities they don't cause lag. It lags usually starting in levels aroound 15+ but I did have it lag at level 9. I was saying that stormbolt trigger combined with the other ability triggers could be causing it to lag, just a thought because that is a lot of towers/units attacking each other and causing those triggers to fire. I truely have no clue as to why it does this. I was beginning to think it was caused when someone left the game and I messed something up in the leaver trigger but it did not seem to be the case.
 
Status
Not open for further replies.
Top