SerweryWłasny serwerDla twórcówForumFAQDokumentacjaBezpieczeństwo
Pobierz launcher
  1. Dokumentacja
  2. Funkcje serwera
  3. getVehicleRespawnPosition

Funkcja

getVehicleRespawnPosition

SerwerPojazdyIdentyczna z MTA:SA

Zwraca współrzędne miejsca, w którym pojazd pojawi się przy odrodzeniu.

Składnia

float, float, float getVehicleRespawnPosition(vehicle vehicle)

Argumenty

vehiclevehicle
Pojazd.

Zwraca

Trzy liczby x, y, z albo false.

Przykład

addCommandHandler("gdzieparking", function(player)
    local vehicle = getPedOccupiedVehicle(player)
    if not vehicle then return end
    local x, y, z = getVehicleRespawnPosition(vehicle)
    outputChatBox(("Parking: %.1f, %.1f, %.1f"):format(x, y, z), player)
end)

Zobacz też