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

How to create a PocketMine-MP.phar file

Discussion in 'Help' started by MalakasPlayzMC, Apr 15, 2017.

  1. MalakasPlayzMC

    MalakasPlayzMC Spider Jockey

    Messages:
    37
    I use BlueLight because I cannot use DevTools to PocketMine due to incompatible API version. When I do /makeserver it creates the phar correctly but when I do /version it shows that this server is running BlueLight and if I update the protocol version of Info.php to 106 and BlueLight is with protocol version 105 I can join only with MCPE 1.0.5
     
  2. Sandertv

    Sandertv Zombie Pigman Poggit Reviewer

    Messages:
    786
    GitHub:
    Sandertv
  3. MalakasPlayzMC

    MalakasPlayzMC Spider Jockey

    Messages:
    37
  4. HimbeersaftLP

    HimbeersaftLP Fish

    Messages:
    2,402
    GitHub:
    HimbeersaftLP
  5. MalakasPlayzMC

    MalakasPlayzMC Spider Jockey

    Messages:
    37
    It creates a copy of the PocketMine file in my server. I edited the protocol version in Info.php from 102 to 106 and I can join with MCPE 1.0.4 only
     
  6. EdwardHamHam

    EdwardHamHam Skeleton

    Messages:
    962
    GitHub:
    edwardhamham
    Are you running the server with the PocketMine-MP phar file when you try to do /makeserver? Because it won't work that way. You have to be running it from source.
     
  7. MalakasPlayzMC

    MalakasPlayzMC Spider Jockey

    Messages:
    37
    What do you mean?
     
  8. EdwardHamHam

    EdwardHamHam Skeleton

    Messages:
    962
    GitHub:
    edwardhamham
    When you clone the PocketMine repository, you have a folder called src, but there won't be a phar file. If you have the src folder, the server will run from that, and you can do /makeserver to create a phar file. You can then delete the src folder.
     
  9. TheDiamondYT

    TheDiamondYT Zombie

    Messages:
    298
    GitHub:
    TheDiamondYT1
    I compile using ConsoleScript.php from DevTools. I made a simple script called c.sh.

    Code:
    php -dphar.readonly=0 ConsoleScript.php --make src --relative ./ --entry src/pocketmine/PocketMine.php --out PocketMine-MP.phar
    
    I run this script on an Android device.
     
  10. corytortoise

    corytortoise Skeleton

    Messages:
    825
    GitHub:
    corytortoise
    Also, if you have both a source folder and a phar in the directory, the server will be run from the phar, not the source. It helps to only have the version you want to use in the server directory.
     
    EdwardHamHam likes this.
  11. TheDiamondYT

    TheDiamondYT Zombie

    Messages:
    298
    GitHub:
    TheDiamondYT1
    Also if you have a phar AND source directory, start.sh will prioritize the phar over the source.
     
  12. 7awariGamer

    7awariGamer Baby Zombie

    Messages:
    120
    GitHub:
    7awariGamer
    Can u learn me plz
     
  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.