Winstrol

Members
  • Content Count

    5
  • Joined

  • Last visited

Community Reputation

0 Neutral

About Winstrol

  • Rank
    Vic

Details

  • Location
    POLAND
  1. db = dbConnect("mysql", "dbname="..xmlNodeGetValue(dbname)..";host="..xmlNodeGetValue(host)..";charset="..xmlNodeGetValue(charset).."", ""..xmlNodeGetValue(user).."", ""..xmlNodeGetValue(pass).."", "share="..xmlNodeGetValue(share).."", "batch="..xmlNodeGetValue(batch).."", "autoreconnect="..xmlNodeGetValue(autorec).."", "log="..xmlNodeGetValue(logs).."")
  2. <config> <dbname>mydb</dbname> <host>127.0.0.1</host> <charset>utf8</charset> <username>root</username> <password></password> <share>1</share> <batch>0</batch> <autoreconnect>1</autoreconnect> <log>1</log> </config>
  3. Hello everyone! I'm 100% newbie in Lua coding, I'm trying to learn Lua language. To the point.. I'm trying connect my gamemode to MySQL, but data to connect with database, I want to get from file, or meta.xml. dbname = get("start.dbname") host = get("start.host") charset = get("start.charset") user = get("start.username") pass = get("start.password") share = get("start.share") batch = get("start.batch") autorec = get("start.autoreconnect") logs = get("start.logs") db = dbConnect("mysql", "dbname="..dbname..";host="..host..";charset="..charset.."", ""..user.."", ""..pass.."", "share="..share.."", "batch="..batch.."", "autoreconnect="..autorec.."", "log="..logs.."") Server console shows me an error. My meta.xml <settings> <setting name="dbname" value="database" /> <setting name="host" value="127.0.0.1" /> <setting name="charset" value="utf8" /> <setting name="username" value="root" /> <setting name="password" value="" /> <setting name="share" value="1" /> <setting name="batch" value="0" /> <setting name="autoreconnect" value="1" /> <setting name="log" value="1" /> </settings> I don't have any idea for do this thing. Only one way is xmlFindChild/xmlLoadString, etc.?