Change sex Problem

Blood Tears

Путник
Пользователь
Сообщения
30
Розыгрыши
0
Репутация
-8
Реакции
2
Баллы
0
When i change my sex from npc, then when i login my head is invisible
Here is the problem:
Im using l2jacis
Код:
    public static void Sex(L2PcInstance player)
   
    {
        if (player.destroyItemByItemId("Consume", Config.DONATE_ITEM, Config.SEX_ITEM_COUNT, player, true))
        {
           
            player.getAppearance().setSex(player.getAppearance().getSex() == Sex.MALE ? Sex.FEMALE : Sex.MALE);
            player.sendMessage("Your gender has been changed, you will be disconected in 3 Seconds!");
            player.broadcastUserInfo();
            player.decayMe();
            player.spawnMe(player.getX(), player.getY(), player.getZ());
            ThreadPool.schedule(() -> player.logout(false), 3000);
           
        }
        else
            player.sendMessage("You do not have enough Donate Coins.");
    }
 
if (actualCommand.startsWith("changeSex")) {
if (coin5 != null && coin5.getCount() >= ItemCount5)
{
player.destroyItemByItemId("Service", ItemId5, ItemCount5, player, true);
player.setSex(!player.getAppearance().getSex());
player.sendHtmlMessage("Пол успешно изменен");
player.teleToLocation(player.getX(), player.getY(), player.getZ());
//Кик игрока, можно убрать
player.kick();
}
else
{
player.sendMessage("Неверное кол-во монет");
return START;
}


l2pcinstance
// Смена пола
public void setSex(boolean f) {
byte abc = (byte) Rnd.get(3);
_appearance = new PcAppearance(abc, abc, abc, f);
//getAppearance().setSex(f);
}
 
When i change my sex from npc, then when i login my head is invisible
Here is the problem:
Im using l2jacis
Код:
    public static void Sex(L2PcInstance player)
 
    {
        if (player.destroyItemByItemId("Consume", Config.DONATE_ITEM, Config.SEX_ITEM_COUNT, player, true))
        {
         
            player.getAppearance().setSex(player.getAppearance().getSex() == Sex.MALE ? Sex.FEMALE : Sex.MALE);
            player.sendMessage("Your gender has been changed, you will be disconected in 3 Seconds!");
            player.broadcastUserInfo();
            player.decayMe();
            player.spawnMe(player.getX(), player.getY(), player.getZ());
            ThreadPool.schedule(() -> player.logout(false), 3000);
         
        }
        else
            player.sendMessage("You do not have enough Donate Coins.");
    }
U need with change sex set to zero face\hairstyle\hair color
 
Назад
Сверху Снизу