SA-MP Forums Archive
Help please - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Help please (/showthread.php?tid=259436)



Help please - bartje01 - 04.06.2011

Hey guys. I want to have a faction named to be shown in a dialog.
I thought that my code should work but it doesnt

The command:
pawn Код:
COMMAND:invite(playerid,params[])
    {
    new id,string[100];
    if(FactionInfo[playerid][fowner] !=1) return SendClientMessage(playerid,COLOR_RED,"You're not a faction owner.");
    if(sscanf(params,"u",id))return SendClientMessage(playerid,COLOR_GREY,"USAGE:/invite [playerid]");
    if(PlayerInfo[id][Faction] >1) return SendClientMessage(playerid,COLOR_RED,"This player is already in a faction.");
    format(string,sizeof(string),"You are invited for %s",FactionInfo[playerid][fname]);
    ShowPlayerDialog(id,4,DIALOG_STYLE_MSGBOX,"Faction Invite",string,"Accept","Decline");
    return 1;
    }
Now the dialog says: You are invited for

The faction name doesnt shows up.
How to fix?