Commit Graph

116 Commits

Author SHA1 Message Date
Andrew
a11434b24f refactor(Core/GameObject): Move the GameObject state save handling to… (#18080)
* refactor(Core/GameObject): Move the GameObject state save handling to instance level

* Update GameObject.h

* remove leftover

* small improvements
2024-01-01 01:51:33 -03:00
IntelligentQuantum
016bb86d3b refactor(Scripts): remove useless includes (#18004) 2023-12-22 18:41:28 +01:00
Kitzunu
ef1b3c2ea0 chore(Core/Misc): Clean up workarounds (#17870)
* Clean advstd to use std c++20 features
* Use ABORT instead of std::abort

Co-authored-by: Shauren <shauren.trinity@gmail.com>
2023-11-27 00:07:39 +01:00
Winfidonarleyan
e90d7a2f92 chore(Core/Misc): sort includes (#17776)
* chore(Cleanup): sort includes

* fix build

* fix build again
2023-11-18 17:51:26 +01:00
Ludwig
f633eb8592 fix(Core/Achivement): Implement ACHIEVEMENT_FLAG_AVERAGE (#17263) 2023-09-21 18:56:28 +02:00
Gultask
8d803334eb feat(Core/SmartAI): Add new event parameter, event_param6 (#16944)
* init

* pt2

* this template stuff must go

* also for my other event
2023-08-12 14:53:15 -03:00
天鹿
df77b5f4f7 chore(core): cleanup code p3 (#16073)
* Update MMapMgr.cpp

* Update UpdateFetcher.cpp

* Update AuctionHouseMgr.cpp

* Update AuctionHouseMgr.h

* Update BattlegroundAV.cpp

* Update ChannelMgr.cpp

* Update ThreatMgr.h

* Update Player.h

* Update PlayerSettings.cpp

* Update ObjectMgr.cpp

* Update Guild.cpp

* Update Guild.h

* Update Map.cpp

* Update World.cpp

* Update boss_nefarian.cpp

* Update boss_prince_malchezaar.cpp

* Update boss_venoxis.cpp

* Update zone_elwynn_forest.cpp

* Update zulfarrak.cpp

* Update boss_novos.cpp
2023-04-24 08:13:07 -03:00
ZhengPeiRu21
1e26cdbee9 fix(Core): Save bonus talent points to DB (#14099)
* fix(Core): Save bonus talent points to DB

* fix(Core): Save bonus talent points to DB

* Oxford comma in comment
2023-04-22 10:09:18 -03:00
天鹿
d75bcf0f67 chore(core): Cleanup code (#16012)
* Update SmartScript.cpp

* Update M2Stores.cpp

* Update PetHandler.cpp

* Update WaypointMovementGenerator.cpp

* Update WorldSession.cpp

* Update spell_item.cpp

* Update LoginDatabase.cpp
2023-04-19 21:34:48 -03:00
M'Dic
8aa2a2ac0f chore (core): Clean up (#15977)
* chore (core): Clean up

* Update SmartScript.cpp

* more clean up

* Update boss_xt002.cpp
2023-04-16 21:04:56 -04:00
Skjalf
6b4be39341 chore(Core/Database): Improve error wording (#15270) 2023-03-06 10:52:05 -03:00
Stefano Borzì
034b521501 feat(CI): add cppcheck (#15211)
Co-authored-by: Skjalf <47818697+Nyeriah@users.noreply.github.com>
2023-03-05 18:47:18 +01:00
Kitzunu
9eb4b3a336 feat(Core/Character): Implement profanity_name (#15156) 2023-03-04 17:43:14 -03:00
Skjalf
12e69248f8 chore(Core/DB): Display the SQL client version found when throwing th… (#15266) 2023-03-04 17:22:56 -03:00
Kitzunu
0c4feb6744 refactor(Core/Motd): Move motd from conf to db (#15111) 2023-02-20 22:07:26 +01:00
Kitzunu
f039836a2f chore(Core/Misc): Change all TODO to doxygen comment (#14966) 2023-02-12 10:05:34 -03:00
Kempec Halk
f780ae84b8 refactor(Core/MySQL): MySQL PreparedStatement Affected Row Count (#12002) 2023-01-28 11:05:55 +01:00
SoalHuang
db2433fd79 fix(Core/Auth): Cleanup PrepareStatements (#14220)
Co-authored-by: soalhuang <soniceme@163.com>
2023-01-28 11:02:48 +01:00
Axel Cocat
07ac386e61 feat(Core/Database): move MySQL handle and HandleMySQLErrno to protected (#14673)
* feat(Core/Database): move MySQL handle and HandleMySQLErrno to protected

* fix: initialization order
2023-01-15 11:02:43 -05:00
UltraNix
b9ea8b16af fix(Core/Session): Fixed loading global account data and tutorials. S… (#14038)
fix(Core/Session): Fixed loading global account data and tutorials. Source: TrinityCore.

Fixes #11974
2022-12-06 09:08:46 -03:00
Yehonal
77a52b8001 fix(CORE): another attempt to fix the dbimport command line warning (#13449) 2022-10-22 00:21:16 +02:00
Yehonal
53219310cf fix(CORE): crash when AC_DISABLE_INTERACTIVE is not defined 2022-10-21 23:05:05 +02:00
M'Dic
e836f08cc4 Revert feat(core): Start Process and DBUpdater (#13465)
Revert "feat(CORE): for Start Process and  DBUpdater

This a selective reverts for commits:
c855e8d227 and  636df19514. To re-enable the windows build to function again while applying updates.

Update DBUpdater.cpp
2022-10-20 07:43:34 +02:00
Yehonal
636df19514 feat(CORE): implemented AC_DISABLE_INTERACTIVE for DBUpdater (#13450)
Implement AC_DISABLE_INTERACTIVE that allow us to skip the question when the db doesn't exit
2022-10-19 10:57:29 +02:00
Angelo Venturini
07d4144c12 fix: codestyle CI (#13453) 2022-10-17 20:21:22 -03:00
Yehonal
563596bc69 fix(CORE): revert to mysql -p argument.
A different and non deprecated approach should be used.
2022-10-17 15:47:34 +00:00
Yehonal
c855e8d227 fix(CORE/dbupdate)): allow to pass MySQL password via env (#13404)
* fix(CORE/dbupdate)): allow to pass MySQL password via env

+ fixed devContainer override file issue
+ added authserver dry-run in our CI
2022-10-17 10:53:42 +02:00
M'Dic
2e6f6e26da Add (core\db): Support for Homebind Orientation (#13389)
Add (core\db) Support for Homebind Orientation
2022-10-12 14:39:02 -04:00
Kargatum
8a334e8210 feat(Core/DB): add support range loop for mysql result (#13355) 2022-10-10 02:46:48 +07:00
Skjalf
760d5e071f feat(Core/DBUpdater): Apply each sql update file in a separate transa… (#12842)
cherry-pick: b79a91039b

Co-authored-by: Shauren <shauren.trinity@gmail.com>
2022-08-26 08:06:35 -03:00
UltraNix
1c6eab5856 fix(Core): Crashfix. (#12643) 2022-08-07 18:22:12 -03:00
Kargatum
4fbec972a8 refactor(Cmake): add support build selected applications and tools (#11836) 2022-05-31 17:05:39 +07:00
Axel Cocat
fbd5e981ca fix(Scripts/Commands): fix baninfo command issues (#11871) 2022-05-27 00:21:43 -03:00
Hanabi
a6a2ca8ef7 feat(Core/GameObjects): Instance gameobject save data implementation (#11113)
* fix(Core): Save gameobject state on instances

Currently, azerothcore doesn't save gameobject states on instances.
Whenever there's a re-start or crash, the instance's gameobjects and
their states aren't saved, producing un-wanted behaviours and blocking instances at times.

Implemented CRUD for new table `instance_saved_data` that holds the states of gameobjects.

- When worldserver launches and gameobjects are loaded, this will check
  if this object's state exists on the DB and sets the previous state.
- On instance deletion (reset) these states are also removed based on
  the instance ID.
- Whenever a gameobject state changes inside a dungeon or raid, we save
  on the database the set state.

* Select query to synchronous and used FindMap()

* loading gameobject states on create

* reseting instance saved data

* missing reset methods and on create state

* database structure

* Update src/server/game/Entities/GameObject/GameObject.cpp

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>

* Update src/server/game/Entities/GameObject/GameObject.cpp

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>

* Update src/server/game/Entities/GameObject/GameObject.cpp

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>

* Update src/server/game/Entities/GameObject/GameObject.cpp

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>

* Update src/server/game/Entities/Player/PlayerMisc.cpp

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>

* Update src/server/game/Groups/Group.cpp

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>

* codestyle

* table changes

* table style

* codestyle

* table changes for columns

* data sanitization

* todo:

- Finish loading db data into the containers
- Using containers to find data
- How to get data from ObjectMGR inside Gameobject?

* loading on start up and db changes

* Removing unused data structure

* Uninitialised integer

* Whitespace

* clean-up and hooks to save states on memory

* Codestyle MySQL deprecated backticks

* i dont understand codefactor

* build

* Update data/sql/updates/pending_db_world/rev_1643395587559675400.sql

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>

* Update src/server/game/Globals/ObjectMgr.h

Co-authored-by: Kargatum <dowlandtop@yandex.com>

* review changes

* unecessary removal

* pushback instead of emplace

* wrong database update

* Update ObjectMgr.cpp

* missing check

* removing entry from the PR

* missing removals

* last delete

* build

* aha! Found the culprit for the sudden assert errors

* type safety, save only important gameobjects

* static cast to unsigned short

* Update data/sql/updates/pending_db_characters/rev_1643629468629316100.sql

Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>

* type changes

* queries fix

* fix build

* enabling which gameobjects to save on the database

* deadmines iron clad door

* Adjustment to gameobject onj create state and instances:

- Gnomeregan doors and Grubbis boss state
- Deadmines missing doors
- Stratholme gameobjects state saved

* forgot emi blastfuse change to despawn

* Leaving group logic

* codestyle

* fixing merge issues

* prevent bad behaviour

* brain meltdown

* Update data/sql/updates/pending_db_characters/rev_1643629468629316100.sql

* Update data/sql/updates/pending_db_world/rev_1649359139539727000.sql

Co-authored-by: Claudiodfc <54484196+claudiodfc@users.noreply.github.com>
Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>
Co-authored-by: Kargatum <dowlandtop@yandex.com>
Co-authored-by: Skjalf <47818697+Nyeriah@users.noreply.github.com>
2022-05-24 10:33:45 -03:00
Kitzunu
336166c83e chore(Core/Misc): Improve wiki link in database error (#11496) 2022-04-23 15:49:35 -03:00
Kargatum
c0210ad7f0 feat(Core/DryRun): add support db autoupdate for DryRun (#9572) 2022-04-21 21:12:12 +02:00
Kitzunu
7ecd738674 feat(Core/Mail): Server mail (#10628) 2022-04-19 23:43:14 +02:00
IntelligentQuantum
b6a07d38c0 feat(Core/Characters): Replace DELETE + INSERT with REPLACE (#10862) 2022-03-15 09:40:55 +01:00
UltraNix
73957b95f6 fix(Core/Mail): do not show expired mails in packets (#10560)
Fixed #5920
2022-03-01 13:57:37 +01:00
Axel Cocat
743c028e31 fix(Core/Database): use char guid if character order is null (#10243)
Co-authored-by: temperrr <temperrr@users.noreply.github.com>
2022-02-27 14:48:18 +01:00
Kargatum
de13bf426e feat(Core/DBLayer): replace char const* to std::string_view (#10211)
* feat(Core/DBLayer): replace `char const*` to `std::string_view`

* CString

* 1

* chore(Core/Misc): code cleanup

* cl

* db fix

* fmt style sql

* to fmt

* py

* del old

* 1

* 2

* 3

* 1

* 1
2022-02-05 00:37:11 +01:00
Kitzunu
c63ebde9d7 feat(Guild/Commands): guild rename (#10323)
* feat(Guild/Commands): guild rename

* cherry-pick commit (678cade116#)

* Update cs_guild.cpp
2022-02-03 06:01:16 -03:00
Skjalf
c45c23ffe7 fix(Core/Player): Align SaveSeasonQuestStatus() with TrinityCore (#10503) 2022-02-02 21:14:02 -03:00
Kargatum
5969df4e30 refactor(Core/Logging): switch to fmt style for LOG_ (#10366)
* feat(Core/Common): add support fmt style for ASSERT and ABORT

* correct CheckCompactArrayMaskOverflow

* 1

* Update src/server/game/Spells/Spell.cpp

* rework logging

* add fmt replace logs

* logging

* FMT_LOG_

* settings

* fix startup

* 1

* 2

* 3

* 4

* 5

* fmt::print

* to fmt
2022-01-27 16:44:41 +01:00
Kargatum
e8f34b2309 feat(Core/Common): add support fmt style for ASSERT and ABORT (#10355)
* feat(Core/Common): add support fmt style for ASSERT and ABORT

* correct CheckCompactArrayMaskOverflow

* 1

* Update src/server/game/Spells/Spell.cpp
2022-01-25 23:15:51 +01:00
Kargatum
8b7df23f06 feat(Core/Time): Implement saparated manager for game time (#8630) 2022-01-24 17:55:00 +07:00
Francesco Borzì
abc56842c4 refactor(Core): remove unused imports (#10296) 2022-01-22 11:21:35 +01:00
Kargatum
6d7f58e6ed feat(Core/Common): delete old Tokenizer (#10121) 2022-01-21 14:59:05 +07:00
Kargatum
2ca5ad6af5 feat(Core/Database): add support set arguments for PrepareStatment (#10066)
- partical cherrypick 0b3f073ca2
2022-01-21 09:45:46 +07:00
Francesco Borzì
9dc88def35 refactor(Core): apply clang-tidy modernize-* (#9975)
Co-authored-by: Kitzunu <24550914+Kitzunu@users.noreply.github.com>
2022-01-17 14:35:07 +01:00