• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C++ MSGGET函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中MSGGET函数的典型用法代码示例。如果您正苦于以下问题:C++ MSGGET函数的具体用法?C++ MSGGET怎么用?C++ MSGGET使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了MSGGET函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: MsgBox

void CAcceptIp::Load(LPSTR filename)
{
	int count=0;
	int Token;
	
	SMDFile=fopen(filename, "r");

	if (SMDFile == NULL)
	{
		MsgBox(lMsg.Get(MSGGET(0, 112)), filename);
		return;
	}

	while ( true )
	{
		Token=GetToken();

		if (Token == END)
		{
			break;
		}

		if ( Token == NAME )
		{
			strcpy(this->szIp[count] , TokenString);
			this->UseIp[count] = true;
			count++;
		}
	}

	fclose(SMDFile);
	LogAdd(lMsg.Get(MSGGET(1, 164)), count);
}
开发者ID:ADMTec,项目名称:GameServer,代码行数:33,代码来源:AcceptIp.cpp


示例2: NpcFasi

BOOL NpcFasi(LPOBJ lpNpc, LPOBJ lpObj)
{
	if ( gDevilSquareEvent != FALSE )
	{
		GCServerCmd(lpObj->m_Index, 1, 6, 0);
	}

	if ( lpObj->m_PK_Level > 4 )
	{
		if ( PvP.gPkLimitFree == FALSE )
		{
			int numbertext = rand() % 3;

			switch ( numbertext )
			{
				case 0:
					ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 98)), lpObj->m_Index);
					break;

				case 1:
					ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 99)), lpObj->m_Index);
					break;

				case 2:
					ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 100)), lpObj->m_Index);
					break;
			}

			lpNpc->TargetNumber = -1;	// Apply Deathway Fix, change 0 to -1;
			return TRUE;
		}
	}

	return FALSE;
}
开发者ID:ADMTec,项目名称:GameServer,代码行数:35,代码来源:NpcTalk.cpp


示例3: PHeadSubSetB

void CCrywolf::NotifyCrywolfPersonalRank()
{
	PMSG_ANS_CRYWOLF_PERSONAL_RANK pMsg;

	PHeadSubSetB((LPBYTE)&pMsg, 0xBD, 0x07, sizeof(pMsg));
	pMsg.btRank = 0;

	for ( int i=OBJ_STARTUSERINDEX;i<OBJMAX;i++)
	{
		if ( gObj[i].Connected == PLAYER_PLAYING &&
			 gObj[i].Type == OBJ_USER &&
			 gObj[i].MapNumber == MAP_INDEX_CRYWOLF_FIRSTZONE)
		{
			pMsg.btRank = this->CalcGettingRank(i);
			pMsg.iGettingExp = this->CalcGettingRewardExp(i, pMsg.btRank);

			if ( gObj[i].m_wExprienceRate == 0)
				pMsg.iGettingExp = 0;

			this->GiveRewardExp(i, pMsg.iGettingExp);

			MsgOutput(i, lMsg.Get(MSGGET(12, 244)), pMsg.btRank);
			MsgOutput(i, lMsg.Get(MSGGET(12, 245)), pMsg.iGettingExp);

			LogAddTD("[ Crywolf ][Personal Rank & Exp.] [%s][%s] Score(%d) Rank(%d) Exp(%d)",
				gObj[i].AccountID, gObj[i].Name, gObj[i].m_iCrywolfMVPScore, pMsg.btRank, pMsg.iGettingExp);

			DataSend(i, (LPBYTE)&pMsg, sizeof(pMsg));
		}
	}
}
开发者ID:Natzugen,项目名称:IGCN---Season-5,代码行数:31,代码来源:Crywolf.cpp


示例4: NpcGuildMasterTalk

BOOL NpcGuildMasterTalk(LPOBJ lpNpc, LPOBJ lpObj)
{
	if ( gGuildCreate == FALSE )
	{
		ChatTargetSend(lpNpc, "서버분할 기간에는 길드를 생성할수가 없습니다", lpObj->m_Index);
		return TRUE;
	}

	if ( lpObj->GuildNumber > 0 )
	{
		ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 116)), lpObj->m_Index);
		return TRUE;
	}

	int capacity = gObjGuildMasterCapacityTest(lpObj);

	if ( capacity == 0 )
	{
		ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 117)), lpObj->m_Index);
	}
	else if ( capacity == 2 )
	{
		ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 118)), lpObj->m_Index);
	}
	else
	{
		GCGuildMasterQuestionSend(lpObj->m_Index);
	}

	return TRUE;
}
开发者ID:constantinbogdan,项目名称:node3d,代码行数:31,代码来源:NpcTalk.cpp


示例5: SendEventStartMsg

void CDevilSquare::SendEventStartMsg()
{
    PMSG_NOTICE pToEventer;
    PMSG_NOTICE pWithOutEvneter;

    TNotice::MakeNoticeMsg(&pToEventer, 0, lMsg.Get(MSGGET(2, 195)));
    TNotice::MakeNoticeMsg(&pWithOutEvneter, 0, lMsg.Get(MSGGET(2, 196)));

    for ( int n=OBJ_STARTUSERINDEX; n<OBJMAX; n++)
    {
        if ( gObj[n].Connected == PLAYER_PLAYING )
        {
            if ( DS_MAP_RANGE(gObj[n].MapNumber) != FALSE )
            {
                DataSend(n, (BYTE *)&pToEventer, pToEventer.h.size);
            }
            else
            {
                DataSend(n, (BYTE *)&pWithOutEvneter, pWithOutEvneter.h.size);
            }
        }
    }

    LogAddTD("[DevilSquare] Start Event");
}
开发者ID:stimpy76,项目名称:zTeam-Source-Season8,代码行数:25,代码来源:DevilSquare.cpp


示例6: NpcGuildMasterTalk

BOOL NpcGuildMasterTalk(LPOBJ lpNpc, LPOBJ lpObj)
{
	if ( gGuildCreate == FALSE )
	{
		ChatTargetSend(lpNpc, "Creation of the guild is DISABLED!", lpObj->m_Index);
		return TRUE;
	}

	if ( lpObj->GuildNumber > 0 )
	{
		ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 116)), lpObj->m_Index);
		return TRUE;
	}

	int capacity = gObjGuildMasterCapacityTest(lpObj);

	if ( capacity == 0 )
	{
		ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 117)), lpObj->m_Index);
	}
	else if ( capacity == 2 )
	{
		char buf[100]={0};
		wsprintf(buf,"You need at least %d resets",ReadConfig.ResetReq_NpcGuildMasterTalk);
		ChatTargetSend(lpNpc, buf, lpObj->m_Index);
		GCServerMsgStringSend(buf,lpObj->m_Index, 0x01);
	}
	else
	{
		GCGuildMasterQuestionSend(lpObj->m_Index);
	}

	return TRUE;
}
开发者ID:ADMTec,项目名称:GameServer,代码行数:34,代码来源:NpcTalk.cpp


示例7: GCStateInfoSend

void CCrywolfStatue::CrywolfStatueAct(int iIndex)
{
	if ( !gObjIsConnected(iIndex))
		return;

	if ( gObj[iIndex].Type != OBJ_NPC || CHECK_CLASS(204, gObj[iIndex].Class) == FALSE )
		return;

	LPOBJ lpObj = &gObj[iIndex];
	int iContractedAlterCount = g_CrywolfNPC_Altar.GetContractedAltarCount();
	int iPriestHPSum = g_CrywolfNPC_Altar.GetPriestHPSum();
	int iPriestMaxHPSum = g_CrywolfNPC_Altar.GetPriestMaxHPSum();

	if ( iContractedAlterCount == 0 || this->m_Shield.m_iShieldHP == 0 )
	{
		if ( this->m_Shield.m_iShieldState == 1 )
		{
			UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(13, 5)));
			this->m_Shield.m_iShieldState = 0;
			this->m_Shield.m_iShieldHP = 0;
			this->m_Shield.m_iShieldMaxHP = 0;
			this->m_Shield.m_iPriestNumber = iContractedAlterCount;
			lpObj->m_ViewSkillState[this->GetStatueViewState(iContractedAlterCount)] = 1;
			GCStateInfoSend(lpObj, 1, this->GetStatueViewState(iContractedAlterCount));
		}
		else if ( this->m_Shield.m_iPriestNumber != iContractedAlterCount )
		{
			this->m_Shield.m_iShieldState = 1;
			this->m_Shield.m_iShieldHP = iPriestHPSum;
			this->m_Shield.m_iShieldMaxHP = iPriestMaxHPSum;
			this->m_Shield.m_iPriestNumber = iContractedAlterCount;
			UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(13, 6)), iContractedAlterCount, iPriestHPSum);

			lpObj->m_ViewSkillState[this->GetStatueViewState(iContractedAlterCount)] = 1;
			GCStateInfoSend(lpObj, 1, this->GetStatueViewState(iContractedAlterCount));
		}

		return;
	}
	else if ( this->m_Shield.m_iShieldState == 0 )
	{
		UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(13, 7)));

			lpObj->m_ViewSkillState[this->GetStatueViewState(iContractedAlterCount)] = 1;
			GCStateInfoSend(lpObj, 1, this->GetStatueViewState(iContractedAlterCount));
	}
	else if ( this->m_Shield.m_iPriestNumber != iContractedAlterCount )
	{
		UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(13, 6)), iContractedAlterCount, iPriestHPSum);

			lpObj->m_ViewSkillState[this->GetStatueViewState(iContractedAlterCount)] = 1;
			GCStateInfoSend(lpObj, 1, this->GetStatueViewState(iContractedAlterCount));
	}

	this->m_Shield.m_iShieldState = 1;
	this->m_Shield.m_iShieldHP = iPriestHPSum;
	this->m_Shield.m_iShieldMaxHP = iPriestMaxHPSum;
	this->m_Shield.m_iPriestNumber = iContractedAlterCount;
}
开发者ID:constantinbogdan,项目名称:node3d,代码行数:59,代码来源:CrywolfStatue.cpp


