HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

multibar cut off?

09-13-2008, 05:11 AM#1
botanic
Im using
Collapse JASS:
local integer mb = CreateMultibar(udg_Multiboard, 0, ( udg_PlayersTotal + 1 ), 4, 600, 200, udg_MULTIBAR_TYPE_MAC)
to create the bar and
Trigger:
Make
Collapse Events
Time - Elapsed game time is 0.05 seconds
Conditions
Collapse Actions
Multiboard - Create a multiboard with 4 columns and (PlayersTotal + 2) rows, titled Stats
Set Multiboard = (Last created multiboard)
Multiboard - Set the display style for Multiboard item in column 1, row 1 to Show text and Hide icons
Collapse For each (Integer A) from 1 to (PlayersTotal + 1), do (Actions)
Collapse Loop - Actions
Multiboard - Set the width for Multiboard item in column 1, row (Integer A) to 1.20% of the total screen width
Multiboard - Set the width for Multiboard item in column 2, row (Integer A) to 6.00% of the total screen width
Multiboard - Set the width for Multiboard item in column 3, row (Integer A) to 3.00% of the total screen width
Multiboard - Set the width for Multiboard item in column 4, row (Integer A) to 3.50% of the total screen width
Collapse For each (Integer A) from 2 to 4, do (Actions)
Collapse Loop - Actions
Collapse For each (Integer B) from 1 to (PlayersTotal + 1), do (Actions)
Collapse Loop - Actions
Multiboard - Set the display style for Multiboard item in column (Integer A), row (Integer B) to Show text and Hide icons
Collapse For each (Integer A) from 2 to 4, do (Actions)
Collapse Loop - Actions
Multiboard - Set the width for Multiboard item in column (Integer A), row (PlayersTotal + 2) to 4.00% of the total screen width
Collapse For each (Integer B) from 1 to (PlayersTotal + 1), do (Actions)
Collapse Loop - Actions
Multiboard - Set the display style for Multiboard item in column (Integer A), row (Integer B) to Show text and Hide icons
Collapse For each (Integer A) from 1 to 4, do (Actions)
Collapse Loop - Actions
Multiboard - Set the display style for Multiboard item in column (Integer A), row (PlayersTotal + 2) to Hide text and Show icons
Multiboard - Set the width for Multiboard item in column 1, row (PlayersTotal + 2) to 4.00% of the total screen width
-------- stuff --------
Multiboard - Set the text for Multiboard item in column 2, row 1 to Name
Multiboard - Set the text for Multiboard item in column 3, row 1 to Kills
Multiboard - Set the text for Multiboard item in column 4, row 1 to Revive
Collapse For each (Integer A) from 1 to PlayersTotal, do (Actions)
Collapse Loop - Actions
Multiboard - Set the text for Multiboard item in column 2, row ((Integer A) + 1) to PlayerCustName[(Integer A)]
Multiboard - Set the text for Multiboard item in column 3, row ((Integer A) + 1) to 0
Trigger - Run MultiBars <gen> (checking conditions)
Multiboard - Show Multiboard
to set it up however I get a problem where it wont go all the way across no matter what i change the farthest i can get the bar to stretch is shown in that picture...
Attached Images
File type: jpgUntitled.jpg (133.8 KB)
09-13-2008, 11:35 PM#2
Ammorth
If you want to start the bar at 100% (max) set both maxval and currentval to the same. You then need to use the update function when you want to update the value the bar represents.
09-14-2008, 12:40 PM#3
botanic
Thats not the issue the problem is that it wont stretch across the entire multiboard =/ I was just using those values to test.

can get it to fill up just fine....
09-14-2008, 07:02 PM#4
Ammorth
Multibars uses 1 column for each "square" in the bar. So, to increase the size of the bar, you need more columns. To add more, just make more columns and set all the extra colum widths to 0 and then draw the multibar.