1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Block Time Money

Discussion in 'Plugin Help' started by WylSmart, Jul 4, 2020.

  1. WylSmart

    WylSmart Slime

    Messages:
    93
    When you stand in a certain position, money is add to you on time, tell me how to organize this function?
     
  2. JviguyGamesYT

    JviguyGamesYT Baby Zombie

    Messages:
    113
    GitHub:
    jviguy
    ok so two things are needed for this a movement detector (easy) task(medium) i would use something like these for testing at a certain block or position (ill be doing block!)
    PHP:
    public function onmove(PlayerMoveEvent $e) {
        
    $regx $e->getPlayer()->getFloorX();
        
    $blockx $regx 1;
        
    $block $player->getLevel()->getBlock($blockx);
        if (
    $block->getId() === (ID OF THE BLOCK U WANT) {
            (
    RUN YOUR TASK HERE WITH THE PLAYER)
        }
    }
    then the task ill work on later cause im not really feeling up to doing tasks at the moment ,but thats what i use for what ur asking for.
     
  3. WylSmart

    WylSmart Slime

    Messages:
    93
    Help me please, next post >> https://forums.pmmp.io/threads/essentialspe-v2-1-0-crash.10057/
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.