Jump to content

Forums

  1. Multi Theft Auto: San Andreas 1.x

    1. Support for MTA:SA 1.x

      HELP! HELP! Need help? Post here.

      53.7k
      posts
    2. User Guides

      These guides are a good place to start learning how to achieve certain things within MTA in an efficient and well mannered way.

      11
      posts
    3. Open Source Contributors

      This space is for contributors to discuss the development of MTA. No user suggestions/support.

      1.3k
      posts
    4. Suggestions

      Suggestions and requests go here. Please note that actual feature requests must be filed on our GitHub.

      7.7k
      posts
    5. Ban appeals

      Use this forum to appeal your GLOBAL MTA:SA bans. Permanent bans only - appeals for timed ones (eg. 24 hours) will be refused.

      Do not use it for appealing server-specific bans as we do not have power over these specific servers.

      4.1k
      posts
  2. General MTA

    1. News

      News and updates on Multi Theft Auto.

      9.6k
      posts
    2. Media

      User-made screens and movies go here.

      4.4k
      posts
    3. Site/Forum/Discord/Mantis/Wiki related

      Share your comments & concerns about our services.

      5.4k
      posts
    4. MTA Chat

      MTA related chat that is NOT support related!

      2.1k
      posts
    5. 327.9k
      posts
  3. MTA Community

    1. Scripting

      All Lua scripting topics related to Multi Theft Auto.

      258.8k
      posts
    2. Maps

      Discussions for maps on various gamemodes.

      13.3k
      posts
    3. Resources

      Everything else about resources.

      28.2k
      posts
    4. Other Creations & GTA modding

      This section includes things such as GUI themes, forum userbars, user-created MTA logos, etc. Also contains topics which cover general GTA modding areas that can be used in MTA, such as modelling.

      2.2k
      posts
    5. Competitive gameplay

      Discussions about various MTA-related competitive gameplay events. Also gang (clan) forums.

      26.7k
      posts
    6. Servers

      Looking for a server to play on? Looking for someone to host your server? Looking for a place to discuss with other server owners? Here's where to look.

      15.2k
      posts
  4. Other

    1. General

      Non-MTA discussions. Anything you want.

      38.1k
      posts
    2. Multi Theft Auto 0.5r2

      Discussion regarding Multi Theft Auto 0.5r2 for GTAIII and Vice City.

      649
      posts
    3. Third party GTA mods

      Showcase for single player mods and requests.

      783
      posts
  5. Archive

    1. 144k
      posts
    2. Trash

      These posts have broken forum rules. They are stored here temporarily so offending users can see what they have done wrong.

      2k
      posts
  • Posts

    • local screenW, screenH = guiGetScreenSize() local render = dxCreateRenderTarget(screenW * 0.3994, screenH * 0.2652) local cx, cy = (screenW/2) - ((screenW * 0.3994) / 2), (screenH/2) - ((screenH * 0.2652) / 2) local scroll = 0.0000 local scrollV = 0.0255 local maxScroll = 0.0000 local selected = 47 local slots = {} local Color = tocolor(140, 140, 140, 150) local selectedColor = tocolor(0, 200, 255, 200) function dxInv() if render and isElement(render) then showCursor(true) dxDrawRoundedRectangle(screenW * 0.3994, screenH * 0.2652, screenW * 0.2012, screenH * 0.4697, 10, tocolor(0, 0, 0, 80), false) x, y = 0.0050, 0.0040 local load = getElementData(localPlayer, 'inv.mochila') slots = {} dxSetRenderTarget(render, true) for i=1,24 do dxDrawRectangle(screenW * x, screenH * (y - scroll), screenW * 0.0920, screenH * 0.0470, i == selected and selectedColor or Color, false) table.insert(slots, {screenW * x, screenH * (y - scroll), screenW * 0.0920, screenH * 0.0470}) dxDrawImage(screenW * (x + 0.0100), screenH * ((y + 0.0070) - scroll), screenW * 0.0700, screenH * 0.0350, "img/agua.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) x = x + 0.0990 if x >= 0.3850 then x = 0.0050 y = y + 0.0495 end end maxScroll = y - 0.2152 dxSetRenderTarget() dxDrawImage(screenW * 0.3994, screenH * 0.2652, screenW * 0.2012, screenH * 0.4697, render) end end addEventHandler('onClientRender', root, dxInv) function scrollRoller(b, p) if p then if b == 'mouse_wheel_up' then scroll = math.max(0, scroll - scrollV) elseif b == 'mouse_wheel_down' then scroll = math.min(maxScroll, scroll + scrollV) end end end addEventHandler('onClientKey', root, scrollRoller) function clickSelect(b, s) if s == 'down' then if b == 'left' then for i,v in ipairs(slots) do if isMouseInPosition(v[1], v[2], v[3], v[4]) then selected = i end end end end end addEventHandler('onClientClick', root, clickSelect)  
    • Hey everyone, I'd like to introduce you to my tool that essentially lets you create seamless segmented runs for any race map. The tool is still in development (and I'm very lazy lol) so updates will be shown on the main GitHub page: https://github.com/chris1384/mta-tas-dm   Here's a little showcase using the janky, older tool that I've made back in 2020:   Here's the behind the scenes using the newer tool that's available for download: Thanks for the attention and have fun!
    • So I'm trying to do an inventory script and I'm having a problem with the dxTarget scaling. https://youtu.be/rCihMvRlvBs       local screenW, screenH = guiGetScreenSize() local render = dxCreateRenderTarget(screenW * 0.3994, screenH * 0.2652) local cx, cy = (screenW/2) - ((screenW * 0.3994) / 2), (screenH/2) - ((screenH * 0.2652) / 2) local scroll = 0.0000 local scrollV = 0.0255 local maxScroll = 0.0000 local selected = 47 local slots = {} local Color = tocolor(140, 140, 140, 150) local selectedColor = tocolor(0, 200, 255, 200) function dxInv()     if render and isElement(render) then         showCursor(true)         dxDrawRoundedRectangle(screenW * 0.3994, screenH * 0.2652, screenW * 0.2012, screenH * 0.4697, 10, tocolor(0, 0, 0, 80), false)                 x, y = 0.0050, 0.0040                 local load = getElementData(localPlayer, 'inv.mochila')         slots = {}         dxSetRenderTarget(render, true)             for i=1,24 do                 dxDrawRectangle(screenW * x, screenH * (y - scroll), screenW * 0.0920, screenH * 0.0470, i == selected and selectedColor or Color, false)                 table.insert(slots, {screenW * x, screenH * (y - scroll), screenW * 0.0920, screenH * 0.0470})                 dxDrawImage(screenW * (x + 0.0100), screenH * ((y + 0.0070) - scroll), screenW * 0.0700, screenH * 0.0350, "img/agua.png", 0, 0, 0, tocolor(255, 255, 255, 255), false)                 x = x + 0.0990                                 if x >= 0.3850 then                     x = 0.0050                     y = y + 0.0495                 end             end             maxScroll = y - 0.2152         dxSetRenderTarget()         dxDrawImage(screenW * 0.3994, screenH * 0.2652, screenW * 0.2012, screenH * 0.4697, render)     end end addEventHandler('onClientRender', root, dxInv) function scrollRoller(b, p)     if p then         if b == 'mouse_wheel_up' then             scroll = math.max(0, scroll - scrollV)         elseif b == 'mouse_wheel_down' then             scroll = math.min(maxScroll, scroll + scrollV)         end     end end addEventHandler('onClientKey', root, scrollRoller) function clickSelect(b, s)     if s == 'down' then         if b == 'left' then             for i,v in ipairs(slots) do                 if isMouseInPosition(v[1] + cy, v[2] + cx, v[3], v[4]) then                     selected = i                 end             end         end     end end addEventHandler('onClientClick', root, clickSelect)  
    • yeah i restarted the resource and it tells me that in console, and when i am in game on my server i can open the staff manager gui but it wont show any buttons..  

Twitter Feed

×
×
  • Create New...