RoC - Integer Comparison - Working slowly

Templarion

Member
Reaction score
8
Greetings!

I started with version 1.0. In version 1.7 I added "Airstrike" triggers.

Right from the beginning I have had problems with this trigger. First it didn't work at all. Now I managed to get it working but for some darn reason it works too slowly!

Basic idea is:
Marines fight against undead until there are less than 21 marines standing. After that they can call an airstrike which bombs the whole town in pieces.

My problem is that when I test this map alone against computers it works. However, when I play it in Battle.Net it works waaaay too slowly! For some reason there have to be less than 5-10 marines standing before they can call it.

I have added the map here as an attachment but if you are too lazy to open it. Here are the triggers:

AirstrikeP1

Event
+Time - Every 1.00 seconds of the game time

Conditions
+AirStrikeSpam Equal to False
+(Number of units in (Units of type Marine (basic))) Less than or equal to 20

Actions
+Set AirStrikeSpam = True
+Sound - Play gameover <gen>
+Game - Display to (All allies of Player 1 (Red)) for 9.00 seconds the text: Marine: "We are all..."


AirstrikeP2

Events
+Unit - A unit enters RadioMast <gen>

Conditions
+AirStrikeSpam Equal to True
+AirStrikeFlag Equal to False
+((Triggering Unit) is Undead) Equal to False

Actions
+Set AirStrikeFlag = True
+Sound - Stop music Immediately
+Trigger - Turn off music 1 <gen>
+Trigger - Turn off music 2 <gen>
+Trigger - Turn off music 3 <gen>
+Trigger - Turn off music 4 <gen>
+Wait 2.00 seconds
....(rest shouldnt matter)

Note! This map is made with Reign of Chaos editor.
 

Attachments

  • Operation Dead End 2.7b.w3m
    382.1 KB · Views: 68

Drunken_God

Hopes to get back into Mapmaking with SC2 :)
Reaction score
106
(Number of units in (Units of type Marine (basic))) Less than or equal to 20
this will return dead units, too
e.g. 10 alive marines and 12 dead marines wouldnt trigger it
 

Templarion

Member
Reaction score
8
Thanks for answer.

Do you mean that trigger is counting "rotting marines", too? Or what?

Because the trigger works but it just works damn slow. How should I fix it?
 

Templarion

Member
Reaction score
8
Thanks for both of you.

I tried to find an easy way to compare if units are alive but I didnt find it.

If someone has a solution, he can tell it to me right away. Reputation will be shared. ;)
 

AdamGriffith

You can change this now in User CP.
Reaction score
69
You should use conditions to make sure you select units which are alive:

Code:
(Number of units in (Units in (Playable map area) matching ((((Matching unit) is alive) Equal to True) and ((Unit-type of (Matching unit)) Equal to Marine (basic))))) Less than or equal to 20

Code:
(Matching unit) is alive)
Is a boolean comparision
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top