| 06-11-2005, 10:33 PM | #1 |
ok, my brother is trying to make something to bind units, sort of like what the game Binders did, and hes asking me for help, but i ran into a problem. Heres what i have so far, tell me whats wrong (i havnt added the removal of the units yet, so dont tell me to add it) Code:
[u]Events[/u] Unit - A unit enters Region 000 <gen> [u]Conditions[/u] (Number of units in (Units in Region 000 <gen> matching ((Unit-type of (Matching unit)) Equal to Footman))) greater than 0 (Number of units in (Units in Region 000 <gen> matching ((Unit-type of (Matching unit)) Equal to Rifleman))) greater than 0 [u]Actions[/u] Unit - Create 1 Mortar Team for (Owner of (Triggering unit)) at (Center of Region 001 <gen>) facing Default building facing degrees Thanx to any1 ahead of time!! ![]() |
| 06-11-2005, 11:19 PM | #2 |
What do you mean by 'bind'? |
| 06-11-2005, 11:30 PM | #3 | |
Use the 'And - Multiple Conditions' condition. Like so: Quote:
|
| 06-12-2005, 01:04 AM | #4 |
no, when u set more than 1 in the conditions area, they act as an "and (multiple functions)" condition, so you dont need to tell it that by bind, i mean to use triggers to remove two or more selected units and give them a better unit. |
| 06-12-2005, 09:22 AM | #5 |
Perhaps you are experiencing the unit enters region bug. Try using a periodic event instead of the "unit enters region", or just move your conditions to the actions (using an if-then-else) and put a small wait action in front of it. |
| 06-12-2005, 06:53 PM | #6 | |
Quote:
![]() |
| 06-12-2005, 08:02 PM | #7 |
Code:
Test
Events
Player - Player 1 (Red) types a chat message containing Test as An exact match
Unit - A unit enters Region 001 <gen>
Conditions
(Number of units in (Units in Region 001 <gen> matching ((Unit-type of (Matching unit)) Equal to Footman))) Greater than 0
(Number of units in (Units in Region 001 <gen> matching ((Unit-type of (Matching unit)) Equal to Rifleman))) Greater than 0
Actions
Game - Display to (All players) the text: Trigger Active.That is an EXACT Cut-and-Paste of the Trigger I recreated. It works perfectly fine. Therefore you most likely are either A) using the wrong region or B) using the wrong unit types. |
| 06-12-2005, 10:05 PM | #8 |
Hi, im yuripro's brother. Thanks to tim I finally got it to work. That's all the information i needed to know. thanks again. |
| 06-12-2005, 10:42 PM | #9 |
Blerg, the solution is to check if the unit is in the region instead of the rect. |
| 06-13-2005, 12:25 AM | #10 |
i have no idea what you said vex, but amazingly, tims trigger worked. Whats wrong with using a periodic even though?? After i used Tims idea, with the same unit, it worked?? Is there yet another bug with periodic events? It only worked when we typed "Test", or w.e we wanted it to look for, but the periodic even didnt work? BTW moo, your not supposed to tell them...... |
| 06-13-2005, 09:11 AM | #11 | |
Quote:
|
| 06-13-2005, 07:06 PM | #12 |
no, im saying, y didnt the periodic event work, some1 else suggested that, it it didnt seem to work. For tims, it works, but you have to type a command like -bind to activate it. O well, this works |
| 06-13-2005, 08:25 PM | #13 |
If it works with a chat command, it should also work with a periodic trigger. After all ,the conditions and actions don't use event responses at all, so no matter on what event the trigger runs, it should work the same. Obviously ,something was wrong with the rest of the trigger when you tested the periodic event. |
