| 07-30-2008, 01:03 AM | #1 |
Hi, anyone knows how does the boolexpr in this function works? what kind of filtering can i use? native TriggerRegisterPlayerUnitEvent takes trigger whichTrigger, player whichPlayer, playerunitevent whichPlayerUnitEvent, boolexpr filter returns event Thanks! |
| 07-30-2008, 01:17 AM | #2 |
Well, I remember seeing similar question before. Anyway, that works exactly like trigger conditions. The filter you provide will be evaluated first, and then trigger conditions will be evaluated. If any of these filters (including conditions) return false, the trigger will not be executed. To create filters, you can use Filter() function which takes a function as its argument. JASS:function myfunc takes nothing returns boolean return false endfunction Filter(function myfunc) Well, I think you may only use GetFilterUnit() in that function. |
| 08-01-2008, 02:01 AM | #3 |
so using this may be faster than trigger conditions, right? |
| 08-01-2008, 04:05 AM | #4 |
there is problems with boolexpr inside event registration - they not called. |
