Advertisement
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

[MISC] 12h MapReset Plugins [Alpha_1.3.9]

Comments in 'Plugin Releases' started by Antisober552, Aug 24, 2013.

  1. Antisober552
    Offline

    Antisober552 Staff Member Plugin Reviewer

    Joined:
    Aug 22, 2013
    Posts:
    35
    Plugins:
    3
    Minecraft User:
    Antisober552
    Hi guys

    I've recently started to writing my own plugins, i made this plugin to reset the map every 12 hours, this plugin only works well with the latest version of Pocketmine-Mp and A loop script

    thanks to Intyre for All his help with this plugin

    Download Link
    https://www.dropbox.com/s/blq9cojzstrrbrt/mapReset.php

    There's no need to configure this plugin + there's no commands for this Plugin

    Code:
    Fixed issue with the timer
    
    Kind Regards
    Antisober552
    Last edited: Sep 2, 2013
  2. ZacHack
    Offline

    ZacHack Staff Member Sectional Moderator

    Joined:
    Aug 23, 2013
    Posts:
    325
    Plugins:
    6
    Minecraft User:
    _ZacHack_
    Can u make a plugin with a restart command? Or can I try to steal your code and try to make one with a command like that and give you like 90% of the credit? Lol
  3. Antisober552
    Offline

    Antisober552 Staff Member Plugin Reviewer

    Joined:
    Aug 22, 2013
    Posts:
    35
    Plugins:
    3
    Minecraft User:
    Antisober552
    HI

    really u can not make a restart command out of my plugins but is you want to use some of my code thats fine with me

    kind regards
    Antisober552
  4. Xfusionios
    Offline

    Xfusionios Active Member Plugin Developer

    Joined:
    Aug 24, 2013
    Posts:
    67
    Plugins:
    2
    Minecraft User:
    XFusionios
    how do u loop the start.bat file i added the goto start then added start: in the code but it still require a button to be press for it fully restart itslelf. I have remove the pause.
  5. ZacHack
    Offline

    ZacHack Staff Member Sectional Moderator

    Joined:
    Aug 23, 2013
    Posts:
    325
    Plugins:
    6
    Minecraft User:
    _ZacHack_
    Thanks man i will try to make one but Ill probably fail lol
  6. Antisober552
    Offline

    Antisober552 Staff Member Plugin Reviewer

    Joined:
    Aug 22, 2013
    Posts:
    35
    Plugins:
    3
    Minecraft User:
    Antisober552
    Hi

    you will never know until you give it ago good luck

    kind regards
    Antisober552
  7. ZacHack
    Offline

    ZacHack Staff Member Sectional Moderator

    Joined:
    Aug 23, 2013
    Posts:
    325
    Plugins:
    6
    Minecraft User:
    _ZacHack_
    Thanks man i will give you credit if i succeed :)
  8. iamadpond
    Offline

    iamadpond Banned

    Joined:
    Aug 24, 2013
    Posts:
    191
    Minecraft User:
    iamadpond
    Bash supports a While command though you will need to edit start.sh to do this, As shogichp's code will the prompt for enter after a crash or certain memory errors, Edited code, Removed the prompt to allow a reloading function:

    Code:
    #!/bin/bash
    DIR="$( cd -P "$( dirname "${BASH_SOURCE[0]}" ) " && pwd ) "
    cd "$DIR"
    if [ -f ./php5/bin/php ]; then
    mkdir -m 0777 bin/
    mv ./php5/bin/php ./bin/php
    rm -rf ./php5/
    fi
    if [ -f ./bin/php ]; then
    ./bin/php -d enable_dl=On PocketMine-Mp.php [email protected]
    exit 0 <-- Zero Dont type this :)
    fi
    exit -d enable_dl=on PocketMine-MP.php [email protected]
    exit 0 <-- Zero Again, dont type
    So an example script would go:

    Code:
    #!/bin/bash
    
    while [ 1 ]
    do
      clear
      bash start.sh
      echo Server Crashed or Stopped by SIGINT
      sleep 5
    done
    Now if you wanted to actually quit the server, that sleep code keeps a window open (For five seconds) for you to use CTRL + C (Sigint).
    Now if you want to run a backup script as well you can try nested while statements:

    Code:
    #!/bin/bash
    
    while true
    do
      clear
      while true
       do
       EXAMPLE COMMAND LOLOL
       done &
    EXAMPLE COMMAND TWO LOLOL
    done
    I wouldn't recommend that though, as if the script is not terminated properly you can run into a nasty always running scenarios the require you to reboot, as pocketmine will be cutting into everything you type and not allow you to type properly. </3
    Last edited: Aug 26, 2013
  9. Huntereb
    Offline

    Huntereb Active Member

    Joined:
    Sep 6, 2013
    Posts:
    41
    Minecraft User:
    Huntereb
    This plugin is broken with the newest version of Pocketmine, can anyone fix it?

    I'm also wondering if someone could make a variant of this plugin that, instead of deleting and reloading the chunks file, it could replace the existing chunks with chunks from a different map (Just copy and replace). That way when the map resets, pre-made areas like spawns will still work.
  10. Antisober552
    Offline

    Antisober552 Staff Member Plugin Reviewer

    Joined:
    Aug 22, 2013
    Posts:
    35
    Plugins:
    3
    Minecraft User:
    Antisober552
    i have updated this plugin to work with 1.3.9 please update

    kind regards
    Team Antinty
    Last edited: Sep 9, 2013
  11. Huntereb
    Offline

    Huntereb Active Member

    Joined:
    Sep 6, 2013
    Posts:
    41
    Minecraft User:
    Huntereb
    This plugin does not work, when it deletes all of the chunks, they are not regenerated. So the world is just blank and you fall forever.
  12. Antisober552
    Offline

    Antisober552 Staff Member Plugin Reviewer

    Joined:
    Aug 22, 2013
    Posts:
    35
    Plugins:
    3
    Minecraft User:
    Antisober552
    thx for the information i will fix this soon
  13. Antisober552
    Offline

    Antisober552 Staff Member Plugin Reviewer

    Joined:
    Aug 22, 2013
    Posts:
    35
    Plugins:
    3
    Minecraft User:
    Antisober552
    time to fix this plugin as theres players out there who want it

Share This Page

Advertisement