tjc12821

Untitled

Oct 28th, 2016
179
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.09 KB | None | 0 0
  1.   virtual void execute() override
  2.   {
  3.     hunter_melee_attack_t::execute();
  4.  
  5.     timespan_t animal_instincts = timespan_t::from_seconds( -3 ); //FIXME find spelldata
  6.  
  7.     if ( p() -> active.pet )
  8.       p() -> active.pet -> active.flanking_strike -> execute();
  9.  
  10.     if ( p() -> talents.animal_instincts -> ok() )
  11.     {
  12.       if ( !p() -> cooldowns.flanking_strike -> up() )
  13.         p() -> animal_instincts_cds.push_back( p() -> cooldowns.flanking_strike );
  14.       if ( !p() -> cooldowns.mongoose_bite -> up() )
  15.         p() -> animal_instincts_cds.push_back( p() -> cooldowns.mongoose_bite );
  16.       if ( !p() -> cooldowns.aspect_of_the_eagle -> up() )
  17.         p() -> animal_instincts_cds.push_back( p() -> cooldowns.aspect_of_the_eagle );
  18.       if ( !p() -> cooldowns.harpoon -> up() )
  19.         p() -> animal_instincts_cds.push_back( p() -> cooldowns.harpoon );
  20.  
  21.       unsigned roll =
  22.         as<unsigned>( p() -> rng().range( 0, p() -> animal_instincts_cds.size() ) );
  23.  
  24.       p() -> animal_instincts_cds[roll] -> adjust( animal_instincts );
  25.       p() -> procs.animal_instincts -> occur();
  26.     }
  27.   }
Advertisement
Add Comment
Please, Sign In to add comment