57726 {
57727
57728
57729
57730
57731
57732
57733
57734
57735
57736
57737
57738
57739
57740
57741
57742
57743
57745 float num = 0.4f;
57751 float num7 = 0.95f;
57755 float num11 = 100f;
57759 bool flag = true;
57762 bool flag3 =
false;
57763 bool flag4 =
false;
57764 float num16 = 0.05f;
57766 bool flag5 =
false;
57768 {
57769 case 558:
57770 case 559:
57771 case 560:
57773 num = 0.7f;
57775 {
57776 num = 0.5f;
57777 }
57779 {
57780 num = 0.2f;
57781 }
57797 break;
57798 case 574:
57799 case 575:
57801 num = 0.6f;
57803 {
57804 num = 0.4f;
57805 }
57822 break;
57823 }
57827 {
57829 {
57831 }
57833 {
57835 }
57837 {
57841 {
57843 }
57849 {
57851 }
57852 for (
int i = 0;
i <
num18;
i++)
57853 {
57854 if (Main.rand.Next(
maxValue) == 0)
57855 {
57857 dust.scale = 0.55f;
57858 dust.fadeIn = 0.7f;
57859 dust.velocity *= 0.1f *
num19;
57861 }
57862 }
57863 }
57864 }
57866 {
57867 for (
int j = 0;
j < 200;
j++)
57868 {
57870 {
57872 {
57873 velocity.X -=
num16;
57874 }
57875 else
57876 {
57877 velocity.X +=
num16;
57878 }
57880 {
57881 velocity.Y -=
num16;
57882 }
57883 else
57884 {
57885 velocity.Y +=
num16;
57886 }
57887 }
57888 }
57889 }
57891 {
57893 }
57894 if (
rotation < -(
float)Math.PI / 2f)
57895 {
57897 }
57899 {
57901 }
57903 if (Main.expertMode)
57904 {
57905 num *= Main.GameModeInfo.KnockbackToEnemiesMultiplier;
57906 }
57909 {
57920 {
57922 }
57926 {
57930 {
57931 velocity.Y -= 0.2f;
57933 {
57934 velocity.Y = -10f;
57935 }
57936 }
57938 {
57941 {
57943 }
57944 }
57945 else
57946 {
57948 }
57949 }
57950 else
57951 {
57956 }
57957 }
57958 else if (
ai[0] == 1f)
57959 {
57962 velocity.Y +=
num17;
57965 {
57967 {
57971 if (Main.rand.Next(5) == 0)
57972 {
57976 }
57977 }
57978 else if (
type == 574 ||
type == 575)
57979 {
57984 }
57985 }
57987 {
57995 }
57996 }
57997 else if (
ai[0] == 2f)
57998 {
57999 if (
ai[1] >= 20f && (
type == 574 ||
type == 575))
58000 {
58003 {
58007 }
58008 else
58009 {
58010 activeSound.Position =
base.Center;
58011 }
58012 }
58018 {
58020 }
58022 {
58029 if (flag)
58030 {
58033 }
58034 }
58035 else
58036 {
58041 {
58043 }
58045 }
58047 {
58053 }
58054 }
58055 else if (
ai[0] == 4f)
58056 {
58059 {
58063 }
58065 }
58068 {
58069 activeSound2.Position =
base.Center;
58070 }
58071 else
58072 {
58076 }
58078 {
58081 {
58082 activeSound2.Position =
base.Center;
58083 }
58084 else
58085 {
58089 }
58090 }
58092 {
58098 }
58100 {
58101 return;
58102 }
58105 position.X -=
width / 2;
58106 position.Y -=
height / 2;
58110 if (
ai[1] == 0f && (
type == 574 ||
type == 575))
58111 {
58112 for (
int k = 0;
k < 4;
k++)
58113 {
58115 Main.dust[
num24].position = base.Center +
Vector2.
UnitY.RotatedByRandom(3.1415927410125732) * (float)Main.rand.NextDouble() *
width / 2f;
58116 }
58117 for (
int l = 0;
l < 20;
l++)
58118 {
58120 Main.dust[
num25].position = base.Center +
Vector2.
UnitY.RotatedByRandom(3.1415927410125732) * (float)Main.rand.NextDouble() *
width / 2f;
58121 Main.dust[
num25].noGravity =
true;
58122 Main.dust[
num25].velocity *= 3f;
58124 Main.dust[
num25].position = base.Center +
Vector2.
UnitY.RotatedByRandom(3.1415927410125732) * (float)Main.rand.NextDouble() *
width / 4f;
58125 Main.dust[
num25].velocity *= 2f;
58126 Main.dust[
num25].noGravity =
true;
58127 Main.dust[
num25].fadeIn = 2.5f;
58128 }
58129 for (
int m = 0;
m < 6;
m++)
58130 {
58133 Main.dust[
num26].noGravity =
true;
58134 Main.dust[
num26].velocity *= 3f;
58135 }
58136 for (
int n = 0;
n < 12;
n++)
58137 {
58140 Main.dust[
num27].noGravity =
true;
58141 Main.dust[
num27].velocity *= 3f;
58142 }
58144 {
58145 int num29 = Gore.NewGore(
position +
new Vector2((
float)(
width * Main.rand.Next(100)) / 100f, (
float)(
height * Main.rand.Next(100)) / 100f) - Vector2.One * 10f,
default(
Vector2), Main.rand.Next(61, 64));
58146 Main.gore[
num29].position = base.Center +
Vector2.
UnitY.RotatedByRandom(3.1415927410125732) * (float)Main.rand.NextDouble() *
width / 2f;
58147 Main.gore[
num29].velocity *= 0.3f;
58148 Main.gore[
num29].velocity.X += (float)Main.rand.Next(-10, 11) * 0.05f;
58149 Main.gore[
num29].velocity.Y += (float)Main.rand.Next(-10, 11) * 0.05f;
58150 }
58151 }
58154 {
58159 }
58160 }
static double Abs(double value)
static int Sign(decimal value)
static SlotId PlayTrackedSound(SoundStyle style, Vector2 position)
static void PlaySound(int type, Vector2 position, int style=1)
static ActiveSound GetActiveSound(SlotId id)
static readonly LegacySoundStyle DD2_KoboldIgnite
static readonly LegacySoundStyle DD2_WyvernScream
static readonly LegacySoundStyle Item14
static readonly LegacySoundStyle DD2_KoboldFlyerChargeScream
static readonly LegacySoundStyle DD2_KoboldIgniteLoop
static readonly LegacySoundStyle DD2_WyvernDiveDown
static readonly LegacySoundStyle DD2_EtherianPortalSpawnEnemy
NPCAimedTarget GetTargetData(bool ignorePlayerTankPets=true)
int GetAttackDamage_ScaledByStrength(float normalDamage)
void HitEffect(int hitDirection=0, double dmg=10.0)
static void TargetClosestOldOnesInvasion(NPC searcher, bool faceTarget=true, Vector2? checkPosition=null)
static float Distance(Vector2 value1, Vector2 value2)
static readonly SlotId Invalid
static SlotId FromFloat(float value)