Jump to content

Trying to edit playerspanel, did something wrong?

Recommended Posts

I have a question about the playerspanel.xc file in the config.


I wanted to adjust it so it would show the winrate on the left side of the players names instead of the wn8 one that the simple variant uses. I also want the names of the tanks in the colors of wn8 ratings. I believe this is a common used setup in other xvm configs, but I can't seem to get it right with your package. (I used LaCourgette's XVM Updater before)


I managed to pull out the playerspanel.xc file I was using before, and it is working as it did before, but instead of 50% I now see 50.xxxxxxxxxxxxx in front of the name, do I need to edit some other file as well in order for the % to show instead of a decimal number? 


I'm using the large panel by the way. I want it to show me the win% with color, white player name, tank name in wn8 color and default tank contour etc. 

Link to comment
  • Administrator

Te macros has changed about 1-2 months ago, you need to convert them to a new format.


Old macro for winrate: {{rating}}


New winrate macro: {{rating%2d~%|--%}}


To display winrate colored by wn8  :) use following line:


<font color='{{c:wn8|#666666}}' alpha='{{alive?#FF|#80}}'>{{rating%2d~%|--%}}</font>

Link to comment

I don't understand a single thing about all these coding things and macro's sorry.. I simply replaced the PlayersPanel.xc provided by your installer, with the one the other installer gave me. The large panel options in that file now look like this: 

// Options for the "large" panels - the widest panels.
    // Режим ушей "large" - широкие уши в игре.
    "large": {
      // Width of the player's name column, 0-250. Default is 170.
      // Ширина поля имени игрока, 0-250. По умолчанию: 170.
      "width": 170,
      // Display format for player nickname (macros allowed, see readme-en.txt).
      // Формат отображения имени игрока (допускаются макроподстановки, см. readme-ru.txt).
      "nickFormatLeft": "<font color='{{c:rating}}'>{{rating}}</font> {{nick}}",
      "nickFormatRight": "{{nick}} <font color='{{c:rating}}'>{{rating}}</font>",
      // Display format for vehicle name (macros allowed, see readme-en.txt).
      // Формат отображения названия танка (допускаются макроподстановки, см. readme-ru.txt).
      "vehicleFormatLeft": "<font color='{{c:wn}}'>{{vehicle}}</font>",
      "vehicleFormatRight": "<font color='{{c:wn}}'>{{vehicle}}</font>"
It shows the colors right, but the winrate is shown as a number with digits after the comma, 53.45531255 for example. I want that to show 53%. Could you point out which line I need to edit? Can't see through dev eyes :(
I tried replacing the lines {{rating}} to {{rating%2d~%|--%}} but that just shows me --%} in the panel, no data or color at all..
Link to comment
  • Administrator

If you use this <font color='{{c:wn8|#666666}}' alpha='{{alive?#FF|#80}}'>{{rating%2d~%|--%}}</font>


It will show decimals without anything after coma. There won't be even a coma.

This is your config in reality of new XVM macros:


// Options for the "large" panels - the widest panels.
    "large": {
      "width": 170,
      "nickFormatLeft": "<font color='{{c:wn8|#666666}}' alpha='{{alive?#FF|#80}}'>{{rating%2d~%|--%}}</font> {{nick}}",
      "nickFormatRight": "{{nick}} <font color='{{c:wn8|#666666}}' alpha='{{alive?#FF|#80}}'>{{rating%2d~%|--%}}</font>",
      "vehicleFormatLeft": "<font color='{{c:wn8}}' alpha='{{alive?#FF|#80}}'>{{vehicle}}</font>",
      "vehicleFormatRight": "<font color='{{c:wn8}}' alpha='{{alive?#FF|#80}}'>{{vehicle}}</font>"
More or less, I am pretty busy, so might need some tunes ;)
Link to comment

But it won't use the winrate colors but the wn8 colors? That's not what I was aiming for :P


Tried that:


Names are ok now, colored in wn8, winrate shows that exact color too tho, so that color should be changed to the winrate scale. Should it look like this then?

"nickFormatLeft": "<font color='{{c:rating|#666666}}' alpha='{{alive?#FF|#80}}'>{{rating%2d~%|--%}}</font> {{nick}}",
"nickFormatRight": "{{nick}} <font color='{{c:rating|#666666}}' alpha='{{alive?#FF|#80}}'>{{rating%2d~%|--%}}</font>",


Or is that too straight forward?

Link to comment

Haha no I wanted the winrate colors to have their own colors :P Just changing that to c:rating will do? Great, thanks for the support, and so fast too with such a busy site! Will use this mod as my new total package, it has so much great functions and it all was out the minute WoT was patched! GJ!


EDIT: It works, you are my hero!

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.