AutoStart Plugin

Discussion in 'Plugin Requests' started by iceblue1188, Jun 20, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    iceblue1188

    Hello!

    Today i was searching for plugins that will autostart your minecraft server if its down (I use a server host, not my computer) and i cannot find one. So, what I'm asking, is if anyone knows an existing plugin (Give me link if so), that does what i need, or if someone can make me this plugin.

    Thanks and have a nice day.
    -zIceGod
     
  2. Offline

    nico123o

    Just saying, there is no way to make a plugin like that because for a plugin to work the server has to be up
     
  3. Online

    timtower Administrator Administrator Moderator

    @iceblue1188 When the server is down then the plugin will be as well. You need something else.
     
  4. Offline

    iceblue1188

    Oh yeah ;-;
    k nvm then.
     
  5. Offline

    meguy26

    @iceblue1188 @timtower
    On the contrary, this is possible... Just very tricky. It is possible to launch an independent process from a java process, which could go and restart the server. The only questions would be:
    1. Where to launch from?
    2. When to launch, is there a bukkit crash event or something?
    3. How to prevent launching on a reload?
     
  6. Offline

    xepisolonxx

    @iceblue1188 there is some stuff you can add on the run file and i think also rtoolkit does something not sure if its still around anymore though hope this helps
     
  7. Offline

    Tecno_Wizard

    @iceblue1188, if I remember correctly spigot added a functionality to start a program as the server finished shutting down, but Bukkit has no such function. The only possibility I can see is having the onDisable method initiate an external program with a delay to account for the server shutting down, but that still isn't really a plugin. Also, as @meguy26 said, there is no way to distinguish a reload from restart.
     
  8. Offline

    meguy26

    @Tecno_Wizard
    I recently discovered shutdown hooks, and used them to start a program after/while the server was stopping. Apparently this auto restart thing is more possible than I thought.
     
  9. Offline

    Tecno_Wizard

    @meguy26 Hmm. Could you send me the link to the source when you're done? I'm interested to see how this is done.
     
  10. Offline

    meguy26

    @Tecno_Wizard
    Source for what? Also, if your talking about shutdown hooks, they are incredibly easy, just get the Runtime object, an call Runtim#addShutdownHook(); addShutdownHook accepts a thread object, that is not yet started.
     
  11. Offline

    Tecno_Wizard

  12. Offline

    teej107

    @meguy26 @Tecno_Wizard How ever it would be impossible to keep the server stopped because a new one would always be starting.
     
  13. Offline

    SuippoKala

    If you are using Multicraft panel, there is a schedule-mechanism. Try that!
     
  14. Offline

    Tecno_Wizard

    That was sitting in the back of my head but I wasn't sure if it was necessary to bring up. Yeah, that would be an issue.
     
  15. Offline

    meguy26

    @teej107 @Tecno_Wizard
    no it wouldnt. A simple config option would fix this, and a /disable command.
     
Thread Status:
Not open for further replies.

Share This Page