Multi Posted October 5, 2013 Posted October 5, 2013 Witam. mam taki kod addEventHandler("onMarkerHit", marker, function(he,md) if not md or getElementType(he)~="player" then return end local pojazd=getPedOccupiedVehicle(he) if not pojazd then return end if getVehicleController(pojazd)~=he then return end if getElementModel(pojazd)==530 then outputChatBox("Dostarczyles Drewno Dostales 150$", he) givePlayerMoney(he, 150) end end) Lecz potrzebowal bym jeszcze 1 funkcji jezeli np mam tego forklifta i ten forklift jest z drewnem na sobie dopiero da kase Jest taka funkcja ?? drewno robie w map editore i forklift moze je podnosic lecz nie znam funkcji na to ze jak fork lift z tym drewnem jest i wjedzie w marker to dostanie kase a jak jest bez drewna to nie dostanie.
Mefisto_PL Posted October 5, 2013 Posted October 5, 2013 A to drewno nie powinno przypadkiem działać przez "attachElements" albo przez bone attachowanie?
Wielebny Posted October 7, 2013 Posted October 7, 2013 Obiekt musi byc przyczepiony za pomocą attachElements - w przeciwnym przypadku nie masz możliwości wykrycia położenia obiektu który jest dynamiczny. Gotowca z przyczepianiem drewna do forklifta i kodem który wykrywa czy forklift wiezie drewno znajdziesz tu: https://github.com/lpiob/MTA-XyzzyRP/tr ... lss-tartak
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now