1using System.Collections.Generic;
318 public static readonly
int[]
IDS =
new int[156]
320 1235, 1643, 1644, 1645, 1646, 1647, 1648, 1649, 1642, 1650,
321 1652, 1653, 1654, 1655, 1656, 1657, 1658, 1651, 1641, 1640,
322 1636, 1612, 1620, 1621, 1622, 1623, 1624, 1625, 1626, 1627,
323 1628, 1629, 1630, 1631, 1632, 1633, 1634, 1635, 1659, 1611,
324 1660, 1662, 1214, 1213, 1212, 1211, 1210, 1209, 1208, 1215,
325 1207, 1205, 1204, 1203, 1202, 1201, 1200, 1234, 1206, 1216,
326 1217, 1218, 1663, 1664, 1750, 1233, 1232, 1230, 1229, 1228,
327 1227, 1226, 1225, 1224, 1223, 1222, 1221, 1220, 1219, 1661,
328 1610, 1231, 1403, 1407, 1408, 1409, 1410, 1411, 1412, 1413,
329 1414, 1406, 1415, 1417, 1418, 1419, 1420, 1421, 1422, 1423,
330 1424, 1416, 1425, 1405, 1402, 1291, 1292, 1293, 1300, 1305,
331 1236, 1310, 1315, 1404, 1320, 1330, 1335, 1340, 1345, 1350,
332 1355, 1400, 1401, 1325, 1290, 1426, 1428, 1239, 1240, 1241,
333 1242, 1243, 1244, 1245, 1246, 1427, 1247, 1249, 1250, 1251,
334 1252, 1253, 1254, 1270, 1271, 1248, 1237, 1238, 1276, 1429,
335 1430, 1431, 1275, 1274, 1273, 1272
340 public static List<string>
hints =
new List<string>();
342 public static string[]
featRef =
new string[5];
346 public override string Name => base.source.GetText().SplitNewline().TryGet(base.Value - 1);
352 string[] array = base.source.GetText().SplitNewline();
353 return array.TryGet(base.Value - 1) + ((base.source.max > 1 && array.Length == 1 && base.Value > 1) ? (
" " + base.Value) :
"");
361 public override int CostLearn => base.source.cost.TryGet(base.Value - 1);
365 return !base.IsGlobalElement;
368 public override Sprite
GetIcon(
string suffix =
"")
370 return SpriteSheet.
Get(
"Media/Graphics/Icon/Element/icon_elements",
"ele_Feat");
378 n.AddText(
"_bullet".lang() +
hint);
388 text = text +
hint.StripLastPun() +
", ";
390 return text.TrimEnd(
' ').TrimEnd(
',');
395 if (base.source.req.Length != 0)
398 if (element ==
null || element.
ValueWithoutLink < ((base.source.req.Length == 1) ? 1 : base.source.req[Mathf.Clamp(((lv == -1 &&
owner !=
null) ?
owner.
Value(
id) : lv) + 1, 1, base.source.req.Length - 1)].ToInt()))
408 if (base.source.req.Length != 0)
410 Element element =
Element.
Create(base.source.req[0], (base.source.req.Length == 1) ? 1 : base.source.req[Mathf.Clamp(((lv == -1 &&
owner !=
null) ?
owner.
Value(
id) : lv) + 1, 1, base.source.req.Length - 1)].ToInt());
431 elinFeatApplyEventArgs.
SetData(a);
433 a = elinFeatApplyEventArgs.
data;
434 int value = base.Value;
435 int A = Mathf.Abs(a);
436 int invert = ((a >= 0) ? 1 : (-1));
439 featRef[0] = a.ToString() ??
"";
440 featRef[1] = a.ToString() ??
"";
444 if (!
hint && a > 0 && chara !=
null)
451 featRef[0] = (a * 25).ToString() ??
"";
454 ModBase(78, -a * 10, hide:
false);
457 featRef[0] = ((a == 1) ? 10 : ((a == 2) ? 20 : 30)).ToString() ??
"";
460 featRef[0] = ((a == 1) ? 1 : ((a == 2) ? 3 : 5)).ToString() ??
"";
463 ModBase(60, a * 4, hide:
false);
466 ModBase(61, a * 4, hide:
false);
469 ModBase(62, a * 4, hide:
false);
496 ModBase(79, a * 5, hide:
false);
499 ModBase(65, ((A == 1) ? 2 : ((A == 2) ? 5 : 10)) * invert, hide:
false);
502 ModBase(64, ((A == 1) ? 2 : ((A == 2) ? 5 : 10)) * invert, hide:
false);
505 ModBase(150, a * 2, hide:
false);
508 ModBase(210, a * 3, hide:
false);
509 ModBase(402, ((A == 3) ? 1 : 0) * invert, hide:
false);
512 ModBase(291, a * 4, hide:
false);
515 ModBase(100, a * 3, hide:
false);
518 ModBase(306, a * 4, hide:
false);
521 ModBase(78, a * 2, hide:
false);
524 ModBase(77, a * 2, hide:
false);
527 featRef[0] = (a * 10).ToString() ??
"";
530 featRef[0] = (a * 10).ToString() ??
"";
533 ModBase(78, a * 15, hide:
false);
536 featRef[0] = (a * 20).ToString() ??
"";
537 featRef[1] = (a * 5).ToString() ??
"";
540 featRef[0] = a.ToString() ??
"";
557 ModBase(60, (A > 5) ? ((A - 5) * -3 * invert) : 0, hide:
false);
558 ModBase(79, (A > 5) ? ((A - 5) * -5 * invert) : 0, hide:
false);
559 ModBase(77, (A > 5) ? ((A - 5) * -3 * invert) : 0, hide:
false);
562 ModBase(60, A * 2 * invert, hide:
false);
563 ModBase(79, A * 3 * invert, hide:
false);
566 ModBase(64, a * 50, hide:
true);
567 ModBase(401, a, hide:
false);
570 ModBase(403, a * 20, hide:
true);
573 ModBase(955, a * 5, hide:
false);
574 ModBase(953, a * 10, hide:
false);
575 ModBase(958, a * 5, hide:
false);
576 ModBase(956, a * 10, hide:
false);
577 ModBase(950, a * -5, hide:
false);
578 ModBase(960, a * -5, hide:
false);
579 ModBase(423, a, hide:
false);
583 ModBase(418, a * 100, hide:
false);
586 ModBase(956, a * 5, hide:
false);
587 ModBase(959, a * 5, hide:
false);
588 ModBase(423, a, hide:
false);
589 ModBase(424, a, hide:
false);
590 ModBase(421, a, hide:
false);
593 ModBase(954, a * 10, hide:
false);
594 ModBase(423, a, hide:
false);
595 ModBase(425, a, hide:
false);
596 ModBase(424, a, hide:
false);
597 ModBase(421, a, hide:
false);
600 ModBase(955, a * 5, hide:
false);
601 ModBase(953, a * 5, hide:
false);
604 ModBase(961, a * 5, hide:
false);
605 ModBase(953, a * 5, hide:
false);
606 ModBase(958, a * 5, hide:
false);
607 ModBase(956, a * 5, hide:
false);
608 ModBase(954, a * 5, hide:
false);
609 ModBase(957, a * 5, hide:
false);
610 ModBase(959, a * 5, hide:
false);
613 ModBase(962, a * 20, hide:
false);
616 ModBase(951, a * 15, hide:
false);
619 ModBase(952, a * -10, hide:
false);
620 ModBase(955, a * 20, hide:
false);
621 ModBase(964, a * 20, hide:
false);
624 ModBase(950, a / 40, hide:
false);
625 ModBase(952, a / 40, hide:
false);
626 ModBase(955, a / 40, hide:
false);
627 ModBase(953, a / 40, hide:
false);
628 ModBase(958, a / 40, hide:
false);
629 ModBase(956, a / 40, hide:
false);
630 ModBase(954, a / 40, hide:
false);
631 ModBase(959, a / 40, hide:
false);
632 ModBase(964, a / 40, hide:
false);
633 ModBase(961, a / 40, hide:
false);
636 ModBase(964, a * 20, hide:
false);
639 ModBase(963, a * 20, hide:
false);
642 ModBase(6020, a, hide:
false);
645 ModBase(950, a * -10, hide:
false);
646 ModBase(951, a * 5, hide:
false);
647 ModBase(961, a * 5, hide:
false);
648 ModBase(8793, a, hide:
false);
649 ModBase(6607, a, hide:
false);
652 ModBase(60, a * 15, hide:
false);
653 ModBase(79, a * 5, hide:
false);
654 ModBase(953, a * 3, hide:
false);
655 ModBase(961, a, hide:
false);
656 ModBase(960, a, hide:
false);
668 featRef[3] = (a - 7).ToString() ??
"";
674 array[0] = num2.ToString() ??
"";
675 featRef[1] = (a * 2).ToString() ??
"";
679 ModBase(73, -a * 5, hide:
false);
682 ModBase(73, a * 5, hide:
false);
685 ModBase(65, a * 3, hide:
false);
688 ModBase(65, -a * 3, hide:
false);
691 ModBase(73, a * 5, hide:
false);
694 ModBase(73, -a * 5, hide:
false);
697 ModBase(72, a * 3, hide:
false);
700 ModBase(72, -a * 3, hide:
false);
703 ModBase(300, a * 4, hide:
false);
706 ModBase(300, -a * 4, hide:
false);
709 ModBase(79, a * 5, hide:
false);
712 ModBase(79, -a * 5, hide:
false);
715 ModBase(70, a * 3, hide:
false);
718 ModBase(70, -a * 3, hide:
false);
721 ModBase(77, a * 5, hide:
false);
724 ModBase(77, -a * 5, hide:
false);
727 ModBase(307, a * 4, hide:
false);
730 ModBase(307, -a * 4, hide:
false);
733 ModBase(951, a * 5, hide:
false);
734 ModBase(950, -a * 5, hide:
false);
737 ModBase(951, -a * 5, hide:
false);
738 ModBase(950, a * 5, hide:
false);
741 ModBase(952, a * 5, hide:
false);
744 ModBase(952, -a * 5, hide:
false);
747 ModBase(960, a * 5, hide:
false);
748 ModBase(956, -a * 5, hide:
false);
751 ModBase(960, -a * 5, hide:
false);
752 ModBase(956, a * 5, hide:
false);
769 ModBase(404, -a * 10, hide:
false);
772 ModBase(77, -a * (4 + num / 5), hide:
false);
775 ModBase(79, a * Mathf.Min(30 + num / 5, 100), hide:
false);
782 ModBase(73, a * (5 + num / 3), hide:
false);
783 ModBase(77, -a * (5 + num / 3), hide:
false);
786 ModBase(404, a * 10, hide:
false);
787 ModBase(401, a, hide:
false);
788 ModBase(79, a * (10 + num / 5), hide:
false);
795 ModBase(65, a * (12 + num), hide:
false);
796 ModBase(77, -a * (5 + num / 5), hide:
false);
803 ModBase(64, -a * (10 + num), hide:
false);
804 ModBase(67, a * (5 + num / 2), hide:
false);
807 ModBase(71, -a * (5 + num / 3), hide:
false);
808 ModBase(72, -a * (4 + num / 4), hide:
false);
809 ModBase(74, a * (6 + num / 2), hide:
false);
810 ModBase(75, a * (2 + num / 6), hide:
false);
813 ModBase(60, -a * 15, hide:
false);
814 ModBase(70, -a * (4 + num / 3), hide:
false);
817 ModBase(61, -a * 15, hide:
false);
818 ModBase(76, -a * (4 + num / 3), hide:
false);
821 ModBase(65, a * (15 + num / 2), hide:
false);
822 ModBase(79, -a * (10 + num / 5), hide:
false);
825 ModBase(77, -a * (3 + num / 4), hide:
false);
828 ModBase(961, a * 5, hide:
false);
831 ModBase(955, a * 20, hide:
false);
836 string text = base.source.GetText(
"textExtra");
839 string text2 = text.SplitNewline().TryGet(value - 1, 99);
840 if (!text2.IsEmpty())
843 string[] array2 = text2.Split(
',');
844 foreach (
string obj
in array2)
847 string text4 = obj.Replace(
";",
",");
848 if (text3.ToInt() < 0)
850 text4 = text4.Replace(
"+#1", text3);
852 text4 = text4.Replace(
"#1", text3);
868 if (value2.
source.id !=
id)
870 NoteElement(value2.
id, value2.
Value);
874 void ModAttribute(
int ele)
877 ModBase(ele, ((A == 1) ? 2 : ((A == 2) ? 4 : 5)) * invert, hide:
false);
880 void ModBase(
int ele,
int _v,
bool hide)
886 if (!hide && _v != 0)
888 NoteElement(ele, _v);
906 void NoteElement(
int ele,
int a)
911 Note(
"hintLearnAbility".lang(row.
GetName().ToTitleCase()));
913 else if (row.
tag.Contains(
"flag"))
919 string @ref = ((a < 0) ?
"" :
"+") + a;
923 @ref = ((a > 0) ?
"+" :
"-").Repeat(Mathf.Clamp(Mathf.Abs(a) / 5 + num4, 1, 5));
924 Note(
"modValueRes".lang(row.
GetName(), @ref));
928 Note(
"modValue".lang(row.
GetName(), @ref));
static void PublishEvent(string eventId, object data=null)
void UnequipAll(int idSlot)
void AddRandomBodyPart(bool msg=false)
ElementContainer faithElements
static SourceManager sources
virtual void SetData(T newData)
Dictionary< int, Element > dict
Element ModPotential(int ele, int v)
Element ModBase(int ele, int v)
Element GetElement(string alias)
static Element Create(int id, int v=0)
const int featUnderground
const int featMiscreation
const int featCannibalism
const int featModelBeliever
const int featEternalYouth
const int featMelilithCurse
const int featGod_element1
const int featExecutioner
const int featHeavyCasting
const int featMagicManner
const int featManaPrecision
const int featMassSummoner
const int featFastLearner
const int featGod_trickery1
const int featCosmicHorror
const int featEarthStrength
const int featGod_healing1
const int featMeatCushion
static readonly int[] IDS
const int featSadCreature
const int featGod_moonshadow1
const int featGoldenFinger
const int featSevenPillars
const int featGod_strife1
const int featSlimeEvolution
const int featGod_harvest1
const int featAnimalLover
const int featFairyResist
const int featGod_machine1
const int featGod_harmony1
const int featGod_oblivion1
virtual List< string > Apply(int a, ElementContainer owner, bool hint=false)
override Sprite GetIcon(string suffix="")
static List< string > hints
override bool CanLink(ElementContainer owner)
string GetHint(ElementContainer owner)
override void WritePurchaseReq(UINote n, int lv=-1)
override bool IsPurchaseFeatReqMet(ElementContainer owner, int lv=-1)
override void OnWriteNote(UINote n, ElementContainer owner)
override bool ShowBonuses
override string GetName()
static Sprite Get(string id)
UIItem AddHeader(string text, Sprite sprite=null)
UIItem AddText(string text, FontColor color=FontColor.DontChange)