Changeset View
Changeset View
Standalone View
Standalone View
binaries/data/mods/public/gui/session/selection_panels_helpers.js
Show All 27 Lines | function hasSameRestrictionCategory(templateName1, templateName2) | ||||
if (template1.buildRestrictions && template2.buildRestrictions) | if (template1.buildRestrictions && template2.buildRestrictions) | ||||
return template1.buildRestrictions.category == template2.buildRestrictions.category; | return template1.buildRestrictions.category == template2.buildRestrictions.category; | ||||
return false; | return false; | ||||
} | } | ||||
function getPlayerHighlightColor(player) | function getPlayerHighlightColor(player) | ||||
{ | { | ||||
return "color:" + rgbToGuiColor(g_Players[player].color) + " 160"; | return "color:" + rgbToGuiColor(g_DisplayedPlayerColors[player], 160); | ||||
} | } | ||||
/** | /** | ||||
* Returns a "color:255 0 0 Alpha" string based on how many resources are needed. | * Returns a "color:255 0 0 Alpha" string based on how many resources are needed. | ||||
*/ | */ | ||||
function resourcesToAlphaMask(neededResources) | function resourcesToAlphaMask(neededResources) | ||||
{ | { | ||||
let totalCost = 0; | let totalCost = 0; | ||||
▲ Show 20 Lines • Show All 450 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator