DirectPlay MessageHandler
i''m having trouble manipulating values outside of the DirectPlay message handler. For example...
HRESULT WINAPI DirectPlayMessageHandler( PVOID pvUserContext, DWORD dwMessageId,
PVOID pMsgBuffer)
{
switch( dwMessageId )
{
case DPN_MSGID_RECEIVE:
{
PDPNMSG_RECEIVE pMsg;
TCHAR strBuffer[256];
pMsg = (PDPNMSG_RECEIVE) pMsgBuffer;
DXUtil_ConvertWideStringToGenericCch( strBuffer, (WCHAR*) pMsg->pReceiveData, 256 );
DS(strBuffer);
NetworkMoveMade = true;
break;
}
}
return S_OK;
}
throws up the error:
ERROR: Chess3D v0.1 error LNK2005: "bool NetworkMoveMade" (?NetworkMoveMade@@3_NA) already defined in DirectPlay.obj
can anyone help?
Scotty.
For clarification, this is more of a C/C++ question than it is a DirectX question. If you ever need some general help, try searching the General Programming forum.
Are there any other extern/global variables called NetworkMoveMade? Also, are you defining NetworkModeMade multiple times in the same source file, through includes or something?
Dustin Franklin
Mircrosoft DirectX MVP
Are there any other extern/global variables called NetworkMoveMade? Also, are you defining NetworkModeMade multiple times in the same source file, through includes or something?
Dustin Franklin
Mircrosoft DirectX MVP
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement