Time Before message on lobby
Title Says EveryThing :D
Go To ZGameClient.cpp Line: 582
Search for : void ZGameClient::OnChannelChat
Code:
void ZGameClient::OnChannelChat(const MUID& uidChannel, char* szName, char* szChat,int nGrade)
{
if (GetChannelUID() != uidChannel) return;
if ((szChat[0]==0) || (szName[0] == 0)) return;
// MUID uid = GetObject(szName);
// MMatchObjectCache* pObjCache = FindObjCache(uid);
MCOLOR _color = MCOLOR(0,0,0);
MMatchUserGradeID gid = (MMatchUserGradeID) nGrade;
// gid = MMUG_DEVELOPER;
char sp_name[256];
bool bSpUser = GetUserGradeIDColor(gid,_color,sp_name);
char szText[512];
if(bSpUser) // Ư¼öÀ¯Àú
{
wsprintf(szText, "%s : %s", sp_name , szChat);
ZChatOutput(szText, ZChat::CMT_NORMAL, ZChat::CL_LOBBY,_color);
}
else if ( !ZGetGameClient()->GetRejectNormalChat() || // ÀÏ¹Ý À¯Àú
(strcmp( szName, ZGetMyInfo()->GetCharName()) == 0))
{
wsprintf(szText, "^4%s^9 : %s", szName, szChat);
ZChatOutput(szText, ZChat::CMT_NORMAL, ZChat::CL_LOBBY);
}
}
Replace With
Code:
void ZGameClient::OnChannelChat(const MUID& uidChannel, char* szName, char* szChat,int nGrade)
{
if (GetChannelUID() != uidChannel) return;
if ((szChat[0]==0) || (szName[0] == 0)) return;
if (ZGetGameClient()->GetRejectNormalChat()) return;
// MUID uid = GetObject(szName);
// MMatchObjectCache* pObjCache = FindObjCache(uid);
MCOLOR _color = MCOLOR(0,0,0);
MMatchUserGradeID gid = (MMatchUserGradeID) nGrade;
char szText[512];
char szTimeStamp[512];
time_t currentTime;
struct tm *timeinfo;
currentTime= time(NULL);
timeinfo= localtime(¤tTime);
strftime (szTimeStamp, 30, "[%H:%M]" , timeinfo);
char sp_name[256];
bool bSpUser = GetUserGradeIDColor(gid,_color,sp_name);
switch(nGrade)
{
case 255 :
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 254:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 252:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 10:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 2:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 0:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
}
ZChatOutput(szText, ZChat::CMT_NORMAL, ZChat::CL_LOBBY,_color);
}
u can add more Grades to use time before message from change Case ( Number of Grade ) and add this line under it: wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
http://www.mediafire.com/convkey/503....jpg?size_id=6
Re: Time Before message on lobby
Quote:
Originally Posted by
Fouad Uwk
Title Says EveryThing :D
Go To ZGameClient.cpp Line: 582
Search for : void ZGameClient::OnChannelChat
Code:
void ZGameClient::OnChannelChat(const MUID& uidChannel, char* szName, char* szChat,int nGrade)
{
if (GetChannelUID() != uidChannel) return;
if ((szChat[0]==0) || (szName[0] == 0)) return;
// MUID uid = GetObject(szName);
// MMatchObjectCache* pObjCache = FindObjCache(uid);
MCOLOR _color = MCOLOR(0,0,0);
MMatchUserGradeID gid = (MMatchUserGradeID) nGrade;
// gid = MMUG_DEVELOPER;
char sp_name[256];
bool bSpUser = GetUserGradeIDColor(gid,_color,sp_name);
char szText[512];
if(bSpUser) // Ư¼öÀ¯Àú
{
wsprintf(szText, "%s : %s", sp_name , szChat);
ZChatOutput(szText, ZChat::CMT_NORMAL, ZChat::CL_LOBBY,_color);
}
else if ( !ZGetGameClient()->GetRejectNormalChat() || // ÀÏ¹Ý À¯Àú
(strcmp( szName, ZGetMyInfo()->GetCharName()) == 0))
{
wsprintf(szText, "^4%s^9 : %s", szName, szChat);
ZChatOutput(szText, ZChat::CMT_NORMAL, ZChat::CL_LOBBY);
}
}
Replace With
Code:
void ZGameClient::OnChannelChat(const MUID& uidChannel, char* szName, char* szChat,int nGrade)
{
if (GetChannelUID() != uidChannel) return;
if ((szChat[0]==0) || (szName[0] == 0)) return;
if (ZGetGameClient()->GetRejectNormalChat()) return;
// MUID uid = GetObject(szName);
// MMatchObjectCache* pObjCache = FindObjCache(uid);
MCOLOR _color = MCOLOR(0,0,0);
MMatchUserGradeID gid = (MMatchUserGradeID) nGrade;
char szText[512];
char szTimeStamp[512];
time_t currentTime;
struct tm *timeinfo;
currentTime= time(NULL);
timeinfo= localtime(¤tTime);
strftime (szTimeStamp, 30, "[%H:%M]" , timeinfo);
char sp_name[256];
bool bSpUser = GetUserGradeIDColor(gid,_color,sp_name);
switch(nGrade)
{
case 255 :
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 254:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 252:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 10:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 2:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 0:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
}
ZChatOutput(szText, ZChat::CMT_NORMAL, ZChat::CL_LOBBY,_color);
}
u can add more Grades to use time before message from change Case ( Number of Grade ) and add this line under it: wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
http://www.mediafire.com/convkey/503....jpg?size_id=6
Thank you fouad, ill use it!
Re: Time Before message on lobby
I'm sure this is the one I gave to someone but originally released by George. But, I seem to have lost my old source so didn't have it, so thanks a bunch!
Re: Time Before message on lobby
If we could have something like:
2 seconds ago
3 hours ago
That will be awesome.
Re: Time Before message on lobby
http://prntscr.com/44i6gh
don't release bugged things or not fully things.
Re: Time Before message on lobby
Quote:
Originally Posted by
mgdmgd
why ?
It's work really good for me.Work 100%
Re: Time Before message on lobby
Re: Time Before message on lobby
Quote:
Originally Posted by
mgdmgd
These codes work perfectly, don't post shit if you cannot add it properly.
Re: Time Before message on lobby
Quote:
Originally Posted by
mgdmgd
if u can't add codes well its not my problem so just dont say its buggyy and dont work cuz it works 100%
Re: Time Before message on lobby
more detailed like x minutes ago would be cool.
Re: Time Before message on lobby
Quote:
Originally Posted by
GermanGuy
more detailed like x minutes ago would be cool.
So that after 1 minute it still says x minutes ago?
Or do you want to alter every line in the chat after each minute so that they accurately represent data?
http://cdn.memegenerator.net/instanc...x/20119689.jpg
I also like how you're calling it "more detailed". Do you find exact timing less detailed? Are clocks less detailed for you?
GermanGuy: When's lunch, mom?
Mom: In 2 hours, 13 minutes, 12 seconds, son.
GermanGuy: Wow bitch, just say 2 pm.
Mom: But son, 2 hours, 13 minutes, 12 seconds is more detailed!
Re: Time Before message on lobby
Quote:
Originally Posted by
Arcelor
So that after 1 minute it still says x minutes ago?
Or do you want to alter every line in the chat after each minute so that they accurately represent data?
http://cdn.memegenerator.net/instanc...x/20119689.jpg
I also like how you're calling it "more detailed". Do you find exact timing less detailed? Are clocks less detailed for you?
GermanGuy: When's lunch, mom?
Mom: In 2 hours, 13 minutes, 12 seconds, son.
GermanGuy: Wow bitch, just say 2 pm.
Mom: But son, 2 hours, 13 minutes, 12 seconds is more detailed!
That made my day bro, thank you <3 hahaha XD
and @mgdmgd , you probably did something wrong!! if NOT..
then just fix your errors, all errors you are encountering are bunch of "identifier not found" or "undeclared".. which are the most easy stuff to fix ! -.-
for example: "szName identifier is not found", does this ring a bell ?! O.O
"lemme go check source code, oh in function variable inputs i missed szName there :/"
since it's not found there :o
Re: Time Before message on lobby
Quote:
Originally Posted by
Arcelor
So that after 1 minute it still says x minutes ago?
Or do you want to alter every line in the chat after each minute so that they accurately represent data?
http://cdn.memegenerator.net/instanc...x/20119689.jpg
I also like how you're calling it "more detailed". Do you find exact timing less detailed? Are clocks less detailed for you?
GermanGuy: When's lunch, mom?
Mom: In 2 hours, 13 minutes, 12 seconds, son.
GermanGuy: Wow bitch, just say 2 pm.
Mom: But son, 2 hours, 13 minutes, 12 seconds is more detailed!
There you go
Quote:
Originally Posted by
NubPro
If we could have something like:
2 seconds ago
3 hours ago
That will be awesome.
PS: it's called detailed in vbulletin.
Re: Time Before message on lobby
Re: Time Before message on lobby
PHP Code:
case 255 :
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 254:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 252:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 10:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 2:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
case 0:
wsprintf(szText, "%s %s : %s", szTimeStamp, szName , szChat);
break;
What the fuck?