| 05-04-2006, 05:28 AM | #1 |
ok I have a couple triggers in my map that are essential to gameplay but run far too often. This first one constantly sets a variable so that if any hero changes via metamorphasis or repicking. it'll still reference the players hero. It's a horrible trigger though, as it would be launching every time the hero is ordered around, and causes a lot of lag. Trigger: that trigger makes gag me every time i see it, i've come up with a possible solution, but I'm worried it might cause some problems. I was thinking that instead of using a variable such as unit hero. I'd just use random unit owned by player matching condition. like this... Trigger: player- set the current research level of summon upgrade to((Hero level of (random unit from(units owned by (picked player) matching ((matching unit) is a hero) equal to true)))/2) for (picked player)but that just seems sloppy and looks like it might cause even more problems even though each player only has one hero, so it's bound to select the right one. other idea that doesn't seem very good to me (all units in playable map area matching (matching unit is a hero) and (matching unit owned by picked player) Anyone know of a better way to reference a generic hero that isnt preplaced? It would be much apreciated. |
| 05-04-2006, 06:29 AM | #2 |
could you explain more about the situations in the game? like when and how the hero owned by certain player will change |
| 05-04-2006, 07:15 AM | #3 |
I see no real cause for a lag when setting a variable when the hero is ordered. I do that myself on my map and it gets no lags. |
| 05-04-2006, 09:13 AM | #5 |
Eh, yea that could cause lags, however I dont even know what the world editor unlimited exactly is doing when it changes armor. If I were you I wouldnt be using world editor unlimited. There is nothing world editor cant do that WEU can. It fucked up my map once anyways. |
| 05-04-2006, 08:38 PM | #6 |
well from what I know its accessing several custom abilities with its own premade variables, and running some functions in the custom script that runs before variables are set (the one in the map name on the trigger editor). But ya I know you can do anything on warcraft editor that WEU can, but WEU is quite helpful. And until I go about learning jass, I think I'm going to hang onto it. thanks for your help mate. |
