Skip to content

Commit

Permalink
Warlock guardians no longer use snapshots.
Browse files Browse the repository at this point in the history
git-svn-id: https://simulationcraft.googlecode.com/svn/branches/mop@11706 3b4652a1-8050-0410-ac47-3d40261b0f8b
  • Loading branch information
[email protected] committed Apr 25, 2012
1 parent ba4ebfb commit c3cf2b1
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 66 deletions.
2 changes: 1 addition & 1 deletion engine/class_modules/sc_warlock.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,7 @@ struct drain_soul_t : public warlock_spell_t
channeled = true;
hasted_ticks = true; // informative
may_crit = false;
tick_power_mod = 2;
tick_power_mod = 2; // from tooltip
}

virtual double action_multiplier( const action_state_t* s ) const
Expand Down
10 changes: 0 additions & 10 deletions engine/class_modules/sc_warlock.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -292,18 +292,8 @@ struct warlock_main_pet_t : public warlock_pet_t

struct warlock_guardian_pet_t : public warlock_pet_t
{
double snapshot_crit, snapshot_haste, snapshot_sp, snapshot_mastery;

warlock_guardian_pet_t( sim_t* sim, warlock_t* owner, const std::string& pet_name, pet_type_e pt );
virtual void summon( timespan_t duration=timespan_t::zero() );
virtual double composite_attack_crit( const weapon_t* ) const;
virtual double composite_attack_expertise( const weapon_t* ) const;
virtual double composite_attack_haste() const;
virtual double composite_attack_hit() const;
virtual double composite_attack_power() const;
virtual double composite_spell_crit() const;
virtual double composite_spell_haste() const;
virtual double composite_spell_power( school_type_e school ) const;
};

// ==========================================================================
Expand Down
56 changes: 3 additions & 53 deletions engine/class_modules/sc_warlock_pets.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -736,63 +736,13 @@ double warlock_main_pet_t::composite_attack_expertise( const weapon_t* ) const
// ==========================================================================

warlock_guardian_pet_t::warlock_guardian_pet_t( sim_t* sim, warlock_t* owner, const std::string& pet_name, pet_type_e pt ) :
warlock_pet_t( sim, owner, pet_name, pt, true ),
snapshot_crit( 0 ), snapshot_haste( 0 ), snapshot_sp( 0 ), snapshot_mastery( 0 )
warlock_pet_t( sim, owner, pet_name, pt, true )
{}

void warlock_guardian_pet_t::summon( timespan_t duration )
{
reset();
warlock_pet_t::summon( duration );
// Guardians use snapshots
snapshot_crit = owner -> composite_spell_crit();
snapshot_haste = owner -> spell_haste;
snapshot_sp = owner -> composite_spell_power( SCHOOL_MAX );
snapshot_mastery = owner -> composite_mastery();
}

double warlock_guardian_pet_t::composite_attack_crit( const weapon_t* ) const
{
return snapshot_crit;
}

double warlock_guardian_pet_t::composite_attack_expertise( const weapon_t* ) const
{
return 0;
}

double warlock_guardian_pet_t::composite_attack_haste() const
{
return snapshot_haste;
}

double warlock_guardian_pet_t::composite_attack_hit() const
{
return 0;
}

double warlock_guardian_pet_t::composite_attack_power() const
{
double ap = 0;
ap += snapshot_sp * ap_per_owner_sp;
return ap;
}

double warlock_guardian_pet_t::composite_spell_crit() const
{
return snapshot_crit;
}

double warlock_guardian_pet_t::composite_spell_haste() const
{
return snapshot_haste;
}

double warlock_guardian_pet_t::composite_spell_power( const school_type_e /*school*/ ) const
{
double sp = 59; // FIXME: Mysterious base spell power. Needs more testing/confirmation for all guardians, especially at level 90.
sp += snapshot_sp;
return sp;
}

// ==========================================================================
Expand Down Expand Up @@ -933,10 +883,10 @@ infernal_pet_t::infernal_pet_t( sim_t* sim, warlock_t* owner ) :
ap_per_owner_sp = 0.566;
}

double infernal_pet_t::composite_spell_power( const school_type_e /*school*/ ) const
double infernal_pet_t::composite_spell_power( const school_type_e school ) const
{
// The infernal, for some reason, does not appear to get the "hidden" base 59 sp
return snapshot_sp;
return owner -> composite_spell_power( school );
}

void infernal_pet_t::init_base()
Expand Down
2 changes: 1 addition & 1 deletion profiles/mop_test/warlock_affliction.simc
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ actions+=/haunt,if=!in_flight&target.debuff.haunt.remains<cast_time+travel_time
actions+=/agony,if=(!ticking|remains<=action.drain_soul.new_tick_time)&target.time_to_die>=8&miss_react
actions+=/corruption,if=(!ticking|remains<tick_time)&target.time_to_die>=6&miss_react
actions+=/unstable_affliction,if=(!ticking|remains<(cast_time+tick_time))&target.time_to_die>=5&miss_react
actions+=/summon_doomguard,if=time>10
actions+=/summon_doomguard
actions+=/drain_soul,interrupt=1,if=target.health.pct<=25
actions+=/life_tap,if=mana.pct<=35
actions+=/malefic_grasp
Expand Down
2 changes: 1 addition & 1 deletion profiles/mop_test/warlock_destruction.simc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ actions+=/volcanic_potion,if=buff.bloodlust.react|!in_combat|target.health.pct<2
actions+=/dark_soul
actions+=/shadowburn,if=ember_react
actions+=/chaos_bolt,if=ember_react
actions+=/summon_doomguard,if=time>10
actions+=/summon_doomguard
actions+=/conflagrate,if=buff.backdraft.down
actions+=/immolate,if=(!ticking|remains<(action.incinerate.cast_time+cast_time))&target.time_to_die>=5&miss_react
actions+=/incinerate
Expand Down

0 comments on commit c3cf2b1

Please sign in to comment.