Üzenetek megjelenítése

Ez a szekció lehetővé teszi a felhasználó által írt összes hozzászólás megtekintését. Vedd figyelembe, hogy csak azokba a fórumokba írt hozzászólásokat látod, amelyekhez hozzáférésed van.


Üzenetek - ReMoTe

Oldalak: 1 2 [3] 4 5 6
31
Segítségkérés / if GetVehicleHealth()
« Dátum: 2012. július 14. - 14:19:48 »
Sziasztok :smokin:
Egy olyan kellene nekem,hogy egy parancs végén,esetemben a /vizsgáztat lekérdezi a kocsi életét és a megatottak alapján jegyet ad...
namost,én ezt így csináltam:
 
   if GetVehicleHealth(vehicleid, 900<1000)
{
    GameTextForPlayer(targetid, \"5-os!\", 3000, 4);
       SendClientMessage(playerid, 0xFF0000AA, \"Sikeresen vizsgáztattál! A vizsgázó jegye: 5-ös! Rangot léphet!\");
       SendClientMessage(targetid, 0xFF0000AA, \"Sikeresen le vizsgáztál! A jegyed: 5-ös! Rangot léphetsz!\");
}

 
A pirossal jelölt errorozik: if GetVehicleHealth(vehicleid, 900<1000)
Hogyan lehetne javítani?

32
Segítségkérés / VehicleSpeed kérdés..[megvalósítható?]
« Dátum: 2012. július 14. - 10:30:04 »
Ohh köszönöm :)

33
Segítségkérés / VehicleSpeed kérdés..[megvalósítható?]
« Dátum: 2012. július 14. - 10:02:17 »
Sziasztok
Megvalósítható az,hogy ha a plyaer eléri kocsival a 90km/h-t és le lassul 30km/h-ra akkor ki ír egy bizonyos szöveget,de ha a player el éri a 30km/h-t (nem 90km/h-ról lassul le) akkor nem írja ki?

34
Szkript kérések / [RégiScript]Megvan Valakinek?
« Dátum: 2012. július 10. - 10:43:03 »
Hellotok!
Egy http://gtaforum.hu/index.php/topic,5941.msg55471.html#msg55471<-ilyen FS-t keresek!
Csak ennek nem jó a letöltõ linkje!Ezért kérlek titeket hátha nektek van..:Akinek van linkeljen kérem szépen!

35
Segítségkérés / 2 rp-s kérdés :)
« Dátum: 2012. július 10. - 09:13:59 »
Hali...kellene nekem egy olyan script,ha megnyomunk egy tetszõleges gombot akkor indexel valamerre (ezt mondjuk object-el lehetne megoldani,vagy lámpa villogással...)
Megy egy olyan,hogy ha eléri a player a 80km/h-t és le leassul 30km/h-ra akkor egy tetszõleges dolgot ír (SendClientMessage) de ha csak úgy (nem 80km/h-ról) lassul 30km/h-ra akkor ne történjen ez meg...
Megoldható?

36
SA-MP: Szerverfejlesztés / Killstrake
« Dátum: 2012. július 09. - 13:32:45 »
KillStreak:
Mód elejére?:
new killstreak[MAX_PLAYERS];

 
Ahová akarod:
 
stock HandleKS(playerid, killerid)
{
     killstreak[playerid] = 0;
     killstreak[killerid] ++;
     new msg1[64], msg2[64], name1[MAX_PLAYER_NAME], name2[MAX_PLAYER_NAME];
     GetPlayerName(playerid, name1, strlen(name1));
     GetPlayerName(playerid, name2, strlen(name2));
     format(msg1, strlen(msg1), \"%s ide,hog ymit írjon ha \'befejezte\' a kill strake-t vagyis meghalt\", name2, name1);
     format(msg2, strlen(msg2), \"%s <-hogy ki %i<- és hogy hanyadik killstreak-nél jár\", name2, killstreak[killerid]);
     SendClientMessageToAll(-1, msg1);
     SendClientMessageToAll(-1, msg2);
     switch(killstreak[killerid])
     {
          case 3:
          {
               //Mit kapjon ha megöl egymás után 3 embert
          }
          case 6:
          {
               //Mit kapjon ha megöl egymás után 6 embert
          }
          case 9:  //A számok átírásával változtathatod,hogy hány embert kelljen a jualomért megölni :)
          {
               //Mit kapjon ha megöl egymás után 9 embert
          }
     }
     return 1;
}

 
Csak akkor ad jutalmat,ha TÉNYLEGESEN fejen lövöd,nem pedig hason :)

37
Segítségkérés / Seb.váltó rendszer (Segítség)
« Dátum: 2012. július 09. - 10:12:41 »
Köszti mindenkinek...tengeri malac...felhasználom a scriptet és bele írtam,hogy te csináltad :)
-
U.i.: Ha valakinek kell,írjon PM-et :)
HOLNAP ZÁROK
[mod]Ha már megírták neked, akkor legyen annyi benned, hogy nem smucigoskodsz.[/mod]

