azerothcore / mod-eluna

Eluna Lua Engine © for WoW Emulators
https://elunaluaengine.github.io/
GNU General Public License v3.0
96 stars 127 forks source link

make error #134

Closed fleamboy closed 1 year ago

fleamboy commented 1 year ago

/AC/azerothcore-npcbots/modules/mod-eluna/src/ElunaLuaEngine_SC.cpp:660:81: fatal error: non-virtual member function marked 'override' hides virtual member function void OnGiveXP(Player player, uint32& amount, Unit victim, uint8 xpSource) override ^ /AC/azerothcore-npcbots/src/server/game/Scripting/ScriptMgr.h:1040:18: note: hidden overloaded virtual function 'PlayerScript::OnGiveXP' declared here: different number of parameters (3 vs 4) virtual void OnGiveXP(Player /player/, uint32& /amount/, Unit /victim/) { }

WildBlizzard commented 1 year ago

Same Error:

/root/Azerothcore/modules/mod-eluna/src/ElunaLuaEngine_SC.cpp: In member function ‘virtual void Eluna_AllMapScript::OnBeforeCreateInstanceScript(InstanceMap, InstanceScript, bool, std::string, uint32)’: /root/Azerothcore/modules/mod-eluna/src/ElunaLuaEngine_SC.cpp:240:81: warning: parameter ‘instanceData’ set but not used [-Wunused-but-set-parameter] 240 | void OnBeforeCreateInstanceScript(InstanceMap instanceMap, InstanceScript instanceData, bool /load/, std::string /data/, uint32 /completedEncounterMask/) override | ~~~~^~~~ /root/Azerothcore/modules/mod-eluna/src/ElunaLuaEngine_SC.cpp: At global scope: /root/Azerothcore/modules/mod-eluna/src/ElunaLuaEngine_SC.cpp:660:10: error: ‘void Eluna_PlayerScript::OnGiveXP(Player, uint32&, Unit, uint8)’ marked ‘override’, but does not override 660 | void OnGiveXP(Player player, uint32& amount, Unit victim, uint8 xpSource) override | ^~~~ compilation terminated due to -Wfatal-errors. make[2]: [modules/CMakeFiles/modules.dir/build.make:230: modules/CMakeFiles/modules.dir/mod-eluna/src/ElunaLuaEngine_SC.cpp.o] Error 1 make[2]: Waiting for unfinished jobs.... make[1]: *** [CMakeFiles/Makefile2:1100: modules/CMakeFiles/modules.dir/all] Error 2

r-o-b-o-t-o commented 1 year ago

The OnGiveXP hook was recently changed, make sure both AzerothCore and mod-eluna are up-to-date then rebuild.

ws316156697 commented 1 year ago

same error modules/mod-eluna/src/ElunaLuaEngine_SC.cpp:660:81: fatal error: non-virtual member function marked 'override' hides virtual member function

55Honey commented 1 year ago

Please update your core to the latest commit. When posting errors, please include both the mod-eluna and the AC revision.