示例8: NpcFasi

BOOL NpcFasi(LPOBJ lpNpc, LPOBJ lpObj)
{
	if ( gLanguage != 0 )
	{
		if ( gDevilSquareEvent != FALSE )
		{
			GCServerCmd(lpObj->m_Index, 1, 6, 0);
		}
	}

	if ( lpObj->m_PK_Level > 4 )
	{
		int hour = 0;
		int min = 0;

		if ( lpNpc->TargetNumber != lpObj->m_Index )
		{
			if ( gObjGetPkTime(lpObj, hour, min) == TRUE )
			{
				char szTemp[100];

				wsprintf(szTemp, lMsg.Get(MSGGET(4, 79)), hour, min);

				ChatTargetSend(lpNpc, szTemp, lpObj->m_Index);

				lpNpc->TargetNumber = lpObj->m_Index;

				/*if ( gPkLimitFree == FALSE )
				{
					return TRUE;
				}*/
			}
		}
		else if ( gPkLimitFree == FALSE )
		{
			int numbertext = rand() % 3;

			switch ( numbertext )
			{
				case 0:
					ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 98)), lpObj->m_Index);
					break;

				case 1:
					ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 99)), lpObj->m_Index);
					break;

				case 2:
					ChatTargetSend(lpNpc, lMsg.Get(MSGGET(4, 100)), lpObj->m_Index);
					break;
			}

			lpNpc->TargetNumber = 0;	// Apply Deathway Fix, change 0 to -1;
			return TRUE;
		}
	}

	return FALSE;
}
开发者ID:constantinbogdan,项目名称:node3d,代码行数:59,代码来源:NpcTalk.cpp


示例9: LogAdd

void DBSockMng::Connect()
{
	
	if (this->wsCDBS[0].GetSocket()  == INVALID_SOCKET )
	{
		int State;
		this->wsCDBS[0].CreateSocket(ghWnd);
		this->wsCDBS[0].SetProtocolCore(DataServerProtocolCore);
		State=this->wsCDBS[0].Connect(DataServerIP, DataServerPort, WM_GM_DATA1_CLIENT_MSG_PROC);
		if (State == 0)
		{
			LogAdd(lMsg.Get(MSGGET(1, 147)), DataServerIP, DataServerPort);
			this->wsCDBS[0].Close();
		}
		else
		{
			LogAdd(lMsg.Get(MSGGET(1, 146)), DataServerIP, DataServerPort);	
			this->m_ActiveServer=DS_0;
			DataServerLogin(DS_0);
		}
	}
	
	if (this->wsCDBS[1].GetSocket() == INVALID_SOCKET)	
	{
		int State;
		this->wsCDBS[1].CreateSocket(ghWnd);
		this->wsCDBS[1].SetProtocolCore(DataServerProtocolCore);
		State=this->wsCDBS[1].Connect(DataServerIP2, DataServerPort2, WM_GM_DATA2_CLIENT_MSG_PROC);// Two ports more than the used1
		if (State==0)
		{
			LogAdd(lMsg.Get(MSGGET(1, 147)), DataServerIP2, DataServerPort2);
			this->wsCDBS[1].Close();
		}
		else
		{
			LogAdd(lMsg.Get(MSGGET(1, 146)), DataServerIP2, DataServerPort2);
			if (this->m_ActiveServer==-1)
			{
				this->m_ActiveServer=DS_1;
			}
			DataServerLogin(DS_1);	// Second DataServer
		}
	}
	
	if ( wsExDbCli.GetSocket()  == INVALID_SOCKET)
	{
		//LogAddC(2, "ExDB Server Check..");
		wsExDbCli.CreateSocket(ghWnd);
		ExDataServerConnect(ExDBServerIP, WM_GM_EXDATA_CLIENT_MSG_PROC);
	}
	else
	{
		if ( wsExDbCli.GetConnect() == 0 )
		{
			//LogAddC(2, "ExDB Server Check..");
			ExDataServerConnect(ExDBServerIP, WM_GM_EXDATA_CLIENT_MSG_PROC);
		}
	}
}
开发者ID:stimpy76,项目名称:zTeam-Source-Season8,代码行数:59,代码来源:DBSockMng.cpp


