DB/WMOAreaTable: Difference between revisions

From wowdev
Jump to navigation Jump to search
No edit summary
m (Add advice for editing this dbc)
 
(12 intermediate revisions by 5 users not shown)
Line 1: Line 1:
due to how the client loads and caches this dbc, the entries need to be sorted by wmo id (and probably groupid as well)
Due to how the client loads and caches this DBC, the entries need to be sorted by WMO id (primary) and SetID (secondary). The best way to modify this DBC is to export it to SQL, sort by WMOID->SetID->GroupID, copy this ordering and re-insert it into SQL before importing into DBC. This ensures the client correctly caches the DBC.


Note that for top-level area entries (those referred to by the WMO root file) may have their WMOGroupID fields set to -1 to signify none.
==0.5.3.3368==
This table mirrors [[DB/AreaTable#0.5.3.3368|DB/AreaTable]]; documented notes, foreign keys and flags are the same. If <tt>m_Flags</tt> is 0, the client will fallback to the parent record's <tt>m_Flags</tt> - if any.
struct WMOAreaTableRec {
  uint32_t m_ID;
  uint32_t m_WMOID;
  uint32_t m_NameSetID;
  int32_t m_WMOGroupID;
  uint32_t m_DayAmbienceSoundID;
  uint32_t m_NightAmbienceSoundID;
  uint32_t m_SoundProviderPref;
  uint32_t m_SoundProviderPrefUnderwater;
  uint32_t m_MIDIAmbience;
  uint32_t m_MIDIAmbienceUnderwater;
  uint32_t m_ZoneMusic;
  uint32_t m_IntroSound;
  uint32_t m_IntroPriority;
  uint32_t m_Flags;
  {{Template:Type|langstringref}} m_AreaName_lang;
};
==1.12.1.5875==
struct WMOAreaTableRec {
  uint32_t m_ID;
  uint32_t m_WMOID;
  uint32_t m_NameSetID;
  int32_t m_WMOGroupID;
  {{Template:Type/foreign_key|table=SoundProviderPreferences}} m_SoundProviderPref;
  {{Template:Type/foreign_key|table=SoundProviderPreferences}} m_SoundProviderPrefUnderwater;
  {{Template:Type/foreign_key|table=SoundAmbience}} m_AmbienceID;
  {{Template:Type/foreign_key|table=ZoneMusic}} m_ZoneMusic;
  {{Template:Type/foreign_key|table=ZoneIntroMusicTable}} m_IntroSound;
  uint32_t m_flags;
  {{Template:Type/foreign_key|table=AreaTable}} m_AreaTableID;
  {{Template:Type|langstringref}} m_AreaName_lang;
};
==Structure==
==Structure==
  '''Column Field Type Notes'''  
  '''Column Field Type Notes'''  
Line 6: Line 43:
  2 root_ID Integer called from a [[WMO#WMO_root_file|WMO-Root file]].
  2 root_ID Integer called from a [[WMO#WMO_root_file|WMO-Root file]].
  3 NameSet Integer If your WMO is spawned with NameSet 4, search for the rows with a 3 in here.
  3 NameSet Integer If your WMO is spawned with NameSet 4, search for the rows with a 3 in here.
  4 group_ID Integer called from a [[WMO#WMO_group_file|WMO-Group file]]. | -1 for overal name ("Stormwind" etc)
  4 WMO_group_ID Integer called from a [[WMO#WMO_group_file|WMO-Group file]]. | -1 for overal name ("Stormwind" etc)
  5 Unknown Integer
  5 SoundProviderPref Integer
  6 Unknown Integer
  6 SoundProviderPrefSubmer Integer
  7 Unknown Integer
  7 AmbienceID Integer
  8 Unknown Integer
  8 ZoneMusic Integer
  9 Unknown Integer
  9 IntroSound Integer
  10 flags Integer CWorldMap::QueryOutdoors: rec.flags & 4 || rec.flags & 2. &0x18: Minimap::s_singleExterior = true unless groupRec::flags & 0x20
  10 flags Integer CWorldMap::QueryOutdoors: rec.flags & 4 || rec.flags & 2. &0x18: Minimap::s_singleExterior = true unless groupRec::flags & 0x20
  11 iRefID_[[AreaTable.dbc|AreaTable]] Integer If 0, the underlying terrain is asked for its id.
  11 iRefID_[[AreaTable.dbc|AreaTable]] Integer If 0, the underlying terrain is asked for its id.
  12-28 Name String + [[Loc]] The name of the area. If 0, an AreaTable query is made.
  12-28 Name String + [[Loc]] The name of the area. If 0, an AreaTable query is made.
===Flags===
{| style="background:#FCFCFC; color:black"
|-
! width="80" | Value
! width="600" | Description
|-
| 0x001 || Render Minimap
|-
| 0x002 || Force Indoors
|-
| 0x004 || Force Outdoors
|-
| 0x008 || Generate Single Exterior Map
|-
| 0x010 || Stormwind
|-
| 0x020 || Chunk uses terrain for Minimap
|-
| 0x040 || Ignore for Minimap and Effects
|-
| 0x080 || Ignore Fatigue
|}


  struct WMOAreaTableRec
  struct WMOAreaTableRec
Line 29: Line 90:
   DWORD m_flags;
   DWORD m_flags;
   DWORD m_AreaTableID;
   DWORD m_AreaTableID;
   DWORD m_AreaName_lang;
   {{Template:Type|langstringref}} m_AreaName_lang;
   DWORD m_field12; // added in 4.x
   DWORD m_field12; // added in 4.x
   DWORD m_field13; // added in 4.x
   DWORD m_field13; // added in 4.x
Line 40: Line 101:
   uint32_t m_WMOID;
   uint32_t m_WMOID;
   uint32_t m_NameSetID;
   uint32_t m_NameSetID;
   uint32_t m_WMOGroupID;
   int32_t m_WMOGroupID;
   {{Template:Type/foreign_key|table=SoundProviderPreferences}} m_SoundProviderPref;
   {{Template:Type/foreign_key|table=SoundProviderPreferences}} m_SoundProviderPref;
   {{Template:Type/foreign_key|table=SoundProviderPreferences}} m_SoundProviderPrefUnderwater;
   {{Template:Type/foreign_key|table=SoundProviderPreferences}} m_SoundProviderPrefUnderwater;
Line 48: Line 109:
   uint32_t m_flags;
   uint32_t m_flags;
   {{Template:Type/foreign_key|table=AreaTable}} m_AreaTableID;
   {{Template:Type/foreign_key|table=AreaTable}} m_AreaTableID;
   {{Template:Type|stringref}} m_AreaName_lang;
   {{Template:Type|langstringref}} m_AreaName_lang;
   {{Template:Type/foreign_key|table=ZoneIntroMusicTable}} m_uwIntroSound;
   {{Template:Type/foreign_key|table=ZoneIntroMusicTable}} m_uwIntroSound;
   {{Template:Type/foreign_key|table=ZoneMusic}} m_uwZoneMusic;
   {{Template:Type/foreign_key|table=ZoneMusic}} m_uwZoneMusic;
Line 54: Line 115:
  };
  };
[[Category:DBC]]
[[Category:DBC]]
[[Category:DBC_Alpha]]
[[Category:DBC_Vanilla]]
[[Category:DBC_WotLK]]
[[Category:DBC_WotLK]]
[[Category:DBC_WoD]]
[[Category:DBC_WoD]]
[[Category:6.0.1.18179]]
[[Category:6.0.1.18179]]

Latest revision as of 06:22, 1 December 2023

Due to how the client loads and caches this DBC, the entries need to be sorted by WMO id (primary) and SetID (secondary). The best way to modify this DBC is to export it to SQL, sort by WMOID->SetID->GroupID, copy this ordering and re-insert it into SQL before importing into DBC. This ensures the client correctly caches the DBC.

Note that for top-level area entries (those referred to by the WMO root file) may have their WMOGroupID fields set to -1 to signify none.

0.5.3.3368

This table mirrors DB/AreaTable; documented notes, foreign keys and flags are the same. If m_Flags is 0, the client will fallback to the parent record's m_Flags - if any.

struct WMOAreaTableRec {
  uint32_t m_ID;
  uint32_t m_WMOID;
  uint32_t m_NameSetID;
  int32_t m_WMOGroupID;
  uint32_t m_DayAmbienceSoundID;
  uint32_t m_NightAmbienceSoundID;
  uint32_t m_SoundProviderPref;
  uint32_t m_SoundProviderPrefUnderwater;
  uint32_t m_MIDIAmbience;
  uint32_t m_MIDIAmbienceUnderwater;
  uint32_t m_ZoneMusic;
  uint32_t m_IntroSound;
  uint32_t m_IntroPriority;
  uint32_t m_Flags;
  langstringref m_AreaName_lang;
};

1.12.1.5875

struct WMOAreaTableRec {
  uint32_t m_ID;
  uint32_t m_WMOID;
  uint32_t m_NameSetID;
  int32_t m_WMOGroupID;
  foreign_key<uint32_t, &SoundProviderPreferencesRec::m_ID> m_SoundProviderPref;
  foreign_key<uint32_t, &SoundProviderPreferencesRec::m_ID> m_SoundProviderPrefUnderwater;
  foreign_key<uint32_t, &SoundAmbienceRec::m_ID> m_AmbienceID;
  foreign_key<uint32_t, &ZoneMusicRec::m_ID> m_ZoneMusic;
  foreign_key<uint32_t, &ZoneIntroMusicTableRec::m_ID> m_IntroSound;
  uint32_t m_flags;
  foreign_key<uint32_t, &AreaTableRec::m_ID> m_AreaTableID;
  langstringref m_AreaName_lang;
};

Structure

Column 	Field 			Type 		Notes 
1 	ID 			Integer 	
2 	root_ID 		Integer 	called from a WMO-Root file.
3 	NameSet 		Integer 	If your WMO is spawned with NameSet 4, search for the rows with a 3 in here.
4 	WMO_group_ID 		Integer 	called from a WMO-Group file. | -1 for overal name ("Stormwind" etc)
5 	SoundProviderPref	Integer 	
6 	SoundProviderPrefSubmer	Integer 	
7 	AmbienceID		Integer 	
8 	ZoneMusic 		Integer 	
9 	IntroSound 		Integer 	
10 	flags			Integer 	CWorldMap::QueryOutdoors: rec.flags & 4 || rec.flags & 2. &0x18: Minimap::s_singleExterior = true unless groupRec::flags & 0x20
11 	iRefID_AreaTable 	Integer		If 0, the underlying terrain is asked for its id.
12-28 	Name 			String + Loc 	The name of the area. If 0, an AreaTable query is made.

Flags

Value Description
0x001 Render Minimap
0x002 Force Indoors
0x004 Force Outdoors
0x008 Generate Single Exterior Map
0x010 Stormwind
0x020 Chunk uses terrain for Minimap
0x040 Ignore for Minimap and Effects
0x080 Ignore Fatigue


struct WMOAreaTableRec
{
 DWORD m_ID;
 DWORD m_WMOID;
 DWORD m_NameSetID;
 DWORD m_WMOGroupID;
 DWORD m_SoundProviderPref;
 DWORD m_SoundProviderPrefUnderwater;
 DWORD m_AmbienceID;
 DWORD m_ZoneMusic;
 DWORD m_IntroSound;
 DWORD m_flags;
 DWORD m_AreaTableID;
 langstringref m_AreaName_lang;
 DWORD m_field12; // added in 4.x
 DWORD m_field13; // added in 4.x
 DWORD m_field14; // added in 4.x
};

6.0.1.18179

struct WMOAreaTableRec {
  uint32_t m_ID;
  uint32_t m_WMOID;
  uint32_t m_NameSetID;
  int32_t m_WMOGroupID;
  foreign_key<uint32_t, &SoundProviderPreferencesRec::m_ID> m_SoundProviderPref;
  foreign_key<uint32_t, &SoundProviderPreferencesRec::m_ID> m_SoundProviderPrefUnderwater;
  foreign_key<uint32_t, &SoundAmbienceRec::m_ID> m_AmbienceID;
  foreign_key<uint32_t, &ZoneMusicRec::m_ID> m_ZoneMusic;
  foreign_key<uint32_t, &ZoneIntroMusicTableRec::m_ID> m_IntroSound;
  uint32_t m_flags;
  foreign_key<uint32_t, &AreaTableRec::m_ID> m_AreaTableID;
  langstringref m_AreaName_lang;
  foreign_key<uint32_t, &ZoneIntroMusicTableRec::m_ID> m_uwIntroSound;
  foreign_key<uint32_t, &ZoneMusicRec::m_ID> m_uwZoneMusic;
  foreign_key<uint32_t, &SoundAmbienceRec::m_ID> m_uwAmbience;
};