A plea for a simple-UI mod :(
rantology
Join Date: 2012-02-05 Member: 143750Members, NS2 Developer, NS2 Playtester, Squad Five Gold, NS2 Map Tester, Reinforced - Shadow, WC 2013 - Gold
<div class="IPBDescription">I lack the knowledge to make one myself.. :/</div>A simple request for a mod, if anyone is bored enough. I'm not even sure that it can be done without the game being mad at client/server differences, but here goes:
Could anyone make a mod (or even point me in the right direction for the files I need to rename/delete) that gets rid of the following UI elements in the game:
-Marine waypoints of every kind
-Structure text (like when you aim at an extractor and it pops up with "EXTRACTORLOL" in your face but you were actually just trying to kill the skulk munching on it that you can no longer see because of the text >:|) preferably leaving the HP % text, it's the structure names I really hate.
-Banner messages for power outages/ups
-The minimap on the top left of the marine UI
-The blue lines on the marine UI
Again even if anyone can point me to the right file(s) to modify that would be hugely helpful. I was digging around in the cinematics files but they were pretty confusing. Worst comes to worst I will figure them out by trial and error- but I was wondering if anyone knew where to look off the top of their head.
Could anyone make a mod (or even point me in the right direction for the files I need to rename/delete) that gets rid of the following UI elements in the game:
-Marine waypoints of every kind
-Structure text (like when you aim at an extractor and it pops up with "EXTRACTORLOL" in your face but you were actually just trying to kill the skulk munching on it that you can no longer see because of the text >:|) preferably leaving the HP % text, it's the structure names I really hate.
-Banner messages for power outages/ups
-The minimap on the top left of the marine UI
-The blue lines on the marine UI
Again even if anyone can point me to the right file(s) to modify that would be hugely helpful. I was digging around in the cinematics files but they were pretty confusing. Worst comes to worst I will figure them out by trial and error- but I was wondering if anyone knew where to look off the top of their head.
Comments
Edit ns2\ui\marine_HUD_frame.dds for this one.
Edit: Just realized Yuuki was already working on it.
<a href="http://www.sendspace.com/file/bgoue1" target="_blank">http://www.sendspace.com/file/bgoue1</a>
Extract anywhere and launch startMod.exe. Or install like an usual mod.
It's really a mess though, I mainly set gui element to being invisible (e.g. self.minimapBackground:SetIsVisible(false)) but everything is in different files and is sometimes hard to find. What would be very nice is to have a config file, where you can set each element being visible or not.
Even better would be something like the <a href="http://visualhud.pk69.com/" target="_blank">Quake Live VHUD</a> system... I'd really like to do something like that to be able to design more quickly, but I'm just not experienced enough to do it in any reasonable amount of time.
It's beautiful Yuuki, thanks a ton. Any idea where/how to get rid of the waypoints, or if it's even possible? (they are cinematic files right?) I agree the customization of the UI is way too difficult :/ portions of the UI are everywhere in the game folders/lua files.. 'hence my plea for help, heh. I wish they would make is easier to mod/tweak as well.
But again thanks for all the help.
To merge with menumod:
-extract the .lua files into the lua folder in menumod
-extract the 'hud' folder into the lua folder in menumod
edit: also the only thing that is slightly inconvenient about using this is that score no longer pops up when you've killed something, which admittedly I relied on a bit.. not a big deal though. Still an awesome mod for being thrown together, improves the game a lot for me.
To put it back, replace the original function in GUINotifications.lua.
I though a bit about making a cleaner version of this, that wouldn't require so much update on new builds, but it's not too easy. On my first version, I also moved some elements on the map key (display only when map key is pressed), like the health.
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->function GUINotifications:UpdateScoreDisplay(deltaTime)
if self.scoreDisplayFadeoutTime > 0 then
self.scoreDisplayFadeoutTime = math.max(0, self.scoreDisplayFadeoutTime - deltaTime)
local fadeRate = 1 - (self.scoreDisplayFadeoutTime / GUINotifications.kScoreDisplayFadeoutTimer)
local fadeColor = self.scoreDisplay:GetColor()
fadeColor.a = 1
fadeColor.a = fadeColor.a - (fadeColor.a * fadeRate)
self.scoreDisplay:SetColor(fadeColor)
if self.scoreDisplayFadeoutTime == 0 then
self.scoreDisplay:SetIsVisible(false)
end
end
if self.scoreDisplayPopdownTime > 0 then
self.scoreDisplayPopdownTime = math.max(0, self.scoreDisplayPopdownTime - deltaTime)
local popRate = self.scoreDisplayPopdownTime / GUINotifications.kScoreDisplayPopTimer
local fontSize = GUINotifications.kScoreDisplayMinFontHeight + ((GUINotifications.kScoreDisplayFontHeight - GUINotifications.kScoreDisplayMinFontHeight) * popRate)
self.scoreDisplay:SetFontSize(fontSize)
if self.scoreDisplayPopdownTime == 0 then
self.scoreDisplayFadeoutTime = GUINotifications.kScoreDisplayFadeoutTimer
end
end
if self.scoreDisplayPopupTime > 0 then
self.scoreDisplayPopupTime = math.max(0, self.scoreDisplayPopupTime - deltaTime)
local popRate = 1 - (self.scoreDisplayPopupTime / GUINotifications.kScoreDisplayPopTimer)
local fontSize = GUINotifications.kScoreDisplayMinFontHeight + ((GUINotifications.kScoreDisplayFontHeight - GUINotifications.kScoreDisplayMinFontHeight) * popRate)
self.scoreDisplay:SetFontSize(fontSize)
if self.scoreDisplayPopupTime == 0 then
self.scoreDisplayPopdownTime = GUINotifications.kScoreDisplayPopTimer
end
end
local newScore, resAwarded = ScoreDisplayUI_GetNewScore()
if newScore > 0 then
// Restart the animation sequence.
self.scoreDisplayPopupTime = GUINotifications.kScoreDisplayPopTimer
self.scoreDisplayPopdownTime = 0
self.scoreDisplayFadeoutTime = 0
local resAwardedString = ""
if resAwarded > 0 then
resAwardedString = string.format(" (+%d res)", resAwarded)
end
self.scoreDisplay:SetText(string.format("+%s%s", tostring(newScore), resAwardedString))
self.scoreDisplay:SetFontSize(GUINotifications.kScoreDisplayMinFontHeight)
self.scoreDisplay:SetColor(GUINotifications.kScoreDisplayTextColor)
self.scoreDisplay:SetIsVisible(true)
end
end<!--c2--></div><!--ec2-->
It is basically just a case of removing al the code for the minimap, but just do a compare on the Marine GUI files in my mod with the one's in the actual game to see the difference.
Here is a screenshot of the UI in my mod, as you can see, I have got rid of almost everything :)
<img src="http://img.photobucket.com/albums/v260/Soulrefuge/2012-05-16_00005.jpg" border="0" class="linked-image" />
In lua\Hud\Marine\GUIMarineHud.lua, delete line 331:
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->self.minimapBackground:SetIsVisible(false)<!--c2--></div><!--ec2-->
and change line 334
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->self.minimapScript:ShowMap(false)<!--c2--></div><!--ec2-->to this
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->self.minimapScript:ShowMap(true)<!--c2--></div><!--ec2-->
Yuuki posted that above, at the bottom of the GUINotifications.lua file you'll see the last section start with "function GUINotifications:UpdateScoreDisplay(deltaTime)", replace everything below that with what Yuuki posted above and the score pop-ups will be back.
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1--><optionGroup>
waypoints
</optionGroup>
<infile>
Marine_Client.lua
</infile>
<replace>
// Don't draw waypoint if we have hints displaying (to avoid the screen telling the player
// about too many things to do)
local waypointVisible = true
</replace>
<by>
// Don't draw waypoint if we have hints displaying (to avoid the screen telling the player
// about too many things to do)
local waypointVisible = false
</by><!--c2--></div><!--ec2-->
It would also help to have other people help me to remove elements of the GUI. If anybody is willing to help.