Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.

Wysłany: 2018-03-18, 00:22


IgorPL222

LUA






Wiek: 26
Na forum: 3112 dni
Posty: 133
Nick w MP: mxgvr

Piwa: 746

Respekt: 55,3

Witam, ostatnio bawi?em si? handlingiem na serwerze, i troszeczk? popsu?em wszystkie auta.
Jak mog? przywr?ci? do wszystkich pojazd?w domy?lny handling.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2018-03-18, 08:44


TeeNekk

Cienzaruwka :v






Wiek: 23
Na forum: 3210 dni
Posty: 264
Nick w MP: TeeNekk.

Piwa: 919

Respekt: 110,5
Respekt: 110,5

Najlepiej jakby? pokaza? kod.

Podpis
Pomogłem Ci
? Może zostawiłbyś za to piwko, lub respekt? Dzięki!
Mój projekt:
?
Postaw piwo autorowi tego posta
 

 
Więcej szczegółów
Wystawiono 1 piw(a):
IgorPL222
Wysłany: 2018-03-18, 10:10


Ciastuuś

Truck soon...






Wiek: 26
Na forum: 3071 dni
Posty: 799
Nick w MP: Ciastuuś

Piwa: 4297

Respekt: 640
Respekt: 640Respekt: 640

To ju? zale?y. Mo?esz zrestartowa? zas?b od pojazd?w, albo w najgorszym b?d? razie opr??ni? tabel? z pojazdami, a je?eli tworzy si? w ka?dym poje?dzie, nawet nowo zakupionym to ju? musisz co? pomy?le?.

Podpis
Truck soon...
Postaw piwo autorowi tego posta
 

 
Więcej szczegółów
Wystawiono 1 piw(a):
IgorPL222
Wysłany: 2018-03-18, 17:54


IgorPL222

LUA






Wiek: 26
Na forum: 3112 dni
Posty: 133
Nick w MP: mxgvr

Piwa: 746

Respekt: 55,3

Oto kod:


-- klasy aut

-- auta

--? - lx

local class_d_vehicles = {
{"Uranus"},
{"Flash"},
{"Euros"},
{"Alpha"},
{"Feltzer"},
{"Hustler"},
{"Hotknife"}, --UNIKAT
{"Phoenix"}, --UNIKAT
{"Windsor"}, --UNIKAT
{"Super GT"},
{"Comet"},
{"Jester"},
{"ZR-350"},
}

local class_f_vehicles = {
{"Infernus"},
{"Turismo"},
{"Stretch"},
}

local class_lvpd_vehicles = {
{"Police LV"},
}

local class_e_vehicles = {
{"Banshee"},
{"Bullet"},
{"Elegy"},
{"Sultan"},
{"Cheetah"},
}

local class_c_vehicles = {
{"Burrito"},
{"Yosemite"},
{"Blista Compact"},
{"Stallion"},
{"Sabre"},
{"Clover"},
{"Sentinel"},
{"Admiral"},
{"BF Injection"},
{"VooDoo"},
{"Police Ranger"},
{"Dune"}, --UNIKAT
{"Monster 1"}, --UNIKAT
{"Bandito"}, --UNIKAT
}

local class_b_vehicles = {
{"Picador"},
{"Virgo"},
{"Fortune"},
{"Esperanto"},
{"Buccaner"},
{"Oceanic"},
{"Glendale"},
{"Willard"},
{"Vincent"},
{"Landstalker"},
{"Rancher"},
{"Mesa"},
}

local class_a_vehicles = {
{"Moonbeam"},
{"Bobcat"},
{"Walton"},
{"Sadler"},
{"Previon"},
{"Intruder"},
{"Regina"},
}

local class_l_vehicles = {
{"Remington"},
{"Blade"},
{"Savanna"},
{"Tornado"},
{"Tahoma"},
}

local class_m_vehicles = {
{"Faggio"},
{"Quadbike"},
}

local class_m2_vehicles = {
{"Freeway"},
{"Wayfarer"},
{"Sanchez"},
}

local class_m3_vehicles = {
{"PCJ-600"},
{"BF-400"},
{"HPV1000"},
}

local class_s_vehicles = {
{"Journey"},
{"Camper"},
}

-- handlingi

