MySQL saving everything apart from playerdata
#5

Quote:
Originally Posted by Kaperstone
Посмотреть сообщение
Why the username is 128 long, the max name length in-game is 20
Why is the IP 128 long, the max ipv2 length is 16
Why register and lastlogin are varchars and not int
Why are all the int's so huge.
Why you don't nave a primary key
Why do you save conntime like this? use the return of gettime(), it increases by 1 every 1 second, you can record the time player spent in-game from playerspawn

OnPlayerSpawn
startOfGameplay=gettime();

And then on player disconnect

OnPlayerDisconnect
totalPlaytime+=gettime() - startOfGameplay;

And just add it to the number you already have in the database.
Thanks for the advice but if I cant get the data to save there's no point in me optimizing it. Ive asked around on other help forums and so far nobody seems to know what the problem is, so its starting to look like a dead end unless any genius's on here can come through and be able to see what the problem is
Reply


Messages In This Thread
MySQL saving everything apart from playerdata - by Ducati - 20.02.2018, 20:50
Re: MySQL saving everything apart from playerdata - by X337 - 21.02.2018, 01:30
Re: MySQL saving everything apart from playerdata - by Ducati - 21.02.2018, 02:10
Re: MySQL saving everything apart from playerdata - by Kaperstone - 21.02.2018, 05:43
Re: MySQL saving everything apart from playerdata - by Ducati - 21.02.2018, 12:47
Re: MySQL saving everything apart from playerdata - by Kaperstone - 21.02.2018, 19:22
Re: MySQL saving everything apart from playerdata - by Ducati - 21.02.2018, 23:31

Forum Jump:


Users browsing this thread: 1 Guest(s)