Szerző Téma: UFO (jármû)  (Megtekintve 1589 alkalommal)

UFO (jármû)
« Dátum: 2012. december 24. - 16:09:44 »
+2 Show voters
CSõsztök
Elhoztam neketek egy UFO-t Ami a Hydrát és ajetpack ot helyettesíti a szerverekben
Eredeti LINK :http://forum.sa-mp.com/showthread.php?t=353323
Ezt a szerverekben az /ovni illetve /ovni2 vel hozhatjátok elõ.
A \"Y\" gombal vetíthettek ki az UFO ból Fényt
Pawn kod :
Ötletadó:SnickerS
KÉszítõ:Adri1
 
//Ovni by adri1
//Idea: SnickertS
//Ovni v2.0 Now in Hydra too by adri1
#include <a_samp>
// On foot
new Ovni[MAX_PLAYERS];
new Light[MAX_PLAYERS];
new bomb;
forward HideBomb();
//On Plane Hydra
new Ovni2[MAX_PLAYERS];
new Light2[MAX_PLAYERS];
new SpawnAuto[MAX_PLAYERS];
public OnPlayerConnect(playerid)
{
Ovni[playerid] = 0;
Light[playerid] = 0;
Ovni2[playerid] = 0;
Light2[playerid] = 0;
return 1;
}
public OnPlayerDisconnect(playerid)
{
    Ovni[playerid] = 0;
    Light[playerid] = 0;
   
Ovni2[playerid] = 0;
Light2[playerid] = 0;
}
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(!IsPlayerInAnyVehicle(playerid))
{
if(Ovni[playerid] == 1)
{
if (newkeys & KEY_FIRE)
{
new Float:x,Float:y,Float:z,Float:a;
GetPlayerPos(playerid,x,y,z);
GetPlayerFacingAngle(playerid,a);
bomb = CreateObject(3786, x, y, z-2, 0, 0, a-90);
MoveObject(bomb, x, y, z-300, 30.0);
SetTimer(\"HideBomb\",1000,0);
}
else if (newkeys & KEY_YES)
{
if(Light[playerid] == 0)
{
    SetPlayerAttachedObject(playerid,5,18656,1,0.918999,-0.342001,-0.760999,-12.000008,0.000000,90.000,1.000000,1.000000,1.000000);
    Light[playerid] = 1;
    }
    else if(Light[playerid] == 1)
    {
SetPlayerAttachedObject(playerid,5,18657,1,0.918999,-0.342001,-0.760999,-12.000008,0.000000,90.000,1.000000,1.000000,1.000000);
    Light[playerid] = 2;
    }
    else if(Light[playerid] == 2)
    {
SetPlayerAttachedObject(playerid,5,18658,1,0.918999,-0.342001,-0.760999,-12.000008,0.000000,90.000,1.000000,1.000000,1.000000);
    Light[playerid] = 0;
    }
}
else if (newkeys & KEY_NO)
{
    RemovePlayerAttachedObject(playerid, 5);
    Light[playerid] = 0;
}
}
}
else if(IsPlayerInAnyVehicle(playerid))
{
if(Ovni2[playerid] == 1)
{
if (newkeys & KEY_YES)
{
if(Light2[playerid] == 0)
{
    SetPlayerAttachedObject(playerid,3,18656,1,5.162999,-0.976000,-4.204011,0.000000,-2.100000,106.999916,4.111006,2.611997,5.209000);
    Light2[playerid] = 1;
    }
    else if(Light2[playerid] == 1)
    {
SetPlayerAttachedObject(playerid,3,18657,1,5.162999,-0.976000,-4.204011,0.000000,-2.100000,106.999916,4.111006,2.611997,5.209000);
    Light2[playerid] = 2;
    }
    else if(Light2[playerid] == 2)
    {
SetPlayerAttachedObject(playerid,3,18658,1,5.162999,-0.976000,-4.204011,0.000000,-2.100000,106.999916,4.111006,2.611997,5.209000);
    Light2[playerid] = 0;
    }
}
else if (newkeys & KEY_NO)
{
    RemovePlayerAttachedObject(playerid, 3);
    Light2[playerid] = 0;
}
}
}
return 1;
}
public OnPlayerExitVehicle(playerid, vehicleid)
{
if(Ovni2[playerid] == 1)
{
        for(new i=0; i<MAX_PLAYER_ATTACHED_OBJECTS; i++)
        {
            if(IsPlayerAttachedObjectSlotUsed(playerid, i)) RemovePlayerAttachedObject(playerid, i);
            Ovni2[playerid] = 0;
        }
}
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if(!strcmp(cmdtext, \"/ovni\", true))
{
if(Ovni[playerid] == 0)
{
   SetPlayerAttachedObject(playerid,0,3515,1,-0.609999,0.000000,-0.003999,0.000000,90.900000,0.000000,0.832001,0.818000,0.553001);
   SetPlayerAttachedObject(playerid,1,18843,1,-0.712000,0.000000,0.000000,0.000000,0.000000,0.000000,0.014000,0.015000,0.016000);
   SetPlayerAttachedObject(playerid,2,3515,1,0.133001,-0.011000,0.017000,0.000000,-90.000000,0.000000,0.818000,0.772001,0.359001);
            SetPlayerAttachedObject(playerid,3,18843,1,0.074999,-0.017000,0.026999,0.000000,0.000000,0.000000,0.019000,0.020000,0.020000);
   Ovni[playerid] = 1;
   SetPlayerSpecialAction(playerid,SPECIAL_ACTION_USEJETPACK);
}
else if(Ovni[playerid] == 1)
{
        for(new i=0; i<MAX_PLAYER_ATTACHED_OBJECTS; i++)
        {
            if(IsPlayerAttachedObjectSlotUsed(playerid, i)) RemovePlayerAttachedObject(playerid, i);
            Ovni[playerid] = 0;
        }
}
return 1;
}
if(!strcmp(cmdtext, \"/ovni2\", true))
{
if(Ovni2[playerid] == 0)
{
   SetPlayerAttachedObject(playerid,0,3515,1,1.281999,-1.577000,-0.281000,-0.499999,90.800125,-0.599996,4.183998,4.936002,2.922001);
   SetPlayerAttachedObject(playerid,1,3515,1,5.023988,-1.466000,-0.072000,0.199999,-89.300010,8.799994,4.148001,4.529000,1.617000);
   SetPlayerAttachedObject(playerid,2,18843,1,4.163002,-1.490000,0.000000,0.000000,0.000000,0.000000,0.089000,0.117999,0.099000);
   Ovni2[playerid] = 1;
   CrearVehiculo(playerid, 520);
}
else if(Ovni2[playerid] == 1)
{
        for(new i=0; i<MAX_PLAYER_ATTACHED_OBJECTS; i++)
        {
            if(IsPlayerAttachedObjectSlotUsed(playerid, i)) RemovePlayerAttachedObject(playerid, i);
            Ovni2[playerid] = 0;
        }
}
return 1;
}
return 0;
}
public OnPlayerDeath(playerid, killerid, reason)
{
if(Ovni[playerid] == 1)
{
        for(new i=0; i<MAX_PLAYER_ATTACHED_OBJECTS; i++)
        {
            if(IsPlayerAttachedObjectSlotUsed(playerid, i)) RemovePlayerAttachedObject(playerid, i);
        }
}
return 1;
}
public HideBomb()
{
new Float:x, Float:y, Float:z;
GetObjectPos(bomb, x, y, z);
DestroyObject(bomb);
CreateExplosion(x, y, z, 2, 200.0);
return 1;
}
CrearVehiculo(playerid, modelid)
{
        new Auto, Float:x,Float:y,Float:z,Float:angulo;
if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
Auto = GetPlayerVehicleID(playerid);
    GetVehiclePos(Auto, x, y, z);
    GetVehicleZAngle(Auto, angulo);
    }
    else
    {
    GetPlayerPos(playerid, x, y, z);
GetPlayerFacingAngle(playerid, angulo);
    }
        if(SpawnAuto[playerid] != 0)DestroyVehicle(SpawnAuto[playerid]);
        SpawnAuto[playerid] = CreateVehicle(modelid,x,y,z,angulo,-1,-1,60);
        PutPlayerInVehicle(playerid,SpawnAuto[playerid],0);
LinkVehicleToInterior(Auto, GetPlayerInterior(playerid));
SetVehicleVirtualWorld(Auto, GetPlayerVirtualWorld(playerid));
        return 1;
}

 
Használjátok egészséggel.
-Thosiro Voltam-
« Utoljára szerkesztve: 2012. december 26. - 12:00:17 írta Thosiro »

Nem elérhető Beckham

  • 1693
  • Noresz
  • Discord: Noresz#4265
    • Profil megtekintése
    • OctansV Alt:v szervere
UFO (jármû)
« Válasz #1 Dátum: 2012. december 24. - 21:59:16 »
0 Show voters
Tetszik,csak egy gond van vele,mikor a fényt világítja akkor látni a hydra árnyékát.

Nem elérhető Cody

UFO (jármû)
« Válasz #2 Dátum: 2012. december 25. - 00:21:11 »
0 Show voters
Már, át hozták ezt a filterszkriptet!!

Link:


http://sampforum.hu/index.php?topic=31480.msg335317#msg335317

Ez, törölhetõ szerintem!!


+


Ha, megkérhetlek írd ki a készítõ nevét is!!

UFO (jármû)
« Válasz #3 Dátum: 2012. december 25. - 10:19:14 »
0 Show voters
Idézetet írta: Cody date=1356391271\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"31339\" data-ipsquote-contentclass=\"forums_Topic
Már, át hozták ezt a filterszkriptet!!

Link:


http://sampforum.hu/index.php?topic=31480.msg335317#msg335317

Ez, törölhetõ szerintem!!


+


Ha, megkérhetlek írd ki a készítõ nevét is!!

 
Igen Látom
Hamarosan odaírom a szerzõ nevét is...

Nem elérhető zeteni

  • 1970
  • Ex-Scripter
    • Profil megtekintése
UFO (jármû)
« Válasz #4 Dátum: 2012. december 25. - 22:06:37 »
0 Show voters
Kezd kicsit elegem lenni ebbõl a \"hamarosan, mindjárt, azonnal, majd\"... Vagy megcsinálod vagy törlöm a témákat.

UFO (jármû)
« Válasz #5 Dátum: 2012. december 25. - 23:44:38 »
0 Show voters
Szerintem az árnyék probléma megoldható lenne, ha a hydrát egy másik interiorba raknád át (nem vagyok benne biztos, sokszor csináltam már így \"láthatatlan jármûvet\", de az árnyékot nem néztem)

UFO (jármû)
« Válasz #6 Dátum: 2012. december 26. - 12:01:04 »
+1 Show voters
Idézetet írta: zeteni date=1356469597\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"31339\" data-ipsquote-contentclass=\"forums_Topic
Kezd kicsit elegem lenni ebbõl a \"hamarosan, mindjárt, azonnal, majd\"... Vagy megcsinálod vagy törlöm a témákat.
 
Nah megvan az öröm ? :D

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal