-
Posts
239 -
Joined
-
Last visited
Everything posted by Seba500PLK
-
ok, tested local screenWidth,screenHeight = guiGetScreenSize() bX, bY = screenWidth/2,screenHeight/2 local scale = screenWidth/800 local scaley = screenWidth/600 local sx,sy = 300,300 sx,sy = sx*scale,sy*scaley function renderoko() dxDrawRectangle (sx/1.35, sy/2.5, sx/10.8, sx/10.8, tocolor ( 0, 0, 0, 150 ) ) if isMouseWithinRangeOf(sx/1.35, sy/2.5, sx/10.8, sx/10.8 ) then dxDrawRectangle (sx/1.35, sy/2.5, sx/10.8, sx/10.8, tocolor ( 195, 195, 195, 50 )) end if click then dxDrawRectangle (sx/1.35, sy/2.5, sx/10.8, sx/10.8, tocolor ( 255, 0, 0, 255) ) end end function key(button,press) if press then if isMouseWithinRangeOf(sx/1.35, sy/2.5, sx/10.8, sx/10.8 ) then if click == true then click = false else click = true outputChatBox("click") end end end end addEventHandler ( "onClientKey", getRootElement(), key ) function open() if open == true then removeEventHandler("onClientRender", root, renderoko) open = false showCursor(false) else addEventHandler("onClientRender", root, renderoko) open = true showCursor(true) end end bindKey ( "g", "down", open ) function isMouseWithinRangeOf(psx,psy,pssx,pssy) if not isCursorShowing() then return false end local cx,cy = getCursorPosition() cx,cy = cx*screenWidth,cy*screenHeight if cx >= psx and cx <= psx+pssx and cy >= psy and cy <= psy+pssy then return true,cx,cy else return false end end
-
oo sorry my bad local screenWidth,screenHeight = guiGetScreenSize() bX, bY = screenWidth/2,screenHeight/2 local scale = screenWidth/800 local scaley = screenWidth/600 local sx,sy = 300,300 sx,sy = sx*scale,sy*scaley function renderoko() dxDrawRectangle (sx/1.35, sy/2.5, sx/10.8, sx/10.8, tocolor ( 0, 0, 0, 150 ) ) if isMouseWithinRangeOf(sx/1.35, sy/2.5, sx/10.8, sx/10 ) then dxDrawRectangle (sx/1.35, sy/2.5, sx/10.8, sx/10.8, tocolor ( 195, 195, 195, 50 )) end if click then dxDrawRectangle (sx/1.35, sy/2.5, sx/10.8, sx/10.8, tocolor ( 255, 0, 0, 255) ) end end function key(button,press) if press then if isMouseWithinRangeOf(sx/1.35, sy/2.5, sx/10.8, sx/10.8 ) then if click == true then click = false else click = true outputChatBox("click") end end end end addEventHandler ( "onClientKey", getRootElement(), key ) function open() if open == true then removeEventHandler("onClientRender", root, renderoko) open = false showCursor(false) else addEventHandler("onClientRender", root, renderoko) open = true showCursor(true) end end bindKey ( "g", "down", open ) function isMouseWithinRangeOf(psx,psy,pssx,pssy) if not isCursorShowing() then return false end local cx,cy = getCursorPosition() cx,cy = cx*x,cy*y if cx >= psx and cx <= psx+pssx and cy >= psy and cy <= psy+pssy then return true,cx,cy else return false end end
-
vehicleCarSpawns = { -- Format: x, y, z, rotation, "Group", {cars} {297.18, 2049.94, 34.28, 0, "Military", {596, 597, 598, 599, 579, 490, 528}}, {1523, -2847.8, 0, 180, "FBI", {472, 473, 595}} }
-
ElementData: markerType this is set?
-
Upgrades bool addVehicleUpgrade ( vehicle theVehicle, int upgrade ) Camera setCameraMatrix Click Dx: (Example) local screenWidth,screenHeight = guiGetScreenSize() bX, bY = screenWidth/2,screenHeight/2 local scale = x/800 local scaley = x/600 local sx,sy = 300,300 sx,sy = sx*scale,sy*scaley function renderoko() dxDrawRectangle (sx/1.35, sy/2.5, sx/10.8, sx/10.8, tocolor ( 0, 0, 0, 150 ) ) if isMouseWithinRangeOf(sx/1.35, sy/2.5, sx/10.8, sx/10.8 ) then dxDrawRectangle (sx/1.35, sy/2.5, sx/10.8, sx/10.8, tocolor ( 195, 195, 195, 50 )) end if click then dxDrawRectangle (sx/1.35, sy/2.5, sx/10.8, sx/10.8, tocolor ( 255, 0, 0, 255) ) end end function key(button,press) if press then if isMouseWithinRangeOf(sx/1.35, sy/2.5, sx/10.8, sx/10.8 ) then if click == true then click = false else click = true outputChatBox("click") end end end end addEventHandler ( "onClientKey", getRootElement(), key ) function open() if open == true then removeEventHandler("onClientRender", root, renderoko) open = false showCursor(false) else addEventHandler("onClientRender", root, renderoko) open = true showCursor(true) end end bindKey ( "g", "down", open ) function isMouseWithinRangeOf(psx,psy,pssx,pssy) if not isCursorShowing() then return false end local cx,cy = getCursorPosition() cx,cy = cx*x,cy*y if cx >= psx and cx <= psx+pssx and cy >= psy and cy <= psy+pssy then return true,cx,cy else return false end end click g in game
-
... I want to repair your vehicle part and not the tune
-
Hello, how to repair a particular part of the car? eg repair only the front bumper
-
Hi, I have a little problem namely shows me $1, and I would like to showed me $00001. How to do it? local nW, nH = guiGetScreenSize( ) dxDrawText("$"..getPlayerMoney( localPlayer ),nW - 450,nH - 500,nW - 7,nH - 57,tocolor( 0,255,0,220 ),nW/500,'pricedown','right','top', false, false, false)
-
Name this animation
-
0.o i no understand. If in server side add outputChatBox : function getCheaterID(g) local sql = dbQuery(dbConnection,"SELECT * FROM TabsCheaterzy") local result = dbPoll ( sql, -1 ) if result then for _, row in ipairs ( result ) do outputChatBox ( row["Nick_Cheatera"] ) --triggerClientEvent ( g, "ZMDA", g, tostring(row["Nick_Cheatera"]) ) end end end addCommandHandler ( "cc", getCheaterID ) in chat show: Kolas Nobas Lia jusah kidol
-
Hi, my problem is grid --Client function grid(cheaters) local ListCheaters = guiCreateGridList ( 0.7, 0.10, 0.2, 0.60, true,t5 ) local ColumnCheaters = guiGridListAddColumn( ListCheaters, "Cheater", 0.85 ) if (isElement(ListCheaters)) then for id, player in ipairs(cheaters) do local row = guiGridListAddRow ( ListCheaters ) guiGridListSetItemText(ListCheaters, guiGridListAddRow(ListCheaters), ColumnCheaters, player, false, false) end end end addEvent( "ZMDA", true ) addEventHandler( "ZMDA", localPlayer,grid) --Server function getCheaterID(g) local sql = dbQuery(dbConnection,"SELECT * FROM TabsCheaterzy") local result = dbPoll ( sql, -1 ) if result then for _, row in ipairs ( result ) do triggerClientEvent ( g, "ZMDA", g, tostring(row["Nick_Cheatera"]) ) end end end addCommandHandler ( "cc", getCheaterID ) MySQL is: Nick_Cheatera Kolas Nobas Lia jusah kidol debugscript 3: ERROR: [sCRIPT]\Panel\scriptClient.lua:16: Bad argument #1 to 'ipairs' (table expected, got string) ERROR: [sCRIPT]\Panel\scriptClient.lua:16: Bad argument #1 to 'ipairs' (table expected, got string) ERROR: [sCRIPT]\Panel\scriptClient.lua:16: Bad argument #1 to 'ipairs' (table expected, got string) ERROR: [sCRIPT]\Panel\scriptClient.lua:16: Bad argument #1 to 'ipairs' (table expected, got string) ERROR: [sCRIPT]\Panel\scriptClient.lua:16: Bad argument #1 to 'ipairs' (table expected, got string)
-
This animation as I drove the man
-
MoveObject - problem
Seba500PLK replied to ProLisu's topic in Pomoc ze skryptami i programowaniem w Lua
Witaj, już wiem dlaczego twój skrypt nie działa. Marker jest troche za nisko więc ustaw wysokość na 12.4. Druga sprawa jest taka ze zle ustawiles argumenty dla funcki MoveObject powinno być tak: moveObject ( theObject, 10000, origX, origY, newZ ) ty masz tak: moveObject ( theObject, origX, origY, newZ ) nie masz zdefiniowanej szybkosci więc w funkcji MarkerHit1 w moveObject po "bra1" wpisz szybkosc np 1000, w MarkerLeave1 to samo -
The video is private. Instaid of private, put it as unlisted ohh sorry, corrected
-
What name this animation? sorry, for quality https://www.youtube.com/watch?v=rB0chjTn-hI
-
MTA DayZ pickups.lua
Seba500PLK replied to Padul's topic in Pomoc ze skryptami i programowaniem w Lua
Poszukałem w kodzie DayZ, jest to chyba wystepowanie itemu tu masz kod z pickups.lua, item[5] to ta wartosc o ktora ci chodzi function createItemLoot(lootPlace, x, y, z, id) col = createColSphere(x, y, z, 1.25) setElementData(col, "itemloot", true) setElementData(col, "parent", lootPlace) setElementData(col, "MAX_Slots", 12) for i, item in ipairs(itemTable[lootPlace]) do local value = math.percentChance(item[5], math.random(1, 2)) setElementData(col, item[1], value) local ammoData, weapID = getWeaponAmmoType(item[1], true) if ammoData and value > 0 then setElementData(col, ammoData, math.random(1, 2)) end end refreshItemLoot(col, lootPlace) return col end -
yeaaa, sorry and solved Thanks
-
I say command getdeadname show: Bad argument @ 'outputChatBox' [Expected string at argument 1, got boolean]