Jump to content

T.P

Members
  • Posts

    2
  • Joined

  • Last visited

Details

  • Gang
    crotex

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

T.P's Achievements

I ordered some spaghetti with marinara sauce and I got egg noodles and ketchup. I'm an average nobody.

I ordered some spaghetti with marinara sauce and I got egg noodles and ketchup. I'm an average nobody. (2/54)

0

Reputation

  1. T.P

    HELP! Speedo meter

    How I would be able to make it how let png display a picture? dxDrawImage(x-110, y-175, nx-110, ny-175, "needle.png"(255, 0, 0, 255), true) Its not work...
  2. Hello everyone! a little help would be needed. there is a speedometer for me, but vainly rehearse to write the needle does not display it. Just line... function drawSpeedo() if active and not isPlayerMapVisible() then local vehicle = getPedOccupiedVehicle(getLocalPlayer()) if (vehicle) then speed = exports.global:getVehicleVelocity(vehicle) local width, height = guiGetScreenSize() local x = width local y = height -- street names local streetname = getElementData(getLocalPlayer(), "speedo:street" ) if streetname then local width = dxGetTextWidth( streetname ) local x = width < 200 and ( x - 110 - width / 2 ) or ( x - 10 - width ) dxDrawRectangle( x - 8, y - 296, width + 17, 24, tocolor( 5, 5, 5, 220 ) ) dxDrawText( streetname, x, y - 292 ) end dxDrawImage(x-210, y-275, 200, 200, "disc.png", 0, 0, 0, tocolor(255, 255, 255, 200), false) local speedlimit = getElementData(getLocalPlayer(), "speedo:limit") if speedlimit and getElementType(vehicle) ~= "Boat" and getElementType(vehicle) ~= "Helicopter" and getElementType(vehicle) ~= "Plane" then local ax, ay = x - 243, y - 202 dxDrawImage(ax,ay,32,37,"images/speed" .. speedlimit .. ".png") ay = ay - 32 if speedlimit >= 120 then dxDrawImage(ax,ay,32,37,"images/highway.png") ay = ay - 32 end if speed > speedlimit then dxDrawImage(ax,ay,32,37,"images/accident.png") end end speed = speed - 100 nx = x + math.sin(math.rad(-(speed)-150)) * 90 ny = y + math.cos(math.rad(-(speed)-150)) * 90 dxDrawLine(x-110, y-175, nx-110, ny-175, tocolor(255, 0, 0, 255), 2, true) end end end I know it...But is bad dxDrawImage(x-110, y-175, nx-110, ny-175, "needle.png"(255, 0, 0, 255), true) What should I exchange? Thanks a lot (sry my bad eng)
×
×
  • Create New...