SA-MP Forums Archive
When player join he is admin rep+ - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: When player join he is admin rep+ (/showthread.php?tid=588317)



When player join he is admin rep+ - Mijata - 07.09.2015

When player join he is admin like me left server and me come again with dirffrent name im admin again??

what to send?


Re: When player join he is admin rep+ - Sew_Sumi - 07.09.2015

Either your script is bugged, or you have a leaked password.

You need to post more info, and some logs maybe. When did it start happening, and who wrote your script...


Re: When player join he is admin rep+ - ]Rafaellos[ - 07.09.2015

Quote:
Originally Posted by Sew_Sumi
Посмотреть сообщение
Either your script is bugged, or you have a leaked password.

You need to post more info, and some logs maybe. When did it start happening, and who wrote your script...
Are you kidding right?

@OP: When the player joins check in your script if you set to 0 all player data values. If you can't find then do it on your own.


Re: When player join he is admin rep+ - Mijata - 07.09.2015

Quote:
Originally Posted by ]Rafaellos[
Посмотреть сообщение
Are you kidding right?

@OP: When the player joins check in your script if you set to 0 all player data values. If you can't find then do it on your own.
what now?


Re: When player join he is admin rep+ - ]Rafaellos[ - 07.09.2015

What do you mean what now? Did you check if you reset player data variables?


Re: When player join he is admin rep+ - SpikY_ - 07.09.2015

show us the codes first.


Re: When player join he is admin rep+ - Mijata - 07.09.2015

Onplayerconnect

Quote:

public OnPlayerConnect(playerid)
{
SetPlayerMapIcon(playerid, 1, 2498.4844,-1643.2212,13.7826, 62, 0, MAPICON_LOCAL);//grove
SetPlayerMapIcon(playerid, 2, 2168.0500,-1672.7062,15.0821, 59, 0, MAPICON_LOCAL);//ballas
SetPlayerMapIcon(playerid, 3, 2801.4448,-1088.8105,30.7218, 60, 0, MAPICON_LOCAL);//vagos
SetPlayerMapIcon(playerid, 4, 1755.6479,-1911.7106,13.5680, 58, 0, MAPICON_LOCAL);//asteca
SetPlayerMapIcon(playerid, 5, 2787.7656,-2440.0081,13.6337, 20, 0, MAPICON_LOCAL);//russian
SetPlayerMapIcon(playerid, 6, 1552.8384,-1675.1357,16.1953, 30, 0, MAPICON_LOCAL);//cops

TextDrawShowForPlayer(playerid,Text:TextdrawUST);
TextDrawShowForPlayer(playerid,Text:TextdrawALT);

new string[64], pName[MAX_PLAYER_NAME];
GetPlayerName(playerid,pName,MAX_PLAYER_NAME);
format(string,sizeof string,"%s Has Joined The Server!",pName);
SendClientMessageToAll(Red,string);




SetWorldTime(0);

SendClientMessage(playerid,bojaz,"Welcome to server enjoy!! If u want to see commands type /help.");



if(fexist(UserPath(playerid)))
{
INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_PASSWORD,"Account Login","Type your password below to login.","Login","Quit");
PlayAudioStreamForPlayer(playerid,"http://s3.argim.net/files/r/gta_san_andreas_theme_song_wmm.mp3");
}
else
{
new string[125];
format(string,sizeof(string),"Hello %s.\nYou're not registered please register.",sendername(playerid));
ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_PASSWORD,"Account Register",string,"Register","Later");
PlayAudioStreamForPlayer(playerid,"http://s3.argim.net/files/r/gta_san_andreas_theme_song_wmm.mp3");

}
HitObjTime[playerid] = 0;
RedScreenTime[playerid] = 0;
AdvTime[playerid] = 0;
return 1;
}

onplayerdisconect

Quote:

public OnPlayerDisconnect(playerid, reason)
{
new ime[MAX_PLAYER_NAME], izlazporuka[45];
GetPlayerName(playerid, ime, sizeof(ime));

format(izlazporuka, sizeof(izlazporuka), "%s Has Left The Server", ime);
SendClientMessageToAll(Red, izlazporuka);

new INI:File = INI_Open(UserPath(playerid));
INI_SetTag(File,"data");
INI_WriteInt(File,"Cash",GetPlayerMoney(playerid)) ;
INI_WriteInt(File,"Admin",PlayerInfo[playerid][pAdmin]);
INI_WriteInt(File,"Banned",PlayerInfo[playerid][pBanned]);
INI_WriteInt(File,"Kills",PlayerInfo[playerid][pKills]);
INI_WriteInt(File,"Deaths",PlayerInfo[playerid][pDeaths]);
INI_WriteInt(File,"Score",GetPlayerScore(playerid) );
INI_Close(File);
return 1;
}




Re: When player join he is admin rep+ - SpikY_ - 07.09.2015

show me DIALOG_LOGIN codes


Re: When player join he is admin rep+ - SpikY_ - 07.09.2015

Quote:
Originally Posted by ]Rafaellos[
Посмотреть сообщение
When the player joins check in your script if you set to 0 all player data values. If you can't find then do it on your own.
check for it now


Re: When player join he is admin rep+ - Sew_Sumi - 07.09.2015

Quote:
Originally Posted by ]Rafaellos[
Посмотреть сообщение
Are you kidding right?
Actually, I'm not kidding...


To have a scripting help thread, simply stating that the player gets admin with no info other than that, then what I said is pretty bang on...




After all, who wrote the script, and why is it that they aren't able to provide ANY INFORMATION other than the one line "Player joins my server, and has admin"


Literally a "What do?" message, where really, that's not what this section is for...


This section is for people who have some idea of what they are doing, not just a simple one line, where no information is given.



Now if you could elaborate please on your one line "Are you kidding"... and elaborate on what you think is wrong with what I said.