231

Members
  • Content Count

    29
  • Joined

  • Last visited

Community Reputation

0 Neutral

About 231

  • Rank
    Advanced Member

Recent Profile Visitors

353 profile views
  1. 231

    Warp player to

    Thanks everyone server.lua:3: Bad argument @ 'getElementPosition' [Expected element at argument 1, got string 'easr'] server.lua:5: attempt to perform arithmetic on local 'posX' (a boolean value)
  2. 231

    Warp player to

    addCommandHandler("easr",function(_, player) players = getElementsByType ( "player" ) for i,v in ipairs(players) do setElementPosition ( source, posX, posY, posZ ) end end) What can be my fault I want to attract all players
  3. 231

    Warp player to

    I want to bring all players on the server with command
  4. 231

    Help me

    local function getPedsOnScreen() local peds = {} for key, ped in ipairs(getElementsByType("ped", root, true)) do if isElementOnScreen(ped) then table.insert(peds, ped) end end return peds end local function dxDrawLinedRectangle(posX, posY, height, width, angleAmount, color, postGUI) radius = height or 50 width = width or 5 angleAmount = angleAmount or 1 color = color or tocolor(255, 255, 255, 200) postGUI = postGUI or false function dxDrawLinedRectangle( x, y, width, height, color, _width, postGUI ) _width = _width or 1 dxDrawLine ( x, y, x+width, y, color, _width, postGUI ) -- Top dxDrawLine ( x, y, x, y+height, color, _width, postGUI ) -- Left dxDrawLine ( x, y+height, x+width, y+height, color, _width, postGUI ) -- Bottom return dxDrawLine ( x+width, y, x+width, y+height, color, _width, postGUI ) -- Right end return true end local function findRotation(x1,y1,x2,y2) local t = -math.deg(math.atan2(x2-x1,y2-y1)) if t < 0 then t = t + 360 end; return t; end local function sortbyrot(a, b) local _, _, rz = getElementRotation(localPlayer) local x, y = getElementPosition(localPlayer) local ax, ay = getElementPosition(a) local bx, by = getElementPosition(b) local arz = findRotation(x, y, ax, ay) arz = math.abs(rz - arz) local brz = findRotation(x, y, bx, by) brz = math.abs(rz - brz) return arz < brz end addEventHandler("onClientRender", root, function() local weapon = getPedWeapon(localPlayer) if weapon and weapon > 0 then local peds = getPedsOnScreen() if #peds > 0 then table.sort(peds, sortbyrot) local chosen = peds[1] local hx, hy, hz = getPedBonePosition(chosen, 6) local sx, sy = getScreenFromWorldPosition(hx, hy, hz) if sx then dxDrawLinedRectangle(sx, sy) end end end end) client.lua/21.attempt to perform arithmetic on local width a nil value mta
  5. 231

    Auto aim to command

    local x, y, z = getElementPosition(getLocalPlayer()) local dx, dy = guiGetScreenSize() aimX, aimY = dx * 0.54, dy * 0.3971 triggerServerEvent("AimOnPosition", resourceRoot) function AimOnPosition() local setToX, setToY = 0, 0 local hx, hy, hz = getPedBonePosition(Ped, 6) local sx, sy = getScreenFromWorldPosition(hx, hy, hz) setToX = math.abs(dx / 2 - (aimX)) setToY = math.abs(dy / 2 - aimY) local a1, a2, a3 = getPedBonePosition(Ped, 6) local a4, a5, a6 = getElementPosition(Ped) local b1, b2, b3 = getElementPosition(localPlayer) local dist = getDistanceBetweenPoints3D(a1, a2, a3, b1, b2, b3) -- here if isRifle then aimX = dx * 0.54 + (10 - dist * 0.2) -- maybe you will need to play around with 10 or *0.2 to get the right result. else aimX = dx * 0.54 end setToX, setToY = getWorldFromScreenPosition(sx - setToX, sy + setToY, dist) _, _, setToX1 = getWorldFromScreenPosition(dx / 2, dy / 2, dist) _, _, setToX2 = getWorldFromScreenPosition(aimX, aimY, dist) setToX3 = (setToX2 - setToX1) setCameraTarget(setToX, setToY, b3 - setToX3 + 0.2 + (a6 - b3)) end function drawStuff() if getControlState("aim_weapon") then AimOnPosition() end end addEventHandler("onClientRender", root, drawStuff) I want this to be a command for players on my server, help me
  6. 231

    Auto aim

    local x,y,z = getElementPosition( getLocalPlayer ()) local Ped = createPed(49,x,y,z) local dx,dy = guiGetScreenSize() aimX ,aimY = dx*0.54 , dy*0.3971 function AimOnPosition() local setToX,setToY = 0,0 local hx, hy, hz = getPedBonePosition(Ped, 6) local sx,sy = getScreenFromWorldPosition(hx,hy,hz) setToX = math.abs(dx/2-(aimX)) setToY = math.abs(dy/2-aimY) local a1,a2,a3 = getPedBonePosition(Ped, 6) local a4,a5,a6 = getElementPosition(Ped) local b1,b2,b3 = getElementPosition(localPlayer) local dist = getDistanceBetweenPoints3D(a1,a2,a3,b1,b2,b3) -- here if isRifle then aimX = dx*0.54 + (10 - dist*0.2) -- maybe you will need to play around with 10 or *0.2 to get the right result. else aimX = dx*0.54 end setToX,setToY = getWorldFromScreenPosition(sx-setToX,sy+setToY,dist) _,_,setToX1 = getWorldFromScreenPosition(dx/2,dy/2,dist) _,_,setToX2 = getWorldFromScreenPosition(aimX,aimY,dist) setToX3 = (setToX2 - setToX1) setCameraTarget(setToX,setToY,b3-setToX3+0.2 +(a6-b3)) end function drawStuff() if getControlState("aim_weapon") then AimOnPosition() end end addEventHandler("onClientRender", root, drawStuff) how can you do it for the players
  7. 231

    createProjectile

    must be activated (Flare from hydra)
  8. 231

    Aimbot Script

    up
  9. 231

    Spawn Kill

    thank you
  10. 231

    Spawn Kill

    I want to be immortal for 30 seconds when I'm dead
  11. 231

    Red V Blue

    How do I make these scripts
  12. 231

    AREA KİLL

    I want you to die outside a certain area