Dialog question
#1

Hey ,I maked a dialog , at player spawn ! , But I want to show the dialog for player just when is first spawn...
Who can I make this ?? Thx
Reply
#2

pawn Код:
new spawned[MAX_PLAYERS] = 0; // Array

public OnPlayerSpawn(playerid)
{
      if(spwaned[playerid] == 0) // Check if the player has spawned before
      {
             ShowPlayerDialog(...........);  // Build your dialog here
             spawned[playerid] = 1;
      }
      //rest of the code
      return 1;
}

// Change the state of that particular playerid in array we created when player disconnects
public OnPlayerDisconnect(playerid, reason)
{
      if(spwaned[playerid] == 1)
      {
              spawned[playerid] = 0;
      }
      return 1;
}
Reply
#3

THX Man , it work's
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)