BryceMehring / Hexel

Retro Tower Defense Game
https://brycemehring.github.io/projects/hexel/
MIT License
5 stars 2 forks source link

Malformed JSON causes crash in multiplayer #52

Open Kioljin opened 9 years ago

Kioljin commented 9 years ago

Infrequently, the client application will cease working upon receiving an incomplete JSON. We should not have a fatal error from JSON and we should be able to try and recreate the packet so our final product is more stable.

Kioljin commented 9 years ago

From what I can tell, this bug is caused when there are a large number of towers and enemies on the screen at one time. I'd venture a guess that LUA is having trouble translating so many objects into a JSON string and back. Therefore we could try to increase the valid number of characters to be sent via JSON or to trim the number of attributes we are sending back and forth somehow.