214 Commits

Author SHA1 Message Date
Shauren
2c9b67f00b Core/Quests: Fixed QuestScript::OnQuestStatusChange incorrectly triggering with QUEST_STATUS_INCOMPLETE when removing items from quest objectives on rewarding quest
Closes #31181
2025-07-30 18:35:39 +02:00
Shauren
cbb532e4be Core/Groups: Use iterators instead of raw LinkedListElement to interact with group members 2025-07-11 17:40:34 +02:00
Shauren
c02e311eef Core/Gossip: Track started interaction types and reset only questgiver on quest accept
Closes #31120
2025-07-05 22:34:45 +02:00
Meji
4c92d3550b Core/Gossip: Send correct response depending on how the interaction was started (#31046) 2025-06-28 18:17:10 +02:00
Meji
138b1b1a21 Core/SpawnTracking: Allow linking a spawn to more than one quest objective (#30995) 2025-06-28 01:38:43 +02:00
Shauren
e59059e1bd Core/Players: PlayerChoice improvements
* Add missing choice properties to database (InfiniteRange, ShowChoicesAsList)
* Allow limiiting the number of responses sent at the same time
* Fixed duration sent in SMSG_DISPLAY_PLAYER_CHOICE
* Remove dynamically generated response identifiers from database
* Remove auto rewarding choice responses
* Change response scripts to be bound to scriptname
2025-06-22 21:56:58 +02:00
Shauren
7c32af9a27 Core/Gossip: Use std::variant to store InteractionData 2025-06-21 13:25:30 +02:00
Shauren
b7122c2f6a Core/PacketIO: Migration to PacketUtilities bit/string operations part 3 2025-05-22 13:46:45 +02:00
Meji
c9099c8756 Core/Misc: Implemented spawn tracking (#30247) 2025-01-04 18:08:09 +01:00
Meji
75bc3021da Core/Gossip: Fix interaction with gossip launched by accepting quest (#30419) 2024-12-29 00:43:01 +01:00
Meji
19a0e885a6 Core/PacketIO: Fix SMSG_UI_MAP_QUEST_LINES_RESPONSE struct (TWW) (#30219) 2024-09-14 13:14:05 +02:00
Meji
efa76de540 Core/PacketIO: Implemented UIMap questlines (#30030) 2024-08-30 18:11:07 +02:00
Shauren
df1ec76d54 Core: Updated to 11.0.2 2024-08-16 00:03:22 +02:00
Meji
c90dbeb648 Core/Quests: Update phaseshift when taking or abandoning quests (#29901) 2024-04-08 13:26:04 +02:00
Jeremy
be11f42a16 Core/Battlegrounds: Move to scripts (#29799)
* Introduce new BattlegroundScript class for map/bg specific scripts
* Remove all sub, zone specific, battleground classes except Arena
* Move all bg zone scripts to new BattlegroundScripts class in script folder
* Remove ZoneScript from Battleground class
* Remove some unused hooks from Battleground
2024-03-28 19:29:22 +01:00
Shauren
ac5aee6a98 Core: Updated to 10.2.6.53840 2024-03-21 21:07:23 +01:00
Shauren
c2e36dea6c Core/Creatures: Implemented serverside checks for UNIT_FLAG2_INTERACT_WHILE_HOSTILE and UNIT_FLAG3_ALLOW_INTERACTION_WHILE_IN_COMBAT
* Also stop sending npc flags for hostile creatures
2024-03-03 00:51:51 +01:00
Shauren
97d7ccd180 Core/Quests: Merged UpdateNearbyCreatureNpcFlags, UpdateVisibleGameobjectsOrSpellClicks and SendQuestGiverStatusMultiple on quest actions
* Fixes quest markers above NPC heads not disappearing when player stops seeing questgiver npc flag
2024-03-03 00:50:38 +01:00
ModoX
dd15d763cc Core/Creatures: Implemented UNIT_NPC_FLAG_GOSSIP as viewer dependent and update npcflags on quest changes (#29646) 2024-02-24 15:05:21 +01:00
ModoX
b3dce0ac08 Core/Creatures: Added possibility to automatically despawn personal summons on quest remove (#29114) 2024-01-08 21:51:46 +01:00
Shauren
41a20b1e40 Core/Achievements: Fixed achievement criteria StartEvent and FailEvent
* Criteria using StartEvent cannot be updated without that event triggering first (not only for timed achievements)
* Implemented most StartEvent and FailEvent types
* Fixed saving criteria removed by RemoveCriteriaProgress
2023-09-25 00:53:56 +02:00
Aqua Deus
a9d459962b Core/Quest: Allow quests flagged as QUEST_FLAGS_AUTO_COMPLETE to be valid in CMSG_QUESTGIVER_REQUEST_REWARD (#29244)
Co-authored-by: Ovahlord <dreadkiller@gmx.de>
2023-08-24 16:24:58 +02:00
Shauren
0fb8765a66 Core/Items: Item bonus generation improvements
* Pass ItemContext to item creation wherever possible
* Support scaling item levels with m+ keystone levels (not used currently)
* Fixed item link validation when client sends it as default uninitialized bonus list with context only
* Support scaling items depending on current active season (seasons not implemented)
* Implemented content tuning redirection
2023-06-17 16:29:59 +02:00
Shauren
0cb8965de2 Core/Quests: New FlagsEx implementations
* QUEST_FLAGS_EX_REWARDS_IGNORE_CAPS
* QUEST_FLAGS_EX_NO_CREDIT_FOR_PROXY
* QUEST_FLAGS_EX_RECAST_ACCEPT_SPELL_ON_LOGIN
* QUEST_FLAGS_EX_REMOVE_ON_PERIODIC_RESET
* QUEST_FLAGS_EX_NO_ABANDON_ONCE_BEGUN
2023-06-11 19:29:42 +02:00
Shauren
4d4c7e6893 Core/Quests: Quest flag fixups
* Update flag names
* Implemented QUEST_FLAGS_COMPLETION_NO_DEATH and QUEST_FLAGS_FAIL_ON_LOGOUT
* Started using QUEST_FLAGS_COMPLETION_EVENT and QUEST_FLAGS_COMPLETION_AREA_TRIGGER instead of a custom SpeclalFlag
* Renamed Quest::IsAutoComplete to Quest::IsTurnIn to better describe what it means (a quest that can be turned in without accepting it to quest log)
* Implemented QUEST_FLAGS_UPDATE_PHASESHIFT and removed forced phaseshift updates on every quest status change
* Implemented QUEST_FLAGS_LAUNCH_GOSSIP_ACCEPT - reopens gossip menu with questgiver
2023-06-10 20:31:33 +02:00
ModoX
36044a9470 Core/Creature: Added possibility to give creatures multiple gossip menu ids and control them via conditions (#28159) 2023-04-05 23:49:46 +02:00
Shauren
0956873613 Core/Creatures: Allow overriding default gossip menu id 2023-03-12 00:13:49 +01:00
Seyden
b5886f6a2d Core/Quests: Dont immediately update object visibility at PhaseShift and wait for the AI Hooks to be called in Player::RewardQuest (#28516) 2023-01-28 15:36:28 +01:00
Shauren
4bec7233ba Core: Updated to 10.0.5 2023-01-28 01:53:26 +01:00
Shauren
d791afae1d Core/Logging: Switch from fmt::sprintf to fmt::format (c++20 standard compatible api) 2023-01-08 21:16:53 +01:00
Shauren
5dca7309f4 Core/Battlegrounds: Fixed AV turnins being counted when opening quest completion UI instead after completing the quest 2022-07-09 00:09:54 +02:00
HelloKitty
c50c877bdb Core/QuestHandler: Fix potential crash caused by QUEST_FLAGS_PARTY_ACCEPT with conditions (#26880)
(cherry picked from commit 5a60082e5d)
2022-03-14 23:55:09 +01:00
Kelno
b6af6634f4 Core/Misc: Clear unused undef leftover in a refactor (#26616)
Previously this function was using a macro that was #undef at the end of the function. Since then it uses a lambda function and the undef is not needed anymore.

(cherry picked from commit 17ed3fd1dc)
2022-03-11 12:14:39 +01:00
Giacomo Pozzoni
5180abfb19 Core/Creature: Add new db field InteractionPauseTimer (#25880)
* Core/Creature: Add new db field InteractionPauseTimer

Add new db field InteractionPauseTimer to allow to define different interaction pause timers for each creature (the previous system was a global setting in worldserver.conf Creature.MovingStopTimeForPlayer)

* Set all columns in creature_template_movement as optional (can be NULL, default NULL). Fill only the columns that should override the default C++ value

* Use the InteractionPauseTimer value throughout the code instead of Creature.MovingStopTimeForPlayer

* Handle InteractionPauseTimer set to 0 as "don't stop at all"

* Implement InteractionPauseTimer in creature_movement_override

creature_movement_override allows NULL values, in which case the values from creature_template_movement will be used for those columns that are NULL, falling back to default C++ values if creature_template_movement has NULL values too (or no rows for the creature)

* Read default InteractionPauseTimer from worldserver.conf

* Rename 2021_99_99_99_world.sql to 2021_01_22_00_world.sql

(cherry picked from commit a22bc236eb)
2022-03-06 00:56:46 +01:00
Giacomo Pozzoni
bfdabb8c37 Core/Quest: Fix wrong feedback sent to the quest sharing sender with auto-accept quests. (PR #25477) Closes #25474.
Co-authored-by: Treeston <treeston.mmoc@gmail.com>
(cherry picked from commit e2d643f551)
2022-02-27 23:03:06 +01:00
Treeston
c13d7df72b Scripts/ChatCommands: Constrain how char const* may be used as a command handler parameter. It may now only be used in the legacy configuration, as the only argument.
(cherry picked from commit 9fda67d016)
2022-02-27 20:59:37 +01:00
ModoX
8de5053a65 Core/Quests: Fixes response selection to use correct referenced identifier (#27808) 2022-02-26 23:07:43 +01:00
Maks Szokalski
bc04acb726 Add "On" to some gossip methods in AI (#25415)
* Add "On" to some methods

* Update npc_innkeeper.cpp

* Update zone_borean_tundra.cpp

(cherry picked from commit 41188eb535)
2022-02-05 22:18:19 +01:00
ModoX
a17944e91e Core/Quests: Set quest slot earlier when abandoning a quest (#27584)
* fixes quest objective conditions still being true when quest is abandoned
2022-01-13 20:31:51 +01:00
Giacomo Pozzoni
a9e325f6b7 Core/Logs: Log full guid instead of just low guid, part 2
(cherry picked from commit 3def52c1c4)
2022-01-01 00:51:54 +01:00
Giacomo Pozzoni
6ec933f281 Core/Logs: Log full guid instead of just low guid
(cherry picked from commit 468ecb7252)
2021-12-31 21:56:40 +01:00
Treeston
51fbda4223 Core/Pooling: Quest pooling rewrite: (PR#23627)
- Split quest pooling from PoolMgr (into QuestPoolMgr)
- Proper saving/restoring on server restart
- No more hacking into sObjectMgr to insert/remove available quests

(cherry picked from commit a5e73e41c0)
2021-12-18 15:28:45 +01:00
Wyrserth
ecce30a807 Core/Quest: do not send SMSG_QUESTGIVER_OFFER_REWARD right after SMSG_QUESTGIVER_QUEST_FAILED.
Allows the gossip window to close after the client receives a quest failed error (for example: not enough inventory space to store the reward).

(cherry picked from commit c8289ada7f)
2021-12-13 00:42:19 +01:00
Shauren
122fe7549d Core/PacketIO: Updated SMSG_QUEST_PUSH_RESPONSE to 9.1.5 2021-11-02 22:51:05 +01:00
Meji
0a83f74876 Core/Achievements: Update CriteriaType enum (#26856) 2021-09-08 22:07:01 +02:00
Shauren
0b2087ae41 Core/Criteria: Add all values of CriteriaStartEvent 2021-06-01 21:16:41 +02:00
Shauren
b9d63c2009 Core/Scripts: Remove deprecated overload of QuestReward without LootItemType argument 2021-05-16 21:56:06 +02:00
Shauren
dd8aed421a Core/Quests: Drop unneeded QuestSpecialFlags 2021-05-09 16:01:34 +02:00
Treeston
0aed5a35ef Core/AI: Kick Gossip functions upstairs, from UnitAI to CreatureAI - they only make sense for Creatures anyway.
Also change a very ugly hack in GetDialogStatus. Ew.

(cherry picked from commit eacfa9d89a)
2021-04-27 23:49:36 +02:00
Shauren
f269f60d8a Scripts/Quests: Implemented new quest scripting hook, OnQuestAcknowledgeAutoAccept, used when player closes quest frame after viewing details of autoaccept quests 2021-02-26 20:42:29 +01:00