| 11-11-2004, 09:38 PM | #1 |
Hum, i started using multiboards just a few days ago so im quite noob with this kind of trigger. The question is, what am i doing wrong in this trigger? I want the multiboard to show the kills of a X player but it dont work, i kill a unit, kills change to 7 and stay like that. Check this: Code:
Multiboard Kills
Events
Unit - A unit Dies
Conditions
(Owner of (Dying unit)) Not equal to (Owner of (Killing unit))
Actions
If ((Owner of (Killing unit)) Equal to Player 7 (Green)) then do (Set kills[(Player number of (Owner of (Killing unit)))] = ((Player number of (Owner of (Killing unit))) + 1)) else do (Do nothing)
If ((Owner of (Killing unit)) Equal to Player 8 (Pink)) then do (Set kills[(Player number of (Owner of (Killing unit)))] = ((Player number of (Owner of (Killing unit))) + 1)) else do (Do nothing)
If ((Owner of (Killing unit)) Equal to Player 9 (Gray)) then do (Set kills[(Player number of (Owner of (Killing unit)))] = ((Player number of (Owner of (Killing unit))) + 1)) else do (Do nothing)
If ((Owner of (Killing unit)) Equal to Player 10 (Light Blue)) then do (Set kills[(Player number of (Owner of (Killing unit)))] = ((Player number of (Owner of (Killing unit))) + 1)) else do (Do nothing)
If ((Owner of (Killing unit)) Equal to Player 7 (Green)) then do (Multiboard - Set the text for (Last created multiboard) item in column 3, row 2 to (String((Player number of (Owner of (Killing unit)))))) else do (Do nothing)
If ((Owner of (Killing unit)) Equal to Player 8 (Pink)) then do (Multiboard - Set the text for (Last created multiboard) item in column 3, row 3 to (String((Player number of (Owner of (Killing unit)))))) else do (Do nothing)
If ((Owner of (Killing unit)) Equal to Player 9 (Gray)) then do (Multiboard - Set the text for (Last created multiboard) item in column 3, row 4 to (String((Player number of (Owner of (Killing unit)))))) else do (Do nothing)
If ((Owner of (Killing unit)) Equal to Player 10 (Light Blue)) then do (Multiboard - Set the text for (Last created multiboard) item in column 3, row 5 to (String((Player number of (Owner of (Killing unit)))))) else do (Do nothing) |
| 11-11-2004, 10:13 PM | #2 | |
Quote:
You are setting up the Kills() array. Fine. Then, you are setting the Multiboard to display the number of the player instead of the Kills() variable you set up. I think you know what to do :) |
| 11-12-2004, 02:26 AM | #3 |
Dalten is correct, in the actions you have Player number of (Owner of (Killing unit)) Instead of kills[(Player number of (Owner of (Killing unit)))]. Also, when you are setting the variable kills[#], you don't need the if statements for each player. However, for making the multiboard you still need to single out each player because their columns are different. Goodluck. :) |
| 11-12-2004, 08:53 AM | #4 |
Oops, right, didnt notice that, thks you two ![]() |