示例10: LogAddC

void CCrywolf::SetState_END()
{
	this->m_dwCrywolfStartProcTick = 0;
	this->m_bChangeAI = FALSE;

	LogAddC(4, "[ Crywolf ] State (%d) -> END", this->m_iCrywolfState);

	if ( this->m_bTurnUpBoss != FALSE && CHECK_LIMIT(this->m_iBossIndex, OBJ_MAXMONSTER) )
	{
		if ( gObj[this->m_iBossIndex].Live != FALSE )
		{
			UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(12, 233)));
			this->SetOccupationState(1);
		}
	}

	this->m_bTurnUpBoss = FALSE;
	this->SetCrywolfBossIndex(-1);

	if ( this->GetOccupationState() == 1 )
	{
		UTIL.SendMapServerGroupMsg(lMsg.Get(MSGGET(12, 234)));
		this->SetOccupationState(1);

		LogAddTD("[ Crywolf ][MVP] FAIL.......!!");
	}
	else
	{
		UTIL.SendMapServerGroupMsg(lMsg.Get(MSGGET(12, 235)));
		this->SetOccupationState(0);

		LogAddTD("[ Crywolf ][MVP] SUCCESS.......!!");
	}

	this->SetCrywolfState(CRYWOLF_STATE_END);
	this->SetCrywolfStateAppliedTime(CRYWOLF_STATE_END);
	this->NotifyCrywolfCurrentState();
	this->ChangeAI(0);
	
	for ( int iAltar = 205 ; iAltar <= 209 ; iAltar++)
	{
		int iUserIndex = g_CrywolfNPC_Altar.GetAltarUserIndex(iAltar);

		if ( iUserIndex != -1 )
		{
			this->CalcGettingScore(iUserIndex, -1, 6);

			if ( this->GetOccupationState() != 1 )
			{
				this->MakeRewardForAltarElf(iUserIndex);
			}
		}
	}

	g_CrywolfNPC_Altar.ResetAllAltar();
	this->NotifyCrywolfPersonalRank();
}
开发者ID:Natzugen,项目名称:IGCN---Season-5,代码行数:57,代码来源:Crywolf.cpp


示例11: LogAddTD

void CCrywolf::ProcState_START()
{
	if ( g_CrywolfNPC_Altar.GetContractedAltarCount() == 0 )
	{
		UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(12, 240)));

		this->SetOccupationState(1);
		this->SetState(CRYWOLF_STATE_END);

		return;
	}

	this->NotifyCrywolfStatueAndAltarInfo();
	this->NotifyCrywolfBossMonsterInfo();
	this->NotifyCrywolfStateLeftTime();

	// VERIFICAR
	if ( (int)(GetTickCount() - this->m_dwCrywolfStartProcTick) > (this->m_iBossTurnUpTime * 1000) &&
		 !this->m_bTurnUpBoss )
	{
		this->m_bTurnUpBoss = TRUE;
		
		UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(12, 241)));

		this->TurnUpBoss();
		
		LogAddTD("[ Crywolf ][MVP] Barlgars TurnUp !!!");
	}

	// VERIFICAR
	if ( (int)(GetTickCount() - this->m_dwCrywolfStartProcTick) > (this->m_iMonsterGroupChangeAITime * 1000) &&
		 !this->m_bChangeAI )
	{
		this->m_bChangeAI = TRUE;
		
		UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(12, 242)));

		this->ChangeAI(2);
		
		LogAddTD("[ Crywolf ][MVP] Start Monster Rush !!!");
	}

	if ( this->m_bTurnUpBoss != FALSE && CHECK_LIMIT(this->m_iBossIndex, OBJ_MAXMONSTER) != FALSE )
	{
		if ( gObj[this->m_iBossIndex].Live == FALSE )
		{
			UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(12, 243)));	

			this->SetOccupationState(0);
			this->SetState(CRYWOLF_STATE_END);
		}
	}
}
开发者ID:Natzugen,项目名称:IGCN---Season-5,代码行数:53,代码来源:Crywolf.cpp


