Jump to content

Search the Community

Showing results for tags 'sa'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Multi Theft Auto: San Andreas 1.x
    • Support for MTA:SA 1.x
    • User Guides
    • Open Source Contributors
    • Suggestions
    • Ban appeals
  • General MTA
    • News
    • Media
    • Site/Forum/Discord/Mantis/Wiki related
    • MTA Chat
    • Other languages
  • MTA Community
    • Scripting
    • Maps
    • Resources
    • Other Creations & GTA modding
    • Competitive gameplay
    • Servers
  • Other
    • General
    • Multi Theft Auto 0.5r2
    • Third party GTA mods
  • Archive
    • Archived Items
    • Trash

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Gang


Location


Occupation


Interests

  1. function autostat(thePlayer) setPlayerStat(thePlayer, 24, 1000) setElementHealth(thePlayer, 255) end addEventHandler("onResourceStart", resourceRoot, autostat) i got this warnings: [22:09:28] WARNING: autostat\autostat.lua:2: Bad argument @ 'setPlayerStat' [Expected element at argument 1, got resource-data] [22:09:34] WARNING: autostat\autostat.lua:3: Bad argument @ 'setElementHealth' [Expected element at argument 1, got resource-data]
  2. function payScript(player,cmd,other,amount) local money = getPlayerMoney(player) local otherPlayer = getPlayerFromName(other) if not other or not amount then outputChatBox("#00BAFF[Play] #FFffFFHelyes használat: #0088FF/pay <név> <összeg>!",player,0,255,255, true) end if ((money - amount) < 0) then outputChatBox("#00BAFF[Play] #FFffFFNincs elegendő #0088FFpénzed!",player,0,255,255, true) return else setPlayerMoney(otherPlayer,getPlayerMoney(otherPlayer) + amount) setPlayerMoney(player,money - amount) outputChatBox("#00bAFF[Play] #0088FF"..amount.."Ft-ot #FFffFFküldtél neki: #0088FF"..other.."!",player,0,255,255, true) outputChatBox("#00BAFF[Play] #FFffFFKaptál #0088FF"..amount.."Ft-ot #FFffFFtőle: #0088FF"..getPlayerName(player).."!",otherPlayer,0,255,255,true) end end addCommandHandler("pay",payScript) and i got this error: xy.lua:11: attempt to perform arithmetic on a boolean value how to fix this?
  3. function aAction ( type, action, admin, player, data, more ) if ( aLogMessages[type] ) then function aStripString ( string ) string = tostring ( string ) string = string.gsub ( string, "$admin", getPlayerName ( admin ):gsub("#%x%x%x%x%x%x","") ) string = string.gsub ( string, "$by_admin_4all", isAnonAdmin4All( admin ) and "" or " by " .. getPlayerName ( admin ):gsub("#%x%x%x%x%x%x","") ) string = string.gsub ( string, "$by_admin_4plr", isAnonAdmin4Victim( admin ) and "" or " by " .. getPlayerName ( admin ):gsub("#%x%x%x%x%x%x","") ) string = string.gsub ( string, "$data2", more or "" ) if ( player ) then string = string.gsub ( string, "$player", getPlayerName ( player ) ) string = string:gsub("#%x%x%x%x%x%x","") end return tostring ( string.gsub ( string, "$data", data or "" ) ) end local node = aLogMessages[type][action] if ( node ) then local r, g, b = node["r"], node["g"], node["b"] if ( node["all"] ) then outputChatBox ( aStripString ( node["all"] ), _root, r, g, b ) end if ( node["admin"] ) and ( admin ~= player ) then outputChatBox ( aStripString ( node["admin"] ), admin, r, g, b ) end if ( node["player"] ) then outputChatBox ( aStripString ( node["player"] ), player, r, g, b ) end if ( node["log"] ) then outputServerLog ( aStripString ( node["log"] ) ) end end end end i added this lines to 'admin_server.lua', but doesn't working the script i got a lot of errors from 'admin_sync.lua':194: attempt to index global 'aPlayers' (a nil value) and rom 'admin serverjoiner.lua':48: attempt to call global 'checkClient' (a nil value) but when i add the original 'aActions' function, the errors will disappear. why? how to fix this?
  4. addEventHandler("onPlayerLogin", getRootElement(), function () local name = getPlayerName ( source ) name:gsub("#%x%x%x%x%x%x", "") if isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)), aclGetGroup("Admin")) then exports[getResourceName(resource)]:addNotification(root, name.." tulajdonos szolgálatba lépett!", "warning") elseif isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)), aclGetGroup("Moderator")) then exports[getResourceName(resource)]:addNotification(root, name.." moderátor szolgálatba lépett!", "warning") elseif isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)), aclGetGroup("SuperModerator")) then exports[getResourceName(resource)]:addNotification(root, name.." szupermoderátor szolgálatba lépett!", "warning") elseif isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)), aclGetGroup("Modi")) then exports[getResourceName(resource)]:addNotification(root, name.." moderátor szolgálatba lépett!", "warning") elseif isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)), aclGetGroup("Operator")) then exports[getResourceName(resource)]:addNotification(root, name.." operátor szolgálatba lépett!", "warning") elseif isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)), aclGetGroup("zuker")) then exports[getResourceName(resource)]:addNotification(root, name.." moderátor szolgálatba lépett!", "warning") elseif isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)), aclGetGroup("Adminseged")) then exports[getResourceName(resource)]:addNotification(root, name.." adminsegéd szolgálatba lépett!", "warning") end end ) i added 'gsub' but the color code not disappear
  5. addEventHandler ( "onElementModelChange", root, function ( oldModel, newModel ) local account = getPlayerAccount ( source ) local accountName = getAccountName ( account ) if ( newModel == 60 and not isObjectInACLGroup ( "user.".. accountName, aclGetGroup ( "Admin" ) ) ) then outputChatBox ( "Bocsi, de ez admin skin. Te nem használhatod! :(", source, r, g, b ) setElementData ( source, oldModel ) end end ) outputChatBox is working fine, but the player can change his skin to 60 no errors/warnings in debugscript How to fix this?
  6. i want to add afk check to my nametag, but i dont know how i tried this, but doesn't working --server function checkAFKPlayers() for index, thePlayer in ipairs(getElementsByType("player")) do if (getPlayerIdleTime(thePlayer) > 300000) then AFKCheck = "AFK" end end end setTimer(checkAFKPlayers, 30000, 0) --client (only the two line) local AFKCheck = {} dxDrawColorText ("#00BAFF" .. getPlayerName(player) .. " (" .. AFKState .. ")", sx-w, sy - offset, sx, sy - offset, tocolor(r,g,b,textalpha), player ~= g_Me and textscale*NAMETAG_TEXTSIZE or (textscale*NAMETAG_TEXTSIZE)/1.5, srfont, "center", "bottom", false, false, false ) how to make this working? /sorry for my bad english:c/
  7. i added this lines to my admintag script, but...doesn't working. no errors/warnings in debugscript 3 :'s settings = { ['antiswear'] = { ['enabled'] = true, ['swears'] = { ['asshole'] = '*******', [':O'] = '****', ['slut'] = '****', ['bitch'] = '*****', [':O'] = '****', ['whore'] = '*****', ['pussy'] = '*****', [':O'] = '***', ['perro'] = '*****', ['puta'] = '****', ['joder'] = '*****' } } } if settings['antiswear']['enabled'] then for i, v in pairs(settings['swearFilter']['swears']) do while msg:lower():find(i:lower(),1,true) do local start, end_ = msg:lower():find(i:lower(),1,true) local found = msg:sub(start,end_) msg = msg:gsub(found,v) end end end what wrong? how to fix this?
  8. local function ujteamsay(message, messageType) if messageType == 2 then cancelEvent() outputChatBox("(CSOPORT) "..getPlayerName(source)..": #FFffFF"..message, root, red, green, blue, true ) end end addEventHandler("onPlayerChat", root, ujteamsay) how to fix this? i want just team mates see the message.. *sorry for my very bad English :c*
  9. function North () local north = createBlipAttachedTo ( north, 4 ); dxDrawImage(north, 20, 20, 'files/images/blips/north.png', 0, 0, 0, tocolor(0, 0, 0, 255), false); end i tried this, but doesn't working. how to add north blip to a radar script?
  10. Здравствуйте, дорогие обитатели форума MTASA. Хочу представить Вашему вниманию, игровой сервер, мод которого написан одним человеком за 4 месяца. Сервер носит развлекательный характер, жанра RPG. Главный приоритет на прокачку персонажа и покупку имущества. Вообщем цель - обогащение, заработок и правильная стратегия развития. Мини-обзор функционала: Средний дневной онлайн: 100-150 человек. Сайт: https://smotramta.ru/ Группа ВКонтакте: https://vk.com/smotramtasa IP Сервера: 94.142.142.146:22003
  11. local myCol = createColRectangle (-2039, 165, 22, 20) local myCol = createColRectangle (1342.5, -1817.4, 38, 40) local myCol = createColRectangle (1960, 1618.5, 16, 20) function destroyTheVehicles (player) if getElementType (player) == "player" and isPedInVehicle (player) then destroyElement (getPedOccupiedVehicle (player)) outputChatBox ("Ide nem léphetsz be kocsival! Felejtsd el, különben büntit kapsz.", player, r, g, b) end end addEventHandler ("onColShapeHit", myCol, destroyTheVehicles) Working on localhost server, but doesn't working on hosted server How to fix this bug?
  12. -- client -- local displayWidth, displayHeight = guiGetScreenSize(); local notificationData = {}; local notificationFont = dxCreateFont('files/fonts/roboto.ttf', 12 * 2, false); local iconsFont = dxCreateFont('files/fonts/icons.ttf', 12 * 2, false); addEventHandler('onClientRender', root, function() for k, v in pairs(notificationData) do if (v.State == 'fadeIn') then local alphaProgress = (getTickCount() - v.AlphaTick) / 650; local alphaAnimation = interpolateBetween(0, 0, 0, 255, 0, 0, alphaProgress, 'Linear'); if (alphaAnimation) then v.Alpha = alphaAnimation; else v.Alpha = 255; end if (alphaProgress > 1) then v.Tick = getTickCount(); v.State = 'openTile'; end elseif (v.State == 'fadeOut') then local alphaProgress = (getTickCount() - v.AlphaTick) / 650; local alphaAnimation = interpolateBetween(255, 0, 0, 0, 0, 0, alphaProgress, 'Linear'); if (alphaAnimation) then v.Alpha = alphaAnimation; else v.Alpha = 0; end if (alphaProgress > 1) then notificationData = {}; end elseif (v.State == 'openTile') then local tileProgress = (getTickCount() - v.Tick) / 350; local tilePosition = interpolateBetween(v.StartX, 0, 0, v.EndX, 0, 0, tileProgress, 'Linear'); local tileWidth = interpolateBetween(0, 0, 0, v.Width, 0, 0, tileProgress, 'Linear'); if (tilePosition and tileWidth) then v.CurrentX = tilePosition; v.CurrentWidth = tileWidth; else v.CurrentX = v.EndX; v.CurrentWidth = v.Width; end if (tileProgress > 1) then v.State = 'fixTile'; setTimer(function() v.Tick = getTickCount(); v.State = 'closeTile'; end, string.len(v.Text) * 45 + 5000, 1); end elseif (v.State == 'closeTile') then local tileProgress = (getTickCount() - v.Tick) / 350; local tilePosition = interpolateBetween(v.EndX, 0, 0, v.StartX, 0, 0, tileProgress, 'Linear'); local tileWidth = interpolateBetween(v.Width, 0, 0, 0, 0, 0, tileProgress, 'Linear'); if (tilePosition and tileWidth) then v.CurrentX = tilePosition; v.CurrentWidth = tileWidth; else v.CurrentX = v.StartX; v.CurrentWidth = 0; end if (tileProgress > 1) then v.AlphaTick = getTickCount(); v.State = 'fadeOut'; end elseif (v.State == 'fixTile') then v.Alpha = 255; v.CurrentX = v.EndX; v.CurrentWidth = v.Width; end roundedRectangle(v.CurrentX, 20, 25 + v.CurrentWidth, 25, tocolor(0, 0, 0, 150 * v.Alpha / 255), _, true); dxDrawRectangle(v.CurrentX, 20, 25, 25, tocolor(0, 0, 0, 255 * v.Alpha / 255), true); if (v.Alpha == 255) then dxDrawText(v.Text, v.CurrentX + 25 + 10, 20, v.CurrentX + 25 + 10 + v.CurrentWidth - 20, 20 + 25, tocolor(255, 255, 255, 255), 0.40, notificationFont, 'center', 'center', true, false, true); end if (v.Type == 'error') then dxDrawText('', v.CurrentX + 5, 20, v.CurrentX + 5 + 25 - 10, 20 + 25, tocolor(215, 90, 90, v.Alpha), 0.50, iconsFont, 'center', 'center', false, false, true); elseif (v.Type == 'warning') then dxDrawText('', v.CurrentX + 5, 20, v.CurrentX + 5 + 25 - 10, 20 + 25, tocolor(220, 180, 80, v.Alpha), 0.50, iconsFont, 'center', 'center', false, false, true); elseif (v.Type == 'info') then dxDrawText('', v.CurrentX + 5, 20, v.CurrentX + 5 + 25 - 10, 20 + 25, tocolor(85, 180, 245, v.Alpha), 0.50, iconsFont, 'center', 'center', false, false, true); elseif (v.Type == 'success') then dxDrawText('', v.CurrentX + 5, 20, v.CurrentX + 5 + 25 - 10, 20 + 25, tocolor(80, 205, 105, v.Alpha), 0.50, iconsFont, 'center', 'center', false, false, true); end end end ) addEvent('addNotification', true); function addNotification(text, type) if (text and type) then if (notificationData ~= nil) then table.remove(notificationData, #notificationData); end table.insert(notificationData, { StartX = (displayWidth / 2) - (25 / 2), EndX = (displayWidth / 2) - ((dxGetTextWidth(text, 0.40, notificationFont) + 20 + 25) / 2), Text = text, Width = dxGetTextWidth(text, 0.40, notificationFont) + 20, Alpha = 0, State = 'fadeIn', Tick = 0, AlphaTick = getTickCount(), CurrentX = (displayWidth / 2) - (25 / 2), CurrentWidth = 0, Type = type or 'info' } ); playSoundFrontEnd(11); end end addEventHandler('addNotification', root, addNotification); function roundedRectangle(x, y, w, h, borderColor, bgColor, postGUI) if (x and y and w and h) then if (not borderColor) then borderColor = tocolor(0, 0, 0, 200); end if (not bgColor) then bgColor = borderColor; end --> Background dxDrawRectangle(x, y, w, h, bgColor, postGUI); --> Border dxDrawRectangle(x + 2, y - 1, w - 4, 1, borderColor, postGUI); -- top dxDrawRectangle(x + 2, y + h, w - 4, 1, borderColor, postGUI); -- bottom dxDrawRectangle(x - 1, y + 2, 1, h - 4, borderColor, postGUI); -- left dxDrawRectangle(x + w, y + 2, 1, h - 4, borderColor, postGUI); -- right end end -- server -- function addNotification(player, text, type) if (player and text and type) then exports["notices"]:addNotification("Test","success"); triggerClientEvent(player, 'addNotification', player, text, type); end end addEventHandler("onResourceStart", addNotification, player, text, type)
  13. Hi all, I request a simple thing, because I really want to see this exist though I dont know how to make it myself. I request that u make a little program or something like that that I can just go in game then press a button or alt tab out and activate it and it will move my character randomly ever few seconds, so that let's say you don't get kicked or something like that. Please if u could do this you would make my day really. Hope to see some, your's truly, Lopexsw.
  14. local screenW, screenH = guiGetScreenSize() local GUIEditor = { button = {}, window = {}, edit = {} } GUIEditor.window[1] = guiCreateWindow(0.35, 0.40, 0.32, 0.12, "Event hírdető panel", true) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.button[1] = guiCreateButton(0.04, 0.68, 0.78, 0.23, "Beírt szöveg kiírása", true, GUIEditor.window[1]) GUIEditor.edit[1] = guiCreateEdit(0.03, 0.21, 0.93, 0.38, "", true, GUIEditor.window[1]) GUIEditor.button[2] = guiCreateButton(0.84, 0.68, 0.14, 0.23, "Bezár", true, GUIEditor.window[1]) guiSetVisible(GUIEditor.window[1], false) guiSetInputMode("no_binds_when_editing") function showGUI() guiSetVisible( GUIEditor.window[1], true ) showCursor( true ) end addEvent( "showguii", true ) addEventHandler( "showguii", localPlayer, showGUI ) addEventHandler("onClientGUIClick",root, function () if source == GUIEditor.button[2] then guiSetVisible(GUIEditor.window[1],false) showCursor(false) end end ) addEventHandler("onClientGUIClick",root, function () if source == GUIEditor.button[1] then guiSetVisible(GUIEditor.window[1],false) showCursor(false) end end ) addEventHandler("onClientGUIClick", GUIEditor.button[1], function ( ) text1 = guiGetText ( GUIEditor.edit[1] ) --text2 = guiGetText ( valasz1 ) --text3 = guiGetText ( valasz2 ) if text1 ~= "" then triggerServerEvent( "server",localPlayer,text1 ) setTimer ( function( ) text1 = nil end,5000, 1 ) end end,false ) addEventHandler ( 'onClientRender',root, function ( ) dxDrawText(text1, (screenW * 0.2924) + 1, (screenH * 0.3778) + 1, (screenW * 0.7014) + 1, (screenH * 0.5400) + 1, tocolor(0, 0, 0, 255), 2.50, "default-bold", "left", "top", false, true, false, false, false) dxDrawText(text1, screenW * 0.2924, screenH * 0.3778, screenW * 0.7014, screenH * 0.5400, tocolor(0, 186, 255, 255), 2.50, "default-bold", "left", "top", false, true, false, false, false) end ) the dx text why not show on all players screen? o-O
  15. local GUIEditor = { window = {}, scrollbar = {}, label = {} } GUIEditor.window[1] = guiCreateWindow(406, 147, 673, 585, "", false) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.scrollbar[1] = guiCreateScrollBar(615, 35, 27, 513, false, false, GUIEditor.window[1]) GUIEditor.label[1] = guiCreateLabel(18, 42, 587, 496, "a\n\nb\n\nc\n\nd\n\ne\n\nf\n\ng\n\nh\n\ni\n\nj\n\nk\n\nl\n\nm\n\nn\n\no\n\np\n\nq\n\nr\n\ns\n\nt\n\nu\n\nv\n\nw\n\nx\n\ny\n\nz", false, GUIEditor.window[1]) scrollbar doesn't working, why? o_O
  16. local x, y = guiGetScreenSize() local font_os = (x/1600+y/900)/2 local font = font_os*1 local nSpaceY = dxGetFontHeight(font, "default-bold") local nSpaceYOld = dxGetFontHeight(2, "default-bold") local szovegek = {} local drawCount = 5 local drawnCount = 0 local drawFrom = 0 local automaticChange = 1 for i=0, 4, 1 do szovegek[i] = "" end function itsRenderTime() for i = 0, 4, 1 do if szovegek[i] then local topSpaceX = dxGetTextWidth(szovegek[i]:gsub("#%x%x%x%x%x%x",""),font,"default-bold") local webX=topSpaceX+font_os*10 dxDrawRectangle ( x-webX-font_os*5, nSpaceYOld*2+font_os*8+nSpaceY*(4-i)+font_os*(4-i), webX, nSpaceY+font_os*4, tocolor ( 0, 0, 0, 155 ) ) dxDrawEmptyRec ( x-webX-font_os*5, nSpaceYOld*2+font_os*8+nSpaceY*(4-i)+font_os*(4-i), webX, nSpaceY+font_os*4, tocolor ( 255, 255, 255, 200 ), 2 ) dxDrawText ( szovegek[i], x-webX, nSpaceYOld*2+font_os*10+nSpaceY*(4-i)+font_os*(4-i), topSpaceX, nSpaceY, tocolor ( 255, 255, 255, 255 ), font, "default-bold", "left", "top",true,false,false,true ) end end end addEventHandler("onClientRender", getRootElement(), itsRenderTime) addEventHandler("onClientPlayerChangeNick", root, function(lastNick, newNick) table.insert(szovegek[i], "#00BAFF" .. lastNick .. " #FFffffneve mostantól #00baff" .. newNick .. "") end) function dxDrawEmptyRec(absX,absY,sizeX,sizeY,color,ancho) dxDrawRectangle ( absX,absY,sizeX,ancho,color ) dxDrawRectangle ( absX,absY+ancho,ancho,sizeY-ancho,color ) dxDrawRectangle ( absX+ancho,absY+sizeY-ancho,sizeX-ancho,ancho,color ) dxDrawRectangle ( absX+sizeX-ancho,absY+ancho,ancho,sizeY-ancho*2,color ) end local aValto = true function azEltunteto() if aValto then aValto = false removeEventHandler ( "onClientRender", root, itsRenderTime ) else aValto = true addEventHandler ( "onClientRender", root, itsRenderTime ) end end bindKey("delete","down",azEltunteto)
×
×
  • Create New...