In-game HUD settings mixup with <custom_ui>, script, XML-RPC

Moderators: w1lla, NADEO

User avatar
undef.de
Posts: 2095
Joined: 06 Apr 2011, 21:57
Location: Germany, North Sea Coast
Contact:

In-game HUD settings mixup with <custom_ui>, script, XML-RPC

Post by undef.de »

As longer as i working on my controller, i think about the mixup how to setup the in-game hud in TM²:

With the <custom_ui> block we can turn on/off some of the in-game Panels/Widgets, but it seems that some of the settings takes no effects or some of the in-game Panels has been already removed:

Code: Select all

<custom_ui>
  <global visible="true"/>              // Works for all working settings below
  <challenge_info visible="true"/>      // Works
  <chat visible="true"/>                // Works
  <scoretable visible="true"/>          // Works
  <notice visible="true"/>              // No effect, because this messages are removed(?)
  <net_infos visible="true"/>           // No effect
  <checkpoint_list visible="true"/>     // No effect
  <round_scores visible="true"/>        // No effect -> UI_DisplaySmallScoresTable
</custom_ui>
With the XML-RPC Method UI_DisplaySmallScoresTable we can setup the <round_scores> of a <custom_ui> block.

With the script setting S_DisplayTimeDiff we can setup the TimeGap-Panel on a checkpoint.

------------------------------

So in my eyes it would be nice to change all of these to be changed only by a 'SetModeScriptSettings' call.

I already have wished something like this at New options for TM² UI.Script.txt, Options for MultilapLayer, Option for "RankingLayer" in Score in TM² Titles and WarmUp.Script.txt new options/possibilities.

That would clean-up the current mixup and gives us the controll over the HUD.

Please nadeo think about this. :thx:
Developer of UASECO, a controller with support of the Modescript Gamemodes for TM².
Visit the official website for more: UASECO.org


Developer of various plugins for XAseco/XAseco2 and MPAseco, visit my lab: www.undef.name

You like what I do? Then award a ManiaStar.
User avatar
Eole
Nadeo
Nadeo
Posts: 1265
Joined: 26 Apr 2011, 21:08

Re: In-game HUD settings mixup with <custom_ui>, script, XML

Post by Eole »

I pushed an update on the Test branch of the repository that should ease the control on the UI. The files are available here (you can download the whole branch to be sure to have all necessary files).

I wrote a quick documentation explaining how the new methods and callbacks work. Basically you have access to a new XmlRpc method "UI_SetProperties" that take an XML string as parameter. This XML contains the visibility and position of the various UI elements of Trackmania. Almost all of them can be shown/hidden and some can be moved. It only work for TM now, but I'll adapt it to Shootmania later.

Example :

Code: Select all

<ui_properties>
  <map_info visible="true" />
  <opponents_info visible="true" />
  <chat visible="true" offset="0. 0." linecount="20" />
  <checkpoint_list visible="true" pos="0. 0. 0." />
  <round_scores visible="true" pos="0. 0. 0." />
  <countdown visible="true" />
  <go visible="true" />
  <chrono visible="true" pos="0. 0. 0." />
  <speed_and_dist visible="true" />
  <personnal_best_and_rank visible="true" pos="0. 0. 0." />
  <position visible="true" />
  <checkpoint_time visible="true" pos="0. 0. 0." />
  <chat_avatar visible="true" />
  <warmup visible="true" pos="0. 0. 0." />
</ui_properties>
Contribute to the ManiaPlanet documentation on GitHub
A question about ManiaScript? Ask it here!
User avatar
Eole
Nadeo
Nadeo
Posts: 1265
Joined: 26 Apr 2011, 21:08

Re: In-game HUD settings mixup with <custom_ui>, script, XML

Post by Eole »

Small update adding control over the warm-up UI.
Contribute to the ManiaPlanet documentation on GitHub
A question about ManiaScript? Ask it here!
User avatar
spaii
Posts: 1100
Joined: 19 Jun 2010, 00:04
Location: Rémy - France
Contact:

Re: In-game HUD settings mixup with <custom_ui>, script, XML

Post by spaii »

Nice :thumbsup:

BTW, is there a solution to disable ladder ranking at podium ? (at top center of screen)

