1.) What I want is to create a unit (Siege Breaker) after a structure (Garage) dies and when the unit dies it will kill another structure (Sentry Gun) but the Sentry Gun is not dying. It does have an invulnerability but I've tried a Remove Behavior and it still does not work.
What I have so far:
Unit - Create 1 Merc - Siege Breaker
Variable - Set Boss[0] = (Last created unit)
Player Group - Pick each player in (All players) and do (Actions)
Actions
Visibility - Destroy Revealer[(Picked player)][0]
Visibility - Create a visibility revealer for player (Picked player) within [01] Boss Spawn
Variable - Set SSW Revealers[(Picked player)][2] = (Last created revealer)
General - Wait for (Conditions), checking every 1.0 Game TIme seconds
Conditions
((Last created unit) is alive) == false
Unit - Kill Sentry Guns[0]
UI - Display "Sentry Gun destroy." for (All players) to Subtitle area
Player Group - Pick each player in (All players) and do (Actions)
2.) Next is I'm trying to issue an order to a unit (Siege Breaker) to patrol from one point to another but when he attacks the order is gone. How do I keep this order going after it attacks another unit?
3.) I'm getting an error message of "Trying to access an element past the end of an array" when this trigger is executed:
(I'm guessing it's the Repeat forever)
Event
Unit - Metal Gate dies
Local variables
Dominion Spawn = (Empty unit group)
Conditions
Actions
Transmission - Send transmission
Ping - Ping the minimap at [01] Marine Spawn for (Active Players)
Player Group - Pick each player in (All players) and do (Actions)
Actions
Visibility - Create a visibility revealer for player (Picked player) within [01] Marine Spawn
Variable - Set SSW Revealers[(Picked player)][0] = (Last created revealer)
Visibility - Create a visibility revealer for player (Picked player) within [01] Watch Out! Sentry Gun!
Variable - Set SSW Revealers[(Picked player)][1] = (Last created revealer)
Sound - Player UI_ObjectiveComplete for (All players)
UI - Display "Watch out for the Sentry Gun" for (All players) to Subtitle area
General - Repeat (Actions) forever
Actions
General - If (Conditions) then do (Actions) else do (Actions)
If
(Garage is alive) == true
Then
General - Repeat (Actions) 2 times
Unit - Create 1 Marine
Unit Group - Add (Last created unit) to Dominion Spawn
General - Wait 0.2 Game Time seconds
Unit - Order all units in Dominion Spawn to ( Patrol targeting [01] Enter) (Replace)
General - Wait for (Conditions), checking every 1.0 Game TIme seconds
Conditions
((Last created unit) is alive) == false
Unit - Kill Sentry Guns[0]
Don't Use (Last Created) more then once, to set a variable for the thing. You really don't want to use a wait for conditions here. (Unless its for a short period) Make a trigger that runs when a unit dies, condition that that unit is Hero[0]. You can disable the trigger after it runs.
2.) Next is I'm trying to issue an order to a unit (Siege Breaker) to patrol from one point to another but when he attacks the order is gone. How do I keep this order going after it attacks another unit?
Units Patrolling attack move between their starting location and their target forever.
Player Group - Pick each player in (All players) and do (Actions)
Actions
Visibility - Create a visibility revealer for player (Picked player) within [01] Marine Spawn
Variable - Set SSW Revealers[(Picked player)][0] = (Last created revealer)
Visibility - Create a visibility revealer for player (Picked player) within [01] Watch Out! Sentry Gun!
Variable - Set SSW Revealers[(Picked player)][1] = (Last created revealer)
You probably want active players, is SSW revealer 14 big?
Also try taking screenshots of your triggers it might save you some time :)
Here's a screenshot step by step of what's going on.
This is the beginning area. When you destroy the Metal Gate it gives me that error. It also will begin spawning 2 Marines at "[01] Garage" point.
When you get to the Garage you see the Sentry Gun to the right. It is flagged as Invulnerable and will instantly kill any enemy nearby.
After the Garage is destroy the Siege Breaker (variable - Boss[0]) spawns and as you can see the Sentry Gun is still alive. About the patrol issue is I was recently fixing another problem with triggers and I accidentally deleted the Unit - Issue Order.
But even after the Siege Breaker is destroyed the Sentry Gun is still alive.
A. Put a test messedge after your wait, and try using a trigger instead of a wait.
If you get the messedge and its trying to kill the unit, then you never set Sentry Guns[0]
I've tried a second trigger using Periodic Event as the event, didn't work.
I've tried the event Unit Dies (Boss[0]) and it doesn't work. By the way: Boss[0] is a global variable, not local.
What other events could I use?
Edit: I've thought of that logic and it brought me here. So either you know how to do this or you don't. I've also set all Sentry Guns to the specified "Sentry Gun[#]" variable. Have 12 total that will be destroyed after a specific structure is also destroyed. I've also tried using a General - Repeat forever action and adding in an If Then Else making the condition be ((Boss[0]) is alive == false) and it still does not work.
Don't Use (Last Created) more then once, to set a variable for the thing. You really don't want to use a wait for conditions here. (Unless its for a short period) Make a trigger that runs when a unit dies, condition that that unit is Hero[0]. You can disable the trigger after it runs.
Dude... Your claiming I don't know how to do it when I already told you how to do it. That doesn't make me happy.
Did you do what I suggested? You think your to good to try debugging?
EDIT: Also do you ever get your "sentry gun destroyed. proceed..." messedge?
Funny how you're saying you're unhappy because I simply said that it seems you don't know how to fix my problem. So please don't get upset over people on the internet trying to solve a problem. I never insulted you but you claim that I should use logic because I never did throughout this whole map which I'm sure a person that has zero programming experience running the Galaxy Editor without any tutorials and getting this far must have pretty fair logic. Here's what I came up with using the Debug Trigger:
If my logic tells me correctly, and god knows it's not much, is it gives me an error but it shows zero Failed Conditions. I've never used the Debug Trigger. Also, it shows it never gets to the Unit - Kill Unit trigger.
Edit: This is my second month, and fourth map. First was a Fastest Map, second was a TPS RPG, third was a 10% scale TPS RPG, and fourth is this one which is a Hero RPG.
Now I'm using some logic here, and thinking-outside-of-the-box-ness-icity but would it be best if I set the Boss units somewhere out of reach in the map (let's say move them to a corner of the map where no player can see) then when the Garage is destroyed instantly move the desired Boss to the spawn location. This way I can have add another trigger (SSW) Boss dies that has the event "Unit - Boss[0] dies" because before I had a periodic event every 5 seconds but it lagged the computer out since I have like 12 of these triggers. I'm going to try that...
Is SSW revealer 14 big? Well, I don't have a Revealer 14. I have 0, 1, and 2 which are radius of 8. I've changed all of the "All players" to "Active players". Oh, one last thing. Why are you freaking out about this?
1.) What I want is to create a unit (Siege Breaker) after a structure (Garage) dies and when the unit dies it will kill another structure (Sentry Gun) but the Sentry Gun is not dying. It does have an invulnerability but I've tried a Remove Behavior and it still does not work.
What I have so far:
2.) Next is I'm trying to issue an order to a unit (Siege Breaker) to patrol from one point to another but when he attacks the order is gone. How do I keep this order going after it attacks another unit?
3.) I'm getting an error message of "Trying to access an element past the end of an array" when this trigger is executed:
(I'm guessing it's the Repeat forever)
Thanks
Don't Use (Last Created) more then once, to set a variable for the thing. You really don't want to use a wait for conditions here. (Unless its for a short period) Make a trigger that runs when a unit dies, condition that that unit is Hero[0]. You can disable the trigger after it runs.
Units Patrolling attack move between their starting location and their target forever.
You probably want active players, is SSW revealer 14 big?
Also try taking screenshots of your triggers it might save you some time :)
@grenegg: Go
Alrighty. Think you said it once (to me). Wrath? Wraith is some ghostly creature.
I've tried ((Boss[0]) is alive) == false and it still doesn't work.
@admielke: Go
I'm still getting over my announce about that happening :) I'll edit some more.
Here's a screenshot step by step of what's going on.
This is the beginning area. When you destroy the Metal Gate it gives me that error. It also will begin spawning 2 Marines at "[01] Garage" point.
When you get to the Garage you see the Sentry Gun to the right. It is flagged as Invulnerable and will instantly kill any enemy nearby.
After the Garage is destroy the Siege Breaker (variable - Boss[0]) spawns and as you can see the Sentry Gun is still alive. About the patrol issue is I was recently fixing another problem with triggers and I accidentally deleted the Unit - Issue Order.
But even after the Siege Breaker is destroyed the Sentry Gun is still alive.
@admielke: Go
Then use something called logic!
Either:
A.) It never gets to (Kill Sentry Guns[0])
or
B.) (Kill Sentry Guns[0]) dosn't work
A. Put a test messedge after your wait, and try using a trigger instead of a wait.
If you get the messedge and its trying to kill the unit, then you never set Sentry Guns[0]
Sorry about the screenshots in-game. Wasn't thinking so here are the triggers.
That is what happens when the Metal Gate is destroyed.
That is what happens after the Garage is destroyed.
And that is what happens after the Siege Breaker is destroyed.
I've tried a second trigger using Periodic Event as the event, didn't work. I've tried the event Unit Dies (Boss[0]) and it doesn't work. By the way: Boss[0] is a global variable, not local. What other events could I use?
Edit: I've thought of that logic and it brought me here. So either you know how to do this or you don't. I've also set all Sentry Guns to the specified "Sentry Gun[#]" variable. Have 12 total that will be destroyed after a specific structure is also destroyed. I've also tried using a General - Repeat forever action and adding in an If Then Else making the condition be ((Boss[0]) is alive == false) and it still does not work.
@admielke: Go
Dude... Your claiming I don't know how to do it when I already told you how to do it. That doesn't make me happy.
Did you do what I suggested? You think your to good to try debugging?
EDIT: Also do you ever get your "sentry gun destroyed. proceed..." messedge?
@grenegg: Go
Funny how you're saying you're unhappy because I simply said that it seems you don't know how to fix my problem. So please don't get upset over people on the internet trying to solve a problem. I never insulted you but you claim that I should use logic because I never did throughout this whole map which I'm sure a person that has zero programming experience running the Galaxy Editor without any tutorials and getting this far must have pretty fair logic. Here's what I came up with using the Debug Trigger:
If my logic tells me correctly, and god knows it's not much, is it gives me an error but it shows zero Failed Conditions. I've never used the Debug Trigger. Also, it shows it never gets to the Unit - Kill Unit trigger.
Edit: This is my second month, and fourth map. First was a Fastest Map, second was a TPS RPG, third was a 10% scale TPS RPG, and fourth is this one which is a Hero RPG.
@admielke: Go
So therefore a trigger that has no conditions has never failed the conditions!
YOU LEVEL UP!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
and btw this is still true:
Now I'm using some logic here, and thinking-outside-of-the-box-ness-icity but would it be best if I set the Boss units somewhere out of reach in the map (let's say move them to a corner of the map where no player can see) then when the Garage is destroyed instantly move the desired Boss to the spawn location. This way I can have add another trigger (SSW) Boss dies that has the event "Unit - Boss[0] dies" because before I had a periodic event every 5 seconds but it lagged the computer out since I have like 12 of these triggers. I'm going to try that...
Is SSW revealer 14 big? Well, I don't have a Revealer 14. I have 0, 1, and 2 which are radius of 8. I've changed all of the "All players" to "Active players". Oh, one last thing. Why are you freaking out about this?
@admielke: Go
you could just do the:
Any unit dies
condition: triggering unit = hero[0]
That i've suggested twice already
And if you have revealer of size[2], and your trying to set one bigger like you are, your gonna get an array out of bounds error.
@grenegg: Go
Got it working. Thanks. Took me so long to reply because after I attempted to fix it every trigger before this one broke. How? Who the fuck knows...
The gnome in your computer knows.
EDIT: Its an evil gnome btw.
@grenegg: Go
I have one last question. When I create the hero chosen it only works if I have Ignore Placement on. Have any ideas why?
Edit: WTF! All I did was delete several units in each corner of the map and it worked. I think I need to take this Evil Gnome to Guantanamo.
@admielke: Go
Dose it work? :D (AKA, you have something weird going on then, but if it works it doesn't matter)
@grenegg: Go
I'd like to know but that's true. Also I was just being sarcastic like you and your gnomes.