ztensity Posted February 18, 2021 Share Posted February 18, 2021 Previous Request Hey guys, I've been trying tirelessly to localize "StaminaChangeOT" and "HypothermalResist" via XPATH with XML and Localization, but I have had absolutely no luck, despite multiple attempts to get these names to change. I have tried to use XML with XPATH and Localization to change these names multiple times. Does anyone have any thoughts? I'm truly hoping that one of The Fun Pimps comes in with the save. Saminal is looking at some of my code as well to see if he can find something that will find a way to Localize these lines. Finally see my picture again with full current code I'm using with no luck of changing the Localization of "StaminaChangeOT" and "HypothermalResist." SOLUTION I figured out a work around after speaking with Sirillion! Sirillion informed me earlier today that it's "not really meant to be part of the UI at all, just a piece of code I found when browsing through the engine." So since he said "StaminaChangeOT" was hardcoded, I decided to go a different route. So I dug through his files to hide the code he added that brought back old buff stat displays (which can't be localized) via the below code: <remove xpath="windows/window[@name='buffInfoPanel']/panel/rect/rect[@name='description2']" /> I then used localization for the buff itself to provide the above description, which looks a bit more immersive: buffElementHotShowerWetName,buffs,Buff,,CleanlinessbuffElementHotShowerWetDesc,buffs,Buff,,"Normally under the rain, you get colder, but since you've taken a hot shower, you receive some unexpected benefits.\n\n\n\nStamina Regeneration: +{cvar(.StaminaRegeneration:0.0)}%\n\nCold Resist: +{cvar(.ColdResistance:0.0)}" I will keep the code that hides those stats hidden while I test things, but ultimately, I'll hide it again for the full release for immersion REQUEST I would like to ask for more ways to localize things. Especially when people such as Sirillion uncover old, unused code. This is amongst many of my thoughts for additions to the game moving forward, but I thought I'd share my solution and thoughts! Link to comment Share on other sites More sharing options...
ztensity Posted February 19, 2021 Author Share Posted February 19, 2021 I figured out a work around after speaking with Sirillion! Sirillion informed me earlier today that it's "not really meant to be part of the UI at all, just a piece of code I found when browsing through the engine." So since he said "StaminaChangeOT" was hardcoded, I decided to go a different route. So I dug through his files to hide the code he added that brought back old buff stat displays (which can't be localized) via the below code: <remove xpath="windows/window[@name='buffInfoPanel']/panel/rect/rect[@name='description2']" /> I then used localization for the buff itself to provide the above description, which looks a bit more immersive: buffElementHotShowerWetName,buffs,Buff,,CleanlinessbuffElementHotShowerWetDesc,buffs,Buff,,"Normally under the rain, you get colder, but since you've taken a hot shower, you receive some unexpected benefits.\n\n\n\nStamina Regeneration: +{cvar(.StaminaRegeneration:0.0)}%\n\nCold Resist: +{cvar(.ColdResistance:0.0)}" I will keep the code that hides those stats hidden while I test things, but ultimately, I'll hide it again for the full release for immersion Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.