Second pass through tables [skip ci]

This commit is contained in:
Akkadius 2020-03-22 03:27:44 -05:00
parent 06a51f555e
commit 8effd671c5
6 changed files with 79 additions and 79 deletions

View File

@ -165,85 +165,85 @@ namespace DatabaseSchema {
static std::vector<std::string> GetContentTables()
{
return {
"aa_ability", //
"aa_ability", // --
"aa_actions", // not in use?
"aa_effects", // not in use?
"aa_rank_effects", //
"aa_rank_prereqs", //
"aa_ranks", //
"aa_rank_effects", // --
"aa_rank_prereqs", // --
"aa_ranks", // --
"aa_required_level_cost", // not in use?
"adventure_template", //
"adventure_template_entry", //
"adventure_template_entry_flavor", //
"adventure_template", // --
"adventure_template_entry", // --
"adventure_template_entry_flavor", // --
"altadv_vars", // no longer in use?
"alternate_currency", //
"auras", //
"base_data",
"blocked_spells", //
"books", //
"char_create_combinations", //
"char_create_point_allocations", //
"alternate_currency", // --
"auras", // --
"base_data", // --
"blocked_spells", // --
"books", // --
"char_create_combinations", // --
"char_create_point_allocations", // --
"class_skill", // not in use?
"damageshieldtypes", // not in use ?
"doors", //
"faction_base_data", //
"faction_list", //
"faction_list_mod", //
"doors", // --
"faction_base_data", // --
"faction_list", // --
"faction_list_mod", // --
"fear_hints", // not used
"fishing", //
"forage", //
"global_loot", //
"goallists", //
"graveyard",
"grid", //
"grid_entries", //
"ground_spawns", //
"horses", //
"items", //
"ldon_trap_entries", //
"ldon_trap_templates", //
"lootdrop", //
"lootdrop_entries", //
"loottable", //
"loottable_entries", //
"merchantlist", //
"npc_emotes", //
"npc_faction", //
"npc_faction_entries", //
"npc_scale_global_base", //
"npc_spells", //
"npc_spells_effects", //
"npc_spells_effects_entries", //
"npc_spells_entries", //
"npc_types", //
"fishing", // --
"forage", // --
"global_loot", // --
"goallists", // --
"graveyard", // --
"grid", // --
"grid_entries", // --
"ground_spawns", // --
"horses", // --
"items", // --
"ldon_trap_entries", // --
"ldon_trap_templates", // --
"lootdrop", // --
"lootdrop_entries", // --
"loottable", // --
"loottable_entries", // --
"merchantlist", // --
"npc_emotes", // --
"npc_faction", // --
"npc_faction_entries", // --
"npc_scale_global_base", // --
"npc_spells", // --
"npc_spells_effects", // --
"npc_spells_effects_entries", // --
"npc_spells_entries", // --
"npc_types", // --
"npc_types_metadata", // not in use?
"npc_types_tint", //
"object", //
"pets", //
"pets_equipmentset", //
"pets_equipmentset_entries", //
"proximities", //
"npc_types_tint", // --
"object", // --
"pets", // --
"pets_equipmentset", // --
"pets_equipmentset_entries", // --
"proximities", // --
"races", // not used - peq editor?
"skill_caps", //
"spawn2", //
"spawn_conditions", //
"spawn_events", //
"spawnentry", //
"spawngroup", //
"spells_new", //
"start_zones", //
"starting_items", //
"task_activities", //
"tasks", //
"tasksets", //
"tradeskill_recipe", //
"tradeskill_recipe_entries", //
"traps", //
"tribute_levels", //
"tributes", //
"veteran_reward_templates", //
"zone", //
"zone_points", //
"skill_caps", // --
"spawn2", // --
"spawn_conditions", // --
"spawn_events", // --
"spawnentry", // --
"spawngroup", // --
"spells_new", // --
"start_zones", // --
"starting_items", // --
"task_activities", // --
"tasks", // --
"tasksets", // --
"tradeskill_recipe", // --
"tradeskill_recipe_entries", // --
"traps", // --
"tribute_levels", // --
"tributes", // --
"veteran_reward_templates", // --
"zone", // --
"zone_points", // --
"zone_server", // unused
"zoneserver_auth", // unused
};

View File

@ -8123,7 +8123,7 @@ void Client::SendFactionMessage(int32 tmpvalue, int32 faction_id, int32 faction_
faction_value = faction_before_hit;
// default to Faction# if we couldn't get the name from the ID
if (database.GetFactionName(faction_id, name, sizeof(name)) == false)
if (content_db.GetFactionName(faction_id, name, sizeof(name)) == false)
snprintf(name, sizeof(name), "Faction%i", faction_id);
if (tmpvalue == 0 || temp == 1 || temp == 2)

View File

@ -1799,7 +1799,7 @@ void command_timezone(Client *c, const Seperator *sep)
c->Message(Chat::Red, "Setting timezone to %i h %i m", hours, minutes);
uint32 ntz=(hours*60)+minutes;
zone->zone_time.setEQTimeZone(ntz);
database.SetZoneTZ(zone->GetZoneID(), zone->GetInstanceVersion(), ntz);
content_db.SetZoneTZ(zone->GetZoneID(), zone->GetInstanceVersion(), ntz);
// Update all clients with new TZ.
auto outapp = new EQApplicationPacket(OP_TimeOfDay, sizeof(TimeOfDay_Struct));
@ -9609,11 +9609,11 @@ void command_setgraveyard(Client *c, const Seperator *sep)
zoneid = content_db.GetZoneID(sep->arg[1]);
if(zoneid > 0) {
graveyard_id = database.CreateGraveyardRecord(zoneid, t->GetPosition());
graveyard_id = content_db.CreateGraveyardRecord(zoneid, t->GetPosition());
if(graveyard_id > 0) {
c->Message(Chat::White, "Successfuly added a new record for this graveyard!");
if(database.AddGraveyardIDToZone(zoneid, graveyard_id) > 0) {
if(content_db.AddGraveyardIDToZone(zoneid, graveyard_id) > 0) {
c->Message(Chat::White, "Successfuly added this new graveyard for the zone %s.", sep->arg[1]);
// TODO: Set graveyard data to the running zone process.
c->Message(Chat::White, "Done!");
@ -9646,7 +9646,7 @@ void command_deletegraveyard(Client *c, const Seperator *sep)
graveyard_id = content_db.GetZoneGraveyardID(zoneid, 0);
if(zoneid > 0 && graveyard_id > 0) {
if(database.DeleteGraveyard(zoneid, graveyard_id))
if(content_db.DeleteGraveyard(zoneid, graveyard_id))
c->Message(Chat::White, "Successfuly deleted graveyard %u for zone %s.", graveyard_id, sep->arg[1]);
else
c->Message(Chat::White, "Unable to delete graveyard %u for zone %s.", graveyard_id, sep->arg[1]);

View File

@ -269,7 +269,7 @@ public:
void SetNPCFactionID(int32 in)
{
npc_faction_id = in;
database.GetFactionIdsForNPC(npc_faction_id, &faction_list, &primary_faction);
content_db.GetFactionIdsForNPC(npc_faction_id, &faction_list, &primary_faction);
}
glm::vec4 m_SpawnPoint;

View File

@ -550,7 +550,7 @@ bool NpcScaleManager::ApplyGlobalBaseScalingToNPCStatically(NPC *&npc)
npc->GetNPCTypeID()
);
auto results = database.QueryDatabase(query);
auto results = content_db.QueryDatabase(query);
return results.Success();
}
@ -610,7 +610,7 @@ bool NpcScaleManager::ApplyGlobalBaseScalingToNPCDynamically(NPC *&npc)
npc->GetNPCTypeID()
);
auto results = database.QueryDatabase(query);
auto results = content_db.QueryDatabase(query);
return results.Success();
}

View File

@ -815,7 +815,7 @@ Zone::Zone(uint32 in_zoneid, uint32 in_instanceid, const char* in_short_name)
if(graveyard_id() > 0)
{
LogDebug("Graveyard ID is [{}]", graveyard_id());
bool GraveYardLoaded = database.GetZoneGraveyard(graveyard_id(), &pgraveyard_zoneid, &m_Graveyard.x, &m_Graveyard.y, &m_Graveyard.z, &m_Graveyard.w);
bool GraveYardLoaded = content_db.GetZoneGraveyard(graveyard_id(), &pgraveyard_zoneid, &m_Graveyard.x, &m_Graveyard.y, &m_Graveyard.z, &m_Graveyard.w);
if (GraveYardLoaded) {
LogDebug("Loaded a graveyard for zone [{}]: graveyard zoneid is [{}] at [{}]", short_name, graveyard_zoneid(), to_string(m_Graveyard).c_str());