Changeset View
Changeset View
Standalone View
Standalone View
binaries/data/mods/public/simulation/ai/common-api/entity.js
Show First 20 Lines • Show All 188 Lines • ▼ Show 20 Lines | m.Template = m.Class({ | ||||
{ | { | ||||
if (this.get("Health") !== undefined) | if (this.get("Health") !== undefined) | ||||
return this.get("Health/Unhealable") !== "true"; | return this.get("Health/Unhealable") !== "true"; | ||||
return false; | return false; | ||||
}, | }, | ||||
"isRepairable": function() { return this.get("Repairable") !== undefined; }, | "isRepairable": function() { return this.get("Repairable") !== undefined; }, | ||||
"getPopulationBonus": function() { return +this.get("Cost/PopulationBonus"); }, | "getPopulationBonus": function() { return +this.get("Population/Bonus"); }, | ||||
"resistanceStrengths": function() { | "resistanceStrengths": function() { | ||||
let resistanceTypes = this.get("Resistance"); | let resistanceTypes = this.get("Resistance"); | ||||
if (!resistanceTypes || !resistanceTypes.Entity) | if (!resistanceTypes || !resistanceTypes.Entity) | ||||
return undefined; | return undefined; | ||||
let resistance = {}; | let resistance = {}; | ||||
if (resistanceTypes.Entity.Capture) | if (resistanceTypes.Entity.Capture) | ||||
▲ Show 20 Lines • Show All 778 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator