Author Topic: Sistema De Duelo  (Read 5053 times)

0 Members and 1 Guest are viewing this topic.

Offline luislabarcalopezpely

  • Street Thug
  • *
  • Posts: 1
    • View Profile
Sistema De Duelo
« on: October 10, 2014, 04:53:28 am »
[pawn]new duelo[MAX_PLAYERS];[/pawn]
en public OnPlayerDisconnect(playerid, reason)
[pawn]duelo[playerid] = 0;[/pawn]

[pawn]public OnPlayerCommandText(playerid, cmdtext[])
{
 else if ( strcmp( cmd, "salirbatalla", true ) == 0 )
{
   if(duelo[playerid] == 0) {
    SendClientMessage(playerid,COLOR_RED,"Error: debes estar en batalla para salir de ella");
    }
   if(duelo[playerid] == 1) {
      if ( !IsLoggedIn( playerid ) ) SendClientMessage( playerid, COLOR_RED, "logueate primero" );
      else
      {
format( szMsg, 128, "%s  a salido de batalla para salir pon /c salirbatalla",gPlayers[playerid] );
SendClientMessageToAll( BLUE, szMsg );
SetPlayerPos(playerid,-702.69311,337.37844,10.89598,0,0);
         duelo[playerid] = 0;
      }
      }
      return 1;
   }

 else if ( strcmp( cmd, "batalla", true ) == 0 )
{
   if(duelo[playerid] == 1) {
    SendClientMessage(playerid,COLOR_RED,"Error: ya estas en batalla");
    }
   if(duelo[playerid] == 0) {
      if ( !IsLoggedIn( playerid ) ) SendClientMessage( playerid, COLOR_RED, "Logueate primero" );
      else
      {
format( szMsg, 128, "%s  a entrado a la batalla para entrar escribe /c batalla",gPlayers[playerid] );
SendClientMessageToAll( BLUE, szMsg );
SetPlayerPos(playerid,-1246.70227,1406.93408,84.69406,0,0);
 SetPlayerWeapon(playerid,27,10000);
 SetPlayerWeapon(playerid,21,10000);
         duelo[playerid] = 1;

      }
      }
      return 1;
   }[/pawn]







[pawn]public OnPlayerSpawn(playerid,classid,teamid)

{

    if(duelo[playerid] == 1) {
    SendClientMessage(playerid,COLOR_RED,"Apareces en batalla usa /c salirbatalla para salir de ella.");
   SetPlayerPos(playerid,-1246.70227,1406.93408,84.69406,0,0);
    }
       if(duelo[playerid] == 0) {
    SendClientMessage(playerid,COLOR_RED,"has salido de batalla");
    }
   return 1;
}[/pawn]
« Last Edit: October 13, 2014, 07:28:19 pm by luislabarcalopezpely »

Offline NeskWriter

  • Crime Boss
  • ****
  • Posts: 355
    • View Profile
Re: Sistema De Duelo
« Reply #1 on: October 10, 2014, 07:18:19 am »
are you kidding


-Funniest quotes-

Quote from: asad3man
i cant able to understand