- Dokumentacja
- Funkcje wspólne
- getElementType
Funkcja
getElementType
Zwraca typ elementu, np. "player", "vehicle", "ped", "object". Elementy GUI mają typy z przedrostkiem "gui-".
Składnia
string getElementType(element theElement)Argumenty
theElementelement- Element.
Zwraca
Typ albo false.
Przykład
addEventHandler("onPlayerDamage", root, function(attacker)
if attacker and getElementType(attacker) == "vehicle" then
outputChatBox("Potrącił cię pojazd!", source)
end
end)