SA-MP Forums Archive
[HELP] ban text - 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: [HELP] ban text (/showthread.php?tid=510451)



[HELP] ban text - Luca12 - 01.05.2014

Hello. I have two diffrent types of ban. I have offban and when player have cheat anticheat ban player. And I have command for offline check player. So my question is how can I put two types of ban and when I check player then if he has offline ban then it show me offline ban but if player has a anticheat ban then it show me that type of ban if you know what I mean? Thanks


Re: [HELP] ban text - SickAttack - 01.05.2014

The best was to do this is by saving the type of ban into the users file then load it from there.


Re: [HELP] ban text - Luca12 - 01.05.2014

I have all of that I just want put that 2 type of bans in one line for example

know I have two lines

pawn Код:
player is not banned and if player is banned here it says reason of ban -- this is offban type of ban --
player is not banned -- this is anticheat ban type of ban and if player is banned here it says reason of ban-- know those two bans I want put in one line not two lines.



Re: [HELP] ban text - Luca12 - 02.05.2014

pawn Код:
here is the first type of ban which is offban

new offplayerbanned = cache_get_field_content_int(0,"OffBanedd");
        if(offplayerbanned == 0) offbantext = "{FFFF66}Player Not banned...";
        else if(offplayerbanned == 1) offbantext = "[PlayerBanned!!!] Reason:";
        cache_get_field_content(0,"OffBanReason",OffBanString[playerid][0],mysql,128);

and here is second type of ban which is anticheat
        new aplayerbanned= cache_get_field_content_int(0,"ABanned");
        if(aplayerbanned == 0) abanstatus = "{FFFF66}Player not banned...";
        else if(aplayerbanned == 1) abantext = "[Banned Player!!!] G-Protect: Reason:";
        cache_get_field_content(0,"ABanReason",ABanString[playerid][0],mysql,128);

and here is the lines

if(offplayerbanned == 0)
        {
            SCMF(playerid,0xDB023EFF,"%s",offbantext);
        }
        else if(offplayerbanned == 1)
        {
            SCMF(playerid,0xDB023EFF,"%s %s",offbantext,OffBanString[playerid][0]);
        }
        if(aplayerbanned == 0)
        {
            SCMF(playerid,0xDB023EFF,"%s",abantext);
        }
        else if(aplayerbanned == 1)
        {
            SCMF(playerid,0xDB023EFF,"%s %s",abantext,ABanString[playerid][0]);
        }
so how can I put this two diffrent type of ban into one line not two if you know what I mean? Thanks


Re: [HELP] ban text - Luca12 - 03.05.2014

okay how should like that. Thanks


Re: [HELP] ban text - Luca12 - 05.05.2014

anyone? thanks when I mean howw should like I mean on code check