| Tematy otagowane jako: nieniszczenie |
| 1. Nieniszczenie się pojazdu |
Witam, mam problem ze skryptem MIKELmta, ot?? jego skrypt nie dzia?a na moim serwerze. Jest dodany do acl, Jednak przy zaci?gni?tym r?cznym i tak da si? rozwala? pojazd zar?wno r?k? jak i innym pojazdem. Jak to naprawi? Prosz? o pomoc. Za pomoc i
Dodam ?e u?ywam systemu pojazd?w OGRPG.
Kod:
[lua]
local function pojazdPusty(veh)
local occupants = getVehicleOccupants(veh)
local seats = getVehicleMaxPassengers(veh)
if (not seats) then return true end
for i=0,seats do
local occupant = occupants[seat]
if occupant and (getElementType(occupant)=="player" or getElementType(occupant)=="ped") then
return false
end
end
return true
end
for i,v in ipairs(getElementsByType("vehicle")) do
if (pojazdPusty(v)) then
setVehicleDamageProof(v,true)
else
if getElementData(v,"damageproof") then setVehicleDamageProof(v, true) return end
setVehicleDamageProof(v,false)
end
end
addEventHandler ( "onVehicleEnter", root, function()
if getElementData(source,"damageproof") then setVehicleDamageProof(source, true) return end
setVehicleDamageProof(source, false)
end)
addEventHandler ( "onVehicleExit", root, function()
if (pojazdPusty(source)) then
setVehicleDamageProof(source, true)
else
if getElementData(source,"damageproof") then setVehicleDamageProof(source, true) return end
setVehicleDamage... |
| 2. [SKRYPT] Nieniszczenie się pojazd |
Hej, cze??, siemanko Mam dla Was skrypt, kt?ry polega na tym, ?e gdy wyjdziemy z auta lub kogo? w nim nie ma to auto si? nie niszczy. Gdy wejdziemy ju? mo?e si? niszczy?. Przydatny pod RPG !
Ukryta wiadomość / Hidden message(aby ją zobaczyć musisz postawić użytkownikowi) | | Wiadomość została ukryta, aby ją przeczytać należy się zalogować. | |
|