Show
Ignore:
Timestamp:
11/21/08 08:47:55 (17 years ago)
Author:
yumileroy
Message:

*DB script table stucture change. Source Mangos. Also fix some bugs. Hopefully this rev will make program usable again.

Original author: megamage
Date: 2008-11-20 10:43:20-06:00

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/src/shared/Database/DBCStores.cpp

    r229 r260  
    1111 * This program is distributed in the hope that it will be useful, 
    1212 * but WITHOUT ANY WARRANTY; without even the implied warranty of 
    13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 
     13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
    1414 * GNU General Public License for more details. 
    1515 * 
    1616 * You should have received a copy of the GNU General Public License 
    1717 * along with this program; if not, write to the Free Software 
    18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 
     18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA 
    1919 */ 
    2020 
     
    122122// DBC used only for initialization sTaxiPathSetBySource at startup. 
    123123TaxiPathNodesByPath sTaxiPathNodesByPath; 
    124 struct TaxiPathNodeEntry 
    125 { 
    126     uint32    path; 
    127     uint32    index; 
    128     uint32    mapid; 
    129     float     x; 
    130     float     y; 
    131     float     z; 
    132     uint32    actionFlag; 
    133     uint32    delay; 
    134 }; 
     124 
    135125static DBCStorage <TaxiPathNodeEntry> sTaxiPathNodeStore(TaxiPathNodeEntryfmt); 
    136  
    137126DBCStorage <TotemCategoryEntry> sTotemCategoryStore(TotemCategoryEntryfmt); 
    138  
    139127DBCStorage <WorldMapAreaEntry>  sWorldMapAreaStore(WorldMapAreaEntryfmt); 
    140128DBCStorage <WorldSafeLocsEntry> sWorldSafeLocsStore(WorldSafeLocsEntryfmt); 
     
    236224        } 
    237225    } 
    238      
     226 
    239227    LoadDBC(availableDbcLocales,bar,bad_dbc_files,sFactionTemplateStore,     dbcPath,"FactionTemplate.dbc"); 
    240228    LoadDBC(availableDbcLocales,bar,bad_dbc_files,sGemPropertiesStore,       dbcPath,"GemProperties.dbc"); 
     
    284272    { 
    285273        SkillLineAbilityEntry const *skillLine = sSkillLineAbilityStore.LookupEntry(j); 
    286      
     274 
    287275        if(!skillLine) 
    288276            continue; 
     
    291279 
    292280        if(spellInfo && (spellInfo->Attributes & 0x1D0) == 0x1D0) 
    293         {       
     281        { 
    294282            for (unsigned int i = 1; i < sCreatureFamilyStore.GetNumRows(); ++i) 
    295283            { 
     
    298286                    continue; 
    299287 
    300                 if(skillLine->skillId != cFamily->skillLine && skillLine->skillId != cFamily->skillLine2) 
     288                if(skillLine->skillId != cFamily->skillLine[0] && skillLine->skillId != cFamily->skillLine[1]) 
    301289                    continue; 
    302290 
     
    310298    LoadDBC(availableDbcLocales,bar,bad_dbc_files,sSpellFocusObjectStore,    dbcPath,"SpellFocusObject.dbc"); 
    311299    LoadDBC(availableDbcLocales,bar,bad_dbc_files,sSpellItemEnchantmentStore,dbcPath,"SpellItemEnchantment.dbc"); 
    312      
    313300    LoadDBC(availableDbcLocales,bar,bad_dbc_files,sSpellItemEnchantmentConditionStore,dbcPath,"SpellItemEnchantmentCondition.dbc"); 
    314301    LoadDBC(availableDbcLocales,bar,bad_dbc_files,sSpellRadiusStore,         dbcPath,"SpellRadius.dbc"); 
     
    456443    // check at up-to-date DBC files (71 is last char title added in 2.4.3) 
    457444    // check at up-to-date DBC files (1768 is last area added in 2.4.3) 
    458     if( !sSpellStore.LookupEntry(53085)            ||  
    459         !sSkillLineAbilityStore.LookupEntry(17514) ||  
     445    if( !sSpellStore.LookupEntry(53085)            || 
     446        !sSkillLineAbilityStore.LookupEntry(17514) || 
    460447        !sMapStore.LookupEntry(598)                || 
    461         !sGemPropertiesStore.LookupEntry(1127)     ||  
    462         !sItemExtendedCostStore.LookupEntry(2425)  ||  
     448        !sGemPropertiesStore.LookupEntry(1127)     || 
     449        !sItemExtendedCostStore.LookupEntry(2425)  || 
    463450        !sCharTitlesStore.LookupEntry(71)          || 
    464451        !sAreaStore.LookupEntry(1768)              )