Jump to content

Search the Community

Showing results for tags 'long execution warning'.

  • 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


About Me


Member Title


Gang


Location


Occupation


Interests

Found 1 result

  1. agroupTitles = {} aperTitles = {} con = dbConnect("sqlite", ":/registry.db") function isPlayerManager(plr) if getElementData(plr,"admin.number") > 2 then return true end return false end function loadgTitles() dbExec(con, "CREATE TABLE IF NOT EXISTS groupTitles ('group', 'text')") dbExec(con, "CREATE TABLE IF NOT EXISTS perTitles ('account', 'text')") dbQuery(makeTitles, {}, con, "SELECT * FROM groupTitles") dbQuery(makpeTitles, {}, con, "SELECT * FROM perTitles") end addEventHandler("onResourceStart", resourceRoot, loadgTitles) function makeTitles(titleQuery) groupTitles = dbPoll(titleQuery, 222222) for i, titleData in ipairs(groupTitles) do if (titleData) then local num = #groupTitles + 1 groupTitles[num] = { titleData["group"], titleData["text"] } outputDebugString("1") end end end function makpeTitles(perQuery) perTitles = dbPoll(perQuery, 222222) for i, perData in ipairs(perTitles) do if (perData) then local num = #perTitles + 1 perTitles[num] = { perData["account"], perData["text"] } outputDebugString("2") end end end function specials () local bool = exports.CIGcrimboss:isPlayerBoss(client) triggerClientEvent("CIGCustomTitles.unlockBoss",client,bool) end addEvent("CIGCustomTitles.getData", true) addEventHandler("CIGCustomTitles.getData", root, specials) function save () local ct = getElementData(source,"ct") setAccountData(getPlayerAccount(source),"ctitle",ct) local r = getElementData(source,"r2") setAccountData(getPlayerAccount(source),"rrgb",r) local g = getElementData(source,"g2") setAccountData(getPlayerAccount(source),"grgb",g) local b = getElementData(source,"b2") setAccountData(getPlayerAccount(source),"brgb",b) end addEventHandler("onPlayerQuit",root,save) addEventHandler("onPlayerLogout",root,save) function save2 (_,acc) local ct = tostring(getAccountData(acc,"ctitle")) setElementData(source,"ct",ct) local rr = tostring(getAccountData(acc,"rrgb")) setElementData(source,"r2",rr) local bb = tostring(getAccountData(acc,"brgb")) setElementData(source,"b2",bb) local gg = tostring(getAccountData(acc,"grgb")) setElementData(source,"g2",gg) local name = getAccountName(acc) triggerClientEvent(source,"CIGcustomTitles.addTitles",source,name) end addEventHandler("onPlayerLogin",root,save2) function onplayerlo () local acc = getAccountName(getPlayerAccount(client)) for i, col in ipairs(agroupTitles) do local thename = col[1] if thename == getElementData(client,"g") then triggerClientEvent(client,"CIGcustomTitles.addATitle",client,col[2]) outputDebugString("4") end end end addEvent("CIGcustomTitles.checkGroup",true) addEventHandler("CIGcustomTitles.checkGroup",root,onplayerlo) function onplayerl () local acc = getAccountName(getPlayerAccount(client)) for i, col in ipairs(aperTitles) do local thename = col[1] if thename == acc then triggerClientEvent(client,"CIGcustomTitles.addATitle",client,col[2]) outputDebugString("5") end end end addEvent("CIGcustomTitles.checkTitle",true) addEventHandler("CIGcustomTitles.checkTitle",root,onplayerl)
×
×
  • Create New...