Jump to content

ilnaz

Members
  • Posts

    19
  • Joined

  • Last visited

Everything posted by ilnaz

  1. I know this, but how to make them the same
  2. How fix shade or brightness wheel or light,? On the left light color and right dark color. shaders didn't help
  3. ilnaz

    How to do it

    how to do it??? https://www.youtube.com/watch?v=-pPPR0kHmEg what function or shader used?? HELP please
  4. How get cursor postion on vehicle UV map(so that draw sticker on vehicle where cursor) when cursor click?
  5. dxDrawImage reduces memory! I used the image drawing function and checked when memory is decreasing. setTimer(function() local st = dxGetStatus() local m1 = st.VideoMemoryFreeForMTA if not c or c ~= m1 then print(m1) c = m1 end end,10,0) When using dxDrawImage in sizes larger than 1024x1024 this is especially noticeable. Memory crashes but with a new load. How can this be avoided so that an unused image is deleted from memory. Sorry for bad English
  6. i remove "\" and save next symbol
  7. i use [[ ]] for replace symbol "\" in text 'example\example'
  8. local text = [[text]] how insert in this "text" other words?
  9. How replace this symbol "\" ? local text = 'aaa\bbb' text = text:gsub('\\','') -- don't work text = text:gsub('%\\','') -- don't work text = text:gsub('\','') -- don't work and an error in debugscript text = text:gsub('%\','') -- don't work and an error in debugscript
  10. How get info from transfer box?
  11. table_example = { [1] = {'example1'}, -- How move this table.move ↑↓ ?? [2] = {'example2'}, }
  12. function NameFunc (text) if string.find(text, "46.") then return true else return false end end NameFunc ("460") -- returned true, wtf!?
  13. How to improve the code so that it works quickly and without delay? This script works well when there are few players, but when more than 20 people come in, it starts to load for a long time. A very long time. It can load for hours. CLIENT ↓↓ triggerServerEvent("onSearchRequest",localPlayer, 'text_search') CLIENT ↑↑ SERVER ↓↓ addEvent("onSearchRequest", true) addEventHandler("onSearchRequest",getRootElement(),function(txt) fetchRemote( "http://5music.online/?song="..(txt:gsub(' ', '+')),onSongReturn,'',true,client) end) function onSongReturn(data,errno,player) if player and isElement(player) then local str1 = string.find(data,"<ul>") local _,str2 = string.find(data,"</ul>") if str1 ~= nil then local data = string.sub(data,str1,str2) triggerClientEvent(player,"onSongReceived", player, data) end end end UPGRADE CODE PLEASE
  14. You can replace! Using the Hacker Resource program. Next, look for using the program: \ MTA San Andreas 1.5 \ MTA \ loader.dll
  15. Author and editor of Ilnaz Isangulov DxCreateDiagram Client-only function Draws an diargam on the screen for a single frame. In order for the diagram to stay visible continuously, you need to call this function with the same parameters on each frame update (see onClientRender). Syntax bool dxCreateDiagram (float N, float posX, float posY, float cleanWidth, int color = tocolor(255,255,255,255), float scaleXY = 1, bool postGUI = false) Required Arguments N: changing parameter, for example speed posX: the absolute X coordinate of the top left corner of the image posY: the absolute Y coordinate of the top left corner of the image cleanWidth: the width at which it will be cleaned and updated Optional Arguments color: Tints the image with a value produced by tocolor or hexadecimal number in format: 0xAARRGGBB (RR = red, GG = green, BB = blue, AA = alpha). postGUI: A bool representing whether the image should be drawn on top of or behind any ingame GUI (rendered by CEGUI). Example Example of a pendulum swinging from the top of the screen, made using dxDrawImage. local screenWidth,screenHeight = guiGetScreenSize() -- Get screen resolution. function renderDisplay ( ) dxCreateDiagram ( math.random ( 0, 200 ), 0, screenHeight / , , tocolor ( 255, 0, 255, 255 ) , 1, false ) end addEventHandler("onClientRender", root, renderDisplay) -- Keep everything visible with onClientRender. Author and editor of Ilnaz Isangulov This is required in the code! local dataTable = {} local zOld = 0 function dxCreateDiagram(N,x,y,cleanSize,color,size,gui) local _,h = guiGetScreenSize() local x = x or 0 local y = y or h/2 local N = N or 0 local cleanSize = cleanSize or h/2 local color = color or tocolor(255, 255, 255, 255) local size = size or 1 local gui = gui or false local izmen = (N-zOld) table.insert( dataTable, izmen) for i, z in pairs(dataTable) do local x3 = dataTable[i+1] or 1 local x2 = dataTable[i] or 1 if i >= cleanSize then for f,_ in pairs(dataTable) do table.remove(dataTable, f) end end dxDrawLine(x+(i-1), y+1-x2, x+i, y+1-x3, color,size,gui) end end Author and editor of Ilnaz Isangulov
  16. ilnaz

    help table lua

    markerData = { location = '1', { [1] = { 1216, -1835, 13.4}, [2] = { 1227.7, -1854.6, 13.4}, }, location = '2', { [1] = { 0, 0, 0}, [2] = { 1227.7, -1854.6, 13.4}, }, location = '3', { [1] = { 1216, -1835, 13.4}, [2] = { 1227.7, -1854.6, 13.4}, }, } local selLocation = 2 for _,tab in pairs(markerData) do if tab['location'] == selLocation then local x, y, z = markerData[ID][1], markerData[ID][2], markerData[ID][3] -- Problem markerData[ID][1] end end
×
×
  • Create New...