Prosze powiedzcie mi co tu jest zle bo nie mam sil (chcialbym aby na komende /praca usuwaly sie te wszystkie elementy)
function praca ( praca )
if getElementData(source,"AGJob") == "postman" then
local player = getPlayerFromName(getElementData(source,"JobOwner"))
if isElement(ptVehicle[player]) then
destroyElement(ptVehicle[player])
end
if isElement(ptVehicleBlip[player]) then
destroyElement(ptVehicleBlip[player])
end
if isElement(ptJobMarker[player]) then
destroyElement(ptJobMarker[player])
end
if isElement(ptJobBlip[player]) then
destroyElement(ptJobBlip[player])
end
if isElement(newMarker[player]) then
destroyElement(newMarker[player])
end
if isElement(nMBlip[player]) then
destroyElement(nMBlip[player])
end
ptNumber[player] = nil
setElementData(player,"AGJob",nil)
setElementModel (player, "0",nil)
end
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