Jump to content

Unknown7

Members
  • Posts

    1
  • Joined

  • Last visited

Unknown7's Achievements

I ordered some spaghetti with marinara sauce and I got egg noodles and ketchup. I'm an average nobody.

I ordered some spaghetti with marinara sauce and I got egg noodles and ketchup. I'm an average nobody. (2/54)

0

Reputation

  1. Hello there! I'm trying to get my old server back online, I'm currently having problems with the stats scripts, which kinda works since it returns the table info on servers, such as dms, wins, cash and etc, even the old stats from 2010. It also inserts the new account starting stats (1dms, 1win, $1000 cash). The problem is that new stats don't get saved. Checking the wiki I found executeSQLUpdate function is deprecated and I should use executeSQLQuery but I don't know exactly how to do it, so I'm asking for help. At least an example on how to do it with my script. Here is the server script using executeSQLUpdate function DBSave(playerName) if statsCash[playerName] then statsCash[playerName] = tonumber(statsCash[playerName]) executeSQLUpdate ("stats", "cash = '" .. statsCash[playerName] .. "', dms = '" .. statsDms[playerName] .. "', wins = '" .. statsWins[playerName] .. "', owner = '" .. statsOwner[playerName] .. "', skill = '" .. statsSpts[playerName] .. "', pts = '" .. statsPts[playerName] .. "'", "player = '" .. playerName .. "'") executeSQLUpdate ("userinfo", "sexage = '" .. infoSex[playerName] .. "', contact = '" .. infoContact[playerName] .. "', message = '" .. infoMsg[playerName] .. "', gametime = '" .. infoGametime[playerName] .. "', seen = '" .. infoSeen[playerName] .. "', lock = '" .. infoLock[playerName] .. "', rating = '" .. infoPrate[playerName] .. "', votes = '" .. infoPvote[playerName] .. "', messageon = '" .. infoMsgon[playerName] .. "'", "player = '" .. playerName .. "'") executeSQLUpdate ("settings", "carcolor1 = '" .. settVColor1[playerName] .. "', carcolor2 = '" .. settVColor2[playerName] .. "', skin = '" .. settSkin[playerName] .. "', namecolor = '" .. settCColor[playerName] .. "', chatcolor = '" .. settTColor[playerName] .. "'", "player = '" .. playerName .. "'") executeSQLUpdate ("xstats", "abooms = '" .. statsX[playerName..'abooms'] .. "', akicks = '" .. statsX[playerName..'akicks'] .. "', abans = '" .. statsX[playerName..'abans'] .. "', pbooms = '" .. statsX[playerName..'pbooms'] .. "', pkicks = '" .. statsX[playerName..'pkicks'] .. "', pbans = '" .. statsX[playerName..'pbans'] .. "', spins = '" .. statsX[playerName..'spins'] .. "', cashin = '" .. statsX[playerName..'cashin'] .. "', cashout = '" .. statsX[playerName..'cashout'] .. "', rolls = '" .. statsX[playerName..'rolls'] .. "'", "player = '" .. playerName .. "'") end end Everything else in the server is working fine, thank you in advance.
×
×
  • Create New...