Advertisement
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Different skin for different players

Comments in 'Plugin Development' started by wolfdale, Oct 28, 2015.

  1. wolfdale
    Offline

    wolfdale Active Member Plugin Developer

    Joined:
    Dec 3, 2014
    Posts:
    276
    Plugins:
    1
    Minecraft User:
    ace
    For example player A will see that player B have a superman skin, but player C will see that player B have a Batman skin, how to do this by code? Thanks
  2. Creeperface
    Offline

    Creeperface Notable Member Plugin Developer

    Joined:
    Nov 8, 2014
    Posts:
    1,346
    Plugins:
    4
    Minecraft User:
    CreeperFace
    PHP:
    $pk = new PlayerListPacket();
    $pk->type PlayerListPacket::TYPE_ADD;
    $pk->entries[] = [$playerB->getUniqueId(), $playerB->getId(), $playerB->getDisplayName(), $isSkinSlim$skinData];

    $playerA->dataPacket($pk);
    //change skin
    $pk->entries[] = [$playerB->getUniqueId(), $playerB->getId(), $playerB->getDisplayName(), $isSkinSlim$skinData];

    $playerC->dataPacket($pk);
    wolfdale likes this.

Share This Page

Advertisement