1562 {
1563 int num = 0;
1566 for (
int i = 0;
i < 200;
i++)
1567 {
1568 if (!Main.npc[i].active)
1569 {
1570 continue;
1571 }
1572 bool flag = false;
1573 if (Main.npc[i].type ==
type)
1574 {
1575 flag = true;
1576 }
1578 {
1579 if (Main.npc[i].type == 74 || Main.npc[i].type == 297 || Main.npc[i].type == 298)
1580 {
1581 flag = true;
1582 }
1583 }
1585 {
1586 if (Main.npc[i].type == 46 || Main.npc[i].type == 540 || Main.npc[i].type == 303 || Main.npc[i].type == 337)
1587 {
1588 flag = true;
1589 }
1590 }
1591 else if (
type == 362 ||
type == 364)
1592 {
1593 if (Main.npc[i].type == 362 || Main.npc[i].type == 363 || Main.npc[i].type == 364 || Main.npc[i].type == 365)
1594 {
1595 flag = true;
1596 }
1597 }
1598 else if (
type == 602)
1599 {
1600 if (Main.npc[i].type == 602 || Main.npc[i].type == 603)
1601 {
1602 flag = true;
1603 }
1604 }
1605 else if (
type == 608)
1606 {
1607 if (Main.npc[i].type == 608 || Main.npc[i].type == 609)
1608 {
1609 flag = true;
1610 }
1611 }
1612 else if (
type == 616 ||
type == 617)
1613 {
1614 if (Main.npc[i].type == 616 || Main.npc[i].type == 617)
1615 {
1616 flag = true;
1617 }
1618 }
1619 else if (
type == 55 && Main.npc[i].type == 230)
1620 {
1621 flag = true;
1622 }
1624 {
1625 flag = true;
1626 }
1627 if (flag)
1628 {
1629 num++;
1635 {
1637 }
1639 {
1641 }
1642 }
1643 }
1644 if (
num2 >= 3 ||
num3 >= 6 || num >= 10)
1645 {
1646 return false;
1647 }
1648 return true;
1649 }
static double Sqrt(double d)
static bool[] IsDragonfly