HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

another rect problem...

08-10-2005, 03:21 PM#1
Skwee
I have a trigger that when one unit enters a preset rect it changes the building in the rect to 80% transparency to give the effect of going inside...

But the problem is that I have about 50 houses I need to go transparent, and I don't want to make 100 triggers.(an extra 50 for leaving the house)

Is there an easy way to do this?

Triggers:

Entering the house:
Quote:
Events
Unit - A unit enters Region 000 <gen>

Actions
Animation - Change House 0000 <gen>'s vertex coloring to (100.00%, 100.00%, 100.00%) with 80.00% transparency

And to leave:
Quote:
Events
Unit - A unit leaves Region 000 <gen>

Conditions
(Number of units in (Units in Region 000 <gen> matching (((Owner of (Matching unit)) controller) Equal to User))) Equal to 0

Actions
Animation - Change House 0000 <gen>'s vertex coloring to (100.00%, 100.00%, 100.00%) with 0.00% transparency
08-10-2005, 03:31 PM#2
Vexorian
The only easier way i can think right now involves JASS and handle variables
08-10-2005, 08:36 PM#3
Skwee
Quote:
Originally Posted by Lord Vexorian
The only easier way i can think right now involves JASS and handle variables

hmm thanks anyway, vex
08-10-2005, 08:44 PM#4
Crimsongg137
try changing the matching unit to leaving unit...
Owner of (Leaving unit)) controller
08-11-2005, 01:05 AM#5
Skwee
Quote:
Originally Posted by Crimsongg137
try changing the matching unit to leaving unit...
Owner of (Leaving unit)) controller

Did you even read my post? the trigger works fine. that wasnt my question....
08-12-2005, 07:38 AM#6
Oblivion9
I might be way off... so I apologize in advance if I am (don't have editor here to verify) but couldn't you assign each region and doodad in an array (assuming that the buildings are doodads otherwise units).

I realize that it's a lot of work, but maybe less than writing each one out... then if a unit enters the region, whatever region number that is in the region array could trigger the corresponding building to do blah blah blah...

But I could be totally wrong.