SerweryWłasny serwerDla twórcówForumFAQDokumentacjaBezpieczeństwo
Pobierz launcher
  1. Dokumentacja
  2. Funkcje wspólne
  3. isElementWithinColShape

Funkcja

isElementWithinColShape

Serwer i klientElementyIdentyczna z MTA:SA

Sprawdza, czy element jest teraz w strefie kolizji.

Składnia

bool isElementWithinColShape(element theElement, colshape theShape)

Argumenty

theElementelement
Element.
theShapecolshape
Strefa.

Zwraca

true, jeśli w strefie.

Przykład

addCommandHandler("kup", function(player)
    if not isElementWithinColShape(player, shopZone) then
        outputChatBox("Musisz być w sklepie.", player, 255, 0, 0)
        return
    end
end)

Zobacz też