Jump to content
MakeWebGames

Recommended Posts

Posted

[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]

  • 2 weeks later...
Posted

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.

Posted

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:

MWG-search.jpg

Posted

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.

Posted

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.

Posted

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.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...