Skip to content

Commit

Permalink
Merge branch 'master' into Playerbot
Browse files Browse the repository at this point in the history
  • Loading branch information
liyunfan1223 committed May 26, 2024
2 parents 5079750 + bb19dbf commit 1e22c4d
Show file tree
Hide file tree
Showing 78 changed files with 102,235 additions and 326 deletions.
2 changes: 1 addition & 1 deletion .github/actions/linux-build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ runs:
using: composite
steps:
- name: Cache
uses: actions/cache@v3
uses: actions/cache@v4
if: inputs.pch != 'true'
with:
path: ${{ github.workspace }}/var/ccache
Expand Down
12 changes: 10 additions & 2 deletions .github/workflows/core-build-nopch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,16 @@ jobs:
CXX: clang++-15
- os: ubuntu-22.04
compiler:
CC: gcc-13
CXX: g++-13
CC: gcc-12
CXX: g++-12
- os: ubuntu-24.04
compiler:
CC: clang-18
CXX: clang++-18
- os: ubuntu-24.04
compiler:
CC: gcc-14
CXX: g++-14
runs-on: ${{ matrix.os }}
name: ${{ matrix.os }}-${{ matrix.compiler }}-nopch
env:
Expand Down
12 changes: 10 additions & 2 deletions .github/workflows/core-build-pch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,16 @@ jobs:
CXX: clang++-15
- os: ubuntu-22.04
compiler:
CC: gcc-13
CXX: g++-13
CC: gcc-12
CXX: g++-12
- os: ubuntu-24.04
compiler:
CC: clang-18
CXX: clang++-18
- os: ubuntu-24.04
compiler:
CC: gcc-14
CXX: g++-14
runs-on: ${{ matrix.os }}
name: ${{ matrix.os }}-${{ matrix.compiler }}-pch
env:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/macos_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ~/Library/Caches/ccache
key: ccache:${{ matrix.os }}:${{ github.ref }}:${{ github.sha }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tools_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Cache
uses: actions/cache@v3
uses: actions/cache@v4
env:
cache-name: cache-tools
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/windows_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: ccache
uses: hendrikmuhs/[email protected].9
uses: hendrikmuhs/[email protected].13
- name: Configure OS
shell: bash
env:
Expand Down
38 changes: 35 additions & 3 deletions apps/docker/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,14 +1,46 @@
#!/usr/bin/env bash
set -euo pipefail

CONF_DIR="${CONF_DIR:-/azerothcore/env/dist/etc}"
LOGS_DIR="${LOGS_DIR:-/azerothcore/env/dist/logs}"

if ! touch "$CONF_DIR/.write-test" || ! touch "$LOGS_DIR/.write-test"; then
cat <<EOF
===== WARNING =====
The current user doesn't have write permissions for
the configuration dir ($CONF_DIR) or logs dir ($LOGS_DIR).
It's likely that services will fail due to this.
This is usually caused by cloning the repository as root,
so the files are owned by root (uid 0).
To resolve this, you can set the ownership of the
configuration directory with the command on the host machine.
Note that if the files are owned as root, the ownership must
be changed as root (hence sudo).
$ sudo chown -R $(id -u):$(id -g) /path/to$CONF_DIR /path/to$LOGS_DIR
Alternatively, you can set the DOCKER_USER environment
variable (on the host machine) to "root", though this
isn't recommended.
$ DOCKER_USER=root docker-compose up -d
====================
EOF
fi

[[ -f "$CONF_DIR/.write-test" ]] && rm -f "$CONF_DIR/.write-test"
[[ -f "$LOGS_DIR/.write-test" ]] && rm -f "$LOGS_DIR/.write-test"

# Copy all default config files to env/dist/etc if they don't already exist
# -r == recursive
# -n == no clobber (don't overwrite)
# -v == be verbose
cp -rnv /azerothcore/env/ref/etc/* /azerothcore/env/dist/etc
cp -rnv /azerothcore/env/ref/etc/* "$CONF_DIR"

CONF="/azerothcore/env/dist/etc/$ACORE_COMPONENT.conf"
CONF_DIST="/azerothcore/env/dist/etc/$ACORE_COMPONENT.conf.dist"
CONF="$CONF_DIR/$ACORE_COMPONENT.conf"
CONF_DIST="$CONF_DIR/$ACORE_COMPONENT.conf.dist"

# Copy the "dist" file to the "conf" if the conf doesn't already exist
if [[ -f "$CONF_DIST" ]]; then
Expand Down
72 changes: 72 additions & 0 deletions data/sql/updates/db_world/2024_05_09_00.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
-- DB update 2024_05_04_00 -> 2024_05_09_00
SET @REFIDONE = 35100,
@REFIDTWO = 35101,
@REFIDTHREE = 35102,
@TANZAR = 22699,
@KRAZ = 22790,
@ASHLI = 22797,
@HARKOR = 22968;

DELETE FROM `gameobject_loot_template` WHERE `Entry` IN (@TANZAR, @KRAZ, @ASHLI, @HARKOR);
INSERT INTO `gameobject_loot_template` (`Entry`, `Item`, `Reference`, `Chance`, `QuestRequired`, `LootMode`, `GroupId`, `MinCount`, `MaxCount`, `Comment`) VALUES
(@TANZAR, @REFIDONE, @REFIDONE, 100, 0, 1, 0, 1, 1, 'Tanzar\'s Trunk - First Hostage Loot'),
(@TANZAR, @REFIDTWO, @REFIDTWO, 100, 0, 1, 0, 1, 1, 'Tanzar\'s Trunk - Second Hostage Loot'),
(@TANZAR, @REFIDTHREE, @REFIDTHREE, 100, 0, 1, 0, 1, 1, 'Tanzar\'s Trunk - Third Hostage Loot'),
(@KRAZ, @REFIDONE, @REFIDONE, 100, 0, 1, 0, 1, 1, 'Kraz\'s Package - First Hostage Loot'),
(@KRAZ, @REFIDTWO, @REFIDTWO, 100, 0, 1, 0, 1, 1, 'Kraz\'s Package - Second Hostage Loot'),
(@KRAZ, @REFIDTHREE, @REFIDTHREE, 100, 0, 1, 0, 1, 1, 'Kraz\'s Package - Third Hostage Loot'),
(@ASHLI, @REFIDONE, @REFIDONE, 100, 0, 1, 0, 1, 1, 'Ashli\'s Bag - First Hostage Loot'),
(@ASHLI, @REFIDTWO, @REFIDTWO, 100, 0, 1, 0, 1, 1, 'Ashli\'s Bag - Second Hostage Loot'),
(@ASHLI, @REFIDTHREE, @REFIDTHREE, 100, 0, 1, 0, 1, 1, 'Ashli\'s Bag - Third Hostage Loot'),
(@HARKOR, @REFIDONE, @REFIDONE, 100, 0, 1, 0, 1, 1, 'Harkor\'s Satchel - First Hostage Loot'),
(@HARKOR, @REFIDTWO, @REFIDTWO, 100, 0, 1, 0, 1, 1, 'Harkor\'s Satchel - Second Hostage Loot'),
(@HARKOR, @REFIDTHREE, @REFIDTHREE, 100, 0, 1, 0, 1, 1, 'Harkor\'s Satchel - Third Hostage Loot');

DELETE FROM `reference_loot_template` WHERE `Entry` IN (@REFIDONE, @REFIDTWO, @REFIDTHREE);
INSERT INTO `reference_loot_template` (`Entry`, `Item`, `Reference`, `Chance`, `QuestRequired`, `LootMode`, `GroupId`, `MinCount`, `MaxCount`, `Comment`) VALUES
(@REFIDONE, 33480, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - First Hostage Loot - Cord of Braided Troll Hair'),
(@REFIDONE, 33481, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - First Hostage Loot - Pauldrons of Stone Resolve'),
(@REFIDONE, 33483, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - First Hostage Loot - Life-step Belt'),
(@REFIDONE, 33489, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - First Hostage Loot - Mantle of Ill Intent'),
(@REFIDONE, 33590, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - First Hostage Loot - Cloak of Fiends'),
(@REFIDONE, 33591, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - First Hostage Loot - Shadowcaster\'s Drape'),
(@REFIDONE, 33805, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - First Hostage Loot - Shadowhunter\'s Treads'),
(@REFIDONE, 33971, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - First Hostage Loot - Elunite Imbued Leggings'),
(@REFIDTWO, 33490, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Second Hostage Loot - Staff of Dark Mending'),
(@REFIDTWO, 33491, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Second Hostage Loot - Tuskbreaker'),
(@REFIDTWO, 33492, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Second Hostage Loot - Trollbane'),
(@REFIDTWO, 33493, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Second Hostage Loot - Umbral Shiv'),
(@REFIDTWO, 33494, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Second Hostage Loot - Amani Divining Staff'),
(@REFIDTWO, 33495, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Second Hostage Loot - Rage'),
(@REFIDTHREE, 33496, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Third Hostage Loot - Signet of Primal Wrath'),
(@REFIDTHREE, 33497, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Third Hostage Loot - Mana Attuned Band'),
(@REFIDTHREE, 33498, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Third Hostage Loot - Signet of the Quiet Forest'),
(@REFIDTHREE, 33499, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Third Hostage Loot - Signet of the Last Defender'),
(@REFIDTHREE, 33500, 0, 0, 0, 1, 1, 1, 1, 'Zul\'Aman - Third Hostage Loot - Signet of Eternal Life');

DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 10) AND (`SourceGroup` IN (@REFIDONE, @REFIDTWO, @REFIDTHREE, @REFIDFOUR)) AND (`ConditionTypeOrReference` = 13) AND (`ConditionValue1` = 8);
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(10, @REFIDONE, 33480, 0, 0, 13, 0, 8, 1, 0, 0, 0, 0, '', 'Yield first hostage loot if first hostage has been rescued'),
(10, @REFIDONE, 33481, 0, 0, 13, 0, 8, 1, 0, 0, 0, 0, '', 'Yield first hostage loot if first hostage has been rescued'),
(10, @REFIDONE, 33483, 0, 0, 13, 0, 8, 1, 0, 0, 0, 0, '', 'Yield first hostage loot if first hostage has been rescued'),
(10, @REFIDONE, 33489, 0, 0, 13, 0, 8, 1, 0, 0, 0, 0, '', 'Yield first hostage loot if first hostage has been rescued'),
(10, @REFIDONE, 33590, 0, 0, 13, 0, 8, 1, 0, 0, 0, 0, '', 'Yield first hostage loot if first hostage has been rescued'),
(10, @REFIDONE, 33591, 0, 0, 13, 0, 8, 1, 0, 0, 0, 0, '', 'Yield first hostage loot if first hostage has been rescued'),
(10, @REFIDONE, 33805, 0, 0, 13, 0, 8, 1, 0, 0, 0, 0, '', 'Yield first hostage loot if first hostage has been rescued'),
(10, @REFIDONE, 33971, 0, 0, 13, 0, 8, 1, 0, 0, 0, 0, '', 'Yield first hostage loot if first hostage has been rescued'),
(10, @REFIDTWO, 33490, 0, 0, 13, 0, 8, 2, 0, 0, 0, 0, '', 'Yield second hostage loot if second hostage has been rescued'),
(10, @REFIDTWO, 33491, 0, 0, 13, 0, 8, 2, 0, 0, 0, 0, '', 'Yield second hostage loot if second hostage has been rescued'),
(10, @REFIDTWO, 33492, 0, 0, 13, 0, 8, 2, 0, 0, 0, 0, '', 'Yield second hostage loot if second hostage has been rescued'),
(10, @REFIDTWO, 33493, 0, 0, 13, 0, 8, 2, 0, 0, 0, 0, '', 'Yield second hostage loot if second hostage has been rescued'),
(10, @REFIDTWO, 33494, 0, 0, 13, 0, 8, 2, 0, 0, 0, 0, '', 'Yield second hostage loot if second hostage has been rescued'),
(10, @REFIDTWO, 33495, 0, 0, 13, 0, 8, 2, 0, 0, 0, 0, '', 'Yield second hostage loot if second hostage has been rescued'),
(10, @REFIDTHREE, 33496, 0, 1, 13, 0, 8, 3, 0, 0, 0, 0, '', 'Yield third hostage loot if third hostage has been rescued'),
(10, @REFIDTHREE, 33497, 0, 1, 13, 0, 8, 3, 0, 0, 0, 0, '', 'Yield third hostage loot if third hostage has been rescued'),
(10, @REFIDTHREE, 33498, 0, 1, 13, 0, 8, 3, 0, 0, 0, 0, '', 'Yield third hostage loot if third hostage has been rescued'),
(10, @REFIDTHREE, 33499, 0, 1, 13, 0, 8, 3, 0, 0, 0, 0, '', 'Yield third hostage loot if third hostage has been rescued'),
(10, @REFIDTHREE, 33500, 0, 1, 13, 0, 8, 3, 0, 0, 0, 0, '', 'Yield third hostage loot if third hostage has been rescued'),
(10, @REFIDTHREE, 33496, 0, 2, 13, 0, 8, 4, 0, 0, 0, 0, '', 'Yield third hostage loot if all hostages have been rescued'),
(10, @REFIDTHREE, 33497, 0, 2, 13, 0, 8, 4, 0, 0, 0, 0, '', 'Yield third hostage loot if all hostages have been rescued'),
(10, @REFIDTHREE, 33498, 0, 2, 13, 0, 8, 4, 0, 0, 0, 0, '', 'Yield third hostage loot if all hostages have been rescued'),
(10, @REFIDTHREE, 33499, 0, 2, 13, 0, 8, 4, 0, 0, 0, 0, '', 'Yield third hostage loot if all hostages have been rescued'),
(10, @REFIDTHREE, 33500, 0, 2, 13, 0, 8, 4, 0, 0, 0, 0, '', 'Yield third hostage loot if all hostages have been rescued');
8 changes: 8 additions & 0 deletions data/sql/updates/db_world/2024_05_11_00.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
-- DB update 2024_05_09_00 -> 2024_05_11_00
--
UPDATE `gameobject_template` SET `AIName` = 'SmartGameObjectAI' WHERE `entry` IN (180690, 180691);

DELETE FROM `smart_scripts` WHERE (`source_type` = 1 AND `entryorguid` IN (180690, 180691));
INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `event_param5`, `event_param6`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_param4`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES
(180690, 1, 0, 0, 70, 0, 100, 0, 2, 0, 0, 0, 0, 0, 106, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Large Scarab Coffer - On Gameobject State Changed - Remove Gameobject Flags Locked'),
(180691, 1, 0, 0, 70, 0, 100, 0, 2, 0, 0, 0, 0, 0, 106, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 'Scarab Coffer - On Gameobject State Changed - Remove Gameobject Flags Locked');
3 changes: 3 additions & 0 deletions data/sql/updates/db_world/2024_05_11_01.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
-- DB update 2024_05_11_00 -> 2024_05_11_01
--
UPDATE `spell_target_position` SET `PositionX`=386.27, `PositionY`=33.4144, `PositionZ`=-130.934, `VerifiedBuild`=52237 WHERE `ID`=21128;
Loading

0 comments on commit 1e22c4d

Please sign in to comment.