AE. Posted November 20, 2020 Share Posted November 20, 2020 whenever i add a scale argument to dgsCreateButton --scaleX,scaleY the text disappears. even if i set the scale to 1 it still disappears, if i want it to work i have to close function brackets before the scalex,scaley arguments Link to comment
Dope88 Posted March 16, 2021 Share Posted March 16, 2021 On 30/05/2017 at 14:53, thisdp said: This is my server. The gui is made by dgs. ( I am bad in design sry) http://i.imgur.com/nKz9FWp.png http://i.imgur.com/ZJhOVEf.png How to create a radial menu like in the second picture? Link to comment
Scripting Moderators thisdp Posted March 25, 2021 Author Scripting Moderators Share Posted March 25, 2021 On 17/03/2021 at 03:28, Dope88 said: How to create a radial menu like in the second picture? Use Cos and Sin to calculate the position Link to comment
Dope88 Posted March 27, 2021 Share Posted March 27, 2021 On 25/03/2021 at 16:16, thisdp said: Use Cos and Sin to calculate the position Thank you for the Answer! What is Cos and Sin? Link to comment
Dope88 Posted March 27, 2021 Share Posted March 27, 2021 On 25/03/2021 at 16:16, thisdp said: Use Cos and Sin to calculate the position Or better question.. Which function creates the menu? Link to comment
Scripting Moderators thisdp Posted March 27, 2021 Author Scripting Moderators Share Posted March 27, 2021 1 hour ago, Dope88 said: Or better question.. Which function creates the menu? No function creates menu, you need to design your menu and implement it with existing types of dgs elements. You can get start with dgs Image or dgs Button. And you'd better to learn how to use GUI before using DGS. 7 hours ago, Dope88 said: Thank you for the Answer! What is Cos and Sin? COS and SIN are the functions in math, which is able to draw a circle easily. Link to comment
DaeRoNz Posted September 1, 2022 Share Posted September 1, 2022 @thisdp is possible change border color and size in element dgsCreateRoundRect ? if yes how .. i tryed some property but nothign work Link to comment
Scripting Moderators thisdp Posted September 9, 2022 Author Scripting Moderators Share Posted September 9, 2022 (edited) On 01/09/2022 at 23:39, DaeRoNz said: @thisdp is possible change border color and size in element dgsCreateRoundRect ? if yes how .. i tryed some property but nothign work you have to use dxSetShaderValue, with borderThickness and borderColor. But in dgs roundeded rectangle plugin, there are functions to do that: dgsRoundRectSetColor dgsRoundRectSetBorderThickness Edited September 9, 2022 by thisdp Link to comment
AngelAlpha Posted January 21, 2023 Share Posted January 21, 2023 (edited) @thisdp bug with tabPanel. When create tabpanel with attach to parent, Y pos tab wrong. Pos cursor when tab activated Pos cursor on tab Tab panel attached to scrollpane Edited January 21, 2023 by AngelAlpha Link to comment
Scripting Moderators thisdp Posted January 21, 2023 Author Scripting Moderators Share Posted January 21, 2023 2 hours ago, AngelAlpha said: @thisdp bug with tabPanel. When create tabpanel with attach to parent, Y pos tab wrong. Pos cursor when tab activated Pos cursor on tab Tab panel attached to scrollpane what function did you use? I need method to reproduce. Link to comment
AngelAlpha Posted January 21, 2023 Share Posted January 21, 2023 10 minutes ago, thisdp said: what function did you use? I need method to reproduce. elements.main_profile = dgsCreateScrollPane (0, 80*px, sx, sy - 80*px, false) ........... local gradient = dgsCreateGradient (tocolor(255, 107, 0), tocolor(255, 240, 0), 90 - 12) local gradient2 = dgsCreateGradient (Config.colors[1], Config.colors[1], 0) elements.tabPanel_profile = dgsCreateTabPanel (100*px, 650*px, 1140*px, 332*px, false, elements.main_profile, 60*px, _, tocolor(50, 50, 50, 0)) elements.tabPanel_profile_main = dgsCreateTab("Основная статистика", elements.tabPanel_profile) elements.tabPanel_profile_finance = dgsCreateTab("Имущество", elements.tabPanel_profile) elements.tabPanel_profile_job = dgsCreateTab("Занятость", elements.tabPanel_profile) dgsSetProperty(elements.tabPanel_profile,"tabImage",{gradient2,gradient2,gradient}) dgsSetProperty(elements.tabPanel_profile,"tabPadding",{15*px, false}) dgsSetProperty(elements.tabPanel_profile_main,"textColor",{tocolor(255, 255, 255), tocolor(150, 150, 150), tocolor(0, 0, 0)}) dgsSetProperty(elements.tabPanel_profile_finance,"textColor",{tocolor(255, 255, 255), tocolor(150, 150, 150), tocolor(0, 0, 0)}) dgsSetProperty(elements.tabPanel_profile_job,"textColor",{tocolor(255, 255, 255), tocolor(150, 150, 150), tocolor(0, 0, 0)}) @thisdp and i find a few mistakes mask.lua > 16 line if not(masks[texture2]) then error(dgsGenAsrt(texture2,"dgsCreateMask",2,"texture",_,_"unsupported type")) end > if not(masks[texture2]) then error(dgsGenAsrt(texture2,"dgsCreateMask",2,"texture",_,_,"unsupported type")) end mask.lua > line 69-81 function dgsMaskCenterTexturePosition(dgsMask,w,h) if not(dgsGetPluginType(mask) == "dgs-dxmask") then error(dgsGenAsrt(mask,"dgsMaskCenterTexturePosition",1,"dgs-dxmask")) end local ratio = w/h local scaleW,scaleH = (ratio>1 and ratio or 1),(1/ratio>1 and 1/ratio or 1) dgsMaskSetSetting(dgsMask,"offset",{scaleW/2-0.5,scaleH/2-0.5,1}) end function dgsMaskAdaptTextureSize(dgsMask,w,h) if not(dgsGetPluginType(mask) == "dgs-dxmask") then error(dgsGenAsrt(mask,"dgsMaskAdaptTextureSize",1,"dgs-dxmask")) end local ratio = w/h local scaleW,scaleH = (ratio>1 and ratio or 1),(1/ratio>1 and 1/ratio or 1) dgsMaskSetSetting(dgsMask,"scale",{scaleW,scaleH,1}) end >>> function dgsMaskCenterTexturePosition(mask,w,h) if not(dgsGetPluginType(mask) == "dgs-dxmask") then error(dgsGenAsrt(mask,"dgsMaskCenterTexturePosition",1,"dgs-dxmask")) end local ratio = w/h local scaleW,scaleH = (ratio>1 and ratio or 1),(1/ratio>1 and 1/ratio or 1) dgsMaskSetSetting(mask,"offset",{scaleW/2-0.5,scaleH/2-0.5,1}) end function dgsMaskAdaptTextureSize(mask,w,h) if not(dgsGetPluginType(mask) == "dgs-dxmask") then error(dgsGenAsrt(mask,"dgsMaskAdaptTextureSize",1,"dgs-dxmask")) end local ratio = w/h local scaleW,scaleH = (ratio>1 and ratio or 1),(1/ratio>1 and 1/ratio or 1) dgsMaskSetSetting(mask,"scale",{scaleW,scaleH,1}) end 1 Link to comment
Scripting Moderators thisdp Posted January 22, 2023 Author Scripting Moderators Share Posted January 22, 2023 16 hours ago, AngelAlpha said: elements.main_profile = dgsCreateScrollPane (0, 80*px, sx, sy - 80*px, false) ........... local gradient = dgsCreateGradient (tocolor(255, 107, 0), tocolor(255, 240, 0), 90 - 12) local gradient2 = dgsCreateGradient (Config.colors[1], Config.colors[1], 0) elements.tabPanel_profile = dgsCreateTabPanel (100*px, 650*px, 1140*px, 332*px, false, elements.main_profile, 60*px, _, tocolor(50, 50, 50, 0)) elements.tabPanel_profile_main = dgsCreateTab("Основная статистика", elements.tabPanel_profile) elements.tabPanel_profile_finance = dgsCreateTab("Имущество", elements.tabPanel_profile) elements.tabPanel_profile_job = dgsCreateTab("Занятость", elements.tabPanel_profile) dgsSetProperty(elements.tabPanel_profile,"tabImage",{gradient2,gradient2,gradient}) dgsSetProperty(elements.tabPanel_profile,"tabPadding",{15*px, false}) dgsSetProperty(elements.tabPanel_profile_main,"textColor",{tocolor(255, 255, 255), tocolor(150, 150, 150), tocolor(0, 0, 0)}) dgsSetProperty(elements.tabPanel_profile_finance,"textColor",{tocolor(255, 255, 255), tocolor(150, 150, 150), tocolor(0, 0, 0)}) dgsSetProperty(elements.tabPanel_profile_job,"textColor",{tocolor(255, 255, 255), tocolor(150, 150, 150), tocolor(0, 0, 0)}) @thisdp and i find a few mistakes mask.lua > 16 line if not(masks[texture2]) then error(dgsGenAsrt(texture2,"dgsCreateMask",2,"texture",_,_"unsupported type")) end > if not(masks[texture2]) then error(dgsGenAsrt(texture2,"dgsCreateMask",2,"texture",_,_,"unsupported type")) end mask.lua > line 69-81 function dgsMaskCenterTexturePosition(dgsMask,w,h) if not(dgsGetPluginType(mask) == "dgs-dxmask") then error(dgsGenAsrt(mask,"dgsMaskCenterTexturePosition",1,"dgs-dxmask")) end local ratio = w/h local scaleW,scaleH = (ratio>1 and ratio or 1),(1/ratio>1 and 1/ratio or 1) dgsMaskSetSetting(dgsMask,"offset",{scaleW/2-0.5,scaleH/2-0.5,1}) end function dgsMaskAdaptTextureSize(dgsMask,w,h) if not(dgsGetPluginType(mask) == "dgs-dxmask") then error(dgsGenAsrt(mask,"dgsMaskAdaptTextureSize",1,"dgs-dxmask")) end local ratio = w/h local scaleW,scaleH = (ratio>1 and ratio or 1),(1/ratio>1 and 1/ratio or 1) dgsMaskSetSetting(dgsMask,"scale",{scaleW,scaleH,1}) end >>> function dgsMaskCenterTexturePosition(mask,w,h) if not(dgsGetPluginType(mask) == "dgs-dxmask") then error(dgsGenAsrt(mask,"dgsMaskCenterTexturePosition",1,"dgs-dxmask")) end local ratio = w/h local scaleW,scaleH = (ratio>1 and ratio or 1),(1/ratio>1 and 1/ratio or 1) dgsMaskSetSetting(mask,"offset",{scaleW/2-0.5,scaleH/2-0.5,1}) end function dgsMaskAdaptTextureSize(mask,w,h) if not(dgsGetPluginType(mask) == "dgs-dxmask") then error(dgsGenAsrt(mask,"dgsMaskAdaptTextureSize",1,"dgs-dxmask")) end local ratio = w/h local scaleW,scaleH = (ratio>1 and ratio or 1),(1/ratio>1 and 1/ratio or 1) dgsMaskSetSetting(mask,"scale",{scaleW,scaleH,1}) end fixed 1 Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now