How to add rules?
#1

OK , Thanks people for the anims , now I want to add rules, could somebody teach me how to do that ?
Reply
#2

Extremely Simple piece of code.
pawn Code:
SendClientMessage(playerid, YOUR_COLOR, "The message you want to display goes here!");
Reply
#3

You should tell us how you want your rules to show up ? when they connect ? or when they spawn ? or when they /register ? please provide us with some description before asking.

Regards, Adil.
Reply
#4

I want it when they spawn @ Pakistan Cool Boy
PS. If it could to freeze everything , so when you spawn it freezes and then the rules show up
Reply
#5

Then put the code under, OnPlayerSpawn
pawn Code:
SendClientMessage(playerid, AEB404, "Rule Number1");
SendClientMessage(playerid, AEB404, "Rule Number2");
SendClientMessage(playerid, AEB404, "Rule Number3");
SendClientMessage(playerid, AEB404, "Rule Number4");
SendClientMessage(playerid, AEB404, "Rule Number5");
Reply
#6

Or, more efficient:
pawn Code:
public OnPlayerSpawn(playerid)
{
   TogglePlayerControllable(playerid, false);
   ShowPlayerDialog(playerid, 1, DIALOG_STYLE_LIST, "Rules here", "Understood", "Cancel");
   return 1;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
   if(dialogid == 1)
   {
      if(!response) // If he clicked on "Cancel"
      {
         Kick(playerid); // It will kick him
         return 1;
      } else {
         TogglePlayerControllable(playerid, true);
      }
      return 1;
   }
   return 0;
}
Reply


Forum Jump:


Users browsing this thread: 5 Guest(s)