Thread: [Solved] Betting system to database
View Single Post
AmXDusT
Member
Join Date: Feb 2019
Location: Italy / Albania
Old 01-07-2020 , 08:41   Re: Betting system to database
Reply With Quote #14

Quote:
Originally Posted by 4ever16 View Post
AmXDusT, can you also add so it prints nickname in database?
edited my previous post with the updated request.

You should delete the table:
Code:
 
DROP TABLE `db_bets`;
If you don't want to remove the entries you might have, execute this query:
Code:
ALTER TABLE `db_bets` ADD `player_nick` VARCHAR(32) NOT NULL AFTER `id`;
But the entries you'll already have won't have nick (unless you use the UPDATE_NICK), you'd have to add them manually for each one.

The plugin will save player's nick on the first bet he does. if he does other bets with different nicks, database won't be updated.
if you want it to be updated on every bet players make, uncomment the "#define UPDATE_NICK" on top.
AmXDusT is offline