Tutorial Handling Data with Data Objects and Managing Player Sessions

Discussion in 'Resources' started by SOFe, Dec 10, 2016.

  1. InspectorGadget

    InspectorGadget Zombie Pigman

    Messages:
    465
    GitHub:
    InspectorGadget
    Very good tutorial, thanks :)
     
  2. Bluplayz

    Bluplayz Spider Jockey

    Messages:
    43
    GitHub:
    bluplayz
    what about creating another player class and extends pocketmine\Player? i try it and it is perfect to add functions for the player like
    PHP:
    //own functions
    if($player instanceof MyPlayerClass){
        
    $player->addJoin();
        
    $player->setMain();
    }
     
  3. Jack Noordhuis

    Jack Noordhuis Zombie Pigman Poggit Reviewer

    Messages:
    620
    GitHub:
    JackNoordhuis
    If every plugin starts doing this then servers running multiple pugins will cause lots of issues very quickly, thats why using custom player classes is discouraged.
     
    Awzaw likes this.
  4. Bluplayz

    Bluplayz Spider Jockey

    Messages:
    43
    GitHub:
    bluplayz
    ah ok, i only have an own player class in one plugin called "Core", there are my network stuff and doesnt make issues xD
     
  5. SOFe

    SOFe Administrator Staff Member PMMP Team Poggit Admin

    Messages:
    1,876
    GitHub:
    sof3
    Citation: https://botbot.me/freenode/pocketmine/2015-07-23/?msg=45322216 :shoghi::shoghi::shoghi::shoghi::shoghi::shoghi::shoghi::shoghi:
     
    Bluplayz likes this.

Share This Page

  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.