Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[script][combat-trainer] fix for devour blocking looting #7087

Merged
merged 2 commits into from
Feb 1, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions combat-trainer.lic
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,8 @@ class LootProcess
@last_ritual = nil
echo(" @last_ritual: #{@last_ritual}") if $debug_mode_ct

@necro_heal = thanatology['heal'] || false
# necro_heal requires CF and/or devour to make it a reality, so condition it based on that
@necro_heal = (thanatology['heal'] && (settings.necromancer_healing['Consumed Flesh'] || settings.necromancer_healing['Devour'])) || false
echo(" @necro_heal: #{@necro_heal}") if $debug_mode_ct

@necro_store = thanatology['store'] || false
Expand Down Expand Up @@ -795,7 +796,10 @@ class LootProcess
echo "Severity to Wounds: #{game_state.wounds}" if $debug_mode_ct
echo "wound_level_threshold: #{@wound_level_threshold}" if $debug_mode_ct
unless game_state.wounds.empty?
if @wound_level_threshold <= game_state.wounds.keys.max
# if devour is active, stop a (second) consume from being requested - has previously caused problem downstream with consume
# flag set but no CF/devour cast to clear hence blocking looting (and potentially other necro_casting defs)
# the check for !devour will also disallow concurrent use of devour and CF but that is not currently supported in CT @ 2/2/2025
if @wound_level_threshold <= game_state.wounds.keys.max && !DRSpells.active_spells['Devour']
do_necro_ritual(mob_noun, 'consume', game_state)
return false
end
Expand Down