RedScout 662 Posted October 4, 2021 Share Posted October 4, 2021 Partyba hívás tiltás(GM-Player) else if (IsGM() == true && pchInvitee->IsGM() == false) Van ez a rész, ez tiltja a partiba hívást, itt pl a gmnek. Ha azt szeretnétek, hogy aki IMPLEMENTOR joggal rendelkezik az tudjon bármit, csak az alatta lévő GM-ek ne, akkor ezeket írjátok át hasonlóan: else if (IsGM() && ch->GetGMLevel() < IMPLEMENTOR && pchInvitee->IsGM() == false) { } 1. Char.cpp-ben keress rá ebben a funkcióban:void CHARACTER::PartyInvite(LPCHARACTER pchInvitee) erre: else if (pchInvitee->IsBlockMode(BLOCK_PARTY_INVITE)) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("<파티> %s 님이 파티 거부 상태입니다."), pchInvitee->GetName()); return; } Add alá: else if (IsGM() == true && pchInvitee->IsGM() == false) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("<Party> You cannot send a party invitation to a player!")); return; } else if (IsGM() == false && pchInvitee->IsGM() == true) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("<Party> You cannot send a party invitation to a GameMaster!")); return; } 2. Privát bolt nyitás tiltás. char_item.cpp-ben keress rá erre: bool CHARACTER::UseItemEx(LPITEM item, TItemPos DestCell) ez alatt erre: case 50200: // 보따리 if (LC_IsYMIR() == true || LC_IsKorea() == true) { if (IS_BOTARYABLE_ZONE(GetMapIndex()) == true) { __OpenPrivateShop(); } else { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("개인 상점을 열 수 없는 지역입니다")); } } írd alá ezt: if (IsGM() == true) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("GameMasters can't build private shops.")); return false; } 3. Tárgy kidobás tiltása. Keress rá erre: bool CHARACTER::DropItem(TItemPos Cell, BYTE bCount) ez alatt erre: (char_item.cpp) LPITEM item = NULL; Add alá: if (IsGM() == true) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("GameMasters can't drop items.")); return false; } /Set parancs tiltása, csak GM felhasználókon tudják majd használni. Keress rá erre:ACMD(do_set) Ez alatt erre: (cmd_gm.cpp) tch = CHARACTER_MANAGER::instance().FindPC(arg1); Add alá: if (tch->IsGM() == false) { ch->ChatPacket(CHAT_TYPE_INFO, "You can only use this on GM characters."); return; } 4. /a parancs tiltása, csak GM felhasználókon tudják majd használni. Keress rá erre: ACMD(do_advance) Ez alatt erre: (cmd_gm.cpp) LPCHARACTER tch = CHARACTER_MANAGER::instance().FindPC(arg1); Add alá: if (tch->IsGM() == false) { ch->ChatPacket(CHAT_TYPE_INFO, "You can only change the level of GM characters."); return; } 5. Setskillother tiltása. Keress rá:ACMD(do_setskillother) ez alatt erre:(cmd_gm.cpp) tch = CHARACTER_MANAGER::instance().FindPC(arg1); Add alá: if (tch->IsGM() == false) { ch->ChatPacket(CHAT_TYPE_INFO, "You can only change GM characters' skills."); return; } 6. Kereskedés. Keress rá: bool CHARACTER::ExchangeStart(LPCHARACTER victim) ez alatt erre:(exchange.cpp) if ( IsOpenSafebox() || GetShopOwner() || GetMyShop() || IsCubeOpen() ) { ChatPacket( CHAT_TYPE_INFO, LC_TEXT("다른 거래창이 열려있을경우 거래를 할수 없습니다." ) ); return false; } Add alá: if (IsGM() == false && victim->IsGM() == true) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("You cannot trade items with a Game Master.")); return false; } if (IsGM() == true && victim->IsGM() == false) { ChatPacket(CHAT_TYPE_INFO, LC_TEXT("Game Masters cannot trade items with players.")); return false; } 7. Klánba hívás tiltása. Keress rá:void CGuild::Invite( LPCHARACTER pchInviter, LPCHARACTER pchInvitee )" ez alatt erre:(guild.cpp) else if ( pchInvitee->GetEmpire() != pchInviter->GetEmpire() ) { pchInviter->ChatPacket( CHAT_TYPE_INFO, LC_TEXT("<길드> 다른 제국 사람을 길드에 초대할 수 없습니다.") ); return; } Add alá: else if (pchInviter->IsGM() == true && pchInvitee->IsGM() == false) { pchInviter->ChatPacket(CHAT_TYPE_INFO, LC_TEXT("<Guild> You can not invite a player to your guild!")); return; } else if (pchInviter->IsGM() == false && pchInvitee->IsGM() == true) { pchInviter->ChatPacket(CHAT_TYPE_INFO, LC_TEXT("<Guild> You can not invite a GM to your guild!")); return; } 8. Tárgyak vásárlása privát boltból. Tiltás. Keress rá erre:void CShopManager::Buy(LPCHARACTER ch, BYTE pos) alatta erre:(shop_manager.cpp) CShop* pkShop = ch->GetShop(); Add alá: if (ch->IsGM() && pkShop->IsPCShop()) { ch->ChatPacket(CHAT_TYPE_INFO, "GameMasters cannot buy items from players' shops."); return; } Forrás: Metin2Dev Quote Link to post Share on other sites
FuveZeq 3 Posted December 26, 2022 Share Posted December 26, 2022 ty Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.