Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 06/11/20 in all areas

  1. local last_button_action = 0 function onClientKey(button, pressOrRelease) if not pressOrRelease then return end local boundKeys = getBoundKeys("vehicle_secondary_fire") if not boundKeys then return end if not boundKeys[button] then return end local tick = getTickCount() if tick - last_button_action < 500 then cancelEvent() return end last_button_action = tick end addEventHandler("onClientKey", root, onClientKey) This will limit the vehicle_secondary_fire control to once every 500 ms, it should be enough to block the super jump on bike. This applies to all vehicles, so you will need to check for vehicle type if you want to limit it to bikes. I used onClientKey because I can't find a smarter way. An alternative is binding a function to the vehicle_secondary_fire keys, but the user can change his binds midways and you would have to check for that at some interval.
    1 point
  2. local gate = createObject (16775, 2532, -1514.5999755859, 27.10000038147, 0, 0, 0) local marker = createMarker (2532, -1514.5999755859, 27.10000038147, "cylinder", 8, 0, 0, 0, 0) function moveGate (thePlayer) local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) if isObjectInACLGroup ("user."..accName, aclGetGroup ( "CV" ) ) then moveObject(gate, 1900, 2532, -1.514,5999755859, 18,89999961853) end end addEventHandler ( "onMarkerHit", root, moveGate ) function move_back_gate () moveObject(gate, 1900, 2532, -1514.5999755859, 27.10000038147, 0, 0, 0) end addEventHandler ("onMarkerLeave", root, move_back_gate) tenta isso, lembrando que você deve estar na acl CV
    1 point
  3. Thread moved to the Scripting forum for best results. Scripting Tutorials forum is for user-made tutorials aimed to teach others.
    1 point
  4. عمل جميل ? استمر وبالتوفيق .
    1 point
  5. function skate2(_, newModel) if (newModel == 99) or (newModel == 92) and (getElementType(source) == "player") then setPedWalkingStyle(source, 138) end end addEventHandler("onElementModelChange", root, skate2)
    1 point
×
×
  • Create New...