Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiples errors after last merge #189

Open
jlecoustre opened this issue May 3, 2023 · 14 comments
Open

Multiples errors after last merge #189

jlecoustre opened this issue May 3, 2023 · 14 comments

Comments

@jlecoustre
Copy link

jlecoustre commented May 3, 2023

Hello,

Unable to compile since the last updates made on https://github.com/ZhengPeiRu21/azerothcore-wotlk/tree/Playerbot
A lot of errors are present there seems to have been a lot of changes that make Playerbot mode non-functional.

Here are some errors:

`[ 31%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/Custom/custom_script_loader.cpp.o
/Games/azerothcore-wotlk/modules/mod-playerbots/src/strategy/actions/LfgActions.cpp:13:35: warning: unused parameter 'event' [-Wunused-parameter]
bool LfgJoinAction::Execute(Event event)
^
/Games/azerothcore-wotlk/modules/mod-playerbots/src/strategy/actions/LfgActions.cpp:103:35: fatal error: no member named 'type' in 'LFGDungeonEntry'
if (!dungeon || (dungeon->type != LFG_TYPE_RANDOM && dungeon->type != LFG_TYPE_DUNGEON && dungeon->type != LFG_TYPE_HEROIC && dungeon->type != LFG_TYPE_RAID))
~~~~~~~ ^
10 warnings and 1 error generated.
make[2]: *** [modules/CMakeFiles/modules.dir/build.make:1448: modules/CMakeFiles/modules.dir/mod-playerbots/src/strategy/actions/LfgActions.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....

/Games/azerothcore-wotlk/modules/mod-playerbots/src/strategy/actions/LfgActions.cpp:107:22: fatal error: no member named 'minlevel' in 'LFGDungeonEntry'; did you mean 'MinLevel'?
if (dungeon->minlevel && botLevel < dungeon->minlevel)
^~~~~~~~
MinLevel
/Games/azerothcore-wotlk/src/server/shared/DataStores/DBCStructure.h:1276:12: note: 'MinLevel' declared here
uint32 MinLevel; // 18
^
10 warnings and 1 error generated.

/Games/azerothcore-wotlk/src/server/game/Guilds/Guild.h:244:23: warning: unused parameter 'style' [-Wunused-parameter]
EmblemInfo(uint32 style = 0, uint32 color = 0, uint32 borderStyle = 0, uint32 borderColor = 0, uint32 backgroundColor = 0) :
^
/Games/azerothcore-wotlk/src/server/game/Guilds/Guild.h:244:41: warning: unused parameter 'color' [-Wunused-parameter]
EmblemInfo(uint32 style = 0, uint32 color = 0, uint32 borderStyle = 0, uint32 borderColor = 0, uint32 backgroundColor = 0) :
^
/Games/azerothcore-wotlk/src/server/game/Guilds/Guild.h:244:59: warning: unused parameter 'borderStyle' [-Wunused-parameter]
EmblemInfo(uint32 style = 0, uint32 color = 0, uint32 borderStyle = 0, uint32 borderColor = 0, uint32 backgroundColor = 0) :
^
/Games/azerothcore-wotlk/src/server/game/Guilds/Guild.h:244:83: warning: unused parameter 'borderColor' [-Wunused-parameter]
EmblemInfo(uint32 style = 0, uint32 color = 0, uint32 borderStyle = 0, uint32 borderColor = 0, uint32 backgroundColor = 0) :
^
/Games/azerothcore-wotlk/src/server/game/Guilds/Guild.h:244:107: warning: unused parameter 'backgroundColor' [-Wunused-parameter]
EmblemInfo(uint32 style = 0, uint32 color = 0, uint32 borderStyle = 0, uint32 borderColor = 0, uint32 backgroundColor = 0) :`

Do you have the possibility to update the code?
thank you very much

@jlecoustre jlecoustre changed the title Multiples errors after last merge with master Multiples errors after last merge May 3, 2023
@rogerc66
Copy link

