Closed Diablosstars closed 1 year ago
Thanks for your PR, please, fix this error
[ 21%] Building CXX object src/server/game/CMakeFiles/game.dir/AI/CreatureAIRegistry.cpp.o
/home/runner/work/mod-npc-talent-template/mod-npc-talent-template/modules/mod-npc-talent-template/src/TemplateNPC.cpp:936:109: fatal error: data argument not used by format string [-Wformat-extra-args]
player->GetSession()->SendAreaTriggerMessage("There's no templates for {} specialization yet.", playerSpecStr.c_str());
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
1 error generated.
make[2]: *** [modules/CMakeFiles/modules.dir/build.make:90: modules/CMakeFiles/modules.dir/mod-npc-talent-template/src/TemplateNPC.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1508: modules/CMakeFiles/modules.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
Thanks for your PR, please, fix this error
[ 21%] Building CXX object src/server/game/CMakeFiles/game.dir/AI/CreatureAIRegistry.cpp.o /home/runner/work/mod-npc-talent-template/mod-npc-talent-template/modules/mod-npc-talent-template/src/TemplateNPC.cpp:936:109: fatal error: data argument not used by format string [-Wformat-extra-args] player->GetSession()->SendAreaTriggerMessage("There's no templates for {} specialization yet.", playerSpecStr.c_str()); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ 1 error generated. make[2]: *** [modules/CMakeFiles/modules.dir/build.make:90: modules/CMakeFiles/modules.dir/mod-npc-talent-template/src/TemplateNPC.cpp.o] Error 1 make[1]: *** [CMakeFiles/Makefile2:1508: modules/CMakeFiles/modules.dir/all] Error 2 make[1]: *** Waiting for unfinished jobs....
There is the incorrect assumption that
SendAreaTrigger
usesfmt::format
, however it usesvsnprinf
. Reverting the change for those calls should fix the issue. I have created a pull request on the Diablosstars branch.
thanks for the PR!
Tested and it's ok
The build is failing here, if this issue will be fixed I can merge the PR
/home/runner/work/mod-npc-talent-template/mod-npc-talent-template/modules/mod-npc-talent-template/src/TemplateNPC.cpp:936:109: fatal error: data argument not used by format string [-Wformat-extra-args]
player->GetSession()->SendAreaTriggerMessage("There's no templates for {} specialization yet.", playerSpecStr.c_str());
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
1 error generated.
make[2]: *** [modules/CMakeFiles/modules.dir/build.make:90: modules/CMakeFiles/modules.dir/mod-npc-talent-template/src/TemplateNPC.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1217: modules/CMakeFiles/modules.dir/all] Error 2
The build is failing here, if this issue will be fixed I can merge the PR
/home/runner/work/mod-npc-talent-template/mod-npc-talent-template/modules/mod-npc-talent-template/src/TemplateNPC.cpp:936:109: fatal error: data argument not used by format string [-Wformat-extra-args] player->GetSession()->SendAreaTriggerMessage("There's no templates for {} specialization yet.", playerSpecStr.c_str()); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ 1 error generated. make[2]: *** [modules/CMakeFiles/modules.dir/build.make:90: modules/CMakeFiles/modules.dir/mod-npc-talent-template/src/TemplateNPC.cpp.o] Error 1 make[1]: *** [CMakeFiles/Makefile2:1217: modules/CMakeFiles/modules.dir/all] Error 2
Still waiting on my PR merge on his branch that fixes this issue. If anybody would like to create a new PR with his changes and then cherry pick mine go ahead.
done https://github.com/azerothcore/mod-npc-talent-template/pull/43
I am closing this PR
All SQL calls were Querying the data base with the %s literals within the query. With FMT, changing to '{}' allows for the variables to be formatted into the strings for all queries.
closes #39