Image
User avatar
Eole
Nadeo
Nadeo
Posts: 1265
Joined: 26 Apr 2011, 21:08

Re: In-game HUD settings mixup with <custom_ui>, script, XML

Post by Eole »

Not right now, but as soon as it will be possible to do it, I'll add it. Same thing for the multilap UI displaying the number of turns.
Contribute to the ManiaPlanet documentation on GitHub
A question about ManiaScript? Ask it here!
User avatar
spaii
Posts: 1100
Joined: 19 Jun 2010, 00:04
Location: Rémy - France
Contact:

Re: In-game HUD settings mixup with <custom_ui>, script, XML

Post by spaii »

Ok, thx a lot :thumbsup:
User avatar
undef.de
Posts: 2095
Joined: 06 Apr 2011, 21:57
Location: Germany, North Sea Coast
Contact:

Re: In-game HUD settings mixup with <custom_ui>, script, XML

Post by undef.de »

Eole wrote: Example :

Code: Select all

<ui_properties>
  <personnal_best_and_rank visible="true" pos="0. 0. 0." />
</ui_properties>
Possible typo: <personnal_best_and_rank> instead of <personal_best_and_rank>? Same in the UI documentation.

For what exactly is the <opponents_info>? Missing the description for that option. ;)

Thanks for this and for adding the others things like <chat_avatar>, <chrono>, <go>...! I love the new possibilities. :yes: Going right now to test them. =)
Developer of UASECO, a controller with support of the Modescript Gamemodes for TM².
Visit the official website for more: UASECO.org


Developer of various plugins for XAseco/XAseco2 and MPAseco, visit my lab: www.undef.name

You like what I do? Then award a ManiaStar.
User avatar
undef.de
Posts: 2095
Joined: 06 Apr 2011, 21:57
Location: Germany, North Sea Coast
Contact:

Re: In-game HUD settings mixup with <custom_ui>, script, XML

Post by undef.de »

This seems to not work for me, the 3...2...1...GO! animation is always visible:

Code: Select all

<go visible="false" />
All others works fine. :thx:


I've taken the default values for every attribute from the Scripts. Eole, feel free to add them to the documentation:

Code: Select all

<ui_properties>
	<map_info visible="true" />
	<opponents_info visible="true" />
	<chat visible="true" offset="0. 0." linecount="7" />
	<checkpoint_list visible="true" pos="40. -90. 5." />
	<round_scores visible="true" pos="104. 14. 5." />
	<countdown visible="true" />
	<go visible="true" />
	<chrono visible="true" pos="0. -80. 5." />
	<speed_and_dist visible="true" />
	<personnal_best_and_rank visible="true" pos="158. -61. 5." />
	<position visible="true" />
	<checkpoint_time visible="true" pos="-8. 31.8 -10." />
	<chat_avatar visible="true" />
	<warmup visible="true" pos="170. 27. 0." />
</ui_properties>
I personaly dislike things like <speed_and_dist>, i prefer the longer <speed_and_distance>. But thats only my humble opinion. ;)
Developer of UASECO, a controller with support of the Modescript Gamemodes for TM².
Visit the official website for more: UASECO.org


Developer of various plugins for XAseco/XAseco2 and MPAseco, visit my lab: www.undef.name

You like what I do? Then award a ManiaStar.
oliverde8
Posts: 1345
Joined: 16 Jun 2010, 07:33
Location: in a Blue Box

Re: In-game HUD settings mixup with <custom_ui>, script, XML

Post by oliverde8 »

Thanks a lot, this is great :thumbsup:
Image
Developper for The next generation, Clean and Powerfull controller eXpansion for your SM & TM server . Working on eXpansion² with full MP4 support and many other awesome features...
User avatar
Suma
Posts: 62
Joined: 22 Feb 2012, 04:00
Contact:

Re: In-game HUD settings mixup with <custom_ui>, script, XML

Post by Suma »

:o coool stuff :clap:

... could you please add also pos to <speed_and_dist visible="true" /> ?

It would be extremely usefull for fast but not yet FS TM, where time is often too short to move the eyes to the right corner of the screen.
At least for old men^^
Post Reply

Return to “Trackmania² Reports”

Who is online

Users browsing this forum: No registered users and 0 guests