44186 {
44187
44188
44189
44190
44191
44192
44193
44194
44196 {
44198 }
44200 {
44206 {
44208 color.A = byte.MaxValue;
44209 for (
int i = 0;
i < 4;
i++)
44210 {
44211 Dust
obj = Main.dust[Dust.NewDust(
base.Center, 0, 0, 264)];
44212 obj.position =
base.Center;
44213 obj.velocity =
velocity * 2f + Utils.RandomVector2(Main.rand, -1f, 1f);
44214 obj.color = color;
44215 obj.scale = 1.2f;
44216 obj.noLight = true;
44217 obj.noGravity = true;
44218 obj.customData = Main.player[
owner];
44219 }
44221 {
44223 }
44224 else
44225 {
44227 }
44228 }
44231 {
44233 }
44235 {
44238 {
44240 }
44241 }
44243 {
44245 color2.A = byte.MaxValue;
44246 Dust
obj2 = Main.dust[Dust.NewDust(
base.Center, 0, 0, 263)];
44247 obj2.position =
base.Center;
44250 obj2.noGravity = true;
44251 obj2.scale = 0.6f;
44252 }
44253 }
44255 {
44257 Main.dust[num].noGravity = true;
44258 Main.dust[num].velocity *= 0.25f;
44259 Main.dust[num].velocity +=
velocity * 0.75f;
44261 {
44264 for (
int j = 0;
j < 20;
j++)
44265 {
44267 Main.dust[num].noGravity = true;
44268 Main.dust[num].velocity *= 0.25f;
44269 Main.dust[num].velocity +=
velocity;
44270 Main.dust[num].velocity.
X *= 1f + (float)Main.rand.Next(-50, 51) * 0.01f;
44271 Main.dust[num].velocity.Y *= 1f + (float)Main.rand.Next(-50, 51) * 0.01f;
44272 }
44273 }
44274 }
44276 {
44279 {
44281 }
44282 }
44284 {
44286 {
44289 }
44292 {
44294 }
44298 {
44302 {
44304 }
44305 }
44306 Lighting.AddLight((
int)base.Center.X / 16, (int)
base.Center.Y / 16, 0.3f, 1.1f, 0.5f);
44307 }
44309 {
44311 {
44314 }
44315 else if (
ai[1] == 1f && Main.netMode != 1)
44316 {
44318 float num3 = 2000f;
44319 for (
int k = 0;
k < 255;
k++)
44320 {
44321 if (Main.player[
k].active && !Main.player[
k].dead)
44322 {
44326 {
44329 }
44330 }
44331 }
44333 {
44335 return;
44336 }
44338 {
44342 }
44343 }
44344 else if (
ai[1] > 20f &&
ai[1] < 200f)
44345 {
44348 if (!Main.player[
num5].active || Main.player[
num5].dead)
44349 {
44353 }
44354 else
44355 {
44358 if (
vector.Length() < 20f)
44359 {
44361 return;
44362 }
44365 {
44367 }
44370 }
44371 }
44372 if (
ai[1] >= 1f &&
ai[1] < 20f)
44373 {
44376 {
44378 }
44379 }
44382 {
44384 }
44388 {
44392 {
44394 }
44395 }
44396 Lighting.AddLight(
base.Center, 1.1f, 0.9f, 0.4f);
44399 {
44401 for (
int l = 0;
l < 12;
l++)
44402 {
44406 int num8 = Dust.NewDust(
base.Center, 0, 0, 6, 0f, 0f, 160);
44407 Main.dust[
num8].scale = 1.1f;
44408 Main.dust[
num8].noGravity =
true;
44412 }
44413 }
44414 if (Main.rand.Next(4) == 0)
44415 {
44416 for (
int m = 0;
m < 1;
m++)
44417 {
44420 Main.dust[
num9].velocity *= 0.1f;
44422 Main.dust[
num9].fadeIn = 0.9f;
44423 }
44424 }
44425 if (Main.rand.Next(32) == 0)
44426 {
44427 for (
int n = 0;
n < 1;
n++)
44428 {
44431 Main.dust[
num10].velocity *= 0.3f;
44433 if (Main.rand.Next(2) == 0)
44434 {
44435 Main.dust[
num10].fadeIn = 1.4f;
44436 }
44437 }
44438 }
44439 if (Main.rand.Next(2) == 0)
44440 {
44442 {
44445 Main.dust[
num12].velocity *= 0.3f;
44446 Main.dust[
num12].noGravity =
true;
44448 if (Main.rand.Next(2) == 0)
44449 {
44450 Main.dust[
num12].fadeIn = 1.4f;
44451 }
44452 }
44453 }
44454 }
44456 {
44458 {
44461 }
44462 else if (
ai[1] == 1f && Main.netMode != 1)
44463 {
44465 float num14 = 2000f;
44467 {
44468 if (Main.player[
num15].active && !Main.player[
num15].dead)
44469 {
44473 {
44476 }
44477 }
44478 }
44480 {
44482 return;
44483 }
44485 {
44489 }
44490 }
44491 else if (
ai[1] > 20f &&
ai[1] < 200f)
44492 {
44495 if (!Main.player[
num17].active || Main.player[
num17].dead)
44496 {
44500 }
44501 else
44502 {
44506 {
44508 return;
44509 }
44512 {
44514 }
44517 }
44518 }
44519 if (
ai[1] >= 1f &&
ai[1] < 20f)
44520 {
44523 {
44525 }
44526 }
44529 {
44531 }
44535 {
44539 {
44541 }
44542 }
44543 Lighting.AddLight(
base.Center, 0.2f, 0.1f, 0.6f);
44546 {
44549 {
44553 int num21 = Dust.NewDust(
base.Center, 0, 0, 27, 0f, 0f, 160);
44554 Main.dust[
num21].scale = 1.1f;
44555 Main.dust[
num21].noGravity =
true;
44559 }
44560 }
44561 if (Main.rand.Next(4) == 0)
44562 {
44564 {
44567 Main.dust[
num23].velocity *= 0.1f;
44569 Main.dust[
num23].fadeIn = 0.9f;
44570 }
44571 }
44572 if (Main.rand.Next(32) == 0)
44573 {
44575 {
44578 Main.dust[
num25].velocity *= 0.3f;
44580 if (Main.rand.Next(2) == 0)
44581 {
44582 Main.dust[
num25].fadeIn = 1.4f;
44583 }
44584 }
44585 }
44586 if (Main.rand.Next(2) == 0)
44587 {
44589 {
44592 Main.dust[
num27].velocity *= 0.3f;
44593 Main.dust[
num27].noGravity =
true;
44595 if (Main.rand.Next(2) == 0)
44596 {
44597 Main.dust[
num27].fadeIn = 1.4f;
44598 }
44599 }
44600 }
44601 }
44603 {
44605 float num29 = 250f;
44608 float num31 = 1.2f;
44611 int num33 = Utils.SelectRandom<
int>(Main.rand, 242, 73, 72, 71, 255);
44614 {
44621 num33 = Utils.SelectRandom<
int>(Main.rand, 242, 59, 88);
44622 }
44624 {
44626 localAI[0] = -Main.rand.Next(48);
44628 }
44629 else if (
ai[1] == 1f &&
owner == Main.myPlayer)
44630 {
44634 {
44635 if (Main.npc[
num37].active && Main.npc[
num37].CanBeChasedBy(
this))
44636 {
44640 {
44643 }
44644 }
44645 }
44647 {
44649 return;
44650 }
44652 {
44656 }
44657 }
44659 {
44662 if (!Main.npc[
num39].active || !Main.npc[
num39].CanBeChasedBy(
this))
44663 {
44667 }
44668 else
44669 {
44673 {
44675 return;
44676 }
44678 {
44681 }
44684 }
44685 }
44687 {
44690 {
44692 }
44693 }
44696 {
44698 }
44702 {
44706 {
44708 }
44709 }
44710 Lighting.AddLight(
base.Center,
rgb2);
44714 {
44716 }
44717 else if (
alpha == 0)
44718 {
44720 {
44723 int num42 = Dust.NewDust(
base.Center, 0, 0,
num34, 0f, 0f, 160);
44725 Main.dust[
num42].noGravity =
true;
44728 }
44729 }
44730 if (Main.rand.Next(12) == 0)
44731 {
44733 {
44736 Main.dust[
num44].velocity *= 0.1f;
44738 Main.dust[
num44].fadeIn = 0.9f;
44739 }
44740 }
44741 if (Main.rand.Next(64) == 0)
44742 {
44744 {
44747 Main.dust[
num46].velocity *= 0.3f;
44749 if (Main.rand.Next(2) == 0)
44750 {
44751 Main.dust[
num46].fadeIn = 1.4f;
44752 }
44753 }
44754 }
44755 if (Main.rand.Next(4) == 0)
44756 {
44758 {
44761 Main.dust[
num48].velocity *= 0.3f;
44762 Main.dust[
num48].noGravity =
true;
44764 if (Main.rand.Next(2) == 0)
44765 {
44766 Main.dust[
num48].fadeIn = 1.4f;
44767 }
44768 }
44769 }
44770 if (Main.rand.Next(12) == 0 &&
type == 634)
44771 {
44774 Main.dust[
num49].velocity *= 0.3f;
44776 Main.dust[
num49].fadeIn = 0.9f;
44777 Main.dust[
num49].noGravity =
true;
44778 }
44779 if (Main.rand.Next(3) == 0 &&
type == 635)
44780 {
44783 Main.dust[
num50].velocity *= 0.3f;
44785 Main.dust[
num50].fadeIn = 1.2f;
44786 Main.dust[
num50].scale = 1.5f;
44787 Main.dust[
num50].noGravity =
true;
44788 }
44789 }
44791 {
44794 {
44796 }
44800 {
44804 {
44806 }
44807 }
44812 Lighting.AddLight((
int)base.Center.X / 16, (int)
base.Center.Y / 16, 0.4f, 0.85f, 0.9f);
44814 if ((
double)
scale < 0.85)
44815 {
44816 num51 = ((Main.rand.Next(3) == 0) ? 1 : 0);
44817 }
44818 else
44819 {
44823 }
44825 {
44827 Main.dust[
num53].position -= Vector2.One * 3f;
44828 Main.dust[
num53].scale = 0.5f;
44829 Main.dust[
num53].noGravity =
true;
44831 Main.dust[
num53].alpha = 255 - (int)(255f *
scale);
44832 }
44833 }
44835 {
44838 {
44840 }
44844 {
44848 {
44850 }
44851 }
44852 Lighting.AddLight((
int)base.Center.X / 16, (int)
base.Center.Y / 16, 0.4f, 0.85f, 0.9f);
44854 {
44856 }
44859 {
44861 return;
44862 }
44863 }
44865 {
44868 {
44871 {
44874 {
44877 }
44878 }
44879 }
44881 {
44883 return;
44884 }
44886 {
44889 {
44891 return;
44892 }
44893 Lighting.AddLight((
int)
base.Center.X / 16, (
int)
base.Center.Y / 16, 0.3f, 0.45f, 0.8f);
44896 {
44899 {
44903 int num55 = Dust.NewDust(
base.Center, 0, 0, 135);
44904 Main.dust[
num55].scale = 1.5f;
44905 Main.dust[
num55].noGravity =
true;
44908 }
44909 }
44910 }
44911 }
44913 {
44915 {
44917 }
44919 {
44921 }
44923 {
44924 Lighting.AddLight((
int)
base.Center.X / 16, (
int)
base.Center.Y / 16, 0.25f, 0.4f, 0.7f);
44925 }
44927 {
44928 Lighting.AddLight((
int)
base.Center.X / 16, (
int)
base.Center.Y / 16, 0.7f, 0.65f, 0.3f);
44929 }
44931 {
44932 Lighting.AddLight(
base.Center, 0.7f, 0.3f, 0.3f);
44933 }
44934 float num56 = 100f;
44937 {
44940 }
44942 {
44945 {
44947 {
44949 Main.dust[
num59].velocity *= 0.2f;
44951 Main.dust[
num59].noGravity =
true;
44952 }
44953 }
44955 {
44957 }
44958 }
44959 else
44960 {
44963 {
44965 return;
44966 }
44967 }
44968 }
44970 {
44971 Lighting.AddLight((
int)
base.Center.X / 16, (
int)
base.Center.Y / 16, 0.4f, 0.1f, 0.2f);
44972 }
44974 {
44975 Lighting.AddLight((
int)
base.Center.X / 16, (
int)
base.Center.Y / 16, 0.4f, 0.1f, 0.3f);
44977 {
44979 {
44981 }
44983 }
44984 if (Main.rand.Next(2) == 0)
44985 {
44987 Dust
obj3 = Main.dust[Dust.NewDust(
base.Center -
vector17 * 8f, 0, 0, 240)];
44988 obj3.noGravity = true;
44990 obj3.velocity =
vector17.RotatedBy(-1.5707963705062866) * 2f;
44992 obj3.scale = 0.5f + Main.rand.NextFloat();
44993 obj3.fadeIn = 0.5f;
44994 }
44995 }
44997 {
44998 Lighting.AddLight((
int)
base.Center.X / 16, (
int)
base.Center.Y / 16, 0.15f, 0.15f, 0.4f);
44999 }
45001 {
45002 int num60 = Dust.NewDust(
base.Center, 0, 0, 229, 0f, 0f, 100);
45003 Main.dust[
num60].noLight =
true;
45004 Main.dust[
num60].noGravity =
true;
45006 Main.dust[
num60].position -= Vector2.One * 4f;
45007 Main.dust[
num60].scale = 0.8f;
45009 {
45012 {
45014 }
45015 }
45016 }
45018 {
45020 {
45023 }
45025 {
45028 {
45031 Main.dust[
num62].scale = 0.5f;
45032 Main.dust[
num62].noGravity =
true;
45033 Main.dust[
num62].velocity /= 2f;
45035 }
45036 }
45038 {
45040 {
45043 Main.dust[
num64].scale = 0.3f;
45044 Main.dust[
num64].noGravity =
true;
45046 }
45047 }
45048 }
45050 {
45052 {
45055 }
45058 {
45060 }
45064 {
45068 {
45070 }
45071 }
45072 Lighting.AddLight((
int)
base.Center.X / 16, (
int)
base.Center.Y / 16, 0.3f, 0.8f, 1.1f);
45073 }
45075 {
45077 {
45081 {
45083 dust.velocity *= 1f;
45084 dust.velocity +=
velocity * 0.65f;
45085 dust.scale = 0.6f;
45086 dust.fadeIn = 0.8f;
45087 dust.noGravity = true;
45088 dust.noLight = true;
45089 dust.position += dust.velocity * 3f;
45090 }
45091 }
45094 {
45096 }
45100 {
45104 {
45106 }
45107 }
45108 Lighting.AddLight((
int)
base.Center.X / 16, (
int)
base.Center.Y / 16, 0.5f, 0.2f, 1.1f);
45109 }
45111 {
45114 {
45116 }
45120 {
45123 Dust
dust2 = Dust.NewDustDirect(
base.Center, 0, 0, 60);
45124 dust2.alpha = 127;
45125 dust2.fadeIn = 1.5f;
45126 dust2.scale = 1.3f;
45127 dust2.velocity *= 0.3f;
45129 dust2.noGravity = true;
45130 dust2.noLight = true;
45131 dust2.color =
new Color(255, 255, 255, 0);
45132 }
45133 Lighting.AddLight(
base.Center, 1.1f, 0.3f, 0.4f);
45134 }
45136 {
45139 {
45141 }
45143 }
45145 {
45147 Main.dust[
num67].scale = (float)Main.rand.Next(1, 10) * 0.1f;
45148 Main.dust[
num67].noGravity =
true;
45149 Main.dust[
num67].fadeIn = 1.5f;
45150 Main.dust[
num67].velocity *= 0.25f;
45152 }
45154 {
45157 {
45161 {
45163 }
45164 }
45165 }
45166 if (
type == 225 && Main.rand.Next(2) == 0)
45167 {
45169 Main.dust[
num68].noGravity =
true;
45170 Main.dust[
num68].scale = 1.3f;
45171 Main.dust[
num68].velocity *= 0.5f;
45172 }
45174 {
45176 {
45178 Main.dust[
num69].noGravity =
true;
45179 Main.dust[
num69].noLight =
true;
45180 Main.dust[
num69].velocity *= 0.5f;
45181 }
45184 {
45186 }
45188 {
45191 }
45192 }
45194 {
45196 {
45198 frame = Main.rand.Next(3);
45199 }
45200 if (
type != 920 &&
type != 921 &&
alpha == 0 && Main.rand.Next(3) == 0)
45201 {
45204 float num71 = 1.2f;
45205 bool noGravity = true;
45208 {
45211 }
45213 {
45216 newColor.A = 150;
45219 noGravity = Main.rand.Next(2) == 0;
45220 }
45222 {
45225 newColor.A = 150;
45226 }
45228 Main.dust[
num73].velocity *= 0.3f;
45230 Main.dust[
num73].noGravity = noGravity;
45231 }
45234 {
45236 }
45237 if (
type != 937 &&
ai[1] == 0f)
45238 {
45241 {
45243 }
45244 else
45245 {
45247 }
45248 }
45249 }
45250 else if (
type == 176)
45251 {
45253 {
45255 Main.dust[
num74].noGravity =
true;
45256 Main.dust[
num74].noLight =
true;
45257 Main.dust[
num74].velocity *= 0.15f;
45258 Main.dust[
num74].fadeIn = 0.8f;
45259 }
45262 {
45264 }
45266 {
45269 }
45270 }
45272 {
45275 {
45277 }
45278 Lighting.AddLight((
int)
base.Center.X / 16, (
int)
base.Center.Y / 16, 0.9f, 0.6f, 0.2f);
45280 {
45282 if (Main.rand.Next(3) != 0)
45283 {
45285 Main.dust[
num76].scale *= 1.3f + (float)Main.rand.Next(10) * 0.05f;
45286 Main.dust[
num76].velocity *= 0.2f;
45287 Main.dust[
num76].noGravity =
true;
45288 Main.dust[
num76].noLight =
true;
45290 }
45291 if (Main.rand.Next(4) == 0)
45292 {
45294 Main.dust[
num77].fadeIn = 0.6f + (float)Main.rand.Next(5) * 0.1f;
45295 Main.dust[
num77].velocity *= 0.05f;
45297 }
45298 }
45300 {
45303 }
45304 }
45306 {
45309 {
45311 }
45312 Lighting.AddLight((
int)base.Center.X / 16, (int)
base.Center.Y / 16, 0.9f, 0.6f, 0.2f);
45314 {
45316 if (Main.rand.Next(3) != 0)
45317 {
45319 Main.dust[
num79].scale *= 1.2f + (float)Main.rand.Next(10) * 0.05f;
45320 Main.dust[
num79].velocity *= 0.2f;
45321 Main.dust[
num79].noGravity =
true;
45322 Main.dust[
num79].noLight =
true;
45324 }
45325 if (Main.rand.Next(4) == 0)
45326 {
45328 Main.dust[
num80].fadeIn = 0.5f + (float)Main.rand.Next(5) * 0.05f;
45329 Main.dust[
num80].velocity *= 0.05f;
45330 }
45331 }
45333 {
45336 }
45337 }
45339 {
45342 {
45345 {
45347 }
45348 }
45349 }
45350 else if (
type == 83 &&
ai[1] == 0f)
45351 {
45354 }
45355 else if (
type == 408 &&
ai[1] == 0f)
45356 {
45359 }
45360 else if (
type == 259 &&
ai[1] == 0f)
45361 {
45364 }
45365 else if (
type == 110 &&
ai[1] == 0f)
45366 {
45369 }
45370 else if (
type == 302 &&
ai[1] == 0f)
45371 {
45374 }
45375 else if (
type == 438 &&
ai[1] == 0f)
45376 {
45379 }
45380 else if (
type == 593 &&
ai[1] == 0f)
45381 {
45384 }
45385 else if (
type == 592 &&
ai[1] == 0f)
45386 {
45389 }
45390 else if (
type == 462 &&
ai[1] == 0f)
45391 {
45393 if (Main.rand.Next(2) == 0)
45394 {
45396 }
45397 else
45398 {
45400 }
45402 int num81 = Main.rand.Next(5, 10);
45404 {
45405 int num83 = Dust.NewDust(
base.Center, 0, 0, 229, 0f, 0f, 100);
45406 Main.dust[
num83].velocity.Y -= 1f;
45408 Main.dust[
num83].position -= Vector2.One * 4f;
45409 Main.dust[
num83].noGravity =
true;
45410 }
45411 }
45412 else if (
type == 84 &&
ai[1] == 0f)
45413 {
45416 }
45417 else if (
type == 389 &&
ai[1] == 0f)
45418 {
45421 }
45422 else if (
type == 257 &&
ai[1] == 0f)
45423 {
45426 }
45427 else if (
type == 100 &&
ai[1] == 0f)
45428 {
45431 }
45432 else if (
type == 98 &&
ai[1] == 0f)
45433 {
45436 }
45437 else if (
type == 184 &&
ai[1] == 0f)
45438 {
45441 }
45442 else if (
type == 980 &&
ai[1] == 0f)
45443 {
45446 }
45447 else if (
type == 195 &&
ai[1] == 0f)
45448 {
45451 }
45452 else if (
type == 275 &&
ai[1] == 0f)
45453 {
45456 }
45457 else if (
type == 276 &&
ai[1] == 0f)
45458 {
45461 }
45462 else if ((
type == 81 ||
type == 82) &&
ai[1] == 0f)
45463 {
45466 }
45467 else if (
type == 180 &&
ai[1] == 0f)
45468 {
45471 }
45472 else if (
type == 248 &&
ai[1] == 0f)
45473 {
45476 }
45477 else if (
type == 576 &&
ai[1] == 0f)
45478 {
45481 }
45483 {
45487 {
45490 float num86 = ((
num84 == 0) ? (12f + 8f * Main.rand.NextFloat()) : (12f * Main.rand.NextFloat()));
45493 obj4.noGravity = true;
45496 }
45497 }
45498 else if (
type == 710)
45499 {
45502 {
45504 }
45505 if (Main.rand.Next(4) == 0)
45506 {
45508 if (Main.rand.Next(2) == 0)
45509 {
45511 Main.dust[
num87].noGravity =
true;
45512 }
45514 Main.dust[
num87].noGravity =
true;
45515 Main.dust[
num87].velocity *= 2f;
45518 {
45519 Main.dust[
num87].fadeIn = 1.5f;
45520 }
45521 else
45522 {
45523 Main.dust[
num87].fadeIn = 1.22f;
45524 }
45526 {
45528 }
45529 }
45530 }
45531 else if (
type == 639)
45532 {
45534 {
45539 }
45542 {
45544 }
45545 }
45546 else if (
type == 640)
45547 {
45550 {
45552 }
45554 {
45556 bool flag = true;
45558 {
45560 {
45561 flag = false;
45562 }
45563 }
45564 if (flag)
45565 {
45567 return;
45568 }
45570 {
45572 {
45573 float num90 =
rotation + ((Main.rand.Next(2) == 1) ? (-1f) : 1f) * ((float)
Math.
PI / 2f);
45574 float num91 = (float)Main.rand.NextDouble() * 0.8f + 1f;
45577 Main.dust[
num92].noGravity =
true;
45578 Main.dust[
num92].scale = 1.2f;
45579 }
45580 if (Main.rand.Next(10) == 0)
45581 {
45584 Main.dust[
num93].velocity *= 0.5f;
45586 }
45587 }
45588 }
45590 {
45591 float num94 =
rotation + (float)
Math.
PI / 2f + ((Main.rand.Next(2) == 1) ? (-1f) : 1f) * ((
float)Math.PI / 2f);
45592 float num95 = (float)Main.rand.NextDouble() * 0.25f + 0.25f;
45595 Main.dust[
num96].noGravity =
true;
45596 Main.dust[
num96].scale = 1.2f;
45597 }
45598 }
45600 {
45602 Main.dust[
num97].noGravity =
true;
45604 Main.dust[
num97].noGravity =
true;
45605 }
45606 else if (
type == 55)
45607 {
45609 Main.dust[
num98].noGravity =
true;
45610 }
45611 else if (
type == 719)
45612 {
45613 if (Main.rand.Next(2) == 0)
45614 {
45616 }
45618 {
45621 {
45623 dust3.noGravity = true;
45624 dust3.velocity +=
velocity * 0.75f;
45625 }
45627 {
45629 dust4.noGravity = true;
45630 dust4.velocity *= 2f;
45631 }
45632 }
45633 }
45634 else if (
type == 763)
45635 {
45637 {
45640 {
45642 dust5.noGravity = true;
45643 dust5.velocity *= 1.5f;
45644 }
45645 }
45646 }
45647 else if (
type == 772)
45648 {
45649 if (Main.rand.Next(7) == 0)
45650 {
45652 {
45653 Dust
dust6 = Dust.NewDustDirect(
position -
velocity,
width,
height, Main.rand.NextFromList<
int>(86, 87, 88, 89, 90, 91, 138), 0f, 0f, 0,
default(
Color), 0.7f);
45654 dust6.noGravity = true;
45656 dust6.fadeIn = 0.8f;
45657 }
45658 }
45659 }
45660 else if (
type == 374)
45661 {
45663 {
45666 }
45667 if (Main.rand.Next(2) == 0)
45668 {
45670 Main.dust[
num103].noGravity =
true;
45671 Main.dust[
num103].velocity *= 0.5f;
45672 }
45673 }
45674 else if (
type == 376)
45675 {
45677 {
45679 }
45682 {
45685 {
45687 }
45689 {
45691 Main.dust[
num106].noGravity =
true;
45692 Main.dust[
num106].velocity.X *= 0.3f;
45693 Main.dust[
num106].velocity.Y *= 0.3f;
45694 Main.dust[
num106].noLight =
true;
45695 }
45697 {
45699 return;
45700 }
45701 }
45702 }
45703 else if (
type == 91 && Main.rand.Next(2) == 0)
45704 {
45706 Main.dust[
num108].velocity *= 0.25f;
45707 }
45709 {
45711 {
45713 }
45715 {
45717 }
45718 }
45720 {
45721 case 14:
45722 case 20:
45723 case 36:
45724 case 83:
45725 case 84:
45726 case 89:
45727 case 100:
45728 case 104:
45729 case 110:
45730 case 158:
45731 case 159:
45732 case 160:
45733 case 161:
45734 case 180:
45735 case 279:
45736 case 283:
45737 case 284:
45738 case 285:
45739 case 286:
45740 case 287:
45741 case 389:
45743 {
45745 }
45747 {
45749 }
45750 break;
45751 case 576:
45752 case 577:
45755 {
45757 {
45759 }
45761 {
45763 }
45764 }
45765 break;
45766 }
45768 {
45770 Main.dust[
num109].noGravity =
true;
45771 Main.dust[
num109].velocity *= 0.1f;
45772 Main.dust[
num109].scale = 0.75f;
45773 Main.dust[
num109].position = (Main.dust[
num109].position +
base.Center) / 2f;
45774 Main.dust[
num109].position +=
velocity * Main.rand.Next(0, 101) * 0.01f;
45775 }
45777 {
45780 {
45782 }
45784 {
45786 }
45787 }
45789 {
45790 DelegateMethods.v3_1 =
new Vector3(0.6f, 1f, 1f) * 0.2f;
45791 Utils.PlotTileLine(
base.Center,
base.Center +
velocity * 10f, 8f, DelegateMethods.CastLightOpen);
45793 {
45797 frame = Main.rand.Next(14);
45800 {
45804 int num113 = Dust.NewDust(
base.Center, 0, 0, 180);
45805 Main.dust[
num113].scale = 1.5f;
45806 Main.dust[
num113].noGravity =
true;
45809 }
45810 }
45811 }
45813 {
45814 DelegateMethods.v3_1 =
new Vector3(0.4f, 0.4f, 0.4f) * 0.7f;
45815 Utils.PlotTileLine(
base.Center,
base.Center +
velocity * 10f, 8f, DelegateMethods.CastLightOpen);
45817 {
45818 frame = Main.rand.Next(2) * 4;
45819 }
45821 {
45825 {
45827 }
45829 {
45831 }
45832 }
45834 {
45837 frame = Main.rand.Next(14);
45840 {
45844 int num116 = Dust.NewDust(
base.Center, 0, 0, 15);
45845 Main.dust[
num116].scale = 1.7f;
45846 Main.dust[
num116].noGravity =
true;
45849 Main.dust[
num116].velocity *= 0.7f;
45850 Main.dust[
num116].position += Main.dust[
num116].velocity * 5f;
45851 }
45852 }
45853 }
45855 {
45857 {
45859 {
45861 Main.dust[
num118].noGravity =
true;
45862 Main.dust[
num118].velocity *= 0.3f;
45863 Main.dust[
num118].noLight =
true;
45864 }
45865 }
45867 {
45871 {
45875 {
45879 int num121 = Dust.NewDust(
base.Center, 0, 0, 62);
45880 Main.dust[
num121].scale = 1.5f;
45881 Main.dust[
num121].noLight =
true;
45882 Main.dust[
num121].noGravity =
true;
45885 }
45886 }
45887 }
45888 }
45890 {
45892 {
45894 return;
45895 }
45898 {
45904 {
45905 if (Main.rand.Next(4) != 0)
45906 {
45907 Dust
dust7 = Dust.NewDustDirect(
base.Center -
base.Size / 4f,
width / 2,
height / 2, Utils.SelectRandom<
int>(Main.rand, 6, 31, 31));
45908 dust7.noGravity = true;
45909 dust7.velocity *= 2.3f;
45910 dust7.fadeIn = 1.5f;
45911 dust7.noLight = true;
45912 }
45913 }
45914 }
45917 {
45918 activeSound.Position =
base.Center;
45919 }
45920 else
45921 {
45925 }
45927 {
45929 {
45930 if (Main.rand.Next(4) != 0)
45931 {
45932 Dust
dust8 = Dust.NewDustDirect(
base.Center -
base.Size / 4f,
width / 2,
height / 2, Utils.SelectRandom<
int>(Main.rand, 6, 31, 31));
45933 dust8.noGravity = true;
45934 dust8.velocity *= 2.3f;
45935 dust8.fadeIn = 1.5f;
45936 dust8.noLight = true;
45937 }
45938 }
45943 {
45945 dust9.noGravity = true;
45947 dust9.velocity *= 0f;
45948 dust9.fadeIn = 1.4f;
45949 dust9.scale = 1.15f;
45950 dust9.noLight = true;
45951 dust9.position +=
velocity * 1.2f;
45954 dust10.noGravity = true;
45956 dust10.velocity *= 0f;
45957 dust10.fadeIn = 1.4f;
45958 dust10.scale = 1.15f;
45959 dust10.noLight = true;
45960 dust10.position +=
velocity * 0.5f;
45961 dust10.position +=
velocity * 1.2f;
45963 }
45964 }
45966 {
45968 }
45971 {
45974 {
45978 {
45982 int num127 = Dust.NewDust(
base.Center, 0, 0, 6);
45983 Main.dust[
num127].scale = 1.5f;
45984 Main.dust[
num127].noLight =
true;
45985 Main.dust[
num127].noGravity =
true;
45988 }
45989 }
45990 }
45991 DelegateMethods.v3_1 =
new Vector3(1f, 0.6f, 0.2f);
45992 Utils.PlotTileLine(
base.Center,
base.Center +
velocity * 4f, 40f, DelegateMethods.CastLightOpen);
45993 }
45995 {
45998 {
46000 }
46002 {
46004 }
46007 bool flag2 =
false;
46009 {
46012 {
46014 break;
46015 }
46016 }
46018 {
46019 int num130 = Main.rand.Next(15, 31);
46021 {
46022 int num132 = Dust.NewDust(
base.Center, 0, 0, 229, 0f, 0f, 100,
default(
Color), 0.8f);
46023 Main.dust[
num132].velocity *= 1.6f;
46024 Main.dust[
num132].velocity.Y -= 1f;
46026 Main.dust[
num132].noGravity =
true;
46027 }
46028 }
46029 }
46031 {
46033 {
46035 }
46037 {
46039 }
46040 }
46042 {
46044 {
46046 }
46047 else
46048 {
46050 }
46052 {
46054 }
46056 {
46058 }
46059 }
46061 {
46063 {
46065 }
46067 {
46069 }
46070 }
46072 {
46074 }
46076 bool flag4 =
false;
46078 {
46079 case 5:
46080 case 14:
46081 case 20:
46082 case 36:
46083 case 38:
46084 case 55:
46085 case 83:
46086 case 84:
46087 case 88:
46088 case 89:
46089 case 98:
46090 case 100:
46091 case 104:
46092 case 110:
46093 case 158:
46094 case 159:
46095 case 160:
46096 case 161:
46097 case 180:
46098 case 184:
46099 case 242:
46100 case 248:
46101 case 257:
46102 case 259:
46103 case 265:
46104 case 270:
46105 case 279:
46106 case 283:
46107 case 284:
46108 case 285:
46109 case 286:
46110 case 287:
46111 case 299:
46112 case 302:
46113 case 323:
46114 case 325:
46115 case 348:
46116 case 349:
46117 case 350:
46118 case 355:
46119 case 374:
46120 case 376:
46121 case 389:
46122 case 435:
46123 case 436:
46124 case 438:
46125 case 440:
46126 case 442:
46127 case 449:
46128 case 459:
46129 case 462:
46130 case 467:
46131 case 468:
46132 case 469:
46133 case 472:
46134 case 483:
46135 case 484:
46136 case 485:
46137 case 498:
46138 case 576:
46139 case 577:
46140 case 585:
46141 case 592:
46142 case 593:
46143 case 601:
46144 case 606:
46145 case 616:
46146 case 634:
46147 case 635:
46148 case 638:
46149 case 639:
46150 case 660:
46151 case 661:
46152 case 682:
46153 case 684:
46154 case 706:
46155 case 709:
46156 case 710:
46157 case 712:
46158 case 876:
46159 case 980:
46160 case 981:
46162 break;
46163 case 1006:
46165 break;
46166 }
46168 {
46170 }
46171 if (
type == 1006 && Main.rand.Next(8) == 0)
46172 {
46173 Dust
dust11 = Dust.NewDustPerfect(
base.Center + Main.rand.NextVector2Circular(4f, 4f), 306,
velocity * 1.25f, 0, Main.hslToRgb(Main.rand.NextFloat(), 1f, 0.5f), 1f + Main.rand.NextFloat() * 0.4f);
46174 dust11.noGravity = true;
46175 dust11.fadeIn = dust11.scale + 0.05f;
46178 dust12.scale -= 0.3f;
46179 }
46181 {
46185 if (
ai[1] < 110f &&
ai[1] > 30f)
46186 {
46194 }
46196 {
46198 }
46200 {
46204 {
46206 Main.dust[
num136].noGravity =
true;
46207 Main.dust[
num136].velocity = base.Center - Main.dust[
num136].position;
46208 Main.dust[
num136].velocity.Normalize();
46209 Main.dust[
num136].velocity *= -5f;
46211 }
46212 }
46213 }
46215 {
46217 {
46221 {
46223 Main.dust[
num138].noGravity =
true;
46224 Main.dust[
num138].velocity = base.Center - Main.dust[
num138].position;
46225 Main.dust[
num138].velocity.Normalize();
46226 Main.dust[
num138].velocity *= -5f;
46228 Main.dust[
num138].noLight =
true;
46229 }
46230 }
46232 {
46234 }
46236 {
46238 }
46241 {
46243 }
46246 {
46248 }
46251 if (Main.rand.Next(3) == 0)
46252 {
46255 Main.dust[
num139].noLight =
true;
46256 Main.dust[
num139].noGravity =
true;
46257 Main.dust[
num139].velocity.
X *= 0.3f;
46258 Main.dust[
num139].velocity.Y *= 0.3f;
46259 }
46260 }
46262 {
46263 int num140 = (int)(43f -
ai[1]) / 13;
46265 {
46267 }
46268 int num141 = ((
ai[1] < 20f) ? 6 : 31);
46270 {
46273 Main.dust[
num143].noLight =
true;
46274 Main.dust[
num143].noGravity =
true;
46275 Main.dust[
num143].velocity.
X *= 0.3f;
46276 Main.dust[
num143].velocity.Y *= 0.3f;
46278 {
46279 Main.dust[
num143].fadeIn = Main.rand.NextFloat() * 2f;
46280 }
46281 }
46284 {
46286 return;
46287 }
46288 }
46290 {
46292 if (Main.rand.Next(3) != 0)
46293 {
46296 Main.dust[
num145].noLight =
true;
46297 Main.dust[
num145].noGravity =
true;
46298 Main.dust[
num145].velocity.
X *= 0.3f;
46299 Main.dust[
num145].velocity.Y *= 0.3f;
46300 }
46303 {
46305 return;
46306 }
46307 }
46309 {
46311 newColor2.A = 200;
46314 {
46316 {
46319 {
46321 Main.dust[
num147].noGravity =
true;
46322 Main.dust[
num147].velocity = base.Center - Main.dust[
num147].position;
46323 Main.dust[
num147].velocity.Normalize();
46324 Main.dust[
num147].velocity *= -3f;
46326 }
46327 }
46328 else
46329 {
46332 {
46334 }
46336 {
46339 Main.dust[
num149].noGravity =
true;
46341 }
46342 }
46343 }
46344 }
46346 {
46348 velocity.Y += 0.2f;
46350 {
46354 {
46357 }
46358 }
46360 {
46364 {
46367 }
46368 }
46369 }
46371 {
46373 {
46376 }
46377 if (
ai[0] == 0f ||
ai[0] == 2f)
46378 {
46382 {
46385 }
46386 }
46387 else if (
ai[0] == 1f)
46388 {
46392 {
46395 }
46396 }
46397 }
46399 {
46401 {
46404 }
46406 {
46408 Main.dust[
num151].velocity *= 0.5f;
46410 Main.dust[
num151].velocity *= 0.5f;
46411 Main.dust[
num151].noGravity =
true;
46412 Main.dust[
num151].scale = 1.2f;
46414 }
46415 }
46417 {
46418 Lighting.AddLight(
base.Center, 0.1f, 0.3f, 0.4f);
46419 }
46420 else if (
type == 576)
46421 {
46422 Lighting.AddLight(
base.Center, 0.4f, 0.2f, 0.4f);
46424 {
46428 obj5.noGravity = true;
46429 obj5.scale = 0.8f;
46430 obj5.noLight = true;
46431 }
46432 }
46433 else if (
type == 581)
46434 {
46436 {
46439 }
46441 {
46442 int num154 = Utils.SelectRandom<
int>(Main.rand, 229, 161, 161);
46444 obj6.velocity = obj6.velocity / 4f +
velocity / 2f;
46445 obj6.noGravity = true;
46446 obj6.scale = 1.2f;
46447 obj6.position =
base.Center;
46448 obj6.noLight = true;
46449 }
46450 }
46451 else if (
type == 671)
46452 {
46454 {
46457 {
46458 int num156 = Utils.SelectRandom<
int>(Main.rand, 27, 62);
46460 obj7.velocity = (Main.rand.NextFloatDirection() * (float)
Math.
PI).ToRotationVector2() * 2f +
velocity.SafeNormalize(
Vector2.
Zero) * 3f;
46461 obj7.noGravity = true;
46462 obj7.scale = 1.5f;
46463 obj7.fadeIn = 1.2f;
46464 obj7.position =
base.Center;
46465 obj7.noLight = true;
46466 }
46467 }
46470 {
46472 }
46474 {
46475 int num158 = Utils.SelectRandom<
int>(Main.rand, 27, 27, 62);
46477 obj8.velocity = obj8.velocity / 4f +
velocity / 2f;
46478 obj8.noGravity = true;
46479 obj8.scale = 1.2f;
46480 obj8.position =
base.Center;
46481 obj8.noLight = true;
46482 }
46483 }
46484 else if (
type == 811)
46485 {
46487 {
46491 {
46493 obj9.velocity = (Main.rand.NextFloatDirection() * (float)
Math.
PI).ToRotationVector2() * 2f +
velocity.SafeNormalize(
Vector2.
Zero) * 3f;
46494 obj9.scale = 1.5f;
46495 obj9.fadeIn = 1.7f;
46496 obj9.position =
base.Center;
46497 }
46498 }
46501 {
46503 }
46505 {
46507 obj10.velocity = obj10.velocity / 4f +
velocity / 2f;
46508 obj10.scale = 1.2f;
46509 obj10.position = base.Center + Main.rand.NextFloat() *
velocity * 2f;
46510 }
46511 }
46512 else if (
type == 819)
46513 {
46515 {
46518 {
46520 obj11.velocity = (Main.rand.NextFloatDirection() * (float)
Math.
PI).ToRotationVector2() * 2f +
velocity.SafeNormalize(
Vector2.
Zero) * 2f;
46521 obj11.scale = 0.9f;
46522 obj11.fadeIn = 1.3f;
46523 obj11.position =
base.Center;
46524 }
46525 }
46528 {
46530 }
46532 {
46534 obj12.velocity = obj12.velocity * 0.5f +
velocity * 0.5f;
46535 obj12.velocity *= 0.25f;
46536 obj12.scale = 0.9f;
46538 }
46539 if (Main.rand.Next(2) == 0)
46540 {
46542 dust13.noGravity = true;
46543 dust13.scale = 0.7f;
46544 }
46545 Lighting.AddLight(
base.Center, 0.3f, 0.05f, 0.05f);
46546 }
46547 else if (
type == 814)
46548 {
46550 {
46554 {
46556 obj13.velocity = (Main.rand.NextFloatDirection() * (float)
Math.
PI).ToRotationVector2() * 2f +
velocity.SafeNormalize(
Vector2.
Zero) * 2f;
46557 obj13.scale = 0.9f;
46558 obj13.fadeIn = 1.1f;
46559 obj13.position =
base.Center;
46560 }
46561 }
46564 {
46566 }
46568 {
46570 obj14.velocity = obj14.velocity / 4f +
velocity / 2f;
46571 obj14.scale = 1.2f;
46572 obj14.position = base.Center + Main.rand.NextFloat() *
velocity * 2f;
46573 }
46575 {
46576 if (Main.rand.Next(3) == 0)
46577 {
46579 obj15.velocity = obj15.velocity / 4f +
velocity / 2f;
46580 obj15.scale = 1.2f;
46582 }
46583 }
46584 }
46585 else if (
type == 675)
46586 {
46588 {
46591 }
46594 {
46596 }
46597 }
46598 else if (
type == 676)
46599 {
46601 {
46604 }
46607 {
46609 }
46611 {
46612 if (Main.rand.Next(5) != 0)
46613 {
46614 int num167 = Utils.SelectRandom<
int>(Main.rand, 4, 256);
46616 dust14.velocity = dust14.velocity / 4f +
velocity / 2f;
46617 dust14.scale = 0.8f + Main.rand.NextFloat() * 0.4f;
46618 dust14.position =
base.Center;
46619 dust14.position +=
new Vector2(
width * 2, 0f).RotatedBy((
float)
Math.
PI * 2f * Main.rand.NextFloat()) * Main.rand.NextFloat();
46620 dust14.noLight = true;
46622 {
46623 dust14.color =
new Color(80, 170, 40, 120);
46624 }
46625 }
46626 }
46627 }
46628 else if (
type == 686)
46629 {
46631 {
46634 }
46636 {
46639 {
46641 }
46642 }
46643 if (Main.rand.Next(4) == 0)
46644 {
46646 dust15.scale *= 0.7f;
46648 }
46650 {
46652 dust16.scale *= 0.85f;
46653 dust16.velocity +=
velocity * 0.85f;
46655 }
46656 }
46657 else if (
type == 711)
46658 {
46660 {
46663 {
46665 dust17.scale *= 0.65f;
46666 dust17.velocity *= 1.5f;
46667 dust17.velocity +=
velocity * 0.3f;
46668 dust17.fadeIn = 0.7f;
46669 }
46670 }
46672 {
46675 {
46677 }
46678 }
46679 if (Main.rand.Next(4) == 0)
46680 {
46682 dust18.scale *= 0.7f;
46684 }
46686 {
46688 dust19.scale *= 0.85f;
46689 dust19.velocity +=
velocity * 0.85f;
46691 }
46692 }
46694 {
46696 {
46699 {
46701 Main.dust[
num170].velocity *= 3f;
46703 Main.dust[
num170].scale *= 1.2f;
46704 Main.dust[
num170].noGravity =
true;
46705 }
46706 }
46709 {
46711 {
46713 Main.dust[
num172].velocity *= 0.6f;
46714 Main.dust[
num172].scale *= 1.4f;
46715 Main.dust[
num172].noGravity =
true;
46716 }
46717 }
46718 }
46719 else if (
type == 270 ||
type == 837)
46720 {
46722 {
46724 }
46726 {
46728 }
46730 {
46732 }
46735 {
46737 }
46739 {
46741 {
46744 Main.dust[
num174].noGravity =
true;
46745 Main.dust[
num174].velocity.
X *= 0.3f;
46746 Main.dust[
num174].velocity.Y *= 0.3f;
46747 }
46748 }
46749 else
46750 {
46752 {
46755 Main.dust[
num176].noGravity =
true;
46756 Main.dust[
num176].velocity.
X *= 0.3f;
46757 Main.dust[
num176].velocity.Y *= 0.3f;
46758 }
46759 }
46760 }
46762 {
46764 {
46766 }
46768 {
46770 }
46771 }
46773 {
46775 {
46777 }
46779 {
46781 }
46783 {
46785 Main.dust[
num177].noGravity =
true;
46786 Main.dust[
num177].velocity *= 0.3f;
46788 }
46789 }
46791 {
46793 {
46795 }
46797 {
46799 }
46801 {
46803 Main.dust[
num178].noGravity =
true;
46804 Main.dust[
num178].velocity *= 0.3f;
46806 }
46807 }
46808 if (
type == 981 && Main.rand.Next(6) == 0)
46809 {
46811 Main.dust[
num179].noLightEmittence =
true;
46812 Main.dust[
num179].noGravity =
true;
46813 Main.dust[
num179].velocity *= 0.2f;
46814 }
46816 {
46818 {
46820 {
46821 float x = position.X - velocity.X / 10f * (float)
num180;
46822 float y = position.Y - velocity.Y / 10f * (float)
num180;
46825 Main.dust[
num181].position.X = x;
46826 Main.dust[
num181].position.Y = y;
46827 Main.dust[
num181].velocity *= 0f;
46828 Main.dust[
num181].noGravity =
true;
46829 }
46830 }
46832 {
46834 }
46836 {
46838 }
46839 }
46840 else if (
type == 207 ||
type == 837)
46841 {
46843 {
46845 {
46846 float x2 = position.X - velocity.X / 10f * (float)
num182;
46847 float y2 = position.Y - velocity.Y / 10f * (float)
num182;
46850 Main.dust[
num183].position.X =
x2;
46851 Main.dust[
num183].position.Y =
y2;
46852 Main.dust[
num183].velocity *= 0f;
46853 Main.dust[
num183].noGravity =
true;
46854 }
46855 }
46859 {
46862 }
46864 {
46866 }
46868 {
46870 }
46874 bool flag5 =
false;
46877 {
46879 {
46880 if (Main.npc[
num190].CanBeChasedBy(
this) && (
ai[1] == 0f ||
ai[1] == (float)(
num190 + 1)))
46881 {
46886 {
46892 }
46893 }
46894 }
46896 {
46898 }
46900 }
46902 {
46905 {
46909 {
46913 }
46914 }
46915 else
46916 {
46918 }
46919 }
46921 {
46923 }
46925 {
46936 {
46938 }
46941 }
46942 }
46943 else if (
type == 81 ||
type == 91)
46944 {
46946 {
46948 velocity.Y += 0.07f;
46949 }
46950 }
46952 {
46954 {
46956 velocity.Y += 0.15f;
46957 }
46958 }
46959 else if (
type == 937)
46960 {
46962 {
46964 velocity.Y += 0.07f;
46965 }
46966 }
46967 else if (
type == 962)
46968 {
46971 {
46975 {
46976 Dust
dust20 = Dust.NewDustPerfect(
base.Center + Main.rand.NextVector2Circular(24f, 24f), 16,
velocity *
MathHelper.
Lerp(0.2f, 0.7f, Main.rand.NextFloat()));
46977 dust20.velocity += Main.rand.NextVector2Circular(0.5f, 0.5f);
46978 dust20.scale = 0.8f + Main.rand.NextFloat() * 0.5f;
46979 }
46981 {
46982 Dust
dust21 = Dust.NewDustPerfect(
base.Center + Main.rand.NextVector2Circular(24f, 24f), 16, Main.rand.NextVector2Circular(2f, 2f) +
velocity *
MathHelper.
Lerp(0.2f, 0.5f, Main.rand.NextFloat()));
46983 dust21.velocity += Main.rand.NextVector2Circular(0.5f, 0.5f);
46984 dust21.scale = 0.8f + Main.rand.NextFloat() * 0.5f;
46985 dust21.fadeIn = 1f;
46986 }
46987 }
46989 {
46990 velocity.Y += 0.15f;
46991 }
46992 }
46993 else if (
type == 337)
46994 {
46996 {
46998 }
46999 if ((double)position.Y < Main.worldSurface * 16.0)
47000 {
47002 }
47004 if (Main.rand.Next(2) == 0)
47005 {
47007 Main.dust[
num204].velocity *= 0.5f;
47008 Main.dust[
num204].noGravity =
true;
47009 }
47010 }
47011 else if (
type == 645)
47012 {
47014 {
47016 }
47018 {
47020 return;
47021 }
47024 dust22.position =
base.Center;
47026 dust22.noGravity = true;
47028 {
47029 dust22.noLight = true;
47030 }
47032 {
47042 {
47044 }
47046 {
47049 }
47051 {
47053 }
47054 return;
47055 }
47058 {
47062 {
47064 if (
nPC2.CanBeChasedBy(
this))
47065 {
47068 {
47071 }
47072 }
47073 }
47075 {
47079 return;
47080 }
47081 }
47082 }
47083 else if (
type >= 424 &&
type <= 426)
47084 {
47086 {
47088 }
47089 if ((
double)
position.
Y < Main.worldSurface * 16.0)
47090 {
47092 }
47098 obj16.velocity =
velocity.RotatedBy(1.5707963705062866) * 0.33f +
velocity / 4f;
47099 obj16.position +=
velocity.RotatedBy(1.5707963705062866);
47100 obj16.fadeIn = 0.5f;
47101 obj16.noGravity = true;
47104 obj17.velocity =
velocity.RotatedBy(-1.5707963705062866) * 0.33f +
velocity / 4f;
47105 obj17.position +=
velocity.RotatedBy(-1.5707963705062866);
47106 obj17.fadeIn = 0.5f;
47107 obj17.noGravity = true;
47109 {
47111 Main.dust[
num211].velocity *= 0.5f;
47112 Main.dust[
num211].scale *= 1.3f;
47113 Main.dust[
num211].fadeIn = 1f;
47114 Main.dust[
num211].noGravity =
true;
47115 }
47116 }
47117 else if (
type == 344)
47118 {
47120 {
47122 return;
47123 }
47126 {
47129 {
47131 }
47132 }
47135 {
47136 velocity.Y += 0.15f;
47137 velocity.X *= 0.96f;
47138 }
47140 {
47146 {
47147 Projectile projectile = Main.projectile[
num214];
47148 if (projectile.whoAmI !=
whoAmI && projectile.active && projectile.type ==
type)
47149 {
47152 {
47156 }
47157 }
47158 }
47160 {
47162 vector29.Y = 0f;
47164 {
47165 vector29.X = 1f;
47166 }
47168 }
47169 }
47170 }
47171 else if (
type == 336 ||
type == 345)
47172 {
47174 {
47177 }
47179 {
47181 velocity.Y += 0.5f;
47182 }
47183 }
47184 else if (
type == 246)
47185 {
47188 {
47190 }
47192 {
47194 velocity.Y += 0.15f;
47195 }
47196 }
47197 else if (
type == 311)
47198 {
47200 {
47202 }
47204 {
47206 }
47208 {
47211 {
47213 }
47214 velocity.Y += 0.5f;
47215 }
47216 }
47217 else if (
type == 312)
47218 {
47220 {
47222 }
47224 {
47226 velocity.Y += 0.5f;
47227 }
47228 Lighting.AddLight(
base.Center, 0.6f, 0.4f, 0.3f);
47229 }
47230 else if (
type != 239 &&
type != 264)
47231 {
47233 {
47235 {
47237 velocity.Y += 0.05f;
47238 }
47239 }
47240 else if (
type == 275 ||
type == 276)
47241 {
47243 {
47245 }
47247 {
47249 }
47251 {
47253 velocity.Y += 0.025f;
47254 }
47255 if (Main.expertMode)
47256 {
47265 {
47268 }
47271 {
47273 }
47274 }
47275 }
47276 else if (
type == 172)
47277 {
47279 {
47281 velocity.Y += 0.085f;
47282 }
47283 }
47284 else if (
type == 117)
47285 {
47287 {
47289 velocity.Y += 0.06f;
47290 }
47291 }
47292 else if (
type == 120)
47293 {
47295 Main.dust[
num219].noGravity =
true;
47296 Main.dust[
num219].velocity *= 0.3f;
47298 {
47300 velocity.Y += 0.05f;
47301 }
47302 }
47303 else if (
type == 195)
47304 {
47307 {
47309 velocity.Y += 0.15f;
47311 }
47312 else
47313 {
47315 }
47316 }
47318 {
47321 {
47323 }
47325 {
47328 {
47329 velocity.Y += 0.075f;
47330 }
47331 }
47332 if (
type == 479 && Main.myPlayer ==
owner)
47333 {
47335 {
47337 }
47339 {
47341 }
47343 {
47345 }
47346 if (
ai[1] > (
float)Main.rand.Next(5, 30))
47347 {
47352 int num222 = Main.rand.Next(2, 4);
47353 if (Main.rand.Next(4) == 0)
47354 {
47356 }
47358 {
47364 NewProjectile(
GetProjectileSource_FromThis(),
base.Center.X,
base.Center.Y,
vector32.X,
vector32.Y,
type,
damage,
knockBack,
owner, 0f, -1000f);
47365 }
47366 }
47367 }
47368 if (
type == 478 && Main.myPlayer ==
owner)
47369 {
47371 if (
ai[1] > (
float)Main.rand.Next(5, 20))
47372 {
47374 {
47376 }
47379 }
47380 }
47381 }
47382 else if (
type == 408)
47383 {
47385 {
47387 velocity.Y += 0.05f;
47388 }
47389 }
47390 else if (
type == 616)
47391 {
47393 {
47396 {
47399 Main.dust[
num226].velocity *= 0f;
47400 Main.dust[
num226].noGravity =
true;
47401 Main.dust[
num226].alpha = 200;
47402 Main.dust[
num226].scale = 0.5f;
47403 }
47404 }
47408 {
47411 }
47413 {
47415 }
47417 {
47419 }
47423 bool flag6 =
false;
47427 {
47430 {
47432 {
47433 if (Main.npc[
num233].CanBeChasedBy(
this) && (
ai[1] == 0f ||
ai[1] == (float)(
num233 + 1)))
47434 {
47439 {
47445 }
47446 }
47447 }
47449 {
47451 }
47453 }
47455 {
47458 {
47462 {
47466 }
47467 }
47468 }
47470 {
47472 }
47474 {
47486 }
47487 }
47488 }
47490 {
47492 {
47493 velocity.X *= 0.98f;
47494 velocity.Y += 0.3f;
47495 }
47496 }
47497 else if (
type == 495)
47498 {
47500 Main.dust[
num245].noGravity =
true;
47501 Main.dust[
num245].velocity *= 0.3f;
47503 {
47505 velocity.Y += 0.04f;
47506 }
47507 }
47508 else if (
type == 498)
47509 {
47511 {
47514 }
47517 {
47518 velocity.X *= 0.98f;
47519 velocity.Y += 0.15f;
47521 }
47522 else
47523 {
47525 }
47526 }
47527 else if (
type == 437)
47528 {
47530 {
47532 {
47534 }
47536 }
47537 }
47539 {
47541 {
47543 {
47544 velocity.Y += 0.1f;
47545 }
47547 {
47548 velocity.Y += 0.1f;
47549 }
47551 {
47553 }
47554 velocity.X *= 0.99f;
47556 {
47557 velocity.Y = 32f;
47558 }
47559 }
47560 else if (
type == 639)
47561 {
47563 {
47564 velocity.Y += 0.1f;
47565 }
47566 }
47567 else if (
type == 710)
47568 {
47570 {
47573 {
47574 velocity.Y += 0.2f;
47576 {
47577 velocity.X *= 0.98f;
47578 }
47580 {
47581 velocity.Y = 12f;
47582 }
47583 }
47584 }
47585 }
47586 else if (
ai[0] >= 15f)
47587 {
47590 {
47591 velocity.Y -= 0.1f;
47592 }
47593 else
47594 {
47595 velocity.Y += 0.1f;
47596 }
47597 }
47598 }
47599 }
47601 {
47603 }
47604 else if (
type == 248)
47605 {
47607 {
47609 }
47610 else
47611 {
47613 }
47614 }
47616 {
47619 {
47621 }
47622 else
47623 {
47625 }
47626 }
47627 else if (
type == 311)
47628 {
47630 {
47631 rotation += velocity.X * 0.1f + (float)Main.rand.Next(-10, 11) * 0.025f;
47632 }
47633 else
47634 {
47636 }
47637 }
47638 else if (
type == 312)
47639 {
47641 }
47642 else if (
type == 675)
47643 {
47645 }
47646 else if (
type != 676)
47647 {
47649 {
47652 {
47654 }
47655 }
47657 {
47660 {
47662 }
47663 }
47664 else if (
type == 660)
47665 {
47667 }
47668 else if (
type == 662 ||
type == 685)
47669 {
47671 }
47673 {
47675 }
47676 else if (
type == 436)
47677 {
47681 {
47683 }
47684 }
47685 else if (
type == 469)
47686 {
47688 {
47691 }
47692 else
47693 {
47696 }
47697 }
47698 else if (
type == 477)
47699 {
47701 {
47704 }
47705 else
47706 {
47708 }
47709 }
47710 else if (
type == 532)
47711 {
47713 }
47714 else if (
type == 483)
47715 {
47717 }
47718 else if (
type == 772)
47719 {
47721 }
47722 else if (
type == 485)
47723 {
47727 Main.dust[
num246].noGravity =
true;
47728 Main.dust[
num246].velocity *= 0.2f;
47729 Main.dust[
num246].position = (Main.dust[
num246].position +
base.Center) / 2f;
47732 {
47736 {
47738 }
47739 }
47741 {
47744 }
47745 else
47746 {
47749 }
47750 }
47751 else if (
type == 640)
47752 {
47754 {
47756 }
47757 }
47758 else if (
type == 325)
47759 {
47761 }
47762 else if (
type != 344 &&
type != 498)
47763 {
47765 }
47766 }
47770 {
47772 }
47774 {
47776 {
47777 velocity.Y = -16f;
47778 }
47780 {
47781 velocity.Y = 16f;
47782 }
47783 }
47784 }
static float Lerp(float value1, float value2, float amount)
static double Cos(double d)
static double Atan2(double y, double x)
static double Sqrt(double d)
static double Abs(double value)
static double Sin(double a)
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)
float Distance(Vector2 Other)
static Color GetPortalColor(int colorIndex)
static Color[] MagicAuraColor
static readonly LegacySoundStyle Item33
static readonly LegacySoundStyle Item115
static readonly LegacySoundStyle Item36
static readonly LegacySoundStyle DD2_SkyDragonsFuryShot
static readonly LegacySoundStyle DD2_LightningBugZap
static readonly LegacySoundStyle DD2_DarkMageAttack
static readonly LegacySoundStyle Item34
static readonly LegacySoundStyle Item124
static readonly LegacySoundStyle Item17
static readonly LegacySoundStyle Item155
static readonly LegacySoundStyle Item5
static readonly LegacySoundStyle Item154
static readonly LegacySoundStyle Item12
static readonly LegacySoundStyle Item1
static readonly LegacySoundStyle Item9
static readonly LegacySoundStyle Item125
static readonly LegacySoundStyle Item42
static readonly LegacySoundStyle DD2_BetsyFireballShot
static readonly LegacySoundStyle Item8
static readonly LegacySoundStyle DD2_PhantomPhoenixShot
static readonly LegacySoundStyle Item11
static readonly LegacySoundStyle Item171
static readonly LegacySoundStyle Item20
static readonly LegacySoundStyle Item114
IEntitySource GetProjectileSource_FromThis()
static int NewProjectile(IEntitySource spawnSource, Vector2 position, Vector2 velocity, int Type, int Damage, float KnockBack, int Owner=-1, float ai0=0f, float ai1=0f, float ai2=0f)
static float Distance(Vector2 value1, Vector2 value2)
static Vector2 Lerp(Vector2 value1, Vector2 value2, float amount)
static readonly SlotId Invalid
static SlotId FromFloat(float value)