Page 1 of 1

BA's team platter widget highlights neutral units

Posted: 02 Dec 2011, 16:20
by knorke
That looks bad on maps with neutral units (Like the one that I try to make. :roll: )
I see no reason why gaiea units should be highlighted so maybe it can be changed to not do that?

Re: BA's team platter widget highlights neutral units

Posted: 13 Dec 2011, 17:27
by zerver
and it kills the FPS

Re: BA's team platter widget highlights neutral units

Posted: 13 Dec 2011, 18:30
by knorke
made changes so that it does not highlight gaiea/neutral units.
Somewhere at top add:

Code: Select all

local GetGaiaTeamID = Spring.GetGaiaTeamID ()
function widget:PlayerChanged()
	GetGaiaTeamID = Spring.GetGaiaTeamID ()
end
and in DrawWorldPreUnit() change
if (teamID)
to
if (teamID and teamID~=GetGaiaTeamID) then

File is attached, I also marked changed lines with --+++

Re: BA's team platter widget highlights neutral units

Posted: 13 Dec 2011, 19:14
by Beherith
Thanks a million knorke, committed.