Important Database Change Coming!
Posted: Thu Jun 04, 2009 3:58 pm
Anyone developing a custom database, make sure you read this thoroughly!
There is a major database change coming from the DB Update server coming in the next week(ish) that will change some of the structures of our spawn tables.Who should care about this change?
Anyone currently building a custom world or adding spawns of any kind to their database manually or via the packet parser.
What is being changed?
Specifically, the zonespawngroup, zonespawnentry and zonespawns tables are being renamed to the following:
spawn_location_name (was zonespawngroup)
spawn_location_entry (was zonespawnentry)
spawn_location_placement (was zonespawns)
Uhh, why?
When we started designing how NPC "groups" would work, we discovered that our previous naming of the 'zonepspawngroup' table actually got us into trouble. A "Spawn Group" was previously known as the grouping of individual spawn points at a particular location in a zone. When NPC "groups" came along, we realized this table naming scheme would only lead to confusion down the road, so we opted to change it now.
After these changes are in place, we'll be adding the 4th table to this design: spawn_location_groups and all will be well with the World.
How is change being deployed?
After you download the newest development code from SVN (likely in the next few days) and start EQ2World.exe, like usual, World will ask for updates from Login, and these new tables will be inserted into your database. The next part of the script will then attempt to copy all the data that is in the obsolete tables to your new tables automatically.
In a few weeks we will push out DROP TABLE queries to clean out those old tables that are no longer needed. This should happen without any intervention on your part, aside from restarting World with the new code to get the changes.
So spawning NPCs has changed, how?
If you use in-game commands to create and save new spawns, nothing will change for you. However, if you're Database monkies like me, you will build your spawns normally (spawn, spawn_npcs, npc_appearance*) but when you place the NPC in a location, you will enter data into the spawn_location_name, entry and position tables instead of the old tables.
If you put spawn location data in the zonespawns tables, it will not be recognized by the World after this weekend.
How should I prepare for this update?
Let's see...
YOU ARE ADVISED TO BACKUP YOUR ENTIRE DB IMMEDIATELY!
YOU ARE ADVISED TO BACKUP YOUR ENTIRE DB IMMEDIATELY!
YOU ARE ADVISED TO BACKUP YOUR ENTIRE DB IMMEDIATELY!
You have been warned
Questions?