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

Wysłany: 2017-02-21, 06:30


xluq







Wiek: 30
Na forum: 3411 dni
Posty: 64
Nick w MP: SagaPlayer8912

Piwa: 3

Respekt: 80

Hej, wie kto? jak zrobi? handling do samochodu? rpg, bo se wgra?em podmianke tesli pod sunrise, i chce zmieni? handling sunrise'a ale nie wiem jak ;/

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-02-21, 12:44


amited







Wiek: 26
Na forum: 3714 dni
Posty: 1233
Nick w MP: Amited

Piwa: 512

Respekt: 466
Respekt: 466

Mo?esz przez panel admina na serverze albo u?y? tego:

Więcej informacji znajdziesz w Wikipedii MTA:

SetVehicleHandling


Podpis
"amited" napisał/a:
Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-02-21, 13:51


_Haze

Peace Yo!






Wiek: 24
Na forum: 4184 dni
Posty: 1648
Nick w MP: Haze

Piwa: 2628

Respekt: 1020
Respekt: 1020

xLuq1337, masz tu jeszcze przydatn? funkcje z wiki
function getVehicleHandlingProperty elementproperty )
    if isElement element ) and getElementType element ) == "vehicle" and type property ) == "string" then -- Make sure there's a valid vehicle and a property string
        local handlingTable = getVehicleHandling ( element ) -- Get the handling as table and save as handlingTable
        local value = handlingTable[property] -- Get the value from the table
        
        if value then -- If there's a value (valid property)
            return value -- Return it
        end
    end
    
    return false -- Not an elementnot a vehicle or no valid property string. Return failure
end
pobierzesz np mase i mo?esz dac +200
Więcej informacji znajdziesz w Wikipedii MTA:

setVehicleHandling


Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-02-21, 14:10


xluq







Wiek: 30
Na forum: 3411 dni
Posty: 64
Nick w MP: SagaPlayer8912

Piwa: 3

Respekt: 80

A moglby ktos dac jaki skrypt ze np. wpisuje id/nazwe danego pojazdu i poprostu handling? daje piwo + moge zrobic grafike

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-02-21, 14:20


_Haze

Peace Yo!






Wiek: 24
Na forum: 4184 dni
Posty: 1648
Nick w MP: Haze

Piwa: 2628

Respekt: 1020
Respekt: 1020

xLuq1337,

function vhandling ( )
   for _,v in pairs(getElementsByType("vehicle")) do
      if getElementModel(v) == 411 then -------------- id samochodu
        setVehicleHandling (v"mass"300.0)-- dajesz handling masy
        setVehicleHandling(v"turnMass"200) -- dajesz handling turnmasy
      elseif getElementModel(v) == jakiesid then 
      end
   end
end
addEventHandler "onPlayerVehicleEnter"rootvhandling )-- jak wejdziesz do auta daje handling

dodajesz tylko linijki setVehicleHandling (v, "handlingjakis", wartosc) i zmieniasz sobie id a jak chcesz inne auta doda? to elseif getElementModel(v) == jakiesid then tak jak masz wy?ej i zn?w zmieniasz

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-02-22, 15:47


amited







Wiek: 26
Na forum: 3714 dni
Posty: 1233
Nick w MP: Amited

Piwa: 512

Respekt: 466
Respekt: 466

xLuq1337, ID ale ?e id pojazdu z gta czy id nadane przez elementDat??

Podpis
"amited" napisał/a:
Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-02-22, 19:17


mixLoLmix2

Programista






Wiek: 35
Na forum: 4113 dni
Posty: 454
Nick w MP: TomeQmix

Piwa: 1915

Respekt: 47,3

ID gta

Podpis
Zajmuję się pisaniem zaawansowanych skryptów lua na zamówienie za bardzo niską cene.
Oraz pomoc przy serwerze mta/forum i tym podobnych.
Discord: TomeQmix#7106
Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-02-22, 21:48


amited







Wiek: 26
Na forum: 3714 dni
Posty: 1233
Nick w MP: Amited

Piwa: 512

Respekt: 466
Respekt: 466

Dam ci kod, w kt?rym kiedy wpiszesz /daj to do pojazdu w kt?rym siedzisz dodany zostanie handling. Id handlingu masz na wiki.

function dajTune(plr,cmd,idTune)
if not idTune then outputChatBox("* U?yj /daj <id tune>",plr) return end
local veh getPedOccupiedVehicle(plr)
if not veh then return end
addVehicleUpgrade(veh,idTune)
end
addCommandHandler("daj",dajTune)


Podpis
"amited" napisał/a:
Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-02-23, 13:09


MrDadosz







Wiek: 27
Na forum: 5652 dni
Posty: 33
Nick w MP: Damian_Red, MrDadosz

Piwa: 11

Respekt: 120
Respekt: 120

Naj?atwiej Ci b?dzie u?y? hedita, proste w u?yciu, wszystko w GUI: https://community.multitheftauto.com/index.php?p=resources&s=details&id=3716

Postaw piwo autorowi tego posta
 

 
Tagi: handling
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA » Handling 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