Jump to content

laserlaser

Members
  • Posts

    92
  • Joined

  • Last visited

Details

  • Gang
    Free

Recent Profile Visitors

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

laserlaser's Achievements

Punk-@ss B*tch

Punk-@ss B*tch (12/54)

0

Reputation

  1. Delete first version at least. There is no change in resource but I deleted my copyright. DONE It would be nice if you re-added the description text
  2. "please delete" in description https://community.multitheftauto.com/index.php?p=resources&s=details&id=7770 ANSWER: this is your resource.. what exactly is it meant for (as you deleted the description)? Per the community regulations, we tend not to/can refuse to delete useful, popular or old resources. You usually release useful and popular resources.
  3. I thinked on it very long time ago.But I decided to not go to do. Because It can't include client scripts. But It is great for someone who want to make only server-side scripts.So great job bro.
  4. Hi everyone, I just make a ModLoader for ModLoading in game and make a sample for SDT_GUI(a.k.a dxGUI). Here is the video: Google Drive Download You should edit 'mods_server.xml' to add new mods.
  5. Project name changed to SDT_GUI. v1.4.4 comes with too much new things.
  6. I think you should just read the my first message. It says: 'I have edit Aibo's DrawColorText 1.5 years ago.'
  7. It's old project And 'colorCoded: Set to true to enable embedded #FFFFFF color codes. Note: clip and wordBreak are forced false if this is set.' I want to use colored text with 'clip' property.
  8. V.1.4.3 COMES ! 11 new beautiful theme added...
  9. Hi, I have edit Aibo's DrawColorText 1.5 years ago. function dxDrawColorText(str, ax, ay, bx, by, color, scale, font, alignX, alignY,clip,wordBreak,postGUI) --local maxWidth = bx-ax local strAdded = 0 if str:sub(1,1) ~= " " then str = " "..str strAdded = 1 end if alignX then if alignX == "center" then local w = dxGetTextWidth(str:gsub("#%x%x%x%x%x%x",""), scale, font) ax = ax + (bx-ax)/2 - w/2 -- maxWidth = bx-ax elseif alignX == "right" then local w = dxGetTextWidth(str:gsub("#%x%x%x%x%x%x",""), scale, font) ax = bx - w -- maxWidth = bx-ax end end if alignY then if alignY == "center" then local h = dxGetFontHeight(scale, font) ay = ay + (by-ay)/2 - h/2 elseif alignY == "bottom" then local h = dxGetFontHeight(scale, font) ay = by - h end end local f = 1 local pat = "(.-)#(%x%x%x%x%x%x)" local s, e, cap, col = str:find(pat, 1) local last = 1 while s do if cap == "" and col then color = tocolor(tonumber("0x"..col:sub(1, 2)), tonumber("0x"..col:sub(3, 4)), tonumber("0x"..col:sub(5, 6)), 255) end if s ~= 1 or cap ~= "" then local w = dxGetTextWidth(cap, scale, font) --if (w > maxWidth) then -- w = maxWidth --end --maxWidth = maxWidth-w if (f == 1) and strAdded == 1 then cap = cap:sub(2) f = f+1 end if not clip then clip = false end if not wordBreak then wordBreak = false end if not postGUI then postGUI = false end dxDrawText(cap, ax, ay, ax+w, by, color, scale, font,"left","top",clip,wordBreak,postGUI) ax = ax + w color = tocolor(tonumber("0x"..col:sub(1, 2)), tonumber("0x"..col:sub(3, 4)), tonumber("0x"..col:sub(5, 6)), 255) end last = e + 1 s, e, cap, col = str:find(pat, last) end if last <= #str then cap = str:sub(last) local w = dxGetTextWidth(cap, scale, font) --if (w > maxWidth) then -- w = maxWidth --end --maxWidth = maxWidth-w if not clip then clip = false end if not wordBreak then wordBreak = false end if not postGUI then postGUI = false end if ( f == 1) and strAdded==1 then cap = cap:sub(2) end f = f+1 dxDrawText(cap, ax, ay, ax+w, by, color, scale, font,"left","top",clip,wordBreak,postGUI) end end I noticed now, It doesn't work OMFG! Where is the problem?
  10. I think you are using v1.4.1, and you cant call the theme like "Subaru" you should use 'dxGetTheme' function.Like 'dxGetTheme("Subaru")' I wrote it in the first message, Edit is not a component now.It's just a template, not a drawable component for now.You can create normal gui edit and attach it to the dxGUI window. x_wnd=dxCreateWindow(...) y_edt=guiCreateEdit(...) guiAttachToDirectX(x_wnd, y_edt, y_edt_x_position_on_the_dx_window, y_edt_y_position_on_the_dx_window) You can use it like that in 1.4.3 I will develop 'Attaching' function and It will be better than 1.4.2
×
×
  • Create New...