[ Help ] - Error compile to class DSCStorage with ScriptDev2 menu

Shout-Out

User Tag List

Results 1 to 2 of 2
  1. #1
    Ithylis's Avatar Member
    Reputation
    1
    Join Date
    Dec 2008
    Posts
    16
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [ Help ] - Error compile to class DSCStorage with ScriptDev2

    Hello, I have a problem of compilation with my script. I checked MANGOS_DLL_SPEC DBCStorage <FactionEntry> const* GetFactionStore() is quite present in the files mangos… One have an idea?

    Thank you and good day.

    Code:
    1>   Création de la bibliothèque ..\..\..\..\bin\win32_release/MaNGOSScript.lib et de l'objet ..\..\..\..\bin\win32_release/MaNGOSScript.exp
    1>ajout_rep.obj : error LNK2001: symbole externe non résolu "class DBCStorage<struct FactionEntry> sFactionStore" (?sFactionStore@@3V?$DBCStorage@UFactionEntry@@@@A)
    1>..\..\..\..\bin\win32_release/MaNGOSScript.dll : fatal error LNK1120: 1 externes non résolus
    Code:
    #include "precompiled.h"
    
    bool Ajout_Rep(Player* pPlayer, Item* _Item, SpellCastTargets const& targets)
    {
    	uint32 faction_id = 930;
    	int32 reputation = 100;
    	FactionEntry const* factionEntry = sFactionStore.LookupEntry(faction_id);
    
    	pPlayer->GetReputationMgr().ModifyReputation(factionEntry, reputation);
    	return false;
    }
    
    void AddSC_Ajout_Rep()
    {
    Script *newscript;
    
    newscript = new Script;
    newscript->Name="Ajout_Rep";
    newscript->pItemUse = &Ajout_Rep;
    newscript->RegisterSelf();
    }

    [ Help ] - Error compile to class DSCStorage with ScriptDev2
  2. #2
    Ithylis's Avatar Member
    Reputation
    1
    Join Date
    Dec 2008
    Posts
    16
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    correct code is :

    Code:
    bool Ajout_Rep(Player* pPlayer, Item* _Item, SpellCastTargets const& targets)
    {
    	uint32 faction_id = 930;
    	int32 reputation = 100;
    	//FactionEntry const* factionEntry = sFactionStore.LookupEntry(faction_id);
            FactionEntry const* factionEntry = GetFactionStore()->LookupEntry(faction_id);
    
    	pPlayer->GetReputationMgr().ModifyReputation(factionEntry, reputation);
    	return true;
    }

Similar Threads

  1. Error compiling with custom scripts
    By Nadromar in forum WoW EMU Questions & Requests
    Replies: 2
    Last Post: 06-14-2009, 01:16 PM
  2. [HELP] ERROR WHEN TRYING TO Start patch with wotlk
    By Anthonyrox8 in forum WoW EMU Questions & Requests
    Replies: 0
    Last Post: 09-25-2008, 09:21 PM
  3. [Help] Error whilst compiling LUA++
    By Entr0py in forum World of Warcraft Emulator Servers
    Replies: 2
    Last Post: 06-10-2008, 02:48 AM
  4. Need Lil Help Error Been While With Ascent
    By [Shon3m] in forum World of Warcraft Emulator Servers
    Replies: 6
    Last Post: 05-20-2008, 06:18 PM
  5. [HELP] Ascent Compiling Error.
    By jokerjokes in forum World of Warcraft Emulator Servers
    Replies: 23
    Last Post: 12-10-2007, 12:53 AM
All times are GMT -5. The time now is 03:57 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search