String size..
#1

Hello guys,
This is the third thread about my ban system.. x)
So, everything looks allright, but when the banned player connect.

He should get a dialog where the informations of ban are marked (His pseudo, name of admin, Reason of ban)
But, they mark just his pseudo, the name of admin and reason stay blank.

PHP код:
if(Banning[i] == 1)
        {
            new 
string[152], pname[24];
            
GetPlayerName(i,pname,sizeof(pname));
            
SetPlayerInterior(i,6);
            
SetPlayerPos(i,279.2436,-162.7030,999.5938);
            
SetPlayerFacingAngle(i,180.2424);
            
format(stringsizeof(string), "{FFFFFF}Vous avez йtй banni.\n\n{FFFFFF}Pseudo: {FFFF00}%s\n{FFFFFF}L'Administrateur: {FFFF00}%s\n{FFFFFF}Raison: {FFFF00}%s",pname,banned[i][adminbanning],banned[i][reason_banned]);
            
ShowPlayerDialog(i678DIALOG_STYLE_MSGBOX"Banni:"string"Quitter""");
            
dUserSetINT(PlayerName(i)).("Nameban",1);
            
Kick(i);
        } 
I think it's the string's array whom's not correct..
Help. ^^
Reply
#2

Come on..
Reply
#3

https://sampwiki.blast.hk/wiki/Kick
Reply
#4

Quote:
Originally Posted by Jefff
Посмотреть сообщение
Why would you post this? Did you read what I have marked above?
Reply
#5

Try [I]printf("DEBUG admin %s reason %s", banned[i][adminbanning],banned[reason_banned]);
And see what it prints, maybe the name and reason aren't even stored properly in those vars?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)