fix for slots
This commit is contained in:
parent
b20a2c751b
commit
8ac1cbfd6a
1 changed files with 1 additions and 1 deletions
|
@ -105,7 +105,7 @@ class PacketClassWriter:
|
|||
name=self.title,
|
||||
ids='{\n\t\t' + ',\n\t\t'.join(self.ids) + '\n\t}\n',
|
||||
definitions='{\n\t\t' + '\n\t\t'.join(self.slots) + '\n\t}\n',
|
||||
slots=', '.join(f"'{x}'" for x in (list(self.attrs) + ["id"])), # TODO de-jank!
|
||||
slots=', '.join((f"'is_{x}'" if keyword.iskeyword(x) else f"'{x}'") for x in (list(self.attrs) + ["id"])), # TODO de-jank!
|
||||
fields='\n\t'.join(self.fields),
|
||||
state=self.state,
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue