Skip to content

Commit

Permalink
Merge branch 'main' into fix/adjust-bosses-lever-and-other-fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
luan authored Dec 2, 2023
2 parents 6e12718 + 2e342cc commit f3db1fa
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ end
local iceYakchal = Action()
function iceYakchal.onUse(player, item, fromPosition, target, toPosition, isHotkey)
local sarcophagus = Position(32205, 31002, 14)
if toPosition.x == sarcophagus.x and toPosition.y == sarcophagus.y and toPosition.z == sarcophagus.z and target.itemid == 7362 and item.itemid == 2361 then
if toPosition.x == sarcophagus.x and toPosition.y == sarcophagus.y and toPosition.z == sarcophagus.z and target.itemid == 7362 and item.itemid == 3249 then
if Game.getStorageValue(GlobalStorage.Yakchal) < os.time() then
Game.setStorageValue(GlobalStorage.Yakchal, os.time() + 24 * 60 * 60)
if math.random(2) == 2 then
Expand Down
8 changes: 7 additions & 1 deletion src/game/game.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7223,7 +7223,13 @@ bool Game::combatChangeMana(std::shared_ptr<Creature> attacker, std::shared_ptr<
}

target->drainMana(attacker, manaLoss);

if (targetPlayer) {
std::string cause = "(other)";
if (attacker) {
cause = attacker->getName();
}
targetPlayer->updateInputAnalyzer(damage.primary.type, damage.primary.value * -1, cause);
}
std::stringstream ss;

std::string damageString = std::to_string(manaLoss);
Expand Down

0 comments on commit f3db1fa

Please sign in to comment.