Dimensions / Solar

The API for Dimensions
MIT License
4 stars 0 forks source link

onEnable or ServerStartEvent? #1

Closed phase closed 9 years ago

phase commented 9 years ago

Do we want to have the enabling be an Event or a method? I personally like the event.

wgaylord commented 9 years ago

Well I think you should use an event based system. Because you could then easily make the other events later with out having to write a whole new system to handle them.

phase commented 9 years ago

@chibill I've already started on the Event system, but I don't know whether or not to use it for enabling/disabling.

wgaylord commented 9 years ago

Well it would be sort of like how forge uses it event system to preinit,init and poatinit mods. (Their is an function with a parm of the event class..)

phase commented 9 years ago

We're going to use an Event system for server starting & closing: ServerBootEvent: Fired right when the server is opened. ServerLoadEvent: Fired when the server starts to load. ServerStopEvent: Fired when the server stops.

wgaylord commented 9 years ago

And also ServerLoadEvent seems point-less. Unless you mean like when it starts to load in all the world data...

Maybe a PluginLoadedEvent to tell other plugins a Plugin was loaded. And it would be sent to all but the freshly loaded plugin.

phase commented 9 years ago

@chibill I mean twhen the world and stuff was loaded. PluginLoadedEvent could work too.

wgaylord commented 9 years ago

Yeah that makes sense now. But the loading of the world would it not be a WorldLoadedEvent? And also a ChunkLoaderEvent when chunks are actually loaded. Maybe the ServerLoadEvent would mean when it loads all the saypve data like the ban list and that?

phase commented 9 years ago

It'd be great to have multiple events for it, such as the Chunk & World loading.

wgaylord commented 9 years ago

See slack I made a google doc spread sheet for us to list event ideas. Also don't put its url up as it is anyone with link can edit.