Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public string GetChat(Player player)
- {
- bool flag = false;
- bool flag2 = false;
- bool flag3 = false;
- bool flag4 = false;
- bool flag5 = false;
- bool flag6 = false;
- bool flag7 = false;
- bool flag8 = false;
- bool flag9 = false;
- for (int i = 0; i < 196; i++)
- {
- if (Main.npc[i].active != 0)
- {
- if (Main.npc[i].type == 17)
- {
- flag = true;
- }
- else
- {
- if (Main.npc[i].type == 18)
- {
- flag2 = true;
- }
- else
- {
- if (Main.npc[i].type == 19)
- {
- flag3 = true;
- }
- else
- {
- if (Main.npc[i].type == 20)
- {
- flag4 = true;
- }
- else
- {
- if (Main.npc[i].type == 37)
- {
- flag5 = true;
- }
- else
- {
- if (Main.npc[i].type == 38)
- {
- flag6 = true;
- }
- else
- {
- if (Main.npc[i].type == 124)
- {
- flag7 = true;
- }
- else
- {
- if (Main.npc[i].type == 107)
- {
- flag8 = true;
- }
- else
- {
- if (Main.npc[i].type == 22)
- {
- flag9 = true;
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- string result = "";
- if (this.type == 17)
- {
- if (!NPC.downedBoss1 && Main.rand.Next(3) == 0)
- {
- if (player.statLifeMax < 200)
- {
- result = Lang.dialog(player, 1);
- }
- else
- {
- if (player.statDefense <= 10)
- {
- result = Lang.dialog(player, 2);
- }
- else
- {
- result = Lang.dialog(player, 3);
- }
- }
- }
- else
- {
- if (Main.gameTime.dayTime)
- {
- if ((double)Main.gameTime.time < 16200.0)
- {
- int num = Main.rand.Next(3);
- if (num == 0)
- {
- result = Lang.dialog(player, 4);
- }
- else
- {
- if (num == 1)
- {
- result = Lang.dialog(player, 5);
- }
- else
- {
- result = Lang.dialog(player, 6);
- }
- }
- }
- else
- {
- if ((double)Main.gameTime.time > 37800.0)
- {
- int num2 = Main.rand.Next(3);
- if (num2 == 0)
- {
- result = Lang.dialog(player, 7);
- }
- else
- {
- if (num2 == 1)
- {
- result = Lang.dialog(player, 8);
- }
- else
- {
- result = Lang.dialog(player, 9);
- }
- }
- }
- else
- {
- int num3 = Main.rand.Next(3);
- if (num3 == 0)
- {
- result = Lang.dialog(player, 10);
- }
- else
- {
- if (num3 == 1)
- {
- result = Lang.dialog(player, 11);
- }
- else
- {
- result = Lang.dialog(player, 12);
- }
- }
- }
- }
- }
- else
- {
- if (Main.gameTime.bloodMoon)
- {
- if (flag2 && flag7 && Main.rand.Next(3) == 0)
- {
- result = Lang.dialog(player, 13);
- }
- else
- {
- int num4 = Main.rand.Next(4);
- if (num4 == 0)
- {
- result = Lang.dialog(player, 14);
- }
- else
- {
- if (num4 == 1)
- {
- result = Lang.dialog(player, 15);
- }
- else
- {
- if (num4 == 2)
- {
- result = Lang.dialog(player, 16);
- }
- else
- {
- result = Lang.dialog(player, 17);
- }
- }
- }
- }
- }
- else
- {
- if ((double)Main.gameTime.time < 9720.0)
- {
- if (Main.rand.Next(2) == 0)
- {
- result = Lang.dialog(player, 18);
- }
- else
- {
- result = Lang.dialog(player, 19);
- }
- }
- else
- {
- if ((double)Main.gameTime.time > 22680.0)
- {
- if (Main.rand.Next(2) == 0)
- {
- result = Lang.dialog(player, 20);
- }
- else
- {
- result = Lang.dialog(player, 21);
- }
- }
- else
- {
- int num5 = Main.rand.Next(3);
- if (num5 == 0)
- {
- result = Lang.dialog(player, 22);
- }
- else
- {
- if (num5 == 1)
- {
- result = Lang.dialog(player, 23);
- }
- else
- {
- result = Lang.dialog(player, 24);
- }
- }
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 18)
- {
- if (Main.gameTime.bloodMoon)
- {
- if ((double)player.statLife < (double)player.statLifeMax * 0.66)
- {
- int num6 = Main.rand.Next(3);
- if (num6 == 0)
- {
- result = Lang.dialog(player, 25);
- }
- else
- {
- if (num6 == 1)
- {
- result = Lang.dialog(player, 26);
- }
- else
- {
- result = Lang.dialog(player, 27);
- }
- }
- }
- else
- {
- int num7 = Main.rand.Next(4);
- if (num7 == 0)
- {
- result = Lang.dialog(player, 28);
- }
- else
- {
- if (num7 == 1)
- {
- result = Lang.dialog(player, 29);
- }
- else
- {
- if (num7 == 2)
- {
- result = Lang.dialog(player, 30);
- }
- else
- {
- result = Lang.dialog(player, 31);
- }
- }
- }
- }
- }
- else
- {
- if (Main.rand.Next(3) == 0 && !NPC.downedBoss3)
- {
- result = Lang.dialog(player, 32);
- }
- else
- {
- if (flag6 && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 33);
- }
- else
- {
- if (flag3 && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 34);
- }
- else
- {
- if (flag9 && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 35);
- }
- else
- {
- if ((double)player.statLife < (double)player.statLifeMax * 0.33)
- {
- int num8 = Main.rand.Next(5);
- if (num8 == 0)
- {
- result = Lang.dialog(player, 36);
- }
- else
- {
- if (num8 == 1)
- {
- result = Lang.dialog(player, 37);
- }
- else
- {
- if (num8 == 2)
- {
- result = Lang.dialog(player, 38);
- }
- else
- {
- if (num8 == 3)
- {
- result = Lang.dialog(player, 39);
- }
- else
- {
- result = Lang.dialog(player, 40);
- }
- }
- }
- }
- }
- else
- {
- if ((double)player.statLife < (double)player.statLifeMax * 0.66)
- {
- int num9 = Main.rand.Next(7);
- if (num9 == 0)
- {
- result = Lang.dialog(player, 41);
- }
- else
- {
- if (num9 == 1)
- {
- result = Lang.dialog(player, 42);
- }
- else
- {
- if (num9 == 2)
- {
- result = Lang.dialog(player, 43);
- }
- else
- {
- if (num9 == 3)
- {
- result = Lang.dialog(player, 44);
- }
- else
- {
- if (num9 == 4)
- {
- result = Lang.dialog(player, 45);
- }
- else
- {
- if (num9 == 5)
- {
- result = Lang.dialog(player, 46);
- }
- else
- {
- result = Lang.dialog(player, 47);
- }
- }
- }
- }
- }
- }
- }
- else
- {
- int num10 = Main.rand.Next(4);
- if (num10 == 0)
- {
- result = Lang.dialog(player, 48);
- }
- else
- {
- if (num10 == 1)
- {
- result = Lang.dialog(player, 49);
- }
- else
- {
- if (num10 == 2)
- {
- result = Lang.dialog(player, 50);
- }
- else
- {
- result = Lang.dialog(player, 51);
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 19)
- {
- if (NPC.downedBoss3 && !Main.hardMode)
- {
- result = Lang.dialog(player, 58);
- }
- else
- {
- if (flag2 && Main.rand.Next(5) == 0)
- {
- result = Lang.dialog(player, 59);
- }
- else
- {
- if (flag2 && Main.rand.Next(5) == 0)
- {
- result = Lang.dialog(player, 60);
- }
- else
- {
- if (flag4 && Main.rand.Next(5) == 0)
- {
- result = Lang.dialog(player, 61);
- }
- else
- {
- if (flag6 && Main.rand.Next(5) == 0)
- {
- result = Lang.dialog(player, 62);
- }
- else
- {
- if (flag6 && Main.rand.Next(5) == 0)
- {
- result = Lang.dialog(player, 63);
- }
- else
- {
- if (Main.gameTime.bloodMoon)
- {
- if (Main.rand.Next(2) == 0)
- {
- result = Lang.dialog(player, 64);
- }
- else
- {
- result = Lang.dialog(player, 65);
- }
- }
- else
- {
- int num11 = Main.rand.Next(3);
- if (num11 == 0)
- {
- result = Lang.dialog(player, 66);
- }
- else
- {
- if (num11 == 1)
- {
- result = Lang.dialog(player, 67);
- }
- else
- {
- result = Lang.dialog(player, 68);
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 20)
- {
- if (!NPC.downedBoss2 && Main.rand.Next(3) == 0)
- {
- result = Lang.dialog(player, 69);
- }
- else
- {
- if (flag3 && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 70);
- }
- else
- {
- if (flag && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 71);
- }
- else
- {
- if (flag5 && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 72);
- }
- else
- {
- if (Main.gameTime.bloodMoon)
- {
- int num12 = Main.rand.Next(4);
- if (num12 == 0)
- {
- result = Lang.dialog(player, 73);
- }
- else
- {
- if (num12 == 1)
- {
- result = Lang.dialog(player, 74);
- }
- else
- {
- if (num12 == 2)
- {
- result = Lang.dialog(player, 75);
- }
- else
- {
- result = Lang.dialog(player, 76);
- }
- }
- }
- }
- else
- {
- int num13 = Main.rand.Next(5);
- if (num13 == 0)
- {
- result = Lang.dialog(player, 77);
- }
- else
- {
- if (num13 == 1)
- {
- result = Lang.dialog(player, 78);
- }
- else
- {
- if (num13 == 2)
- {
- result = Lang.dialog(player, 79);
- }
- else
- {
- if (num13 == 3)
- {
- result = Lang.dialog(player, 80);
- }
- else
- {
- result = Lang.dialog(player, 81);
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 37)
- {
- if (Main.gameTime.dayTime)
- {
- int num14 = Main.rand.Next(3);
- if (num14 == 0)
- {
- result = Lang.dialog(player, 82);
- }
- else
- {
- if (num14 == 1)
- {
- result = Lang.dialog(player, 83);
- }
- else
- {
- result = Lang.dialog(player, 84);
- }
- }
- }
- else
- {
- if (player.statLifeMax < 300 || player.statDefense < 10)
- {
- int num15 = Main.rand.Next(4);
- if (num15 == 0)
- {
- result = Lang.dialog(player, 85);
- }
- else
- {
- if (num15 == 1)
- {
- result = Lang.dialog(player, 86);
- }
- else
- {
- if (num15 == 2)
- {
- result = Lang.dialog(player, 87);
- }
- else
- {
- result = Lang.dialog(player, 88);
- }
- }
- }
- }
- else
- {
- int num16 = Main.rand.Next(4);
- if (num16 == 0)
- {
- result = Lang.dialog(player, 89);
- }
- else
- {
- if (num16 == 1)
- {
- result = Lang.dialog(player, 90);
- }
- else
- {
- if (num16 == 2)
- {
- result = Lang.dialog(player, 91);
- }
- else
- {
- result = Lang.dialog(player, 92);
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 38)
- {
- if (!NPC.downedBoss2 && Main.rand.Next(3) == 0)
- {
- result = Lang.dialog(player, 93);
- }
- if (Main.gameTime.bloodMoon)
- {
- int num17 = Main.rand.Next(3);
- if (num17 == 0)
- {
- result = Lang.dialog(player, 94);
- }
- else
- {
- if (num17 == 1)
- {
- result = Lang.dialog(player, 95);
- }
- else
- {
- result = Lang.dialog(player, 96);
- }
- }
- }
- else
- {
- if (flag3 && Main.rand.Next(5) == 0)
- {
- result = Lang.dialog(player, 97);
- }
- else
- {
- if (flag3 && Main.rand.Next(5) == 0)
- {
- result = Lang.dialog(player, 98);
- }
- else
- {
- if (flag2 && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 99);
- }
- else
- {
- if (flag4 && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 100);
- }
- else
- {
- if (!Main.gameTime.dayTime)
- {
- int num18 = Main.rand.Next(4);
- if (num18 == 0)
- {
- result = Lang.dialog(player, 101);
- }
- else
- {
- if (num18 == 1)
- {
- result = Lang.dialog(player, 102);
- }
- else
- {
- if (num18 == 2)
- {
- result = Lang.dialog(player, 103);
- }
- else
- {
- result = Lang.dialog(player, 104);
- }
- }
- }
- }
- else
- {
- int num19 = Main.rand.Next(5);
- if (num19 == 0)
- {
- result = Lang.dialog(player, 105);
- }
- else
- {
- if (num19 == 1)
- {
- result = Lang.dialog(player, 106);
- }
- else
- {
- if (num19 == 2)
- {
- result = Lang.dialog(player, 107);
- }
- else
- {
- if (num19 == 3)
- {
- result = Lang.dialog(player, 108);
- }
- else
- {
- result = Lang.dialog(player, 109);
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 54)
- {
- if (!flag7 && Main.rand.Next(2) == 0)
- {
- result = Lang.dialog(player, 110);
- }
- else
- {
- if (Main.gameTime.bloodMoon)
- {
- result = Lang.dialog(player, 111);
- }
- else
- {
- if (flag2 && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 112);
- }
- else
- {
- if (player.head == 24)
- {
- result = Lang.dialog(player, 113);
- }
- else
- {
- int num20 = Main.rand.Next(6);
- if (num20 == 0)
- {
- result = Lang.dialog(player, 114);
- }
- else
- {
- if (num20 == 1)
- {
- result = Lang.dialog(player, 115);
- }
- else
- {
- if (num20 == 2)
- {
- result = Lang.dialog(player, 116);
- }
- else
- {
- if (num20 == 3)
- {
- result = Lang.dialog(player, 117);
- }
- else
- {
- if (num20 == 4)
- {
- result = Lang.dialog(player, 118);
- }
- else
- {
- result = Lang.dialog(player, 119);
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 105)
- {
- result = Lang.dialog(player, 120);
- }
- else
- {
- if (this.type == 107)
- {
- if (this.homeless)
- {
- int num21 = Main.rand.Next(5);
- if (num21 == 0)
- {
- result = Lang.dialog(player, 121);
- }
- else
- {
- if (num21 == 1)
- {
- result = Lang.dialog(player, 122);
- }
- else
- {
- if (num21 == 2)
- {
- result = Lang.dialog(player, 123);
- }
- else
- {
- if (num21 == 3)
- {
- result = Lang.dialog(player, 124);
- }
- else
- {
- result = Lang.dialog(player, 125);
- }
- }
- }
- }
- }
- else
- {
- if (flag7 && Main.rand.Next(4) == 0)
- {
- result = Lang.dialog(player, 126);
- }
- else
- {
- if (!Main.gameTime.dayTime)
- {
- int num22 = Main.rand.Next(5);
- if (num22 == 0)
- {
- result = Lang.dialog(player, 127);
- }
- else
- {
- if (num22 == 1)
- {
- result = Lang.dialog(player, 128);
- }
- else
- {
- if (num22 == 2)
- {
- result = Lang.dialog(player, 129);
- }
- else
- {
- if (num22 == 3)
- {
- result = Lang.dialog(player, 130);
- }
- else
- {
- result = Lang.dialog(player, 131);
- }
- }
- }
- }
- }
- else
- {
- int num23 = Main.rand.Next(5);
- if (num23 == 0)
- {
- result = Lang.dialog(player, 132);
- }
- else
- {
- if (num23 == 1)
- {
- result = Lang.dialog(player, 133);
- }
- else
- {
- if (num23 == 2)
- {
- result = Lang.dialog(player, 134);
- }
- else
- {
- if (num23 == 3)
- {
- result = Lang.dialog(player, 135);
- }
- else
- {
- result = Lang.dialog(player, 136);
- }
- }
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 106)
- {
- result = Lang.dialog(player, 137);
- }
- else
- {
- if (this.type == 108)
- {
- if (this.homeless)
- {
- int num24 = Main.rand.Next(3);
- if (num24 == 0)
- {
- result = Lang.dialog(player, 138);
- }
- else
- {
- if (num24 == 1 && !player.male)
- {
- result = Lang.dialog(player, 139);
- }
- else
- {
- if (num24 == 1)
- {
- result = Lang.dialog(player, 140);
- }
- else
- {
- if (num24 == 2)
- {
- result = Lang.dialog(player, 141);
- }
- }
- }
- }
- }
- else
- {
- if (player.male && flag9 && Main.rand.Next(6) == 0)
- {
- result = Lang.dialog(player, 142);
- }
- else
- {
- if (player.male && flag6 && Main.rand.Next(6) == 0)
- {
- result = Lang.dialog(player, 143);
- }
- else
- {
- if (player.male && flag8 && Main.rand.Next(6) == 0)
- {
- result = Lang.dialog(player, 144);
- }
- else
- {
- if (!player.male && flag2 && Main.rand.Next(6) == 0)
- {
- result = Lang.dialog(player, 145);
- }
- else
- {
- if (!player.male && flag7 && Main.rand.Next(6) == 0)
- {
- result = Lang.dialog(player, 146);
- }
- else
- {
- if (!player.male && flag4 && Main.rand.Next(6) == 0)
- {
- result = Lang.dialog(player, 147);
- }
- else
- {
- if (!Main.gameTime.dayTime)
- {
- int num25 = Main.rand.Next(3);
- if (num25 == 0)
- {
- result = Lang.dialog(player, 148);
- }
- else
- {
- if (num25 == 1)
- {
- result = Lang.dialog(player, 149);
- }
- else
- {
- if (num25 == 2)
- {
- result = Lang.dialog(player, 150);
- }
- }
- }
- }
- else
- {
- int num26 = Main.rand.Next(5);
- if (num26 == 0)
- {
- result = Lang.dialog(player, 151);
- }
- else
- {
- if (num26 == 1)
- {
- result = Lang.dialog(player, 152);
- }
- else
- {
- if (num26 == 2)
- {
- result = Lang.dialog(player, 153);
- }
- else
- {
- if (num26 == 3)
- {
- result = Lang.dialog(player, 154);
- }
- else
- {
- result = Lang.dialog(player, 155);
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 123)
- {
- result = Lang.dialog(player, 156);
- }
- else
- {
- if (this.type == 124)
- {
- if (this.homeless)
- {
- int num27 = Main.rand.Next(4);
- if (num27 == 0)
- {
- result = Lang.dialog(player, 157);
- }
- else
- {
- if (num27 == 1)
- {
- result = Lang.dialog(player, 158);
- }
- else
- {
- if (num27 == 2)
- {
- result = Lang.dialog(player, 159);
- }
- else
- {
- result = Lang.dialog(player, 160);
- }
- }
- }
- }
- else
- {
- if (Main.gameTime.bloodMoon)
- {
- int num28 = Main.rand.Next(4);
- if (num28 == 0)
- {
- result = Lang.dialog(player, 161);
- }
- else
- {
- if (num28 == 1)
- {
- result = Lang.dialog(player, 162);
- }
- else
- {
- if (num28 == 2)
- {
- result = Lang.dialog(player, 163);
- }
- else
- {
- result = Lang.dialog(player, 164);
- }
- }
- }
- }
- else
- {
- if (flag8 && Main.rand.Next(6) == 0)
- {
- result = Lang.dialog(player, 165);
- }
- else
- {
- if (flag3 && Main.rand.Next(6) == 0)
- {
- result = Lang.dialog(player, 166);
- }
- else
- {
- int num29 = Main.rand.Next(3);
- if (num29 == 0)
- {
- result = Lang.dialog(player, 167);
- }
- else
- {
- if (num29 == 1)
- {
- result = Lang.dialog(player, 168);
- }
- else
- {
- result = Lang.dialog(player, 169);
- }
- }
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 22)
- {
- if (Main.gameTime.bloodMoon)
- {
- int num30 = Main.rand.Next(3);
- if (num30 == 0)
- {
- result = Lang.dialog(player, 170);
- }
- else
- {
- if (num30 == 1)
- {
- result = Lang.dialog(player, 171);
- }
- else
- {
- result = Lang.dialog(player, 172);
- }
- }
- }
- else
- {
- if (!Main.gameTime.dayTime)
- {
- result = Lang.dialog(player, 173);
- }
- else
- {
- int num31 = Main.rand.Next(3);
- if (num31 == 0)
- {
- result = Lang.dialog(player, 174);
- }
- else
- {
- if (num31 == 1)
- {
- result = Lang.dialog(player, 175);
- }
- else
- {
- result = Lang.dialog(player, 176);
- }
- }
- }
- }
- }
- else
- {
- if (this.type == 142)
- {
- int num32 = Main.rand.Next(3);
- if (num32 == 0)
- {
- result = Lang.dialog(player, 224);
- }
- else
- {
- if (num32 == 1)
- {
- result = Lang.dialog(player, 225);
- }
- else
- {
- if (num32 == 2)
- {
- result = Lang.dialog(player, 226);
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- return result;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement