Hello I am a beginner in Pocketmine code and I would like to know how to make a custom name to give the player object ?
I assume you mean to give a player a custom named item. You'd start by creating an item using the ItemFactory::get() method, or by using the older method, Item::get(). After you have your Item object, you can use Item->setCustomName(), then give it to the player. If you don't care about what I just said, or still don't understand, just import ItemFactory and use this: PHP: /** @Player $player */ $item = ItemFactory::get(364 /* Steak ID, I think? */, 0 /*Item Damage/meta */, 1/* Count*/); $item->setCustomName("Super Steak"); $player->getInventory()->addItem($item); There are more parameters you can use for creating the Item object, but this method is a bit more friendly to newer developers.
I did give an example, it's the code I posted. If you don't know what to do with it, then there are other things you need to learn about first, such as PHP basics and how to utilize the PMMP API.