Skip to content

Commit

Permalink
[Simplified Player] Stop them applying damage buff to trinkets/other
Browse files Browse the repository at this point in the history
sources
  • Loading branch information
Saeldur committed Jan 16, 2025
1 parent 8cde8dd commit a5d0f6d
Showing 1 changed file with 25 additions and 20 deletions.
45 changes: 25 additions & 20 deletions engine/class_modules/sc_evoker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -485,6 +485,11 @@ struct simplified_player_t : public player_t
return debug_cast<simplified_player_t*>( player );
}

simplified_player_t* p() const
{
return debug_cast<simplified_player_t*>( player );
}

action_t* damage_proc;
double haste_modifier;

Expand All @@ -499,6 +504,26 @@ struct simplified_player_t : public player_t
set_action_stats( settings, p );
}

double composite_da_multiplier( const action_state_t* s ) const override
{
double m = spell_t::composite_da_multiplier( s );

m *= 1.0 + p()->cache.mastery_value();

for ( auto* b : p()->damage_buffs )
{
if ( b->check() )
{
m *= 1.0 + b->check_stack_value();
}
}

if ( haste_modifier > 0 )
m *= 1.0 - haste_modifier + haste_modifier / p()->cache.spell_cast_speed();

return m;
}

void set_action_stats( bob_settings_t settings, simplified_player_t* p )
{
double scaling_factor = pow( 1 + settings.scaling_factor, ( p->option.item_level - 489 ) );
Expand Down Expand Up @@ -637,26 +662,6 @@ struct simplified_player_t : public player_t
snapshot_stats = new snapshot_stats_t( this, "" );
}

double composite_player_multiplier( school_e school ) const override
{
double m = player_t::composite_player_multiplier( school );

m *= 1.0 + cache.mastery_value();

for ( auto* b : damage_buffs )
{
if ( b->check() )
{
m *= 1.0 + b->check_stack_value();
}
}

if ( haste_modifier > 0 )
m *= 1.0 - haste_modifier + haste_modifier / cache.spell_cast_speed();

return m;
}

void acquire_target( retarget_source event, player_t* context ) override
{
if ( ability->execute_event && ability->target->is_sleeping() )
Expand Down

0 comments on commit a5d0f6d

Please sign in to comment.