| 05-21-2006, 04:13 PM | #1 |
Been trying alot but getting troublesome... I want a multiboard that changes size depending on how many players are in the game, 1 row per player... I've done that... Now the problem is... I got a trigger that is supposed to add a value to a specific row depending on who killed a unit... If player 1 kills a unit... it ofcourse adds the value to row 1... but... if the 2nd player joined the game as player 4... and there's only 2 players... How do I get Player 4's value into Row 2? Player Number doesnt work since it writes it in Row 4 (duh...), and Row 4 is not supposed to exist... |
| 05-21-2006, 04:27 PM | #2 |
This is very complicated, it all depends on how you have made your mutliboard, please can you post the code of your multiboard so we know how to adjust to it. In reality though, you need to save a integer variable showing which player is which. this can get messy |
| 05-21-2006, 04:35 PM | #3 |
its actually quite simple. In your init event (or every x seconds if you want to account for leaves), create a player array and loop through all players from 1 - 12. Check if player is on and then set player[playernumber - 1] to that. In your multiboard, use this playerarray variable to decide the size and position required. |
| 05-21-2006, 04:38 PM | #4 |
That really wont work, player 12 can be in players 2s place on the multiboard, you have to assign and edit. It especially gets complicated when you have computers as a middish player like player 3 - 10 |
| 05-21-2006, 04:53 PM | #6 |
Might not be 100% correct atm... but it's (AmountOfPlayers + 2) rows because the top row is Titles, and the bottom is Time. Supposed to look like this: ---------------------------------- Name_____Lives____Rep_____PvP Siphon_____50 ______0 _____+0 Random____50 ______0______+0 Time:____________00:00:01____ ----------------------------------- That's how it should look if it's only two people playing, and it does look like this, the trouble is.. if Random joined as Player 6... I can't assign new values to Lives/Rep/PvP since I havent found any good triggers for that. You see, Random is Player 2 now... But was 6 when he joined... So he would still count as Player #6. Example: Player 6 (Random) kills a unit. Now he's supposed to get Rep for that, and it's supposed to show in Column 3, Row 3... (hard, this is what I dont know how to fix) Player 1 (Siphon) kills a unit. Now he's supposed to get Rep for that, and it's supposed to show in Column 3, Row 2... (easy.. Player Number + 1) |
| 05-21-2006, 05:08 PM | #7 |
Where you loop Integeber B, don't you mean (Integer B + 2) and not +1?... Also, show us how you got the variable "AmountOfPlayers" stored. EDIT: I found out your problem. Here, do this: Create an integer array. Name it like PlayerRow[] Now, when you do the playerslot comparison crap to check the amount of players, add the actions Trigger: ![]() Set PlayerRow[0] = PlayerRow[0] + 1
![]() Set PlayerRow[Player's Number] = PlayerRow[0] (which is 1)Now, when yer adding the kills to the row, instead of using GetPlayerNumber, use the integer PlayerRow[GetPlayerNumber]. I dunno if that made any sense to you, but it should work - hehe. |
| 05-21-2006, 05:29 PM | #8 |
Don't quite understand... I'll add the trigger so u can implement it yourself. EDIT: Nvm, I understand it now Trigger: Names![]() Conditions![]() Actions |
