Sleitnick / AeroGameFramework

AeroGameFramework is a Roblox game framework that makes development easy and fun. The framework is designed to simplify the communication between modules and seamlessly bridge the gap between the server and client.
https://sleitnick.github.io/AeroGameFramework/
MIT License
216 stars 56 forks source link

Mention that AeroServer and Areo are injected into modules #31

Closed catgirlinspace closed 6 years ago

catgirlinspace commented 6 years ago

While looking at the recent DataService update to figure out how the event passing worked, I noticed that it was using self.Shared.Event which confused me because the README.md never mentions anything being injected into modules. Documentation on this would be very useful. (But it does only take a few minutes to reverse engineer AeroServer to the point where it gets injected)

Sleitnick commented 6 years ago

Yes, this was not always the case. Modules used to not include injections. It was changed in later updates because it is quite useful to always have connection to the framework.

catgirlinspace commented 6 years ago

Is this from the WrapModule function? Or did it come earlier?

Sleitnick commented 6 years ago

I added WrapModule today because it seemed common (at least for me) to manually set metatables of my own custom modules to be included in the framework.

Before, lazy-loaded modules simply set the metatable when the modules were set up, but now I am utilizing the WrapModule method for those as well to keep things consistent.

Sleitnick commented 6 years ago

This has been included within the new documentation. See the ServerService.md and ClientController.md files within the doc directory.