12271 {
12272 switch (Style)
12273 {
12274 case 0:
12275 {
12277 int num2 = effectRect.Width * effectRect.Height / 5;
12279 for (
int j = 0;
j <
num2;
j++)
12280 {
12282 Main.dust[
num3].scale = (float)
rand.Next(20, 70) * 0.01f;
12284 {
12286 }
12288 {
12290 }
12291 }
12292 break;
12293 }
12294 case 1:
12295 {
12297 int num10 = effectRect.Width * effectRect.Height / 5;
12300 {
12304 {
12306 }
12308 {
12310 }
12311 }
12312 break;
12313 }
12314 case 2:
12315 {
12318 {
12320 }
12321 break;
12322 }
12323 case 3:
12324 {
12327 for (
int l = 0;
l <
num5;
l++)
12328 {
12331 for (
int m = 0;
m < 5;
m++)
12332 {
12333 if (
rand.Next(3) == 0)
12334 {
12335 Main.dust[
num6].velocity *= 0.75f;
12336 }
12337 }
12338 if (
rand.Next(3) == 0)
12339 {
12342 }
12343 if (
rand.Next(3) == 0)
12344 {
12347 }
12348 if (
rand.Next(2) == 0)
12349 {
12350 Main.dust[
num6].fadeIn = (float)
rand.Next(75, 100) * 0.01f;
12351 Main.dust[
num6].scale = (float)
rand.Next(25, 75) * 0.01f;
12352 }
12354 }
12355 break;
12356 }
12357 case 4:
12358 {
12360 int num17 = effectRect.Width * effectRect.Height / 5;
12363 {
12366 obj4.noLight = true;
12367 obj4.noGravity = true;
12368 obj4.scale = 1.2f;
12369 obj4.fadeIn = 0.4f;
12370 obj4.color.A = byte.MaxValue;
12371 }
12372 break;
12373 }
12374 case 5:
12375 {
12379 {
12381 obj3.velocity.Y *= 0f;
12382 obj3.velocity.Y -= 3.5f;
12383 obj3.velocity.X *= 1.5f;
12384 obj3.scale = 0.8f;
12385 obj3.alpha = 130;
12386 obj3.noGravity = true;
12387 obj3.fadeIn = 1.2f;
12388 }
12390 break;
12391 }
12392 case 7:
12393 {
12397 {
12399 obj5.velocity.Y *= 0f;
12400 obj5.velocity.Y -= 3.5f;
12401 obj5.velocity.X *= 1.5f;
12402 obj5.scale = 0.8f;
12403 obj5.alpha = 130;
12404 obj5.noGravity = true;
12405 obj5.fadeIn = 1.2f;
12406 }
12408 break;
12409 }
12410 case 9:
12411 {
12415 {
12417 }
12419 break;
12420 }
12421 case 10:
12422 {
12426 for (
int n = 0;
n <
num7;
n++)
12427 {
12428 float fadeIn = 0.4f +
rand.NextFloat();
12429 float scale = 0.4f +
rand.NextFloat();
12432 dust.scale = (float)
rand.Next(20, 70) * 0.01f;
12434 {
12435 dust.scale += 0.25f;
12436 }
12438 {
12439 dust.scale += 0.25f;
12440 }
12441 if ((
float)
n < (float)
num7 * 0.8f)
12442 {
12443 dust.velocity +=
vector * 0.1f *
rand.NextFloat();
12444 }
12445 dust.noGravity = true;
12446 dust.noLight = true;
12447 dust.scale = scale;
12448 dust.fadeIn = fadeIn;
12449 if (
dust.dustIndex != 6000)
12450 {
12452 obj2.scale *= 0.65f;
12453 obj2.fadeIn *= 0.65f;
12455 }
12456 }
12458 break;
12459 }
12460 case 11:
12461 {
12462 for (
int k = 0;
k < 50;
k++)
12463 {
12467 {
12468 case 0:
12469 case 1:
12471 break;
12472 case 2:
12474 break;
12475 case 3:
12477 break;
12478 }
12479 Dust
obj = Dust.NewDustPerfect(
rand.NextVector2FromRectangle(
effectRect), 267);
12480 obj.noGravity = true;
12481 obj.color = color;
12482 obj.velocity *= 2f;
12483 obj.scale = 0.8f +
rand.NextFloat() * 0.6f;
12484 obj.fadeIn = 0.5f;
12485 }
12486 break;
12487 }
12488 case 13:
12489 {
12491 for (
int i = 0;
i < 21;
i++)
12492 {
12494 Main.dust[num].velocity *= 1.75f;
12496 {
12497 Main.dust[num].velocity *= 1.5f;
12498 }
12499 Main.dust[num].noLightEmittence =
true;
12500 Main.dust[num].noGravity =
true;
12501 }
12502 break;
12503 }
12504 }
12505 }
static void PlaySound(int type, Vector2 position, int style=1)
static Color GetPortalColor(int colorIndex)
static void SpawnInWorldDust(int tileStyle, Rectangle dustBox)
static readonly LegacySoundStyle Item6
static readonly LegacySoundStyle Item8
static UnifiedRandom rand
static Microsoft.Xna.Framework.Color hslToRgb(Vector3 hslVector)