Hey guys, I'm trying to make a map currently that, if you move a unit onto 1 of 2 xel'naga towers, that are overlooking pits of lava, the lava will lower. It's supposed to open up extra paths for your units to travel. I tried using the raise lower water tutorial with the triggers as "if unit enters region 001" instead of when the timers ran out.
Basically I'm trying to make a 1v1 melee map with paths around the outside of it that are normally filled with lava. I want both players to be able to control whether the lava is raised, which is the default setting, or lowered based on whether or not they have a unit at either of the xel'naga towers. (By using points or regions hidden on top of the xel'naga tower)
I can't get it to raise or lower the lava, but I think I'm doing the triggers wrong. Well obviously I'm doing them wrong but I felt like the Events of "Any Unit Leaves within 5.0 of Point 001" is not going to suffice if I want either Xel'Naga tower to work.
I want to make sure it checks that both points don't have a unit near them before raising the lava again. I'm worried it will raise the lava if either player leaves their xel'naga tower regardless. It's not working at all yet but I figured I'd ask to see if I can grab some quick help.
you could use a unit group and add the units near the tower to it and when they leave remove them. every time a unit leaves check to see if there are units in the unit group and proceed.
Trying to figure out how to do that now. I keep trying to use If Then Else statements but the conditions are not what I'm looking for when i want it to check something. This is my first time making anything custom with the editor. I only messed around with the sc1 editor so it's kind of a big leap atm.
I would personally use data for this, and then link it to the trigger. Have an ability used whenever the tower is activated. Because Blizzard already has the conditions that checks if it is already activated, you don't have to worry about that. Then have a trigger that is triggered by "unit used ability" and then have the ability be the dummy ability you made. (A dummy ability, if you didn't know, is an ability that does nothing but is used to trigger something else) Then just use the set water level trigger.
I'm not sure if you got this part yet, but I am assuming that you want the lava to damage the units inside of it periodically? Put a region around the area where the lava is. Then have a trigger, initially off, that periodically picks all the units inside of the region every second, and then does a certain amount or percent damage to them, whichever you want. You can also have some conditions that check the height of a unit and make sure that it is in the lava, so flying units aren't killed. You can also give less or more damage to different units, or make some units immune, like a colossus or thor maybe. Up to you.
So that is how I would do it. You are also going to need another dummy ability that is used when the tower is deactivated. Have another trigger that is triggered by that ability, and then lower the lava and turn the search trigger off.
2 variables -
Any unit that enters the region is added to the unit group. (Xel'Naga Towers are units in the triggers So I had to account for them.)
One Trigger counts units in the Unit group and adds them to an integer. If the Integer is >= 3 then the lava lowers, if it's <=2 Then it stays raised.
It checks every .5 secs to see what units are in the unit group.
Thanks for the suggestions. I did delve into the data editor a bit but it's beyond me at the moment. Gonna keep working at it.
I did publish the map, still in a "beta" I guess since it doesn't have doodads or textures and I need to finalize the Terrain layout.
It's called "Lava Corridors" on NA-Battle.net if you're interested in playing a melee map against your friends that involves controlling lava, you're in luck!
I have another question now. I'm trying to create pathing blockers in the center of the lava while it is up, and then removing them when the lava goes down. I already have the triggers to raise and lower the lava but I'm not sure how to create the pathing blockers in the correct position. Should I use Regions or Points? And any idea what functions I should use to spawn/remove the pathing blockers?
I want pathing blockers to make units pathing smarter. Rallying past the lava should not cause your units to run into it when the lava is up. I wanted the pathing blockers in the center so that if you had flying units fly over the lava units might chase them into it but clicking past the lava the units will be smart enough to run around. Any ideas?
I figured it out, sort of. But the units will dance around the lava continually trying to go through but realizing they can't make it and turning around. Not ideal but at least they're not running directly in.
edit- yeah they're dancing around the lava.. Hmm Trying to wonder if there's a way to make them realize it's completely blocked off and not reset.. every couple seconds they turn around and go back towards the lava, and then turn around again when their pathing see the pathing blockers, and again a couple seconds later they'll turn around. If they're already around the corner they'll go around but they get stuck running around the corners back and forth.
-I'm having trouble with spawning dynamic pathing blockers 2x2. I had it working sort of. It began to lag the game the longer they went so I added a debug feature to tell me how many were spawning. It now counts the amount of units in the region, including the dynamic pathing blockers. It turns out it was spawning tons of em. While it worked, sort of. The lag is the worst thing I don't want.
I'm looking into scrapping the entire pathing blockers spawning atm. I can't figure out a way to make them spawn in a straight line across the lava canyons. W/o screwing it up.
I tried making it only able to spawn 14 at the most, but it seems to hate me and it keeps bouncing between 0 and 11 every couple seconds.
My triggers are attempting to limit it by throwing them into a unit group and counting them into an integer and if the integer is >0 when the lava is down it is supposed to remove all unit path blockers. When the lava is up, and the integer is <13 it is supposed to spawn unit pathing blockers. But for some reason it keeps spawning them and removing them at the same time no matter if the lava is up or not.
Just wondering if there is an easier way to do this, I can't seem to get my triggers to want to function properly. I just don't want the units to run into the lava if you click past it.
Hey guys, I'm trying to make a map currently that, if you move a unit onto 1 of 2 xel'naga towers, that are overlooking pits of lava, the lava will lower. It's supposed to open up extra paths for your units to travel. I tried using the raise lower water tutorial with the triggers as "if unit enters region 001" instead of when the timers ran out.
Basically I'm trying to make a 1v1 melee map with paths around the outside of it that are normally filled with lava. I want both players to be able to control whether the lava is raised, which is the default setting, or lowered based on whether or not they have a unit at either of the xel'naga towers. (By using points or regions hidden on top of the xel'naga tower)
I can't get it to raise or lower the lava, but I think I'm doing the triggers wrong. Well obviously I'm doing them wrong but I felt like the Events of "Any Unit Leaves within 5.0 of Point 001" is not going to suffice if I want either Xel'Naga tower to work.
I want to make sure it checks that both points don't have a unit near them before raising the lava again. I'm worried it will raise the lava if either player leaves their xel'naga tower regardless. It's not working at all yet but I figured I'd ask to see if I can grab some quick help.
Thanks for listening. Hope to hear from ya.
you could use a unit group and add the units near the tower to it and when they leave remove them. every time a unit leaves check to see if there are units in the unit group and proceed.
Trying to figure out how to do that now. I keep trying to use If Then Else statements but the conditions are not what I'm looking for when i want it to check something. This is my first time making anything custom with the editor. I only messed around with the sc1 editor so it's kind of a big leap atm.
Why not just check the number of units in region (convert circle to region - position of Xelnaga tower 1/2)? If > 0, keep lava down.
I would personally use data for this, and then link it to the trigger. Have an ability used whenever the tower is activated. Because Blizzard already has the conditions that checks if it is already activated, you don't have to worry about that. Then have a trigger that is triggered by "unit used ability" and then have the ability be the dummy ability you made. (A dummy ability, if you didn't know, is an ability that does nothing but is used to trigger something else) Then just use the set water level trigger.
I'm not sure if you got this part yet, but I am assuming that you want the lava to damage the units inside of it periodically? Put a region around the area where the lava is. Then have a trigger, initially off, that periodically picks all the units inside of the region every second, and then does a certain amount or percent damage to them, whichever you want. You can also have some conditions that check the height of a unit and make sure that it is in the lava, so flying units aren't killed. You can also give less or more damage to different units, or make some units immune, like a colossus or thor maybe. Up to you.
So that is how I would do it. You are also going to need another dummy ability that is used when the tower is deactivated. Have another trigger that is triggered by that ability, and then lower the lava and turn the search trigger off.
Great to be back and part of the community again!
Got it guys! Thanks!
Here's the Triggers:
2 variables - Any unit that enters the region is added to the unit group. (Xel'Naga Towers are units in the triggers So I had to account for them.) One Trigger counts units in the Unit group and adds them to an integer. If the Integer is >= 3 then the lava lowers, if it's <=2 Then it stays raised. It checks every .5 secs to see what units are in the unit group.
Thanks for the suggestions. I did delve into the data editor a bit but it's beyond me at the moment. Gonna keep working at it.
I did publish the map, still in a "beta" I guess since it doesn't have doodads or textures and I need to finalize the Terrain layout.
It's called "Lava Corridors" on NA-Battle.net if you're interested in playing a melee map against your friends that involves controlling lava, you're in luck!
I also made a quick video of it:
Thanks for the help guys!
I have another question now. I'm trying to create pathing blockers in the center of the lava while it is up, and then removing them when the lava goes down. I already have the triggers to raise and lower the lava but I'm not sure how to create the pathing blockers in the correct position. Should I use Regions or Points? And any idea what functions I should use to spawn/remove the pathing blockers?
I want pathing blockers to make units pathing smarter. Rallying past the lava should not cause your units to run into it when the lava is up. I wanted the pathing blockers in the center so that if you had flying units fly over the lava units might chase them into it but clicking past the lava the units will be smart enough to run around. Any ideas?
I figured it out, sort of. But the units will dance around the lava continually trying to go through but realizing they can't make it and turning around. Not ideal but at least they're not running directly in.
edit- yeah they're dancing around the lava.. Hmm Trying to wonder if there's a way to make them realize it's completely blocked off and not reset.. every couple seconds they turn around and go back towards the lava, and then turn around again when their pathing see the pathing blockers, and again a couple seconds later they'll turn around. If they're already around the corner they'll go around but they get stuck running around the corners back and forth.
I need some more help!
-I'm having trouble with spawning dynamic pathing blockers 2x2. I had it working sort of. It began to lag the game the longer they went so I added a debug feature to tell me how many were spawning. It now counts the amount of units in the region, including the dynamic pathing blockers. It turns out it was spawning tons of em. While it worked, sort of. The lag is the worst thing I don't want.
I'm looking into scrapping the entire pathing blockers spawning atm. I can't figure out a way to make them spawn in a straight line across the lava canyons. W/o screwing it up.
I tried making it only able to spawn 14 at the most, but it seems to hate me and it keeps bouncing between 0 and 11 every couple seconds.
My triggers are attempting to limit it by throwing them into a unit group and counting them into an integer and if the integer is >0 when the lava is down it is supposed to remove all unit path blockers. When the lava is up, and the integer is <13 it is supposed to spawn unit pathing blockers. But for some reason it keeps spawning them and removing them at the same time no matter if the lava is up or not.
Just wondering if there is an easier way to do this, I can't seem to get my triggers to want to function properly. I just don't want the units to run into the lava if you click past it.