Jump to content

Spc

Members
  • Posts

    46
  • Joined

  • Last visited

Everything posted by Spc

  1. I don't want to use Slothbot.
  2. local sound function playBackgroundSound() if sound and isElement(sound) then stopSound(sound) end local hour,minutes = getTime( ) if hour >= 6 and hour < 12 then sound = playSound ( "day.mp3" ) elseif ( hour >= 12 ) and ( hour < 15 ) then sound = playSound ( "day.mp3" ) elseif ( hour >= 15 ) and ( hour < 20 ) then sound = playSound ( "night.mp3" ) elseif ( hour >= 20 ) and ( hour < 24 ) then sound = playSound ( "night.mp3" ) end end setTimer(playBackgroundSound, 600000, 0) setTimer(playBackgroundSound, 500, 1) Try.
  3. Hey, I want to make a ped attacking player when he will be close to him. Any idea?
  4. I have a bug with trailers (screenshot). On my player's camera the trailer looks normal, but everyone else can see the bugged trailer. Is it MTA bug or something?
  5. I solved it. function job_trailerAttach(veh) cancelEvent() local x, y, z = getElementPosition(veh) local x2, y2, z2 = getElementPosition(source) local _,_,rz=getElementRotation(veh) local rrz=math.rad(rz) local x= x + (2 * math.sin(-rrz)) local y= y + (2 * math.cos(-rrz)) detachTrailerFromVehicle(veh, source) setElementPosition(veh, x, y, z) setElementPosition(source, x2, y2, z2) end addEventHandler("onTrailerAttach", getRootElement(), job_trailerAttach) Thank you all for help.
  6. Probably yes. But i want to disable attaching. Nonstop attaching / dettaching attach is not my goal.
  7. I still can attach to the trailer.
  8. It's not it.The trailer is attaching and dettaching nonstop.
  9. Hey, I've got a problem. function job_trailerAttach(veh) cancelEvent() end addEventHandler("onTrailerAttach", getRootElement(), job_trailerAttach) I want to "turn off" the trailer attaching, but cancelEvent() didn't work. There's any solution?
  10. I have problem with players. On my server player ped is like "a shadow". SS: screensht. It happens when I run my server files. If they're off and e.g. I run "play" this error doesn't appear. Where is the problem? Spawn? GUI? (sorry for my bad english :p)
  11. Sorry for my English. I wonder how to do an countdown timer? Eg from 2 minutes. Thanks in advance.
  12. Spc

    Reaction test script

    I want to make the players write the result on the chat.
  13. Hey, I;m wondering how to do reaction test script? Any tips? E.g. thanks in advance
  14. I don't want to slow down the game. I want decrease the player's speed
  15. I'm trying to decrease the player's speed, however I'm not any successful. I want the player to always move at the speed I set. So always when the move. Is it somehow possible to make that when a player moves, he moves at an decreased speed?
×
×
  • Create New...