|
|
@@ -359,6 +359,12 @@ const solutionsCleanup = () => {
|
|
|
});
|
|
|
}
|
|
|
|
|
|
+const getTotalProfit = (sid1, sid2, gold_side_jc) => {
|
|
|
+ const sol1 = GAMES.Solutions[sid1];
|
|
|
+ const sol2 = GAMES.Solutions[sid2];
|
|
|
+ return calcTotalProfit(sol1, sol2, gold_side_jc);
|
|
|
+}
|
|
|
+
|
|
|
const getDataFromChild = (type, callback) => {
|
|
|
const id = ++Request.count;
|
|
|
Request.callbacks[id] = callback;
|
|
|
@@ -401,5 +407,5 @@ setInterval(() => {
|
|
|
module.exports = {
|
|
|
updateGamesList, updateGamesEvents, getGamesList,
|
|
|
updateGamesRelation, getGamesRelation, removeGamesRelation,
|
|
|
- getGamesEvents, getSolutions, calcTotalProfit,
|
|
|
+ getGamesEvents, getSolutions, getTotalProfit,
|
|
|
}
|