char* szWords[] = { "caralho", "porra" };
if (IsGoldGrade(pObj)) //Ignore, its ok. //Crashing after i added the
{
for (int x = 0; x < sizeof(szWords); x++) {
if (strstr((strlwr((char*)szWords[x])), szChat)) {
char szBuffer[256];
sprintf(szBuffer, "You can't type %s", szWords[x]);
Announce(pObj, szBuffer);
memset(szBuffer, 0, 256);
return;
}
}
}
Idk,但我不能用它作为“代码”在stackoverflow上。为什么我的应用程序崩溃?我的代码有什么问题?
引擎收录:http://pastebin.com/u8yit8Rw
PS:因为使用IM的Visual Studio 2003
至少告诉我们是什么错误... – csmckelvey
你好。我在我的游戏服务器上使用。错误是,当这个函数执行时,我的游戏崩溃了。 – Lcs
Pastebin上的文件包含可能被堆栈溢出禁止的单词。删除这些单词,你应该能够将整个代码粘贴到你的问题中。 –