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

Solved Change player gamemode

Discussion in 'Development' started by @McJblus, Apr 2, 2019.

  1. @McJblus

    @McJblus Spider

    Messages:
    6
    Hello, I would like to create some commands "/ gmc (for the creative mode) and the others, / gms, / gma, I'd like to know what is the event to insert in the code so that it changes our mode of games
     
  2. KielKing

    KielKing Zombie

    Messages:
    245
    GitHub:
    kielking
    PHP:
    /** @var Player $player */
    $player->setGamemode(Player::CREATIVE);
     
  3. @McJblus

    @McJblus Spider

    Messages:
    6
    thank you ^^
     
  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.