Jump to content

Sistema gaya


alexander0195

Mensajes recomendados

 

questlua_pc.cpp // actualización

Arat:
    int pc_get_another_quest_flag(lua_State* L)

Üstüne ekle:

#ifdef ENABLE_GEM_SYSTEM
    int pc_open_gem_shop(lua_State * L)
    {
        LPCHARACTER ch = CQuestManager::instance().GetCurrentCharacterPtr();

        if (ch->IsOpenSafebox() || ch->GetExchange() || ch->GetMyShop() || ch->IsCubeOpen() || ch->isSashOpened(true) || ch->isSashOpened(false) || ch->isChangeLookOpened() || ch->isAuraOpened(true) || ch->isAuraOpened(false))
        {
            ch->ChatPacket(CHAT_TYPE_INFO, LC_TEXT("?? ???? ??????? ????? ?? ? ????."));
            return 0;
        }

#ifdef ENABLE_BOSS_GEM_SYSTEM
        int gemShopType = (int)lua_tonumber(L, 1);
        ch->OpenGemShop(gemShopType);
#else
        ch->OpenGemShop();
#endif
        return 0;
    }

    int pc_create_gaya(lua_State * L)
    {
        if (!lua_isnumber(L, 1))
        {
            lua_pushboolean(L, 0);
            return 1;
        }

        int cost = (int)lua_tonumber(L, 1);
        int pct = (int)lua_tonumber(L, 2);
        int metinstone_cell = (int)lua_tonumber(L, 3);
        int glimmerstone_count = (int)lua_tonumber(L, 4);

        LPCHARACTER ch = CQuestManager::instance().GetCurrentCharacterPtr();

        LPITEM metinstone_item = ch->GetStoneInventoryItem(metinstone_cell);

        if (metinstone_item)
            lua_pushboolean(L, ch->CreateGaya(glimmerstone_count, metinstone_item, cost, pct));
        else
            lua_pushboolean(L, 0);

        return 1;
    }
#endif


Arat:
            { NULL,            NULL            }

Üstüne ekle:

#ifdef ENABLE_GEM_SYSTEM
            {"open_gem_shop", pc_open_gem_shop},
            {"create_gaya", pc_create_gaya},
            // {"open_gem_shops", pc_open_gem_shops},
#endif
 

IMG_20210530_021829.png

Debes iniciar sesión para ver el contenido del enlace en esta publicación.

Enlace para comentar
Compartir en otros sitios

Unirse a la conversación

Puedes publicar ahora y registrarte más tarde. Si tienes una cuenta, regístrate para publicar con su cuenta.

Guest
Responder a este tema...

×   Has pegado contenido con formato .   Eliminar formato

  Only 75 emoji are allowed.

×   Tu enlace se ha incorporado automáticamente.   Mostrar un enlace en su lugar

×   Se ha restaurado el contenido anterior. .   Borrar editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recientemente navegando por este tema   0 miembros

    • No hay usuarios registrados visitando esta página.
×
×
  • Crear nuevo...