CommonClient: consolidate Connect packet sending

This commit is contained in:
Fabian Dill
2021-11-21 02:50:24 +01:00
parent a27d09f81a
commit 47c5c407ef
3 changed files with 14 additions and 20 deletions

View File

@@ -72,15 +72,7 @@ class FactorioContext(CommonContext):
raise Exception("Cannot connect to a server with unknown own identity, "
"bridge to Factorio first.")
await self.send_msgs([{
"cmd": 'Connect',
'password': self.password,
'name': self.auth,
'version': Utils.version_tuple,
'tags': self.tags,
'uuid': Utils.get_unique_identifier(),
'game': "Factorio"
}])
await self.send_connect()
def on_print(self, args: dict):
super(FactorioContext, self).on_print(args)