owenashurst / agar.io-clone

Agar.io clone written with Socket.IO and HTML5 canvas
MIT License
2.89k stars 1.12k forks source link

Added Chat Client and Canvas modules #421

Closed aadilzbhatti closed 8 years ago

aadilzbhatti commented 8 years ago

In this pull request, I have moved the Chat Client and Canvas objects and their respective functions into their own files, called "chat-client.js" and "canvas.js". This is in contrast to the current model with both of these objects defined in the global "app.js" code. I think that doing this will make it easier for incoming developers to be able to work with the current code as well as for us to test functionality in specific parts of the project without breaking others.

I plan to refactor more of the code and hopefully will be able to successfully break down the project into very simple components (game logic, chat client, game canvas, controls, relevant constants, etc.). I think overall this would make the project more welcoming to developers who want to use the code.

Please let me know if there's anything I should structure differently, rename, etc.

  

igorantun commented 8 years ago

Looks great, I'm sure it'll help a lot :) Thanks once again for contributing!

aadilzbhatti commented 8 years ago

:+1: