Posts: 684
Threads: 122
Joined: Jul 2011
Reputation:
0
When deleting a dynamic door, I want to have the whole column 'doorid' to be reset to 0, then re auto increment every row. Would that be possible?
Posts: 1,801
Threads: 21
Joined: Mar 2008
Reputation:
0
Well, you have to drop the column and then re-add it. But in general, I would not change the auto_increment values (for safety reasons).
(There is a way do directly change it, can't remember now).
You can do, that the auto_increment value is only an 'internal value', to make sure every row is unique.
Then it doesn't even matter if 'doorid' is 1000000 or 23.
I guess you load the dynamic doors in an array in OnGameModeInit, you can use another ID for the Script (just counting up).
EDIT: Well I think you wont have too many doors that the IDs will go extremely high, also, are there references with other tables?