38
Segítségkérés / Seb.váltó rendszer (Segítség)
« Dátum: 2012. július 09. - 08:38:46 »
És itt,hol lehet megadni hogy mekkora seb-nél kelljen váltani??
+ itt nincs figyelmeztetés,hogy a motor fullad válts pedig az kéne :)
Azért köszi...ezeket ha tudod akkor mond meg ... :D

39
Segítségkérés / TextDraw készítés :)
« Dátum: 2012. július 08. - 10:12:05 »
Sziasztok!
Kellene nekem ehhez a scripthez:
 
function UpdateSpeed()
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(!IsPlayerConnected(i)) continue;
if(!IsPlayerInAnyVehicle(i)) continue;
if(GetVehicleSpeed(GetPlayerVehicleID(i)) > 30)
{
    if(pWarned) continue;
    pWarned = true;
    GameTextForPlayer(playerid, \"A MOTOR FULLAD!\", 3000, 1);
           SendClientMessage(playerid, COLOR_RED, \"Vigyázz a motor migyárt lefuladd! Nyomd meg a SPACE gombot!\");
           DieTimer = SetTimerEx(\"motor\", 3000, false, \"d\", i);
}
}
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(!IsPlayerConnected(i)) continue;
if(!IsPlayerInAnyVehicle(i)) continue;
if(GetVehicleSpeed(GetPlayerVehicleID(i)) > 60)
{
    if(pWarned) continue;
    pWarned = true;
    GameTextForPlayer(playerid, \"A MOTOR FULLAD!\", 3000, 1);
           SendClientMessage(playerid, COLOR_RED, \"Vigyázz a motor migyárt lefuladd! Nyomd meg a SPACE gombot!\");
           DieTimer = SetTimerEx(\"motor\", 3000, false, \"d\", i);
}
}
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(!IsPlayerConnected(i)) continue;
if(!IsPlayerInAnyVehicle(i)) continue;
if(GetVehicleSpeed(GetPlayerVehicleID(i)) > 90)
{
    if(pWarned) continue;
    pWarned = true;
    GameTextForPlayer(playerid, \"A MOTOR FULLAD!\", 3000, 1);
           SendClientMessage(playerid, COLOR_RED, \"Vigyázz a motor migyárt lefuladd! Nyomd meg a SPACE gombot!\");
           DieTimer = SetTimerEx(\"motor\", 3000, false, \"d\", i);
}
}
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(!IsPlayerConnected(i)) continue;
if(!IsPlayerInAnyVehicle(i)) continue;
if(GetVehicleSpeed(GetPlayerVehicleID(i)) > 120)
{
    if(pWarned) continue;
    pWarned = true;
    GameTextForPlayer(playerid, \"A MOTOR FULLAD!\", 3000, 1);
           SendClientMessage(playerid, COLOR_RED, \"Vigyázz a motor migyárt lefuladd! Nyomd meg a SPACE gombot!\");
           DieTimer = SetTimerEx(\"motor\", 3000, false, \"d\", i);
}
}
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(!IsPlayerConnected(i)) continue;
if(!IsPlayerInAnyVehicle(i)) continue;
if(GetVehicleSpeed(GetPlayerVehicleID(i)) > 150)
{
    if(pWarned) continue;
    pWarned = true;
    GameTextForPlayer(playerid, \"A MOTOR FULLAD!\", 3000, 1);
           SendClientMessage(playerid, COLOR_RED, \"Vigyázz a motor migyárt lefuladd! Nyomd meg a SPACE gombot!\");
           DieTimer = SetTimerEx(\"motor\", 3000, false, \"d\", i);
}
}
}

 
(A script csak egy részét illesztettem be, az illetéktelen kezek elõl [csak ez a rész a lényeg])
Egy olyan,hogy amikor a kocsi sebessége 30km/h
(
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(!IsPlayerConnected(i)) continue;
if(!IsPlayerInAnyVehicle(i)) continue;
if(GetVehicleSpeed(GetPlayerVehicleID(i)) > 30)
{
    if(pWarned) continue;
    pWarned = true;
    GameTextForPlayer(playerid, \"A MOTOR FULLAD!\", 3000, 1);
           SendClientMessage(playerid, COLOR_RED, \"Vigyázz a motor migyárt lefuladd! Nyomd meg a SPACE gombot!\");
           DieTimer = SetTimerEx(\"motor\", 3000, false, \"d\", i);
}
}

)
Akkor egy TextDraw,a jobb alsó sarokban írja: Váltó:1-es és így tovább ahogy a scriptben látni :)
Elõre kössz: REMOTE :)

40
Segítségkérés / Ezt hogyan javítsam?
« Dátum: 2012. július 08. - 09:51:12 »
Hali :)
Kaptam egy error-t ennél a sornál:
if(newkeys == KEY_SPRINT) KillTimer(motor), pWarned[playerid] = false;
Error:error 076: syntax error in the expression, or invalid function call
Mi a gond? :)

41
Munkaerő keresése / Maper keresetik,egy aáltaálon "kis" mapoláshoz
« Dátum: 2012. július 07. - 17:22:19 »
Hali...az OxfordRPG-re kellene nekem egy bíróságot mapolni,egy másik interiorba! (nem a 0-ásba)
Ha valaki be mapolja,azt meg köszönném :)

42
Fórum Archívum (Témák/Fórumok) / Törölve
« Dátum: 2012. július 07. - 17:20:40 »
Törölve

43
Segítségkérés / Seb.váltó rendszer (Segítség)
« Dátum: 2012. július 07. - 16:41:22 »
Idézetet írta: TengeriMalac date=1341652698\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"23905\" data-ipsquote-contentclass=\"forums_Topic
http://sampforum.hu/index.php?topic=27551.0 --> ez kell hozzá
 

#include <a_samp>
#include <setvehiclespeed>
#define function%0(%1)  forward%0(%1);public%0(%1)
new DieTimer[MAX_PLAYERS],
bool:pWarned[MAX_PLAYERS] = false;
public OnFilterScriptInit() SetTimer(\"UpdateSpeed\", 1000, true);
public OnFilterScriptExit() for(new i = 0; i < MAX_PLAYERS; i++) KillTimer(DieTimer);
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys) {
if(newkeys == KEY_SPRINT) KillTimer(motor), pWarned[playerid] = false;
return 1;
}
function UpdateSpeed() {
for(new i = 0; i < MAX_PLAYERS; i++) {
if(!IsPlayerConnected(i)) continue;
if(!IsPlayerInAnyVehicle(i)) continue;
if(GetVehicleSpeed(GetPlayerVehicleID(i)) > 90) {
    if(pWarned) continue;
    pWarned = true;
    GameTextForPlayer(playerid,\"MOTOR FULLAD!\", 3000, 1);
           SendClientMessage(playerid,\"Vigyázz a motor migyárt lefuladd! Nyomd meg a SPACE gombot!\");
           DieTimer = SetTimerEx(\"motor\", 3000, false, \"d\", i);
}
}
}
function motor(playerid) {
new vehicle = GetPlayerVehicleID(playerid);
new engine, lights, alarm, doors, bonnet, boot, objective;
GetVehicleParamsEx(vehicle, engine, lights, alarm, doors, bonnet, boot, objective);
SetVehicleParamsEx(vehicle, 0, lights, alarm, doors, bonnet, boot, 0);
SetVehiclespeed(GetPlayervehicleID(playerid), 0);
pWarned[playerid] = false;
return 1;
}

 
Nem teszteltem, de ránézésre jónak néz ki xD
 
Deleted...Szerkesztve
4-error
(13)->error 076: syntax error in the expression, or invalid function call
(23)->error 017: undefined symbol \"playerid\"
(24)->error 017: undefined symbol \"playerid\"
(24)->error 017: undefined symbol \"SetVehiclespeed\"
Pawn compiler 3.2.3664           Copyright © 1997-2006, ITB CompuPhase
4 Errors.

44
Segítségkérés / Sebesség lekérése
« Dátum: 2012. július 07. - 10:03:32 »
Kössz

45
Segítségkérés / Script átalakítása
« Dátum: 2012. július 07. - 09:59:16 »
Hello...ebbe a script,be kellene beilleszteni egy ilyet:
Ha a kocsi sebessége eléri a 30km/h-t akkor GameTextForPlayer \"Válts!!\" ha nem vált 10-mp-n belül,lefullad a motor :)
A váltáshoz használt gomb a script-be: KEY_FIRE =Bal klikk :)
 
#include <a_samp>
#define Loop(%0,%1) \\
for(new %0; %0 != %1; %0++) // Macro :)
 
#define GEAR_KEY KEY_FIRE // Váltáshoz használandó gomb
new
timer[MAX_PLAYERS], // Idõzítõ
Text: GearInfo[MAX_PLAYERS], // R N D
Text: Speedo[MAX_PLAYERS], // Sebmérõ
Text: General[5], // Struktúra
Text: Gear[6], //
cGear[MAX_VEHICLES], // current gear
warn[MAX_VEHICLES], // Sebesség magas/alacsony
gul[MAX_VEHICLES] //
;
 
forward ShiftFunction(playerid);
public OnFilterScriptInit()
{
General[0] = TextDrawCreate(554.000000, 414.000000, \"_\");
TextDrawBackgroundColor(General[0], 255);
TextDrawFont(General[0], 1);
TextDrawLetterSize(General[0], 0.500000, 2.599999);
TextDrawColor(General[0], -1);
TextDrawSetOutline(General[0], 0);
TextDrawSetProportional(General[0], 1);
TextDrawSetShadow(General[0], 1);
TextDrawUseBox(General[0], 1);
TextDrawBoxColor(General[0], 70);
TextDrawTextSize(General[0], 628.000000, 0.000000);
General[1] = TextDrawCreate(554.000000, 440.000000, \"_\");
TextDrawBackgroundColor(General[1], 255);
TextDrawFont(General[1], 1);
TextDrawLetterSize(General[1], 0.500000, -0.300000);
TextDrawColor(General[1], -1);
TextDrawSetOutline(General[1], 0);
TextDrawSetProportional(General[1], 1);
TextDrawSetShadow(General[1], 1);
TextDrawUseBox(General[1], 1);
TextDrawBoxColor(General[1], 120);
TextDrawTextSize(General[1], 628.000000, 0.000000);
General[2] = TextDrawCreate(554.000000, 414.000000, \"_\");
TextDrawBackgroundColor(General[2], 255);
TextDrawFont(General[2], 1);
TextDrawLetterSize(General[2], 0.500000, -0.300000);
TextDrawColor(General[2], -1);
TextDrawSetOutline(General[2], 0);
TextDrawSetProportional(General[2], 1);
TextDrawSetShadow(General[2], 1);
TextDrawUseBox(General[2], 1);
TextDrawBoxColor(General[2], 120);
TextDrawTextSize(General[2], 628.000000, 0.000000);
General[3] = TextDrawCreate(631.000000, 414.000000, \"_\");
TextDrawBackgroundColor(General[3], 255);
TextDrawFont(General[3], 1);
TextDrawLetterSize(General[3], 0.500000, 2.599999);
TextDrawColor(General[3], -1);
TextDrawSetOutline(General[3], 0);
TextDrawSetProportional(General[3], 1);
TextDrawSetShadow(General[3], 1);
TextDrawUseBox(General[3], 1);
TextDrawBoxColor(General[3], 120);
TextDrawTextSize(General[3], 629.000000, 0.000000);
General[4] = TextDrawCreate(554.000000, 414.000000, \"_\");
TextDrawBackgroundColor(General[4], 255);
TextDrawFont(General[4], 1);
TextDrawLetterSize(General[4], 0.500000, 2.599999);
TextDrawColor(General[4], -1);
TextDrawSetOutline(General[4], 0);
TextDrawSetProportional(General[4], 1);
TextDrawSetShadow(General[4], 1);
TextDrawUseBox(General[4], 1);
TextDrawBoxColor(General[4], 120);
TextDrawTextSize(General[4], 550.000000, 0.000000);
Gear[0] = TextDrawCreate(558.000000, 430.000000, \"_\");
TextDrawBackgroundColor(Gear[0], 255);
TextDrawFont(Gear[0], 1);
TextDrawLetterSize(Gear[0], 0.500000, 0.399999);
TextDrawColor(Gear[0], -1);
TextDrawSetOutline(Gear[0], 0);
TextDrawSetProportional(Gear[0], 1);
TextDrawSetShadow(Gear[0], 1);
TextDrawUseBox(Gear[0], 1);
TextDrawBoxColor(Gear[0], -1);
TextDrawTextSize(Gear[0], 553.000000, 0.000000);
Gear[1] = TextDrawCreate(562.000000, 427.399993, \"_\");
TextDrawBackgroundColor(Gear[1], 255);
TextDrawFont(Gear[1], 1);
TextDrawLetterSize(Gear[1], 0.549999, 0.699999);
TextDrawColor(Gear[1], -1);
TextDrawSetOutline(Gear[1], 0);
TextDrawSetProportional(Gear[1], 1);
TextDrawSetShadow(Gear[1], 1);
TextDrawUseBox(Gear[1], 1);
TextDrawBoxColor(Gear[1], -151807233);
TextDrawTextSize(Gear[1], 557.000000, 0.000000);
Gear[2] = TextDrawCreate(566.000000, 424.600006, \"_\");
TextDrawBackgroundColor(Gear[2], 255);
TextDrawFont(Gear[2], 1);
TextDrawLetterSize(Gear[2], 0.549999, 1.000000);
TextDrawColor(Gear[2], -1);
TextDrawSetOutline(Gear[2], 0);
TextDrawSetProportional(Gear[2], 1);
TextDrawSetShadow(Gear[2], 1);
TextDrawUseBox(Gear[2], 1);
TextDrawBoxColor(Gear[2], -1823745);
TextDrawTextSize(Gear[2], 561.000000, 0.000000);
Gear[3] = TextDrawCreate(570.000000, 422.000000, \"_\");
TextDrawBackgroundColor(Gear[3], 255);
TextDrawFont(Gear[3], 1);
TextDrawLetterSize(Gear[3], 0.549999, 1.300000);
TextDrawColor(Gear[3], -1);
TextDrawSetOutline(Gear[3], 0);
TextDrawSetProportional(Gear[3], 1);
TextDrawSetShadow(Gear[3], 1);
TextDrawUseBox(Gear[3], 1);
TextDrawBoxColor(Gear[3], -1813566465);
TextDrawTextSize(Gear[3], 565.000000, 0.000000);
Gear[4] = TextDrawCreate(574.000000, 419.299987, \"_\");
TextDrawBackgroundColor(Gear[4], 255);
TextDrawFont(Gear[4], 1);
TextDrawLetterSize(Gear[4], 0.549999, 1.600000);
TextDrawColor(Gear[4], -1);
TextDrawSetOutline(Gear[4], 0);
TextDrawSetProportional(Gear[4], 1);
TextDrawSetShadow(Gear[4], 1);
TextDrawUseBox(Gear[4], 1);
TextDrawBoxColor(Gear[4], -1813566465);
TextDrawTextSize(Gear[4], 569.000000, 0.000000);
Gear[5] = TextDrawCreate(578.000000, 417.299987, \"_\");
TextDrawBackgroundColor(Gear[5], 255);
TextDrawFont(Gear[5], 1);
TextDrawLetterSize(Gear[5], 0.549999, 1.800000);
TextDrawColor(Gear[5], -1);
TextDrawSetOutline(Gear[5], 0);
TextDrawSetProportional(Gear[5], 1);
TextDrawSetShadow(Gear[5], 1);
TextDrawUseBox(Gear[5], 1);
TextDrawBoxColor(Gear[5], -16776961);
TextDrawTextSize(Gear[5], 573.000000, 0.000000);
print(\"\\n--------------------------------------\");
print(\"Sebességváltó rendszer by ReMoTe\");
print(\"--------------------------------------\\n\");
return 1;
}
public OnPlayerDisconnect(playerid, reason)
{
KillTimer(timer[playerid]);
TextDrawDestroy(GearInfo[playerid]);
TextDrawDestroy(Speedo[playerid]);
return 1;
}
public OnPlayerConnect(playerid)
{
    GearInfo[playerid] = TextDrawCreate(596.000000, 425.000000, \"~w~R ~g~~h~N ~w~D\");
TextDrawBackgroundColor(GearInfo[playerid], 255);
TextDrawFont(GearInfo[playerid], 1);
TextDrawLetterSize(GearInfo[playerid], 0.320000, 1.299999);
TextDrawColor(GearInfo[playerid], -1);
TextDrawSetOutline(GearInfo[playerid], 0);
TextDrawSetProportional(GearInfo[playerid], 1);
TextDrawSetShadow(GearInfo[playerid], 1);
Speedo[playerid] = TextDrawCreate(579.000000, 414.000000, \"255 ~w~km/h\");
TextDrawBackgroundColor(Speedo[playerid], 0x000000FF);
TextDrawFont(Speedo[playerid], 1);
TextDrawLetterSize(Speedo[playerid], 0.170000, 0.799999);
TextDrawColor(Speedo[playerid], 0xA803D0FF);
TextDrawSetOutline(Speedo[playerid], 0);
TextDrawSetProportional(Speedo[playerid], 1);
TextDrawSetShadow(Speedo[playerid], 1);
    timer[playerid] = SetTimerEx(\"ShiftFunction\",150,true,\"i\",playerid);
return 1;
}
stock GetSpeed(playerid)
{
new Float:ST[3];
GetVehicleVelocity(GetPlayerVehicleID(playerid),ST[0],ST[1],ST[2]);
return floatround(1.61*floatsqroot(floatpower(floatabs(ST[0]), 2.0) + floatpower(floatabs(ST[1]), 2.0) + floatpower(floatabs(ST[2]), 2.0)) * 100.3);
}
public ShiftFunction(playerid)
{
if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
static
    Float: Speed,
    string[24],
   veh,
   model;
veh = GetPlayerVehicleID(playerid),
model = GetVehicleModel(veh);
if(model == 481 || model == 510 || model == 509) return 1; // Motorok
Loop(x, 5) TextDrawShowForPlayer(playerid, General
  • );

if(!IsVehicleDrivingBackwards(veh))
{
   Speed = GetSpeed(playerid);
   format(string, sizeof(string), \"%0.0f ~w~km/h\", Speed);
   TextDrawSetString(Speedo[playerid], string);
   TextDrawShowForPlayer(playerid, Speedo[playerid]);
   TextDrawShowForPlayer(playerid, GearInfo[playerid]);
   switch(cGear[veh])
   {
      case 6:
      {
         if(Speed > 180)
          {
              Loop(s, 6) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=6;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~6\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
            return 1;
         }
         else if(Speed > 165)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 5) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=5;
            warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~6\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 160)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 4) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=4;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~6\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 155)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 3) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=3;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~6\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 150)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 2) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=2;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~6\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 130)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 1) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=1;
              warn[veh]=0;
                TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~6\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed < 130)
          {
              warn[veh]++;
             if(warn[veh]==20)
             {
               cGear[veh]--;
               warn[veh]=0;
            }
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 1) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=1;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~g~~h~N ~w~6\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
      }
      case 5:
      {
         if(Speed > 150)
          {
              Loop(s, 6) TextDrawShowForPlayer(playerid, Gear);
             warn[veh]++;
             if(warn[veh]==15)
             {
               cGear[veh]++;
               SlowenVehicle(veh, 1.5);
               warn[veh]=0;
            }
            gul[veh]=6;
            TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~5\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 135)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 5) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=5;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~5\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 130)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 4) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=4;
            warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~5\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 125)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 3) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=3;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~5\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 120)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 2) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=2;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~5\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed < 120)
          {
              warn[veh]++;
             if(warn[veh]==20)
             {
               cGear[veh]--;
               warn[veh]=0;
            }
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 1) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=1;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~g~~h~N ~w~5\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
      }
      case 4:
      {
         if(Speed > 120)
          {
              Loop(s, 6) TextDrawShowForPlayer(playerid, Gear);
             warn[veh]++;
             if(warn[veh]==15)
             {
               cGear[veh]++;
               SlowenVehicle(veh, 1.5);
               warn[veh]=0;
            }
            gul[veh]=6;
            TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~4\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 110)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 5) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=5;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~4\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 105)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 4) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=4;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~4\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 100)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 3) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=3;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~4\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 90)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 2) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=2;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~4\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed < 90)
          {
              warn[veh]++;
             if(warn[veh]==20)
             {
               cGear[veh]--;
               warn[veh]=0;
            }
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 1) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=1;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~g~~h~N ~w~4\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
      }
      case 3:
      {
         if(Speed > 90)
          {
              Loop(s, 6) TextDrawShowForPlayer(playerid, Gear);
             warn[veh]++;
             if(warn[veh]==15)
             {
               cGear[veh]++;
               SlowenVehicle(veh, 1.5);
               warn[veh]=0;
            }
            gul[veh]=6;
            TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~3\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 80)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 5) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=5;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~3\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 75)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 4) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=4;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~3\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 70)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 3) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=3;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~3\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 60)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 2) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=2;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~3\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed < 60)
          {
              warn[veh]++;
             if(warn[veh]==20)
             {
               cGear[veh]--;
               warn[veh]=0;
            }
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 1) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=1;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~g~~h~N ~w~3\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
      }
      case 2:
      {
         if(Speed > 60)
          {
              Loop(s, 6) TextDrawShowForPlayer(playerid, Gear);
             warn[veh]++;
             if(warn[veh]==15)
             {
               cGear[veh]++;
               SlowenVehicle(veh, 1.5);
               warn[veh]=0;
            }
            gul[veh]=6;
            TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~2\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 50)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 5) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=5;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~2\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 45)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 4) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=4;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~2\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 40)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 3) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=3;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~2\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 30)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 2) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=2;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~2\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed < 30)
          {
              warn[veh]++;
             if(warn[veh]==20)
             {
               cGear[veh]--;
               warn[veh]=0;
            }
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 1) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=1;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~g~~h~N ~w~2\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
      }
      case 1:
      {
          if(Speed > 30)
          {
              Loop(s, 6) TextDrawShowForPlayer(playerid, Gear);
             warn[veh]++;
             if(warn[veh]==15)
             {
               cGear[veh]++;
               SlowenVehicle(veh, 1.5);
               warn[veh]=0;
            }
            gul[veh]=6;
            TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~1\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 20)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 5) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=5;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~1\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 15)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 4) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=4;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~1\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 10)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 3) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=3;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~1\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 5)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 2) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=2;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~w~N ~g~~h~1\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         else if(Speed > 0)
          {
              Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
              Loop(s, 1) TextDrawShowForPlayer(playerid, Gear);
              gul[veh]=1;
              warn[veh]=0;
              TextDrawSetString(GearInfo[playerid], \"~w~R ~g~~h~N ~w~Állsz\"), TextDrawShowForPlayer(playerid, GearInfo[playerid]);
                    return 1;
         }
         }
   }
}
else
{
    cGear[veh]=1;
   Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
            TextDrawSetString(GearInfo[playerid], \"~g~~h~R ~w~N D\");
            TextDrawSetString(Speedo[playerid], \"- ~w~km/h\");
            TextDrawShowForPlayer(playerid, Speedo[playerid]);
   TextDrawShowForPlayer(playerid, GearInfo[playerid]);
            return 1;
}
}
else
{
Loop(x, 5) TextDrawHideForPlayer(playerid, General
  • );

TextDrawHideForPlayer(playerid, Speedo[playerid]);
TextDrawHideForPlayer(playerid, GearInfo[playerid]);
Loop(s, 6) TextDrawHideForPlayer(playerid, Gear);
}
return 1;
}
 
