| 04-16-2004, 03:52 AM | #1 |
Hey, this trigger is supposed to make it so that if a unit enters a region, and the player-owner of entering unit is not equal to player 10(light blue) then kill the entering unit. heres what i got so far function You_walk_on_u_die_nigger_Conditions takes nothing returns boolean if ( not ( GetOwningPlayer(GetEnteringUnit()) != Player(9) ) ) then return false endif return true endfunction function You_walk_on_u_die_nigger_Actions takes nothing returns nothing endfunction //=========================================================================== function InitTrig_You_walk_on_u_die_nigger takes nothing returns nothing call TriggerAddCondition( gg_trg_You_walk_on_u_die_nigger, Condition( function Trig_You_walk_on_u_die_nigger_Conditions ) ) set gg_trg_You_walk_on_u_die_nigger = CreateTrigger( ) call TriggerRegisterEnterRectSimple( gg_trg_You_walk_on_u_die_nigger, gg_rct_Region_233 ) call TriggerAddAction( gg_trg_You_walk_on_u_die_nigger, function trig_You_walk_on_u_die_nigger_Actions ) endfunction WHAT IS WRONG WITH IT????? CAN SOME1 PLZ HELP ME? |
| 04-16-2004, 04:04 AM | #2 | |
Quote:
that seams a little racist to me, but here is the answer. there is no need to have jass: Code:
REgion
Events
Unit - A unit enters Region 000 <gen>
Conditions
(Owner of (Entering unit)) Not equal to Player 10 (Light Blue)
Actions
Unit - Kill (Entering unit)
|
| 04-16-2004, 04:09 AM | #3 |
And if you need it for a larger trigger, just take that and convert it to custom text. |
| 04-16-2004, 07:13 PM | #4 |
Hey, i no i dont need jass, but i have like 900 regions i need 2 do that 4 so jass would b 900 times faster. can some1 plz help me out on the jass |
| 04-16-2004, 07:43 PM | #5 |
Make the trigger in GUI [the dropdown boxes] Then convert to custom text. Voila. It's JASS. For such a simple trigger, converting will work fine. |
| 04-16-2004, 09:39 PM | #6 |
The best thing would be to have all the rects added to a region an use an enter region event instead of a rect enter event (which creates a region for that rect anyways) edit: and the problem in your jass trigger is that you weren't killing the unit call KillUnit( GetTriggerUnit() ) |
