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.
[01:31 pm]
l)ark_ssj9kevin -- DarkenedFantasies
DarkenedFantasies shouted: FaRTy1billion Ah, crap! This landing site doesn't have any minerals!
sick refeernce
[10:39 am]
NudeRaider -- Are you frigging kidding me? Such an impactful patch in this economy? https://www.youtube.com/watch?v=fYsP29E-FUs
[09:55 am]
IskatuMesk -- just a wee baby in his crib
[02:55 am]
DarkenedFantasies -- FaRTy1billion
FaRTy1billion shouted: too bad new accounts start with -150 minerals
Ah, crap! This landing site doesn't have any minerals!
[2026-5-30. : 12:34 am]
Symmetry -- in another 6 years
[2026-5-29. : 10:54 pm]
NudeRaider -- just like you
[2026-5-29. : 10:51 pm]
Symmetry -- looks like every box is 40 today
[2026-5-28. : 11:53 pm]
O)FaRTy1billion[MM] -- too bad new accounts start with -150 minerals
[2026-5-28. : 11:53 pm]
IskatuMesk -- if blud wanted ad revenue hed be putting those reindeer breeding programs front and center and call it Staredit Dot Nut
[2026-5-28. : 9:43 pm]
Symmetry -- gotta start making extra accounts to game the magic boxes
Please log in to shout.


Members Online: Moose