HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Help!

05-27-2004, 07:46 PM#1
Nabren
I'm using if/then/else in the action to apply a special effect to all units selected by the triggering player. Problem is, I only want him to be able to do it to units he owns, not other players units, as he can right now. So I figured the solution was simple, in the condition simply something like:

(Owner of (Targeted Unit)) Equal to (Triggering Player) in the condition, which does nothing but make the WHOLE thing not work.

So how would I go about this? Thanks for any help in advance.
05-27-2004, 08:14 PM#2
Milkman
Quote:
(Owner of (Targeted Unit)) Equal to (Triggering Player) in the condition,


There is no unit event, right? So then theres no Triggering player and no targeted unit, also the thing u want is Selected Unit.

Try something like: Pick all units selected by player 1 matching condition Owned by player 1 and do actions: Your IF/THEN/ELSE statement

Wops, that might not work since u still have to add the notorious condition afterwards, since selected units matching codition isnt available.

Then do this:
Event- A unit is selected
Condition:Unit selected is owned by player 1 equal to true.
Actions:
Your stuff...
05-27-2004, 08:17 PM#3
Nabren
I'd love to be able to use the selected event, problem is they choose which effect to apply through a series of dialog boxes, so when I need the select event to happen, it's already happened, and that trigger would never run.

Basically, they select all units they want to apply the effect to, type a command, the dialog comes up, and they choose which effect to apply. So I need it to only apply to units they own. Is this even possible?
05-27-2004, 08:23 PM#4
Milkman
Of course, I think.. Just gotta think a little...

Ok, so do this: When the units are selected, use the action:
Unit Group - Add Units of Player matching conditions
By doing this you can use the selected event.

However this is a UMSWE thing, so if u don't have it, Download it.
Now that you have all theese units in a group and when you've chosen the thing in the dialog... Apply it to them units in the unitgroup..

Hope it works
05-27-2004, 08:27 PM#5
Vexorian
Just use

A player selects a unit as event

then use triggering unit for the unit and triggering player for the player
05-28-2004, 01:33 AM#6
Nabren
Quote:
Originally Posted by Lord Vexorian
Just use

A player selects a unit as event

then use triggering unit for the unit and triggering player for the player

I cant find that event, is it in a different editor or something other than official one?
05-28-2004, 01:42 AM#7
Nabren
Nevermind, i'm blind. However, that type of event won't help me. I need it to check during the action not the event.
05-28-2004, 12:23 PM#8
Milkman
Ok, if i have understood this right:

You select a bunch of units and then type: KEWL or whatever.
This fires a dialog box and when u press the dialogbutton, u want to have the units he previously selected?

If this is the case. Do as i told you in the above post.