示例12: gObjIsConnected

void CCrywolf::CrywolfMonsterDieProc(int iMonIndex, int iKillerIndex)
{
	LPOBJ lpMonObj = &gObj[iMonIndex];
	LPOBJ lpKillerObj = &gObj[iKillerIndex];
	BOOL bExistKiller = gObjIsConnected(iKillerIndex);

	if ( g_Crywolf.GetCrywolfState() == CRYWOLF_STATE_START )
	{
		if ( lpMonObj->MapNumber == MAP_INDEX_CRYWOLF_FIRSTZONE )
		{
			if ( lpMonObj->m_iCurrentAI != 0 )
			{
				if ( lpMonObj->Class == 349 )
				{
					if ( bExistKiller )
					{
						UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(12, 247)), lpKillerObj->Name);

						LogAddTD("[ Crywolf ][MVP] [Balgars Dead] by [%s][%s]",
							lpKillerObj->AccountID, lpKillerObj->Name);
					}
					else
					{
						UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(12, 248)));

						LogAddTD("[ Crywolf ][MVP] [Balgars Dead] by Unknown User");
					}
				}

				if ( lpMonObj->Class == 340 )
				{
					if ( bExistKiller )
					{
						UTIL.SendCrywolfUserAnyMsg(2, lMsg.Get(MSGGET(12, 249)),
							lpMonObj->m_iGroupNumber, lpKillerObj->Name);

						LogAddTD("[ Crywolf ][MVP] [DarkElf Dead] by [%s][%s]",
							lpKillerObj->AccountID, lpKillerObj->Name);
					}
				}
		
				int iScore = this->CalcGettingScore(iKillerIndex, iMonIndex, 100);


				if ( iScore != -1 )
				{
					MsgOutput(iKillerIndex, lMsg.Get(MSGGET(12, 250)), iScore);
				}
			}
		}
	}
}
开发者ID:Natzugen,项目名称:IGCN---Season-5,代码行数:52,代码来源:Crywolf.cpp


示例13: wsprintf

void cVipSystem::State(LPOBJ lpObj)
{
	char Tmp[512]={0};
	if (lpObj->VipDays >= 1)
	{
		wsprintf(Tmp,lMsg.Get(MSGGET(14, 57)),lpObj->VipDays,lpObj->VipMoney);
		GCServerMsgStringSend(Tmp,lpObj->m_Index, 0x00);
	} else {
		if (lpObj->VipMoney > 0)
		{
			wsprintf(Tmp,lMsg.Get(MSGGET(14, 153)),lpObj->VipMoney);
			GCServerMsgStringSend(Tmp,lpObj->m_Index, 0x00);
		}
	}
}
开发者ID:ADMTec,项目名称:GameServer,代码行数:15,代码来源:VIPSystem.cpp


示例14: cSummerEvent__InsideTrigger

void cSummerEvent__InsideTrigger(void * lpParam)
{
    SummerEvent.Start = 1;

    LogAddTD("[SummerEvent] Event Start");
    AllSendServerMsg(lMsg.Get(MSGGET(14, 135)));
    SummerEvent.SetMonsters();
    Sleep(SummerEvent.Minutes * 60000);
    SummerEvent.ClearMonsters();
    LogAddTD("[SummerEvent] Event End");
    AllSendServerMsg(lMsg.Get(MSGGET(14, 136)));

    SummerEvent.Start = 0;
    _endthread();
}
开发者ID:ADMTec,项目名称:GameServer,代码行数:15,代码来源:SummerEvent.cpp


示例15: MsgOutput

