Changeset View
Changeset View
Standalone View
Standalone View
binaries/data/mods/public/simulation/components/ResourceTrickle.js
Show First 20 Lines • Show All 51 Lines • ▼ Show 20 Lines | ResourceTrickle.prototype.Trickle = function(data, lateness) | ||||
if (!cmpPlayer) | if (!cmpPlayer) | ||||
return; | return; | ||||
cmpPlayer.AddResources(this.rates); | cmpPlayer.AddResources(this.rates); | ||||
}; | }; | ||||
ResourceTrickle.prototype.OnValueModification = function(msg) | ResourceTrickle.prototype.OnValueModification = function(msg) | ||||
{ | { | ||||
if (msg.component != "ResourceTrickle") | |||||
return; | |||||
this.CheckTimer(); | this.CheckTimer(); | ||||
}; | }; | ||||
ResourceTrickle.prototype.OnOwnershipChanged = function(msg) | ResourceTrickle.prototype.OnOwnershipChanged = function(msg) | ||||
{ | { | ||||
if (msg.to != INVALID_PLAYER) | if (msg.to != INVALID_PLAYER) | ||||
this.CheckTimer(); | this.CheckTimer(); | ||||
}; | }; | ||||
▲ Show 20 Lines • Show All 43 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator