1. questlua_pc.cpp // güncellemesi
  2. Arat:
  3. int pc_get_another_quest_flag(lua_State* L)
  4. Üstüne ekle:
  5. #ifdef ENABLE_GEM_SYSTEM
  6. int pc_open_gem_shop(lua_State * L)
  7. {
  8. LPCHARACTER ch = CQuestManager::instance().GetCurrentCharacterPtr();
  9. if (ch->IsOpenSafebox() || ch->GetExchange() || ch->GetMyShop() || ch->IsCubeOpen() || ch->isSashOpened(true) || ch->isSashOpened(false) || ch->isChangeLookOpened() || ch->isAuraOpened(true) || ch->isAuraOpened(false))
  10. {
  11. ch->ChatPacket(CHAT_TYPE_INFO, LC_TEXT("?? ???? ??????? ????? ?? ? ????."));
  12. return 0;
  13. }
  14. #ifdef ENABLE_BOSS_GEM_SYSTEM
  15. int gemShopType = (int)lua_tonumber(L, 1);
  16. ch->OpenGemShop(gemShopType);
  17. #else
  18. ch->OpenGemShop();
  19. #endif
  20. return 0;
  21. }
  22. int pc_create_gaya(lua_State * L)
  23. {
  24. if (!lua_isnumber(L, 1))
  25. {
  26. lua_pushboolean(L, 0);
  27. return 1;
  28. }
  29. int cost = (int)lua_tonumber(L, 1);
  30. int pct = (int)lua_tonumber(L, 2);
  31. int metinstone_cell = (int)lua_tonumber(L, 3);
  32. int glimmerstone_count = (int)lua_tonumber(L, 4);
  33. LPCHARACTER ch = CQuestManager::instance().GetCurrentCharacterPtr();
  34. LPITEM metinstone_item = ch->GetStoneInventoryItem(metinstone_cell);
  35. if (metinstone_item)
  36. lua_pushboolean(L, ch->CreateGaya(glimmerstone_count, metinstone_item, cost, pct));
  37. else
  38. lua_pushboolean(L, 0);
  39. return 1;
  40. }
  41. #endif
  42. Arat:
  43. { NULL, NULL }
  44. Üstüne ekle:
  45. #ifdef ENABLE_GEM_SYSTEM
  46. {"open_gem_shop", pc_open_gem_shop},
  47. {"create_gaya", pc_create_gaya},
  48. // {"open_gem_shops", pc_open_gem_shops},
  49. #endif