void CCrywolfAltar::ResetAltarUserIndex(int iAltarObjIndex, int iClass)
{
    int iAltarNumber = this->GetAlatarNumber(iClass);
    CCrywolfAltarInfo * AltarInfo = &this->m_AltarInfo[iAltarNumber];

    if ( gObjIsConnected(AltarInfo->m_iUserIndex) != FALSE )
    {
        MsgOutput(AltarInfo->m_iUserIndex, lMsg.Get(MSGGET(13, 4)), iAltarNumber);
        LogAddTD("[ Crywolf ][Altar Op.] [%s][%s] Remove contract Altar[%d]", gObj[AltarInfo->m_iUserIndex].AccountID, gObj[AltarInfo->m_iUserIndex].Name, iAltarNumber);
    }

    if ( AltarInfo->m_iContractCount >= MAX_ALTAR_CONTRACTS )
    {
        AltarInfo->SetAltarState(3);
        gObjAddBuffEffect(&gObj[iAltarObjIndex], AT_CW_ALTAR_INACTIVE, 0, 0, 0, 0, -10);
    }
    else
    {
        gObjAddBuffEffect(&gObj[iAltarObjIndex], AT_CW_ALTAR_ACTIVE, 0, 0, 0, 0, -10);
        AltarInfo->SetAltarState(0);
    }

    AltarInfo->m_iUserIndex = -1;
    AltarInfo->m_dwAppliedContractTime = 0;
    AltarInfo->m_dwValidContractTime = 0;
    AltarInfo->m_dwLastValidContractTime = GetTickCount();
}
开发者ID:Natzugen,项目名称:muOnline-season6,代码行数:27,代码来源:CrywolfAltar.cpp


示例16: PHeadSetB

void cVipSystem::BuyItem(LPOBJ lpObj, int IDNumber)
{
	if(IDNumber >= 0 && IDNumber <= (this->ItemsCount-1))
	{
		BOOL IfBuy = FALSE;	
		PMSG_BUYRESULT pResult;
		PHeadSetB((LPBYTE)&pResult, 0x32, sizeof(pResult));

		if(this->Shop[IDNumber].Cost < lpObj->VipMoney)
		{
			pResult.Result = gObjShopBuyInventoryInsertItem(lpObj->m_Index,this->m_item[IDNumber]);
				
			if ( pResult.Result != 0xFF )
			{
				lpObj->AccountExtraInfoModified = 1;

				ItemByteConvert((LPBYTE)&pResult.ItemInfo, this->m_item[IDNumber]);
				DataSend(lpObj->m_Index, (LPBYTE)&pResult, pResult.h.size);
				lpObj->VipMoney -= this->Shop[IDNumber].Cost;
				IfBuy = TRUE;
			}else
			{				
				GCServerMsgStringSend(lMsg.Get(MSGGET(14, 58)),lpObj->m_Index, 0x01);
			}
		}
		//Log
		if(IfBuy == TRUE)
		{
			LogAddTD("[VIPShop] BuyItem [%s][%s] Item {%d %d} Cost: %d",lpObj->AccountID,lpObj->Name,this->Shop[IDNumber].Type,this->Shop[IDNumber].Index,this->Shop[IDNumber].Cost);
		} else 
		{
			LogAddTD("[VIPShop] Attempt to BuyItem [%s][%s] Item {%d %d} Cost: %d",lpObj->AccountID,lpObj->Name,this->Shop[IDNumber].Type,this->Shop[IDNumber].Index,this->Shop[IDNumber].Cost);
		}
	}
}
开发者ID:ADMTec,项目名称:GameServer,代码行数:35,代码来源:VIPSystem.cpp


示例17: fopen

void CheatGuard::ReadXOR(char * File)
{
	int Token;
	this->Init();
	// ----
	SMDFile		= fopen(File, "r");
	int Count	= 0;
	// ----
	if( SMDFile == 0 )
	{
		MsgBox(lMsg.Get(MSGGET(0, 112)), File);
		return;
	}
	// ----
	while(true) 
	{
		Token = GetToken();
		// ----
		if( Token == END )
		{
			break;
		}
		else
		{
			this->XOR[Count] = TokenNumber;
			Count++;
		}
	}
	// ----
	LogAddTD("[CheatGuard] [%d] Keys loaded", Count);
	fclose(SMDFile);
}
开发者ID:EderRS,项目名称:muOnline-season6,代码行数:32,代码来源:CheatGuard.cpp


示例18: MsgOutput

