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

Implemented Proposed EnergyLink 2.0 protocol #3117

Open
wants to merge 12 commits into
base: main
Choose a base branch
from
3 changes: 2 additions & 1 deletion worlds/factorio/Client.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,8 @@ async def game_watcher(ctx: FactorioContext):
"cmd": "Set", "key": ctx.energylink_key, "operations":
[{"operation": "add", "value": -ctx.energy_link_increment * in_world_bridges},
{"operation": "max", "value": 0}],
"last_deplete": ctx.last_deplete
"last_deplete": ctx.last_deplete,
"slot": ctx.slot
Jarno458 marked this conversation as resolved.
Show resolved Hide resolved
}]))
# Above Capacity - (len(Bridges) * ENERGY_INCREMENT)
elif in_world_energy > (in_world_bridges * ctx.energy_link_increment * 5) - \
Expand Down
2 changes: 1 addition & 1 deletion worlds/pokemon_rb/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ async def game_watcher(self, ctx):
else:
logger.info(f"Withdrew ${-self.banking_command}.")
await ctx.send_msgs([{
"cmd": "Set", "key": f"EnergyLink{ctx.team}", "operations":
"cmd": "Set", "key": f"EnergyLink{ctx.team}", "slot": ctx.slot, "operations":
[{"operation": "add", "value": self.banking_command * BANK_EXCHANGE_RATE},
{"operation": "max", "value": 0}],
}])
Expand Down
Loading