stock IsVehicleDrivingBackwards(vehicleid) // By Joker
{
static
Float:Float[3]
;
if(GetVehicleVelocity(vehicleid, Float[1], Float[2], Float[0]))
{
GetVehicleZAngle(vehicleid, Float[0]);
if(Float[0] < 90)
{
   if(Float[1] > 0 && Float[2] < 0) return true;
}
else if(Float[0] < 180)
{
   if(Float[1] > 0 && Float[2] > 0) return true;
}
else if(Float[0] < 270)
{
   if(Float[1] < 0 && Float[2] > 0) return true;
}
else if(Float[1] < 0 && Float[2] < 0) return true;
}
return false;
}
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(newstate == PLAYER_STATE_DRIVER) cGear[GetPlayerVehicleID(playerid)]=1;
return 1;
}
stock SlowenVehicle(vid,Float:howmuch)
{
    static Float:T[3];
GetVehicleVelocity(vid, T[0], T[1], T[2]);
    return
   SetVehicleVelocity(vid,T[0] / howmuch , T[1] / howmuch , T[2]);
}
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
    if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
    {
    new veh = GetPlayerVehicleID(playerid);
if(newkeys & GEAR_KEY)
{
    if(cGear[veh] !=6)
    {
               if(gul[veh] == 4 || gul[veh] == 5)
      {
         cGear[veh]++;
         gul[veh]=1;
         warn[veh]=0;
      }
               else if(gul[veh] == 6 || gul[veh] == 3)
               {
                   cGear[veh]++;
                   warn[veh]=0;
                   gul[veh]=1;
                   SlowenVehicle(veh,1.3);
      }
   }
}
}
return 1;
}

Oldalak: 1 2 [3] 4 5 6
SimplePortal 2.3.7 © 2008-2024, SimplePortal