void CCrywolfAltar::ResetAltarUserIndex(int iAltarObjIndex, int iClass)
{
	int iAltarNumber = this->GetAlatarNumber(iClass);
	CCrywolfAltarInfo * AltarInfo = &this->m_AltarInfo[iAltarNumber];

	if ( gObjIsConnected(AltarInfo->m_iUserIndex) != FALSE )
	{
		MsgOutput(AltarInfo->m_iUserIndex, lMsg.Get(MSGGET(13, 4)), iAltarNumber);
		CLog.LogAdd("[ Crywolf ][Altar Op.] [%s][%s] Remove contract Altar[%d]",
		gObj[AltarInfo->m_iUserIndex].AccountID, gObj[AltarInfo->m_iUserIndex].Name,
		iAltarNumber);
	}

	if ( AltarInfo->m_iContractCount >= MAX_ALTAR_CONTRACTS )
	{
		AltarInfo->SetAltarState(3);

		memset(gObj[iAltarObjIndex].m_ViewSkillState, 0, sizeof(gObj[iAltarObjIndex].m_ViewSkillState));
		gObj[iAltarObjIndex].m_ViewSkillState[eVS_ALTAR_MAX_CONTRACT] = 1;
		GCStateInfoSend(&gObj[iAltarObjIndex], 1, eVS_ALTAR_MAX_CONTRACT);
	}
	else
	{
		memset(gObj[iAltarObjIndex].m_ViewSkillState, 0, sizeof(gObj[iAltarObjIndex].m_ViewSkillState));
		gObj[iAltarObjIndex].m_ViewSkillState[eVS_POTION_SOUL] = 1;
		GCStateInfoSend(&gObj[iAltarObjIndex], 1, eVS_POTION_SOUL);
		AltarInfo->SetAltarState(0);
	}

	AltarInfo->m_iUserIndex = -1;
	AltarInfo->m_dwAppliedContractTime = 0;
	AltarInfo->m_dwValidContractTime = 0;
	AltarInfo->m_dwLastValidContractTime = GetTickCount();
}
开发者ID:ElBedeawi,项目名称:mu-server-ex,代码行数:34,代码来源:CrywolfAltar.cpp


示例19: LogAdd

WORD CMagicDamage::GetNormalBrandOfSkill(int iSkill)
{
	if ( iSkill < 0 || iSkill > MAX_SKILL-1 )
	{
		LogAdd(lMsg.Get(MSGGET(1, 201)), __FILE__, __LINE__);
		return -1;
	}

	int Cnt = 0;
	WORD nBrandOfSkill;
	WORD iBrandOfSkill = iSkill;
	
	while( nBrandOfSkill = this->GetBrandOfSkill(iBrandOfSkill) , g_MasterSkillSystem.CheckMasterLevelSkill(nBrandOfSkill) )
	{
		iBrandOfSkill = nBrandOfSkill;
		Cnt++;

		if( Cnt > 3 )
		{
			LogAdd("[GetNormalBrandOfSkill] fail!!! - %d",iSkill);
			return iSkill;
		}
	}

return nBrandOfSkill;
}
开发者ID:AkiraJue,项目名称:OpenMuS9,代码行数:26,代码来源:MagicDamage.cpp


示例20: NpcCastleGuard

BOOL NpcCastleGuard(LPOBJ lpNpc, LPOBJ lpObj) //GS-CS Decompiled 100%
{
	if ( (lpObj->m_IfState.use ) > 0 )
	{
		return TRUE;
	}

#if(GS_CASTLE==1)
	if(g_CastleSiege.GetCastleState() == 7)
	{
		ChatTargetSend(lpNpc,(lMsg.Get(MSGGET(6, 87))), lpObj->m_Index);
		return TRUE;
	}
#endif

	PMSG_TALKRESULT pMsg;

	pMsg.h.c = 0xC3;
	pMsg.h.headcode = 0x30;
	pMsg.h.size = sizeof(pMsg);
	pMsg.result = 0x0D;

	DataSend(lpObj->m_Index, (LPBYTE)&pMsg, pMsg.h.size);

	lpObj->m_IfState.use = 1;
	lpObj->m_IfState.type = 12;


	return TRUE;
}
开发者ID:constantinbogdan,项目名称:node3d,代码行数:30,代码来源:NpcTalk.cpp



注:本文中的MSGGET函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ MSGPACK_UNUSED函数代码示例发布时间:2022-05-30
下一篇:
C++ MSGBUF函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap