Player Invisibility Script
#7

Damn, thats genious. Thank you !
pawn Code:
public OnPlayerCommadText(playerid, cmdtext[])
{
  if(!strcmp("/makemeinvisible", cmdtext))
  {
   
    new a = GetMaxPlayers();
    for(new id = 0; id > a; id++)
    {
      if(!IsPlayerConnected(id)) continue;
      ShowPlayerNameTagForPlayer( id, playerid, false );
      SetPlayerMarkerForPlayer( id, playerid, 0xFFFFFF00 );
    }
    new Float:x, Float:y, Float:z, Float:a;
    GetPlayerPos(playerid, x, y, z);
    GetPlayerFacingAngle(playerid, a);
    nrg = CreateVehicle(522, x, y, z, a, -1, -1, -1);
    LinkVehicleToInterior(nrg, 16);
    PutPlayerInVehicle(playerid, nrg, 0);
    SendClientMessage(playerid, color, "You are invisible to other players. Just don't leave your vehicle");
    SendClientMessage(playerid, color, "To become visible again, just press ENTER");
    return 1;
  }
  return 0;
}

public OnPlayerExitVehicle(playerid, vehicleid)
{
  if(vehicleid == nrg)
  {
    DestroyVehicle(nrg);
    new a = GetMaxPlayers();
    for(new id = 0; id > a; id++)
    {
      if(!IsPlayerConnected) continue;
      ShowPlayerNameTagForPlayer( id, playerid, true );
      SetPlayerMarkerForPlayer( id, playerid, COLOR );
    }
    SendClientMessage(playerid, color, "You are now visible to other players");
  }
  return 1;
}
Reply


Messages In This Thread
Player Invisibility Script - by Jbosh123 - 28.08.2009, 08:28
Re: Player Invisibility Script - by SampStunta - 28.08.2009, 08:37
Re: Player Invisibility Script - by dice7 - 28.08.2009, 08:56
Re: Player Invisibility Script - by WrathOfGenesis - 28.08.2009, 09:05
Re: Player Invisibility Script - by dice7 - 28.08.2009, 09:09
Re: Player Invisibility Script - by FreeSoul - 28.08.2009, 09:13
Re: Player Invisibility Script - by dice7 - 28.08.2009, 09:23
Re: Player Invisibility Script - by Sergei - 28.08.2009, 10:29
Re: Player Invisibility Script - by Joe Staff - 28.08.2009, 12:20
Re: Player Invisibility Script - by Zeromanster - 28.08.2009, 12:41

Forum Jump:


Users browsing this thread: 2 Guest(s)