Fixed negative PP #406
This commit is contained in:
@@ -3951,11 +3951,11 @@ CM.Sim.hasGod=function(what) {
|
|||||||
|
|
||||||
CM.Sim.eff = function(name) {
|
CM.Sim.eff = function(name) {
|
||||||
if (typeof CM.Sim.effs[name]==='undefined') {
|
if (typeof CM.Sim.effs[name]==='undefined') {
|
||||||
CM.Sim.effs[name] = 1
|
CM.Sim.effs[name] = 1;
|
||||||
return CM.Sim.effs[name]
|
return CM.Sim.effs[name];
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return Game.effs[name];
|
return CM.Sim.effs[name];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4089,7 +4089,7 @@ CM.Sim.CalculateGains = function() {
|
|||||||
var mult = 1;
|
var mult = 1;
|
||||||
// Include minigame effects
|
// Include minigame effects
|
||||||
var effs={};
|
var effs={};
|
||||||
for (var i in CM.Cache.Objects) {
|
for (var i in Game.Objects) {
|
||||||
// TODO Store minigames and effects in Cache
|
// TODO Store minigames and effects in Cache
|
||||||
// Include possibility of new/modded building and new/modded minigames
|
// Include possibility of new/modded building and new/modded minigames
|
||||||
if (CM.Sim.Objects[i].minigameLoaded && CM.Sim.Objects[i].minigame.effs) {
|
if (CM.Sim.Objects[i].minigameLoaded && CM.Sim.Objects[i].minigame.effs) {
|
||||||
|
|||||||
@@ -114,11 +114,11 @@ CM.Sim.hasGod=function(what) {
|
|||||||
|
|
||||||
CM.Sim.eff = function(name) {
|
CM.Sim.eff = function(name) {
|
||||||
if (typeof CM.Sim.effs[name]==='undefined') {
|
if (typeof CM.Sim.effs[name]==='undefined') {
|
||||||
CM.Sim.effs[name] = 1
|
CM.Sim.effs[name] = 1;
|
||||||
return CM.Sim.effs[name]
|
return CM.Sim.effs[name];
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return Game.effs[name];
|
return CM.Sim.effs[name];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -252,7 +252,7 @@ CM.Sim.CalculateGains = function() {
|
|||||||
var mult = 1;
|
var mult = 1;
|
||||||
// Include minigame effects
|
// Include minigame effects
|
||||||
var effs={};
|
var effs={};
|
||||||
for (var i in CM.Cache.Objects) {
|
for (var i in Game.Objects) {
|
||||||
// TODO Store minigames and effects in Cache
|
// TODO Store minigames and effects in Cache
|
||||||
// Include possibility of new/modded building and new/modded minigames
|
// Include possibility of new/modded building and new/modded minigames
|
||||||
if (CM.Sim.Objects[i].minigameLoaded && CM.Sim.Objects[i].minigame.effs) {
|
if (CM.Sim.Objects[i].minigameLoaded && CM.Sim.Objects[i].minigame.effs) {
|
||||||
|
|||||||
Reference in New Issue
Block a user