• Need Help Creating Files with GLON Serverside
    3 replies, posted
Recently, I found a version of NoxiousNet's 2009 gamemode code and said, [I]"Why don't I try to get it all to work in order to better understand lua?"[/I] I set out on that goal and I've nearly recreated [B]ALMOST [/B]every single feature that exists in NoxiousNet as of the time of posting. I am only having one problem, however, I cannot for the life of me get glon to write to a unique file for every steam id (not STEAM_X:X:XXXXXXXXX, it uses the ending, eg XXXXXXXXXX.txt) that joins and adds data for the accounts, store, and money to function. I have tried everything, but no matter how much I try, it either creates the file clientside instead of serverside like it was intended, or doesn't work at all. [B]I will give the[/B] [B]global/core.lua file to anyone who can help create the tables serverside, and have the server read, edit, and add new lines to the files created. [/B]The files must be able to decode the files and use the values stored in the file as values (eg acc_table["MemberLevel"] = pl.MemberLevel ). All data files [B]must[/B] be created under [B]/noxaccounts or /accounts.[/B] If possible, or allowed, I will give the person who helps me first with my issue the code[B] for use on their servers AND THEIR SERVERS ONLY, please do not disappoint me and distribute the files.[/B]
[b][url=http://wiki.garrysmod.com/?title=Player.UniqueID]Player.UniqueID [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b], first of all. And what is the issue more precisely? The code is executed clientside?
nah he just want to do Saving [lua] file.Write("users/"..ply:UniqueID()..".txt",glon.encode(acc_table)) // Everyone gets their own seperate acc file with their stuff stored in it [/lua] Loading [lua] file.Read("users/"..ply:UniqueID()..".txt").MemberLevel // Loads the Memberlevel from the table [/lua]
[QUOTE=RetTurtl3;34324325]nah he just want to do Saving [lua] file.Write("users/"..ply:UniqueID()..".txt",glon.encode(acc_table)) // Everyone gets their own seperate acc file with their stuff stored in it [/lua] Loading [lua] file.Read("users/"..ply:UniqueID()..".txt").MemberLevel // Loads the Memberlevel from the table [/lua][/QUOTE] Thank you fine sirs, I will try it out, I will personally thank you both if it works. Cheers. But could you mind adding me on Steam? [editline]21st January 2012[/editline] [QUOTE=vercas;34322937][b][url=http://wiki.garrysmod.com/?title=Player.UniqueID]Player.UniqueID [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b], first of all. And what is the issue more precisely? The code is executed clientside?[/QUOTE] Yes it is, I need it to be executed serverside as soon as the player joins.
Sorry, you need to Log In to post a reply to this thread.