Hide -
ctopha - 06.06.2016
Hello everybody, now i've created saved hide system
And
Here is the code
Код:
stock OnUserLogin(playerid)
{
format(word, sizeof(word), "*** "LB2_E"Welcome back {%06x}%s, "LB2_E"you have been automatically logged in!", pColor[playerid], pName[playerid]);
SendClientMessage(playerid, COLOR_RED, word);
if(pTotalHours[playerid] == 0)
format(word, sizeof(word), "*** "LB2_E"You have been online for "YELLOW_E"%d minutes, %d seconds.", pTotalMinutes[playerid], pTotalSeconds[playerid]);
else
format(word, sizeof(word), "*** "LB2_E"You have been online for "YELLOW_E"%d hours, %d minutes, %d seconds.", pTotalHours[playerid], pTotalMinutes[playerid], pTotalSeconds[playerid]);
SendClientMessage(playerid, COLOR_RED, word);
// MOTD
//SendClientMessage(playerid, COLOR_GREEN, "MOTD: "LB_E"Check out our new race records! Major upgrade done to the house system!");
format(tmpe, sizeof(tmpe), "02[Join] 03%s(%d) has joined the server. 11(Logged in as a %s)", pName[playerid], playerid, GetPlayerAdminLevelName(playerid));
IRC_GroupSay(ircGroup, IRC_CHANNEL, tmpe);
format(tmpe, sizeof(tmpe), "02[Join] 03%s(%d) has joined the server. 11(Logged in as a %s) 1(IP: %s)", pName[playerid], playerid, GetPlayerAdminLevelName(playerid), PlayerIP);
IRC_GroupSay(ircGroup, IRC_aCHANNEL, tmpe);
if(pAdmin[playerid] != 0 || pPremium[playerid] != 0)
{
switch(pAdmin[playerid])
{
case 0: tmpe = "Premium Member";
case 1: tmpe = "Trial Administrator";
case 2: tmpe = "Administrator";
case 3: tmpe = "Super Administrator";
case 4: tmpe = "Advanced Administrator";
case 5: tmpe = "Experienced Administrator";
case 6: tmpe = "Senior Administrator";
case 7: tmpe = "Superme Administrator";
case 8: tmpe = "Elite Administrator";
case 9: tmpe = "Professional Administrator";
case 10: tmpe = "Master Administrator";
case 11: tmpe = "Lead Administrator";
case 12: tmpe = "Head Administrator";
case 13: tmpe = "Server Manager";
case 14: tmpe = "Head Manager";
case 15: tmpe = "Server Owner";
}
format(word, sizeof(word), "["BLUE_E"UoS"WHITE_E"] "YELLOW_E"%s {%06x}%s(%i) "YELLOW_E"has been auto-logged in.", tmpe, pColor[playerid], pName[playerid], playerid);
SendClientMessageToAll(COLOR_WHITE, word);
}
format(word, sizeof(word), "~b~~h~Welcome back, ~r~~h~%s~b~~h~!~n~~b~~h~You are logged in as %s!", pName[playerid], GetPlayerAdminLevelName(playerid));
InfoTD_MSG(playerid, 5500, word);
}
I don't want this meesage will be shown when the admin will be hidden.
>
Код:
format(word, sizeof(word), "["BLUE_E"UoS"WHITE_E"] "YELLOW_E"%s {%06x}%s(%i) "YELLOW_E"has been auto-logged in.", tmpe, pColor[playerid], pName[playerid], playerid);
SendClientMessageToAll(COLOR_WHITE, word);
Here is the variable of the hide system
pInfo[playerid][hidden] == 1 (hidden)
pInfo[playerid][hidden] == 0 (unhidden)
Re: Hide -
cuzido - 06.06.2016
Just have it shown only if the hidden variable is 0:
PHP код:
if(pInfo[playerid][hidden] == 0){
format(word, sizeof(word), "["BLUE_E"UoS"WHITE_E"] "YELLOW_E"%s {%06x}%s(%i) "YELLOW_E"has been auto-logged in.", tmpe, pColor[playerid], pName[playerid], playerid);
SendClientMessageToAll(COLOR_WHITE, word);
}
Re: Hide -
ctopha - 07.06.2016
I just need another help
Код:
if(pLogged[p2] == 1)
{
format(word, sizeof(word), ""LB2_E"> Registered "WHITE_E"(Logged in)");
switch(pAdmin[p2])
{
case 0:
{
if(pPremium[p2] == 0) str3 = ""LB2_E"> Status: "WHITE_E"Regular Player";
else format(str3, sizeof(str3), ""LB2_E"> Status: "WHITE_E"Premium Member (Level :%d)", pPremium[p2]);
}
case 1: str3 = ""LB2_E"> Status: "WHITE_E"Trial Administrator";
case 2: str3 = ""LB2_E"> Status: "WHITE_E"Administrator";
case 3: str3 = ""LB2_E"> Status: "WHITE_E"Super Administrator";
case 4: str3 = ""LB2_E"> Status: "WHITE_E"Advanced Administrator";
case 5: str3 = ""LB2_E"> Status: "WHITE_E"Experienced Administrator";
case 6: str3 = ""LB2_E"> Status: "WHITE_E"Senior Administrator";
case 7: str3 = ""LB2_E"> Status: "WHITE_E"Superme Administrator";
case 8: str3 = ""LB2_E"> Status: "WHITE_E"Elite Administrator";
case 9: str3 = ""LB2_E"> Status: "WHITE_E"Professional Administrator";
case 10: str3 = ""LB2_E"> Status: "WHITE_E"Master Administrator";
case 11: str3 = ""LB2_E"> Status: "WHITE_E"Lead Administrator";
case 12: str3 = ""LB2_E"> Status: "WHITE_E"Head Administrator";
case 13: str3 = ""LB2_E"> Status: "WHITE_E"Server Manager";
case 14: str3 = ""LB2_E"> Status: "WHITE_E"Head Manager";
case 15: str3 = ""LB2_E"> Status: "WHITE_E"Server Owner";
}
I want if i was hidden it will show me as a regular player while being hided
Like Status: Regular player