morgan1122 Posted December 21, 2010 Posted December 21, 2010 [align=center]How do i reset my game so when i want to start it so i have no forums no levels no stats and just my user?[/align] [align=center][/align] [align=center]I LOVE THIS SITE IT TELLS ME SO MUCH ;)[/align] Quote
Dayo Posted December 21, 2010 Posted December 21, 2010 Gointo phpmyadmin and delete all rows in the tables like users userstats etc... All except your ID I offer this service but at a low cost Quote
Danny696 Posted December 21, 2010 Posted December 21, 2010 Why are you typing so big and so orange, and ive already told you on msn -.- Quote
Dominion Posted December 21, 2010 Posted December 21, 2010 [mccode] Reset your users without deleating them You will also need to know how to truncate a table - http://ww.w3schools.com/sql/sql_drop.asp [mysql]TRUNCATE TABLE table_name[/mysql] Quote
morgan1122 Posted December 21, 2010 Author Posted December 21, 2010 does this work with x10 hosting guys Quote
Dominion Posted December 21, 2010 Posted December 21, 2010 does this work with x10 hosting guys As long as you have php + (my)sql as with any host... Quote
Spudinski Posted December 30, 2010 Posted December 30, 2010 There's a problem with TRUNCATE. It does NOT reset the AUTO_INCREMENT value. This, in simple terms, means your player ID's will be messed up. I would suggest creating a new database, setting it up via a mirrored copy of the game and just switching the DB's to the original game. There would be no interference for players then, and no downtime or errors. Quote
Paul Evans Posted December 30, 2010 Posted December 30, 2010 Valid point Spudie, Although i believe i did one of these before and i also coded one up for the owners of Killah-City so if you search the Forum im sure you'll find what your looking for. The Search part looks a little like this: Quote
Dominion Posted December 30, 2010 Posted December 30, 2010 They wanted to keep users so the AUTO_INCREMENT things like id would not need a reset. As for the rest [mysql] ALTER TABLE table_name AUTO_INCREMENT = 1[/mysql] obviously replacing “1” with the number you want. Could work it out on something like wamp to avoid downtime. Quote
Paul Evans Posted January 1, 2011 Posted January 1, 2011 Actually spudie if you read what the guy said he said he wanted to keep id 1 so dom is kind of right. Quote
Spudinski Posted January 1, 2011 Posted January 1, 2011 But the problem is, once he inputs hi database file his ID will be 2. Not 1 like it is supposed to be. And that will make some modifications, and even some main MCCodes files malfunction. Quote
Paul Evans Posted January 1, 2011 Posted January 1, 2011 Good point but that's if you use truncate like he said he wanted all but id 1 gone so personally truncate wouldn't be the best solution (unless you do like a truncate script then a input then set the auto_increment). Personally i just did alot of deleting (via code) it took abit more time but same result. I could have a look for the file i coded up like 2 years ago if that would help in any way. Quote
Dominion Posted January 1, 2011 Posted January 1, 2011 I read the original post wrong, just reinstall mcc if all you want is everything reset. Spuds right it should be 0. Quote
Spudinski Posted January 1, 2011 Posted January 1, 2011 @CG: MySQL queries would be faster, both sides. DELETE FROM `users` WHERE `userid` != 1; DELETE FROM `userstats` WHERE `userid` != 1; TRUNCATE {..} # the rest of the tables Quote
Paul Evans Posted January 1, 2011 Posted January 1, 2011 Ah yeah but that depends on the depth of editing on the db Spud/dom. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.