local handlings = {
{"mass"},
{"turnMass"},
{"dragCoeff"},
{"centerOfMass"},
{"percentSubmerged"},
{"tractionMultiplier"},
{"tractionLoss"},
{"tractionBias"},
{"numberOfGears"},
{"maxVelocity"},
{"engineAcceleration"},
{"engineInertia"},
{"driveType"},
{"engineType"},
{"brakeDeceleration"},
{"brakeBias"},
{"ABS"},
{"steeringLock"},
{"suspensionForceLevel"},
{"suspensionDamping"},
{"suspensionHighSpeedDamping"},
{"suspensionUpperLimit"},
{"suspensionLowerLimit"},
{"suspensionFrontRearBias"},
{"suspensionAntiDiveMultiplier"},
{"seatOffsetDistance"},
{"collisionDamageMultiplier"},
{"monetary"},
{"modelFlags"},
{"handlingFlags"},
{"headLight"},
{"tailLight"},
{"animGroup"},
}

local class_d_handling = {engineAcceleration=33,maxVelocity=201} --240
local class_c_handling = {engineAcceleration=29,maxVelocity=185} --220
local class_lvpd_handling = {engineAcceleration=24,maxVelocity=185} --220
local class_b_handling = {engineAcceleration=16,maxVelocity=150} --180
local class_a_handling = {engineAcceleration=11,maxVelocity=135} --160
local class_l_handling = {engineAcceleration=20,maxVelocity=176} --210
local class_m_handling = {engineAcceleration=15,maxVelocity=100}
local class_m2_handling = {engineAcceleration=46,maxVelocity=171} --204
local class_m3_handling = {engineAcceleration=65,maxVelocity=201} --240
local class_s_handling = {engineAcceleration=14,maxVelocity=134} --120

local class_f_handling = {engineAcceleration=65,maxVelocity=301} --360
local class_e_handling = {engineAcceleration=14,maxVelocity=134} --120

for i,v in ipairs(class_f_vehicles) do
    for k,x in ipairs(handlings) do
        if class_f_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_f_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_e_vehicles) do
    for k,x in ipairs(handlings) do
        if class_e_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_e_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_d_vehicles) do
    for k,x in ipairs(handlings) do
        if class_d_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_d_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_c_vehicles) do
    for k,x in ipairs(handlings) do
        if class_c_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_c_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_lvpd_vehicles) do
    for k,x in ipairs(handlings) do
        if class_lvpd_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_lvpd_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_b_vehicles) do
    for k,x in ipairs(handlings) do
        if class_b_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_b_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_a_vehicles) do
    for k,x in ipairs(handlings) do
        if class_a_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_a_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_l_vehicles) do
    for k,x in ipairs(handlings) do
        if class_l_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_l_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_m_vehicles) do
    for k,x in ipairs(handlings) do
        if class_m_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_m_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_m2_vehicles) do
    for k,x in ipairs(handlings) do
        if class_m2_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_m2_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_m3_vehicles) do
    for k,x in ipairs(handlings) do
        if class_m3_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_m3_handling[x[1]])
        end
    end
end

for i,v in ipairs(class_s_vehicles) do
    for k,x in ipairs(handlings) do
        if class_s_handling[x[1]] and getVehicleModelFromName(v[1]) then
             setModelHandling(getVehicleModelFromName(v[1]), x[1], class_s_handling[x[1]])
        end
    end
end

--

local getCustomsVehicles = {
[526] = "Centauro", 
[529] = "Imponte",
[467] = "Cabbie",
}

function getVehicleCustomName(model)
    if getCustomsVehicles[modelthen
        return getCustomsVehicles[model]
    end
    return getVehicleNameFromModel(model)
end


[ Dodano: 2018-03-18, 18:55 ]
Dobra, poradzi?em sobie. Napisa?em skrypt kt?ry zeruje w ka?dym aucie hand. Za pomoc daje piwko!

Podpis
discord: mxgvr
Postaw piwo autorowi tego posta
 

 
Tagi: nieudana :: zabawa :: handlingiem
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA Ten temat jest zablokowany bez możliwości zmiany postów lub pisania odpowiedzi

Nie możesz pisać nowych tematów
Nie możesz odpowiadać w tematach
Nie możesz zmieniać swoich postów
Nie możesz usuwać swoich postów
Nie możesz głosować w ankietach
Dodaj temat do Ulubionych
Wersja do druku