Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes to Sim.js and content mod acceptance #560 #592

Merged
merged 2 commits into from
Feb 21, 2021
Merged

Fixes to Sim.js and content mod acceptance #560 #592

merged 2 commits into from
Feb 21, 2021

Conversation

DanielNoord
Copy link
Collaborator

Building on discussion in #560 and #591 I have rewritten Sim.js to be a little less 'static'.

New lines in CM.Main.Loop() check for new mods and if any are found it reloads all relevant function needed for the calculations in Sim.js.

I believe this closes #560 and therefore also #591

@hyoretsu
Copy link

hyoretsu commented Feb 21, 2021

For the most part, yes, but it still broke on CM.Sim.CalculateGains since adding kitten upgrades needs to inject a new line

if (Game.Has('Misfortune #603')) {
 catMult *= 1 + milkProgress * 0.05 * milkMult;
}

@hyoretsu
Copy link

hyoretsu commented Feb 21, 2021

If this also conflicts somewhere, upgrades that lower building/upgrade costs also need to inject into Game.modifyBuildingPrice and Game.Upgrade.prototype.getPrice.

@DanielNoord
Copy link
Collaborator Author

CM.Sim.CalculateGains will be fixed in #593
If I get to that issue I will also check for Game.modifyBuildingPrice and Game.Upgrade.prototype.getPrice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Incompatible with some content mods
2 participants