• Pointshop randomly removes points
    15 replies, posted
The pointshop by _undefined for some reason is always randomly resetting people points and items. The player it does it to is random, when it does it is random, but it only happens if someone rejoins. Doing research i saw somewhere about having to set up a database with MySQL for it to stop. I'm using NFO to host my server, so as one of the autoinstallers, i can add mysqlOO, and i dont completely know what that is. So when i go into lua>bin i have gmsv_mysqloo_win32.dll. I'm not sure if that is supposed to be the data base, or if it isnt, then how to set one up. i went to [URL="https://confluence.atlassian.com/display/DOC/Database+Setup+For+MySQL"]this site[/URL] but i dont know if this is the proper way to do it for gmod. Can anyone who has solved this tell me steps to fixing it?
what if i just didnt have MySQL. Because on previous servers i didnt have it, and i never had this problem... I'm not completely sure what it does.
The main advantage of MySQL is that the database can be easily shared across servers. Or it could be used if you want to read server data from a website.
ahhh... and so if im not interested in any of that, i can remove it, correct?
If you're not already using it and you're having problems, check that file permissions are correct for the sv.db file on your server
look, i have never used this MySQL, let alone hearing about it. I have no idea how to check the permissions, or how to open the MySQL, and it annoys me that Handsome Matt says there is no solution. Seeing how long he has been here, and how many posts he has, he seems like a reliable source. Ho would i even open a .db file, or find it? How would i know what permissions should be set on it? I am just lost in all of this and i am getting 1 sentence responses. How would you feel if you were playing on a server for a while then all the sudden your points were gone. This isn't just for me, it's for all the future server owners that are having the same problem. Please, i need someway to prevent this point problem from occurring, and i know there are people out there that have fixed it somehow... I just dont know what to do...
Your problem may be solved by navigating to garrysmod/addons/pointshop/lua/sh_config.lua and changing [lua]PS.Config.DataProvider = 'mysql'[/lua] to [lua]PS.Config.DataProvider = 'pdata'[/lua] on line 5
[QUOTE=Bazoogle;44721522]...[/QUOTE] To be blunt, I don't think people who cannot understand what to do when they are being told where to look should even run servers.
internet, first off, thank you very much for giving the very precise information, (all i really needed was the file name and location ;D). However, it is already set to pdata... perhaps mysql isnt the problem, and it should be changed to mysql. And Blasteh, saying, "check that file permissions are correct for the sv.db file" is very vague. i dont know the location of the file, how to check the permission, or what to do with the .db. you did not tell me where to look.
It seems that you'll have to use MySQL, I'm not sure how else to fix your problem. If you have a MySQL database given you by your host, get the details. Otherwise, Google a MySQL host up or use a free web host that gives you one. Get the details of the database. Install [url=https://github.com/adamdburton/pointshop-mysql]this[/url] addon onto your server. Upload the .sql file in the addon folder to your MySQL server through phpMyAdmin. Open up lua/providers/mysql.lua and set up the database information in the first few lines. Finally, you should just set the data provider to "mysql", ie, do the opposite of what I told you.
garrysmod\garrysmod\sv.db Not sure how much access you have with your host, but your server needs write access to this file. Contact NFO if you don't know how to check.
[QUOTE=Handsome Matt;44720158]We have really shit code for the MySQL data provider, no idea how to fix it, nor the time really. Sorry bud.[/QUOTE] I fixed it, but then the [URL="https://github.com/adamdburton/pointshop/commit/d0e1d643bf9eb9b177e9dc8db818ea34c8b438e9"]PointShop[/URL] and [URL="https://github.com/adamdburton/pointshop-mysql/commit/d3febd670488e381c1b5e77ab37259097717ed15"]PointShop-MySQL[/URL] repository was rolled back, because of a rumor that it was broken and it was never put back after I pointed out that is was in fact not true.
All right. So i have made my database with [url]http://www.freemysqlhosting.net/[/url] and then went into phpMyAdmin. Now i have the MySQL lua set up, and the addon is in. however, i didnt know how to get the pointshop.sql from my server to the phpMyAdmin, seeing how it was online. so i simply used the one from my addons, which i dont think that is what you are supposed to do. And now you just loose all your points everytime you rejoin. So my questions are 1, how do you get your pointshop.sql from your host (im using filezilla, but dont have to) onto phpMyAdmin. and 2) is there anything i should do to it once i do add it... [editline]4th May 2014[/editline] Well, ok, so i was able to get my pointshop.sql from my host... just by simply putting in the file loaction and using the user nae and password. But what do i do with this now that i have it. I'm not completely sure, and i am sorry for my ignorance... I have never done anything with mySQL before >_>
AHHHHHH!!! Finally, i got MySQL to work!!! i guess i didnt have the info in the .lua correct!!! Thank you all for helping, i hope anyone who reads this in the future that it helps them too, and if i have any problems, i will post here, so thank you guys for the help, you are awesome!
Sorry, you need to Log In to post a reply to this thread.