/respawn bugs as hell if player is in vehicle
#1

here is my respawn command...

pawn Код:
dcmd_respawn(playerid,params[])
    {
      if(PlayerInfo[playerid][pAdmin] == 0) return 1;
      new id,pName[MAX_PLAYER_NAME],idName[MAX_PLAYER_NAME],server[256];
      if(sscanf(params,"u",id)) return SendClientMessage(playerid,COLOR_DARKRED,"Usage: /respawn <playerid/partofname>");
      if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, COLOR_DARKRED, "Player not found");
      GetPlayerName(playerid,pName,sizeof(pName));
      GetPlayerName(id,idName,sizeof(idName));
      format(server,sizeof(server),"%s was respawned by Admin %s",idName,pName);
      SetPlayerVirtualWorld(playerid,0);
      SendClientMessageToAll(COLOR_DARKRED,server);
      RemovePlayerFromVehicle(id);
      SpawnPlayer(id);
      return 1;
    }
if the player is in a car, the player gets stuck in the car until /slap... Then he can do F and exit.
Reply


Messages In This Thread
/respawn bugs as hell if player is in vehicle - by introzen - 01.04.2009, 14:55
Re: /respawn bugs as hell if player is in vehicle - by Norn - 01.04.2009, 15:00
Re: /respawn bugs as hell if player is in vehicle - by introzen - 01.04.2009, 15:11
Re: /respawn bugs as hell if player is in vehicle - by On_Top_Non_Stop - 01.04.2009, 15:19
Re: /respawn bugs as hell if player is in vehicle - by introzen - 01.04.2009, 15:23

Forum Jump:


Users browsing this thread: 1 Guest(s)