rogerc66 commented May 6, 2023

Yes, I’m having the same error, failed to compile.

@rookis1
Copy link

rookis1 commented May 6, 2023

[ 79%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/item_scripts.cpp.o
[ 79%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/mob_generic_creature.cpp.o
[ 79%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/npc_innkeeper.cpp.o
5 warnings generated.
[ 79%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/npc_professions.cpp.o
[ 79%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/npc_stave_of_ancients.cpp.o
[ 79%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/npc_taxi.cpp.o
[ 79%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/npcs_special.cpp.o
[ 79%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/player_scripts.cpp.o
5 warnings generated.
[ 80%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/server_mail.cpp.o
[ 80%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/World/world_script_loader.cpp.o
[ 80%] Linking CXX static library libscripts.a
[ 80%] Built target scripts
make: *** [Makefile:130: all] Error 2
failed to compile

@ldsanahuja
Copy link

Hi,
DBCStructure.h changed at some point. Also had this problem in other modules (mod-autobalance) Worked for me replacing in line 100 of LfgActions.cpp the for loop code:

for (std::vector<uint32>::iterator i = dungeons.begin(); i != dungeons.end(); ++i)
    {
        LFGDungeonEntry const* dungeon = sLFGDungeonStore.LookupEntry(*i);
        if (!dungeon || (dungeon->TypeID != LFG_TYPE_RANDOM && dungeon->TypeID != LFG_TYPE_DUNGEON && dungeon->TypeID != LFG_TYPE_HEROIC && dungeon->TypeID != LFG_TYPE_RAID))
            continue;

        uint32 botLevel = bot->getLevel();
        if (dungeon->TargetLevelMin && botLevel < dungeon->TargetLevelMin)
            continue;

        if (dungeon->TargetLevelMin && botLevel > dungeon->TargetLevelMin + 10)
            continue;

        if (dungeon->TargetLevelMax && botLevel > dungeon->TargetLevelMax)
            continue;

        selected.push_back(dungeon->ID);
        list.insert(dungeon->ID);
    }

Also another error in line 174 replaced for

    LOG_INFO("playerbots", "Bot {} {}:{} <{}>: queues LFG, Dungeon as {} ({})",
        bot->GetGUID().ToString().c_str(), bot->GetTeamId() == TEAM_ALLIANCE ? "A" : "H",
        bot->getLevel(), bot->GetName().c_str(), _roles, many ? "several dungeons" : dungeon->Name[0]);

@Embracefate989
Copy link
Contributor

659a216 edit your LfgActions.cpp in "core\modules\mod-playerbots\src\strategy\actions" to the changes in that link, it fixes the issues while compiling, namings changed in DBCStructure.h at some point and hasn't been updated in some modules so you need to manually update them until zheng get's back to fix them

@rookis1
Copy link

rookis1 commented May 8, 2023

659a216 edit your LfgActions.cpp in "core\modules\mod-playerbots\src\strategy\actions" to the changes in that link, it fixes the issues while compiling, namings changed in DBCStructure.h at some point and hasn't been updated in some modules so you need to manually update them until zheng get's back to fix them

that's right! I follow this suggestion and it compiles normally! thanks!

@htc16
Copy link
Contributor

htc16 commented May 8, 2023

@ZhengPeiRu21

@Embracefate989
Copy link
Contributor

@ZhengPeiRu21

I believe zheng is on vacation right now for the next 5 weeks but if your having issues compiling see the changes I made in my comment above to fix it temporarily until zheng returns
image

@Falladis
Copy link

Falladis commented May 8, 2023

659a216 edit your LfgActions.cpp in "core\modules\mod-playerbots\src\strategy\actions" to the changes in that link, it fixes the issues while compiling, namings changed in DBCStructure.h at some point and hasn't been updated in some modules so you need to manually update them until zheng get's back to fix them

using that file I still get compiling errors like it made no difference.

@Embracefate989
Copy link
Contributor

659a216 edit your LfgActions.cpp in "core\modules\mod-playerbots\src\strategy\actions" to the changes in that link, it fixes the issues while compiling, namings changed in DBCStructure.h at some point and hasn't been updated in some modules so you need to manually update them until zheng get's back to fix them

using that file I still get compiling errors like it made no difference.

Send a screenshot of your error log and console output of the errors and I'll try to help, also make sure you renamed it to mod-playerbots if you downloaded as zip or it will not compile and will spit out errors like "Unresolved external symbol"

@Falladis
Copy link

Falladis commented May 9, 2023

659a216 edit your LfgActions.cpp in "core\modules\mod-playerbots\src\strategy\actions" to the changes in that link, it fixes the issues while compiling, namings changed in DBCStructure.h at some point and hasn't been updated in some modules so you need to manually update them until zheng get's back to fix them

using that file I still get compiling errors like it made no difference.

Send a screenshot of your error log and console output of the errors and I'll try to help, also make sure you renamed it to mod-playerbots if you downloaded as zip or it will not compile and will spit out errors like "Unresolved external symbol"

Here is my entire compilation log. I am using the fork of AC (https://github.com/ZhengPeiRu21/azerothcore-wotlk/tree/Playerbot) and the .zip module for AC (renamed).

https://pastebin.com/10dpSeNA

@Embracefate989
Copy link
Contributor

659a216 edit your LfgActions.cpp in "core\modules\mod-playerbots\src\strategy\actions" to the changes in that link, it fixes the issues while compiling, namings changed in DBCStructure.h at some point and hasn't been updated in some modules so you need to manually update them until zheng get's back to fix them

using that file I still get compiling errors like it made no difference.

Send a screenshot of your error log and console output of the errors and I'll try to help, also make sure you renamed it to mod-playerbots if you downloaded as zip or it will not compile and will spit out errors like "Unresolved external symbol"

Here is my entire compilation log. I am using the fork of AC (https://github.com/ZhengPeiRu21/azerothcore-wotlk/tree/Playerbot) and the .zip module for AC (renamed).

https://pastebin.com/10dpSeNA

Not sure if I'll be able to help much since I don't have any experiencing compiling the core outside of windows but I see a bunch of fatal errors in that log like in
"/home/user/acbots/azerothcore-wotlk/modules/mod-playerbots/src/PlayerbotDbStore.cpp" uses "PlayerbotsDatabasePreparedStatement" instead of "CharacterDatabasePreparedStatement"
and in "/home/user/acbots/azerothcore-wotlk/modules/mod-playerbots/src/PlayerbotDungeonSuggestionMgr.cpp" it's calling for an undeclared indentifier 'PlayerbotsDatabase' and a bunch of "enumeration previously declared with nonfixed underlying type" errors I'm not too sure how to fix, as well as in
"/home/user/acbots/azerothcore-wotlk/modules/mod-playerbots/src/ChatFilter.cpp" there's a fatal error with no member named GetTargetIcon in 'group',
I'd recommend freshly cloning the forked core from https://github.com/ZhengPeiRu21/azerothcore-wotlk/tree/Playerbot and the module from here fixing the issue In my previous comment and trying again following the steps from https://www.azerothcore.org/wiki/installation for the rest of the installation and seeing if the error persists if it does I'd suggest just waiting till zheng is back from their vacation and hoping they can offer more help than I can, sorry I can't offer more help!

@rookis1
Copy link

rookis1 commented May 11, 2023

659a216 edit your LfgActions.cpp in "core\modules\mod-playerbots\src\strategy\actions" to the changes in that link, it fixes the issues while compiling, namings changed in DBCStructure.h at some point and hasn't been updated in some modules so you need to manually update them until zheng get's back to fix them

using that file I still get compiling errors like it made no difference.

Send a screenshot of your error log and console output of the errors and I'll try to help, also make sure you renamed it to mod-playerbots if you downloaded as zip or it will not compile and will spit out errors like "Unresolved external symbol"

Here is my entire compilation log. I am using the fork of AC (https://github.com/ZhengPeiRu21/azerothcore-wotlk/tree/Playerbot) and the .zip module for AC (renamed).

https://pastebin.com/10dpSeNA

Hi, DBCStructure.h changed at some point. Also had this problem in other modules (mod-autobalance) Worked for me replacing in line 100 of LfgActions.cpp the for loop code:

for (std::vector<uint32>::iterator i = dungeons.begin(); i != dungeons.end(); ++i)
    {
        LFGDungeonEntry const* dungeon = sLFGDungeonStore.LookupEntry(*i);
        if (!dungeon || (dungeon->TypeID != LFG_TYPE_RANDOM && dungeon->TypeID != LFG_TYPE_DUNGEON && dungeon->TypeID != LFG_TYPE_HEROIC && dungeon->TypeID != LFG_TYPE_RAID))
            continue;

        uint32 botLevel = bot->getLevel();
        if (dungeon->TargetLevelMin && botLevel < dungeon->TargetLevelMin)
            continue;

        if (dungeon->TargetLevelMin && botLevel > dungeon->TargetLevelMin + 10)
            continue;

        if (dungeon->TargetLevelMax && botLevel > dungeon->TargetLevelMax)
            continue;

        selected.push_back(dungeon->ID);
        list.insert(dungeon->ID);
    }

Also another error in line 174 replaced for

    LOG_INFO("playerbots", "Bot {} {}:{} <{}>: queues LFG, Dungeon as {} ({})",
        bot->GetGUID().ToString().c_str(), bot->GetTeamId() == TEAM_ALLIANCE ? "A" : "H",
        bot->getLevel(), bot->GetName().c_str(), _roles, many ? "several dungeons" : dungeon->Name[0]);

@Falladis
Copy link

659a216 edit your LfgActions.cpp in "core\modules\mod-playerbots\src\strategy\actions" to the changes in that link, it fixes the issues while compiling, namings changed in DBCStructure.h at some point and hasn't been updated in some modules so you need to manually update them until zheng get's back to fix them

using that file I still get compiling errors like it made no difference.

Send a screenshot of your error log and console output of the errors and I'll try to help, also make sure you renamed it to mod-playerbots if you downloaded as zip or it will not compile and will spit out errors like "Unresolved external symbol"

Here is my entire compilation log. I am using the fork of AC (https://github.com/ZhengPeiRu21/azerothcore-wotlk/tree/Playerbot) and the .zip module for AC (renamed).
https://pastebin.com/10dpSeNA

Not sure if I'll be able to help much since I don't have any experiencing compiling the core outside of windows but I see a bunch of fatal errors in that log like in "/home/user/acbots/azerothcore-wotlk/modules/mod-playerbots/src/PlayerbotDbStore.cpp" uses "PlayerbotsDatabasePreparedStatement" instead of "CharacterDatabasePreparedStatement" and in "/home/user/acbots/azerothcore-wotlk/modules/mod-playerbots/src/PlayerbotDungeonSuggestionMgr.cpp" it's calling for an undeclared indentifier 'PlayerbotsDatabase' and a bunch of "enumeration previously declared with nonfixed underlying type" errors I'm not too sure how to fix, as well as in "/home/user/acbots/azerothcore-wotlk/modules/mod-playerbots/src/ChatFilter.cpp" there's a fatal error with no member named GetTargetIcon in 'group', I'd recommend freshly cloning the forked core from https://github.com/ZhengPeiRu21/azerothcore-wotlk/tree/Playerbot and the module from here fixing the issue In my previous comment and trying again following the steps from https://www.azerothcore.org/wiki/installation for the rest of the installation and seeing if the error persists if it does I'd suggest just waiting till zheng is back from their vacation and hoping they can offer more help than I can, sorry I can't offer more help!

sadly that is the forked core acting up for me.

@Dreathean
Copy link

@jlecoustre this should no longer be an issue, please close out

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants