mirror of
https://github.com/OpenFusionProject/OpenFusion.git
synced 2024-11-04 22:40:05 +00:00
Disabled GM mode (#22)
Temporarily disabled, players can now use item commands without GM mode.
This commit is contained in:
parent
786ee5f4f4
commit
ab6df26f92
@ -192,14 +192,15 @@ void CNLoginServer::handlePacket(CNSocket* sock, CNPacketData* data) {
|
||||
|
||||
int64_t UID = character->PCStyle.iPC_UID;
|
||||
|
||||
bool BecomeGM;
|
||||
// commented and disabled for now
|
||||
//bool BecomeGM;
|
||||
|
||||
if (U16toU8(character->PCStyle.szFirstName) == settings::GMPASS) {
|
||||
BecomeGM = true;
|
||||
U8toU16("GM",character->PCStyle.szFirstName);
|
||||
} else {
|
||||
BecomeGM = false;
|
||||
}
|
||||
//if (U16toU8(character->PCStyle.szFirstName) == settings::GMPASS) {
|
||||
// BecomeGM = true;
|
||||
// U8toU16("GM",character->PCStyle.szFirstName);
|
||||
//} else {
|
||||
// BecomeGM = false;
|
||||
//}
|
||||
|
||||
character->PCStyle.iNameCheck = 1;
|
||||
response->sPC_Style = character->PCStyle;
|
||||
@ -225,7 +226,7 @@ void CNLoginServer::handlePacket(CNSocket* sock, CNPacketData* data) {
|
||||
loginSessions[sock].characters[UID].Equip[2].iType = 2;
|
||||
loginSessions[sock].characters[UID].Equip[3].iID = character->sOn_Item.iEquipFootID; // foot!
|
||||
loginSessions[sock].characters[UID].Equip[3].iType = 3;
|
||||
loginSessions[sock].characters[UID].IsGM = BecomeGM;
|
||||
loginSessions[sock].characters[UID].IsGM = false;
|
||||
|
||||
sock->sendPacket(new CNPacketData((void*)response, P_LS2CL_REP_CHAR_CREATE_SUCC, sizeof(sP_LS2CL_REP_CHAR_CREATE_SUCC), sock->getEKey()));
|
||||
break;
|
||||
|
@ -98,10 +98,11 @@ void ItemManager::itemGMGiveHandler(CNSocket* sock, CNPacketData* data) {
|
||||
sP_CL2FE_REQ_PC_GIVE_ITEM* itemreq = (sP_CL2FE_REQ_PC_GIVE_ITEM*)data->buf;
|
||||
PlayerView& plr = PlayerManager::players[sock];
|
||||
|
||||
if (!plr.plr.IsGM) {
|
||||
// Commented and disabled for future use
|
||||
//if (!plr.plr.IsGM) {
|
||||
// TODO: send fail packet
|
||||
return;
|
||||
}
|
||||
// return;
|
||||
//}
|
||||
|
||||
if (itemreq->eIL == 2) {
|
||||
// Quest item, not a real item, handle this later, stubbed for now
|
||||
|
Loading…
Reference in New Issue
Block a user