43832 {
43834 bool flag =
type >= 986 &&
type <= 993;
43836 bool flag2 =
false;
43837 if (player.inventory[player.selectedItem].fishingPole == 0 || player.CCed || player.noItems)
43838 {
43840 }
43841 else if (player.inventory[player.selectedItem].shoot !=
type && !flag)
43842 {
43844 }
43845 else if (player.pulley)
43846 {
43848 }
43849 else if (player.dead)
43850 {
43852 }
43854 {
43856 return;
43857 }
43859 {
43862 {
43864 }
43865 }
43867 {
43869 {
43873 {
43875 }
43876 }
43878 {
43880 }
43882 {
43885 }
43887 int num = 10;
43889 float num2 = player.position.X + (float)(player.width / 2) -
vector.X;
43890 float num3 = player.position.Y + (float)(player.height / 2) -
vector.Y;
43893 {
43895 }
43899 velocity.X = (velocity.X * (float)(num - 1) +
num2) / (
float)num;
43900 velocity.Y = (velocity.Y * (float)(num - 1) +
num3) / (
float)num;
43902 if (Main.myPlayer ==
owner &&
base.Hitbox.Intersects(player.Hitbox))
43903 {
43905 }
43906 return;
43907 }
43908 bool flag3 =
false;
43910 float num5 = player.position.X + (float)(player.width / 2) -
vector2.X;
43911 float num6 = player.position.Y + (float)(player.height / 2) -
vector2.Y;
43914 {
43916 }
43918 {
43920 {
43921 if (Main.myPlayer ==
owner)
43922 {
43923 Main.player[
owner].AddBuff(353, 60);
43924 }
43926 {
43929 }
43930 }
43932 velocity.X *= 0.9f;
43934 int num8 = (int)(
base.Center.Y / 16f);
43935 _ = position.Y / 16f;
43937 if (Main.tile[
num7,
num8] ==
null)
43938 {
43940 }
43941 if (Main.tile[
num7,
num9] ==
null)
43942 {
43944 }
43946 {
43947 velocity.Y *= 0.5f;
43948 }
43949 num7 = (int)(
base.Center.X / 16f);
43950 num8 = (int)(
base.Center.Y / 16f);
43953 {
43954 velocity.Y -= 0.1f;
43956 {
43957 velocity.Y = -8f;
43958 }
43960 {
43962 }
43963 }
43964 else
43965 {
43967 }
43969 {
43971 }
43972 }
43973 else
43974 {
43976 {
43977 velocity.X *= 0.95f;
43978 }
43979 velocity.X *= 0.98f;
43980 velocity.Y += 0.2f;
43982 {
43983 velocity.Y = 15.9f;
43984 }
43985 }
43986 if (Main.myPlayer ==
owner && player.GetFishingConditions().BaitItemType == 2673)
43987 {
43989 }
43991 {
43993 }
43995 {
43996 return;
43997 }
43998 if (
ai[1] == 0f && Main.myPlayer ==
owner)
43999 {
44002 {
44003 localAI[1] += Main.rand.Next(1, 3);
44004 }
44006 localAI[1] += Main.rand.Next(1, 3);
44007 if (Main.rand.Next(60) == 0)
44008 {
44010 }
44012 {
44015 }
44016 }
44017 else if (
ai[1] < 0f)
44018 {
44020 {
44021 velocity.Y = (float)Main.rand.Next(100, 500) * 0.015f;
44022 velocity.X = (float)Main.rand.Next(-100, 101) * 0.015f;
44026 }
44027 ai[1] += Main.rand.Next(1, 5);
44029 {
44033 }
44034 }
44035 }
static double Atan2(double y, double x)
static double Sqrt(double d)
static double Abs(double value)
static void PlaySound(int type, Vector2 position, int style=1)
static readonly LegacySoundStyle Item17
static string GetTextValue(string key)
float AI_061_FishingBobber_GetWaterLine(int X, int Y)
void AI_061_FishingBobber_DoASplash()
void ReduceRemainingChumsInPool()