If it would be liked I can add in the feature so that if for instance Account A makes CharacterA and Account A deleted CharacterA and than Account B makes CharacterA and proceeds to delete him that there would be a way to name Account B's back-up CharacterA1 and require a rename on next boot.
This, I assume is how live works in a sense (when merging the clusters people with duplicate names would have that happen).
Either way, this fixes the current code in place and if people feel that the above could would be useful I can find time to crank that out as well or if a better route is needed than that can be submitted as well.
The only other suggestion I could think of is prevent Name from being a 'key' to allow duplicates of Name. I'm not sure how this would work when copied over if a character with the same name exists.
- Code: Select all
13:23:17,535 - [3] - ERROR - DOL.Database.ObjectDatabase - Error while adding data object DOLCharactersBackup e11089ab-968f-44a5-bb41-63711b5214e2
MySql.Data.MySqlClient.MySqlException (0x80004005): Duplicate entry 'Kallendra' for key 'Name'
at MySql.Data.MySqlClient.MySqlStream.ReadPacket()
at MySql.Data.MySqlClient.NativeDriver.ReadResult(UInt64& affectedRows, Int64& lastInsertId)
at MySql.Data.MySqlClient.MySqlDataReader.GetResultSet()
at MySql.Data.MySqlClient.MySqlDataReader.NextResult()
at MySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehavior behavior)
at MySql.Data.MySqlClient.MySqlCommand.ExecuteNonQuery()
at DOL.Database.Connection.DataConnection.ExecuteNonQuery(String sqlcommand) in Source\DOLDatabase\Connection\DataConnection.cs:line 235
at DOL.Database.Handlers.MySQLObjectDatabase.AddObjectImpl(DataObject dataObject) Source\DOLDatabase\Handlers\MySQLObjectDatabase.cs:line 158