Assert::AreEqual(newMultishotCooldownTime,player->GetAbility3().GetCooldownTime(),util::wformat("Player starts with {} seconds of cooldown on Multishot.",newMultishotCooldownTime).c_str());
Assert::AreEqual(20,testMonster.GetHealth(),L"Monster should have taken 10 hitpoints of damage even if the attack was a valid backstab (no enchantment).");
Assert::AreEqual(20,testMonster.GetHealth(),L"Monster should have taken 10 hitpoints of damage with the backstab bonus because the player is not behind the target.");
UpdateLoop();//We immediately load the file. In a loading screen setting we would defer UpdateLoop() such that we have extra time to update the screen, UpdateLoop() is divided into many parts of the music loading process.
UpdateLoop();//We immediately load the file. In a loading screen setting we would defer UpdateLoop() such that we have extra time to update the screen, UpdateLoop() is divided into many parts of the music loading process.
}
//Start playing the tracks and setup a callback to repeat at looped time.
if(damageNumberPtr.get()->type==DamageNumberType::CRIT)gotodoneChangingDamageNumberColors;//Crit number priority. Other colors should not apply if the crit has applied.
if(!HasFourWaySprites())ERR(std::format("WARNING! Facing direction of a one-way facing monster was detected to be facing NORTH (Monster {} at Pos {}). THIS SHOULD NOT BE HAPPENING!",GetDisplayName(),GetPos().str()))
returngame->GetPlayer()->GetPos().y>GetPos().y;
}break;
caseSOUTH:{
if(!HasFourWaySprites())ERR(std::format("WARNING! Facing direction of a one-way facing monster was detected to be facing SOUTH (Monster {} at Pos {}). THIS SHOULD NOT BE HAPPENING!",GetDisplayName(),GetPos().str()))
returngame->GetPlayer()->GetPos().y<GetPos().y;
}break;
caseEAST:{
returngame->GetPlayer()->GetPos().x<GetPos().x;
}break;
caseWEST:{
returngame->GetPlayer()->GetPos().x>GetPos().x;
}break;
default:{
ERR(std::format("WARNING! Facing direction of a monster was detected to be facing {} (Monster {} at Pos {}). This is not a normal facing direction and THIS SHOULD NOT BE HAPPENING!",int(GetFacingDirection()),GetDisplayName(),GetPos().str()));
returnfalse;
}
}
ERR("WARNING! An unhandled case was detected while trying to determine if an attack was a backstab attack! THIS SHOULD NOT BE HAPPENING!");
//NOTE: Marking a monster for deletion does not trigger any death events. It just simply removes the monster from the field!!
// The way this works is that monsters marked for deletion will cause the monster update loop to detect there's at least one or more monsters that must be deleted and will call erase_if on the list at the end of the iteration loop.