Staredit Network > Forums > SC2 Assistance > Topic: Can't use variable in certain event
Can't use variable in certain event
Dec 26 2010, 9:03 pm
By: PIESOFTHENORTH  

Dec 26 2010, 9:03 pm PIESOFTHENORTH Post #1



I am having difficulty with these things.

1. In the event Unit enters a distance from Unit it won't let me use a variable unit for the second unit. Any way to allow this?

2. Is there a way to keep text tags locked on the unit when it moves? I can attach it but it doesn't stick to the unit when it moves away.

3. I have an trigger that orders a unit to hold position, I have another trigger that fires when a unit is ordered to hold position. The first trigger does its job fine, but for some reason the second trigger doesn't fire. I tried putting a computer in the slot of the player that has this unit (this is all in editor testing btw), but it still won't work.



None.

Dec 26 2010, 9:52 pm Ahli Post #2

I do stuff and thingies... Try widening and reducing the number of small nooks and crannies to correct the problem.

@1
Use a region and attach the region onto the unit.

@3
Does the second trigger work, if the player presses the button ingame?
You can workaround that with the run trigger action.




Dec 27 2010, 12:22 am PIESOFTHENORTH Post #3



If I manually hold position then the second trigger works for me, but the unit i'm trying to order is for a different player.



None.

Dec 27 2010, 3:16 am Roy Post #4

An artist's depiction of an Extended Unit Death

Quote from PIESOFTHENORTH
1. In the event Unit enters a distance from Unit it won't let me use a variable unit for the second unit. Any way to allow this?
As far as I know, no, not directly. Using a different event would probably be better, depending on what you want to accomplish.

Quote from PIESOFTHENORTH
2. Is there a way to keep text tags locked on the unit when it moves? I can attach it but it doesn't stick to the unit when it moves away.
There is an action called "Set Position of Text Tag" which takes in a point. You can periodically set it to the position of a specified unit.

Quote from PIESOFTHENORTH
3. I have an trigger that orders a unit to hold position, I have another trigger that fires when a unit is ordered to hold position. The first trigger does its job fine, but for some reason the second trigger doesn't fire. I tried putting a computer in the slot of the player that has this unit (this is all in editor testing btw), but it still won't work.
There is a conditional statement to check a current unit's order. If the hold position event is supposed to fire from an order from a trigger, then simply have the trigger run when you want it to run. The event fires when a hold position has been issued by a player in-game, and not when one has been set via an action.




Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[10:53 pm]
Oh_Man -- https://youtu.be/MHOZptE-_-c are yall seeing this map? it's insane
[2024-5-04. : 1:05 am]
Vrael -- I won't stand for people going around saying things like im not a total madman
[2024-5-04. : 1:05 am]
Vrael -- that's better
[2024-5-04. : 12:39 am]
NudeRaider -- can confirm, Vrael is a total madman
[2024-5-03. : 10:18 pm]
Vrael -- who says I'm not a total madman?
[2024-5-03. : 2:26 pm]
UndeadStar -- Vrael, since the ad messages get removed, you look like a total madman for someone that come late
[2024-5-02. : 1:19 pm]
Vrael -- IM GONNA MANUFACTURE SOME SPORTBALL EQUIPMENT WHERE THE SUN DONT SHINE BOY
[2024-5-02. : 1:35 am]
Ultraviolet -- Vrael
Vrael shouted: NEED SOME SPORTBALL> WE GOT YOUR SPORTBALL EQUIPMENT MANUFACTURING
Gonna put deez sportballs in your mouth
[2024-5-01. : 1:24 pm]
Vrael -- NEED SOME SPORTBALL> WE GOT YOUR SPORTBALL EQUIPMENT MANUFACTURING
[2024-4-30. : 5:08 pm]
Oh_Man -- https://youtu.be/lGxUOgfmUCQ
Please log in to shout.


Members Online: Roy, Ultraviolet, lil-Inferno