Jump to content

syn0nym

Members
  • Posts

    23
  • Joined

  • Last visited

Recent Profile Visitors

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

syn0nym's Achievements

Advanced Member

Advanced Member (8/54)

3

Reputation

  1. So i have little problem with dgsCreateImage, so when you run this code and clicked on the image/red round rectangle, the text is not visible, so how to make the text keep visible when the image is clicked loadstring(exports.dgs:dgsImportFunction())() showCursor (true) local x, y = dgsGetScreenSize() local window = dgsCreateWindow ((x/2) - (400/2), (y/2) - (300/2), 400, 300, "test", false) local rndRect = dgsCreateRoundRect (30, false, tocolor(225,0,0)) local img = dgsCreateImage (15, 20, 100, 50, rndRect, false, window) local text = dgsCreateLabel (30, 25, 100, 20, "Text", false, window)
  2. So, i have a little problem about gui gridlist, i write a gridlist code and it run like this. https://ibb.co/n8T02cn local screenX, screenY = guiGetScreenSize() local table1 = {1, 2, 3, 4, 5} local table2 = {"Lorem ipsum dolor sit amet", "consectetur adipiscing elit", "sed do eiusmod tempor incididunt ut labore et dolore magna aliqua", "Ut enim ad minim veniam"} local gui = {} local windowX, windowY = 500, 300 gui["window"] = guiCreateWindow( (screenX/ 2) - (windowX/2), (screenY/2) - (windowY/2), windowX, windowY, "WINDOW", false) guiSetVisible (gui["window"], false ) gui["gridlist"] = guiCreateGridList ((windowX/2) - (450/2), 70, 450, 190, false, gui["window"]) gui["id-column"] = guiGridListAddColumn (gui["gridlist"], "ID", 0.1) gui["test-column"] = guiGridListAddColumn (gui["gridlist"], "Test", 0.8) for key, values in ipairs (table1) do for key1, values1 in ipairs (table2) do gui["rows"] = guiGridListAddRow (gui["gridlist"], values, values1) end end function startGUI () if guiGetVisible (gui["window"]) then guiSetVisible (gui["window"], false) showCursor (false) else guiSetVisible (gui["window"], true) showCursor (true) end end bindKey ("F3", "down", startGUI) it may some bug, i want to make the id dont same, example column 1 row 1 only return 1 id and lorem ipsum and forward. Please Help me & Sorry for bad english.
  3. So i want to make a animation to count a number, i have some variable to make and my problem is which function to make a counting number values = 350000 -- Value of max count speed = 1000 -- Speed of count
  4. So i want to ask, if i make a gui button normally we trigger a function using a mouse click, but it is possible to make it using a bindkey like enter button? x, y = guiGetScreenSize () button = guiCreateButton (300, 500, 200, 100, "Test", false) addEventHandler ( "onClientGUIClick", button, test, false ) function test () outputChatBox ("Button Clicked !") end bindKey ("enter", "down", test)
  5. Your last tag should be </meta>
  6. Thank you for helping, it's working
  7. Okay, so i created a gui function in client side, then i want to trigger it using triggerClientEvent in the server side, but when the code run there a some problem. Client GUIEditor = { window = {}, label = {}, edit = {}, button = {}, } function centerWindow (center_window) local screenW, screenH = guiGetScreenSize() local windowW, windowH = guiGetSize(center_window, false) local x, y = (screenW - windowW) /2,(screenH - windowH) /2 return guiSetPosition(center_window, x, y, false) end GUIEditor.window[1] = guiCreateWindow (0, 0, 300, 400, "Test", false) centerWindow (GUIEditor.window[1]) guiSetVisible (GUIEditor.window[1], false) GUIEditor.label[1] = guiCreateLabel (20, 50, 100, 70, "Test", false, GUIEditor.window[1]) GUIEditor.edit[1] = guiCreateEdit (20, 90, 200, 30, "", false, GUIEditor.window[1]) GUIEditor.button[1] = guiCreateButton (20, 150, 150, 40, "Button", false, GUIEditor.window[1]) function openGUI (bool) if (bool == true) then guiSetVisible (GUIEditor.window[1], true) showCursor (true) end end addEvent ("showGUI", true) addEventHandler ("showGUI", root, openGUI) Server function playerJoin () triggerClientEvent (source, "showGUI", source, true) end addEventHandler ("onPlayerJoin", root, playerJoin)
  8. I have some problem with a dgsCreateWindow, so i make a dgswindow and a show cursor,when my cursor is clicking on outside the dgswindow area, the dgswindow is not visible, how to make dgswindow keep visible when cursor is clicking on outside area of the dgswindow. Here the code dgsCreateWindow( 440 , 160 , 300 , 400 , " " , false) showCursor(true)
  9. MaD.SphinX See you in Valhalla bro =D UNTUK KALIAN YANG MENGERTI BAHASA. Pendaftaran ini akan terus dibuka sepanjang tahun 2021-2022. Minimal anda mengerti I.T. atau bisa sedikit coding website. 10% Skill, 100% KEMAUAN. Permisi Mas, saya berminat untuk jadi scripter, saya juga sudah pernah main di server IRRP pada 2020, tetapi skill saya dalam coding masih dibilang baru, saya hanya menguasi HTML dan CSS, dan untuk bahasa pemprograman Lua masih dibilang baru, jika mas Cobrax berminat dapat menghubungi saya melalui discord mxzyy#9967 sekian terimakasih mas.
  10. I've been try using a dgsCreateLabel, but when i use a wordBreak property it doesn't work. here my code local window = dgsCreateWindow ( 440 , 160 , 400 , 300 , "" , false) local label = dgsCreateLabel ( 20 , 10 , 300 , 100 , "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.", false , window) dgsSetProperty (label , "wordBreak" , true)
  11. Hello thanks for clicking this topic. so i have a problem when i code, i want to make a dxDrawTest and a blurred background using setCameraMatrix and dgsCreateBlurBox, when i run my code the text is not showing, but when i clear the dgsCreateBlurBox, the text is showing, so my question is how to make the text visible with the dgsCreateBlurBox Here my code local sW, sH = guiGetScreenSize( ) local blurbox = dgsCreateBlurBox(sW, sH) local blurArea = dgsCreateImage(0,0,1,1,blurbox,true) function Text ( ) setCameraMatrix(1468.8785400391, -919.25317382813, 100.153465271, 1468.388671875, -918.42474365234, 99.881813049316) dxDrawText ( "Test", 44, sH - 43, sW, sH, tocolor ( 255, 255, 255, 255 ), 1, "pricedown" ) end function Render ( ) addEventHandler ( "onClientRender", root, Text ) end dgsSetLayer(blurArea, "bottom") showCursor(true) addEventHandler ( "onClientResourceStart", resourceRoot, Render )
  12. Thanks you very much it's working.
  13. Thanks for click this topic, so i have some code which is will make a some cinematic from 3 different location, but i want make it looping from the third location back to the first and keep going like that, here my code local times = 10000 function cinematic() smoothMoveCamera(2444.0747070312, -1656.7917480469, 28.93049621582, 2526.1335449219, -1710.7858886719, 10.195858001709, 2489.0947265625, -1636.412109375, 30.221374511719, 2499.2856445312, -1728.2391357422, -8.0401239395142, 10000) end function cinematic2() smoothMoveCamera(1726.8065185547, -1484.8432617188, 143.54656982422, 1670.5084228516, -1413.7943115234, 185.7670135498, 1535.7916259766, -1267.5806884766, 272.14398193359, 1474.7834472656, -1199.0876464844, 311.97747802734, 10000) end function cinematic3() smoothMoveCamera(1338.3666992188, -1257.4116210938, 95.983924865723, 1352.1002197266, -1257.2800292969, -3.0684490203857, 1340.6787109375, -1498.6977539062, 95.983924865723, 1354.4122314453, -1498.5661621094, -3.0684490203857, 10000) end setPlayerHudComponentVisible("all", false) setTimer(cinematic, times * 0, 1) setTimer(cinematic2, times , 1) setTimer(cinematic3, times * 2 , 1)
  14. Okay thanks for replying my topic, is there any suggestion for make a custom gui like a HTML?
×
×
  • Create New...