Mr.Loki

Members
  • Content count

    500
  • Joined

  • Last visited

  • Days Won

    3

Mr.Loki last won the day on September 16

Mr.Loki had the most liked content!

Community Reputation

102 Excellent

About Mr.Loki

  • Rank
    Playa Partner
  • Birthday 04/08/93

Details

  • Gang
    Top KeK
  • Location
    Trinidad
  • Occupation
    Pilot
  • Interests
    Give me an apple... and I'll eat it!

Recent Profile Visitors

1,617 profile views
  1. [Help]problems with CarSell

    local sellMarker = createMarker( -1545.0999755859, 126.80000305176, 2.5, "cylinder", 22, 255, 0, 0, 120) local myBlip = createBlip( -1545.0999755859, 126.80000305176, 3.5999999046326, 55, 1.5, 255, 0, 255, player ) function sellVehicle(player) if (getElementType(player) == "player") then if (not getPedOccupiedVehicle(player)) then outputChatBox("You need to be in a Vehicle to sell it.", player, 255, 0, 0) return end local vehicle = getPedOccupiedVehicle(player) local prices = math.random(4000, 10000) givePlayerMoney(player, prices) outputChatBox("You have sold the "..getVehicleName(vehicle).. " for "..prices.."!", player, 0, 255, 0 ) setVehicleLocked ( vehicle, true ) removePlayerFromVehicle ( player ) setTimer(function(veh) respawnVehicle(veh) setVehicleLocked(veh,false) end,5000,1,vehicle) end end end addEventHandler("onMarkerHit",sellMarker, sellVehicle, carRespawn)
  2. [HELP]Random Spawn

    Create a table with with spawn points then just spawn the forms randomly with it.
  3. setElementData

    You need to read and modify the data before overwriting it getElementData Modify the table and add new stuff Then setData
  4. [Question] Animating dxDrawMaterialLine3D

    Try this local size = 1 local img = point(100,-1) local rot = 0 function createIMG(dt) local x,y,z = getElementPosition( localPlayer ) local rx = math.sin(rot)*size local rz = math.cos(rot)*size dxDrawMaterialLine3D( x-rx, y, 1+z-rz, x+rx, y, 1+z+rz, img, size*2, -1, x, y+1, 1+z ) rot = rot +(.01*dt/17) end addEventHandler("onClientPreRender", root, createIMG)
  5. [Question] Animating dxDrawMaterialLine3D

    For it to rotate you need to use the lookAt args and and use sine and cosine to rotate around the x and y. Also the way u calculated the size made the image oval and i fixed that. local size = 3 local img = point(500,-1) local rot = 0 function createIMG() local x,y,z = local rx = math.sin(rot)*1 local ry = math.cos(rot)*1 dxDrawMaterialLine3D( x, y, z, x, y, z+size, img, size, -1, x+rx, y+ry, z ) rot = rot +.01 end addEventHandler("onClientRender", root, createIMG)
  6. Timer

    Store the timer in a table for each player for example Table[player]= Timer(function ()end,3000,1) And to check you simply do if isTimer(Table[player]) then Output you deny message else Let them in end
  7. [QUESTION] Possible convert Vice City map to MTA?

    Yes check the mapping section of the forums
  8. [HELP] Browser

    That's because there are other domains that the site uses for resources like media. Use this event to capture all of them that were blocked and store them in a table somewhere Then requestBrowserDomains of that table with the blocked domains You may need to refresh and repeat before all domains can be unblocked so save them somewhere and when someone tries to go to that site in the server use the request domains function and send a table of all the domains that should be whitelisted.
  9. [HELP] Browser

    Yeah you can but you'd need to whitelist a bunch of domains that the site uses.
  10. Help Me!!

  11. creating vehicle

    You will need to use triggerServerEvent and create the vehicle on the server then you can use warpPedIntoVehicle to teleport the player instantly into the vehicle on creation.
  12. Clickable dx rectangle/text

    You need to add the dxVisible var to your clicking event so it only executes if dxVisible is true. Like this: function onClick(button, state) if dxVisible and (button == "left") and (state == "up") then -- check if dx-rectangle is showing here if isMouseInPosition( 490, 284, 116, 47 ) then outputChatBox ( "Машина заспавнена!" ) --car spawn createVehicle(434,x,y,z) y = y + 5 elseif isMouseInPosition( 737, 284, 116, 47 ) then outputChatBox ( "Вы сменили скин!" ) --skin change setElementModel ( player, 25) end end end addEventHandler( "onClientClick", root, onClick )
  13. Why this show all clients`?

    Why are you checking if the localPlayer is the localPlayer ._. localPlayer can only be localPlayer ._______. Are you getting any errors in the debug when you restart the script? /debugscript 3
  14. Help me

    The function dxDrawImage3D is a Useful/Custom function meaning you need to add this function to your code for it to work. Also use the code button <> when posting code. local white = tocolor(255,255,255,255) function dxDrawImage3D(x,y,z,w,h,m,c,r,...) local lx, ly, lz = x+w, y+h, (z+tonumber(r or 0)) or z return dxDrawMaterialLine3D(x,y,z, lx, ly, lz, m, h, c or white, ...) end local face = dxCreateTexture("weed.png") addEventHandler("onClientRender", root, function() dxDrawImage3D(-2410.76001, -600.35828, 132.64066, face, tocloro(255,255,255,255)) end )
  15. Railroad crossings

    Without more info/code we can't help you...