Skip to content

EA 23.202 Nightly

September 20, 2025

22 files modified.

Important Changes

None.

AI_Fuck

public void Finish()

cs
		}
		if (ntr)
		{
			chara2.things.Find<TraitDreamBug>()?.ModNum(-1); 
			Thing thing = chara2.things.Find<TraitDreamBug>(); 
			if (thing != null) 
			{ 
				thing.ModNum(-1); 
				if (chara.IsPC) 
				{ 
					Msg.Say("dream_spell", EClass.sources.elements.map[9156].GetName().ToLowerInvariant()); 
					EClass.pc.GainAbility(9156, EClass.rnd(2) + 1); 
				} 
			} 
		}
		if (!ntr || !chara.HasElement(1239) || chara2.HasElement(1216))
		{

ActEffect

public static bool DamageEle(Card CC, EffectId id, int power, Element e, List<Po

cs
		{
		case EffectId.Arrow:
		case EffectId.MoonSpear:
		case EffectId.MoonArrow:
		{
			effect = Effect.Get((id == EffectId.MoonSpear) ? "spell_moonspear" : "spell_arrow"); 
			effect = Effect.Get((id == EffectId.MoonSpear || id == EffectId.MoonArrow) ? "spell_moonspear" : "spell_arrow"); 
			if (id == EffectId.Arrow)
			{
				effect.sr.color = elementRef.colorSprite;

public static bool DamageEle(Card CC, EffectId id, int power, Element e, List<Po

cs
		}
		if (effect != null)
		{
			if (id == EffectId.Arrow || id == EffectId.MoonSpear) 
			if (id == EffectId.Arrow || id == EffectId.MoonSpear || id == EffectId.MoonArrow) 
			{
				TryDelay(delegate
				{

public static bool DamageEle(Card CC, EffectId id, int power, Element e, List<Po

cs
			{
				continue;
			}
			if ((uint)(id - 250) <= 1u || id == EffectId.Sword || id == EffectId.MoonSpear) 
			switch (id) 
			{
			case EffectId.Arrow: 
			case EffectId.Hand: 
			case EffectId.Sword: 
			case EffectId.MoonSpear: 
			case EffectId.MoonArrow: 
				if (c.isChara && CC.isChara)
				{
					c.Chara.RequestProtection(CC.Chara, delegate(Chara a)

public static bool DamageEle(Card CC, EffectId id, int power, Element e, List<Po

cs
						c = a;
					});
				}
				if (id == EffectId.MoonSpear) 
				if (id == EffectId.MoonSpear || (id == EffectId.MoonArrow && EClass.rnd(5) == 0)) 
				{
					attackSource = AttackSource.MoonSpear;
				}
				break; 
			}
			switch (id)
			{

public static bool DamageEle(Card CC, EffectId id, int power, Element e, List<Po

cs
	}
	case EffectId.Arrow:
	case EffectId.MoonSpear:
	case EffectId.MoonArrow:
	{
		List<Point> list = new List<Point>();
		list.Add(tp.Copy());

Card

public Thing TryMakeRandomItem(int lv = -1, TryMakeRandomItemSource itemSource =

cs
		for (int i = 0; i < 20; i++)
		{
			CardRow cardRow = SpawnList.Get(text).Select(lv + i);
			if ((cardRow.model.Chara.race.corpse[0] != "_meat" && id != "milk" && id != "_egg" && id != "egg_fertilized") || (itemSource == TryMakeRandomItemSource.Cooking && cardRow.model.HasElement(701))) 
			if (cardRow.model.Chara.race.corpse[0] != "_meat" && id != "milk" && id != "_egg" && id != "egg_fertilized") 
			{
				continue;
			}
			if (itemSource == TryMakeRandomItemSource.Cooking) 
			{ 
				if (cardRow.model.HasElement(701)) 
				{ 
					continue; 
				} 
				if (crafter != null && crafter.id == "big_sister") 
				{ 
					cardRow = crafter.source; 
				} 
			} 
			if (id == "milk")
			{
				if (c_idRefCard.IsEmpty())

public virtual int GetPrice(CurrencyType currency = CurrencyType.Money, bool sel

cs
		}
		switch (currency)
		{
		case CurrencyType.Influence: 
			if (id == "lunch_love") 
			{ 
				return 10; 
			} 
			break; 
		case CurrencyType.Ecopo:
			switch (id)
			{

Chara

public void SetFeat(int id, int value = 1, bool msg = false)

cs
		{
			flag = !flag;
		}
		PlaySound("mutation"); 
		switch (id) 
		{ 
		case 1270: 
			if (!flag) 
			{ 
				PlaySound("chime_angel"); 
			} 
			break; 
		case 1271: 
			if (!flag) 
			{ 
				PlaySound("chime_devil"); 
			} 
			break; 
		default: 
			PlaySound("mutation"); 
			break; 
		} 
		Msg.SetColor(flag ? Msg.colors.Negative : Msg.colors.Ding);
		Say((value > num) ? feat.source.GetText("textInc") : feat.source.GetText("textDec"), this, feat.FullName);
	}

CharaRenderer

public void DrawHat()

cs
		RenderObject.currentParam.liquidLv = 0;
		RenderObject.currentParam.x += 0.01f * (float)pref.equipX;
		RenderObject.currentParam.y += num + 0.01f * (float)(pref.equipY + cardRow.pref.equipY);
		RenderObject.currentParam.z -= pref.hatY; 
		RenderObject.currentParam.z += 0f - pref.hatY + ((pccData != null) ? 0.4f : 0.3f); 
		RenderObject.currentParam.tile = cardRow._tiles[owner.uid % cardRow._tiles.Length] * ((!flag) ? 1 : (-1));
		RenderObject.currentParam.mat = cardRow.DefaultMaterial;
		RenderObject.currentParam.matColor = cardRow.GetColorInt(RenderObject.currentParam.mat);
		cardRow.renderData.Draw(RenderObject.currentParam);
		RenderObject.currentParam.x -= 0.01f * (float)pref.equipX;
		RenderObject.currentParam.y -= num + 0.01f * (float)(pref.equipY + cardRow.pref.equipY);
		RenderObject.currentParam.z += pref.hatY; 
		RenderObject.currentParam.z -= 0f - pref.hatY + ((pccData != null) ? 0.4f : 0.3f); 
		RenderObject.currentParam.liquidLv = liquidLv;
	}

ConSleep

public override void OnRemoved()

cs
			member.SAN.Mod(-15);
		}
	}
	if (EClass.player.karma < 80 && EClass.pc.HasElement(1270)) 
	{ 
		EClass.pc.SetFeat(1270, 0, msg: true); 
	} 
	if (EClass.player.karma > -80 && EClass.pc.HasElement(1271)) 
	{ 
		EClass.pc.SetFeat(1271, 0, msg: true); 
	} 
	Rand.SetSeed(EClass.game.seed + EClass.player.stats.days); 
	if (EClass.player.karma >= 80) 
	{ 
		if (EClass.rnd(EClass.debug.enable ? 1 : 5) == 0 && !EClass.pc.HasElement(1270)) 
		{ 
			EClass.pc.SetFeat(1270, 1, msg: true); 
		} 
	} 
	else if (EClass.player.karma <= -80 && EClass.rnd(EClass.debug.enable ? 1 : 2) == 0 && !EClass.pc.HasElement(1271)) 
	{ 
		EClass.pc.SetFeat(1271, 1, msg: true); 
	} 
	Rand.SetSeed(); 
	static void TryPick(Thing t, ItemPosition pos)
	{
		if (t != null)

CoreDebug

public void UpdateInput()

cs
	}
	if (Input.GetKeyDown(KeyCode.F4))
	{
		EClass.ui.AddLayer<LayerCalendar>(); 
		EClass.player.karma = EScriptable.rnd(200) - 100; 
		Msg.Say("k:" + EClass.player.karma + "  "); 
		if (EClass.player.karma < 80 && EClass.pc.HasElement(1270)) 
		{ 
			EClass.pc.SetFeat(1270, 0, msg: true); 
		} 
		if (EClass.player.karma > -80 && EClass.pc.HasElement(1271)) 
		{ 
			EClass.pc.SetFeat(1271, 0, msg: true); 
		} 
		if (EClass.player.karma >= 80) 
		{ 
			if (EScriptable.rnd(EClass.debug.enable ? 1 : 5) == 0 && !EClass.pc.HasElement(1270)) 
			{ 
				EClass.pc.SetFeat(1270, 1, msg: true); 
			} 
		} 
		else if (EClass.player.karma <= -80 && EScriptable.rnd(EClass.debug.enable ? 1 : 2) == 0 && !EClass.pc.HasElement(1271)) 
		{ 
			EClass.pc.SetFeat(1271, 1, msg: true); 
		} 
		return;
	}
	if (Input.GetKeyDown(KeyCode.F5))

DramaManager

public void ParseLine(Dictionary<string, string> item)

cs
	case "end":
		AddEvent(new DramaEventExit());
		break;
	case "modAffinity":
		AddEvent(delegate
		{ 
			int num = int.Parse(p2); 
			if (EMono.debug.enable) 
			{ 
				num *= 10; 
			} 
			EMono.pc.ModAffinity(tg.chara, num); 
		}); 
		break; 
	case "acceptQuest":
		if (LayerDrama.fromBook)
		{

public void ParseLine(Dictionary<string, string> item)

cs
		break;
	case "new":
	case "saveBGM":
	case "addAffinity":
	case "checkAffinity":
		break;
	}

ENC

public class ENC

cs

	public const int mod_drill = 606;

	public const int strongStomach = 480; 
	public const int revealFaith = 481; 

	public const int mod_ammo_recover = 604;

public class ENC

cs

	public const int bane_all = 468;

	public const int revealFaith = 481; 
	public const int strongStomach = 480; 

	public const int force_weapon = 482;

public class ENC

cs
{
	651, 650, 641, 640, 624, 609, 622, 621, 608, 620,
	652, 623, 653, 851, 655, 656, 660, 661, 662, 663,
	664, 665, 666, 850, 607, 865, 852, 654, 606, 480, 
	664, 665, 666, 850, 607, 865, 852, 654, 606, 481, 
	604, 416, 417, 418, 419, 421, 422, 415, 423, 425,
	426, 427, 428, 429, 430, 424, 414, 412, 411, 605,
	380, 381, 382, 400, 401, 402, 403, 404, 405, 406,
	407, 408, 409, 410, 435, 436, 420, 438, 468, 481, 
	407, 408, 409, 410, 435, 436, 420, 438, 468, 480, 
	482, 483, 484, 485, 467, 486, 437, 489, 600, 601,
	602, 603, 487, 466, 488, 464, 439, 465, 440, 441,
	443, 444, 445, 446, 442, 450, 460, 461, 463, 462,

EffectId

public enum EffectId

cs
	Youth = 300,
	EternalYouth = 301,
	MoonSpear = 302,
	BurnMana = 303
	BurnMana = 303, 
	MoonArrow = 304
}

FACTION

public class FACTION

cs

	public const int bfVolcano = 3704;

	public const int bfTranquil = 3703; 
	public const int actBuildInspect = 4006;

	public const int actBuildRecipe = 4005;

public class FACTION

cs

	public const int actBuildMine = 4001;

	public const int bfTranquil = 3703; 
	public const int bfStart = 3900;

	public const int bfChitin = 3805;

public class FACTION

cs

	public const int bfLandmark3 = 3782;

	public const int bfHunt = 3705; 
	public const int bfLandmark1 = 3780;

	public const int bfBreed = 3710;

public class FACTION

cs

	public const int bfFish = 3706;

	public const int bfHunt = 3705; 
	public const int bfMushroom = 3801;

	public static readonly int[] IDS = new int[53]
	{
		3500, 3600, 3601, 3603, 3604, 3605, 3700, 2207, 3606, 3602,
		2206, 2119, 2204, 2203, 2202, 2201, 2200, 2120, 2118, 2117,
		2116, 2115, 3701, 2003, 2205, 3702, 3781, 3704, 3703, 4006, 
		4005, 4004, 4003, 4002, 4001, 3900, 3805, 3804, 3803, 3802, 
		4000, 3800, 3784, 3783, 3782, 3705, 3780, 3710, 3709, 3708, 
		3707, 3706, 3801
		2116, 2115, 3701, 2003, 2205, 3702, 3781, 3704, 4006, 4005, 
		4004, 4003, 4002, 4001, 3703, 3900, 3805, 3804, 3803, 3802, 
		4000, 3800, 3784, 3783, 3782, 3780, 3710, 3709, 3708, 3707, 
		3706, 3705, 3801
	};
}
public class Faction : EClass

FEAT

``

cs

public class FEAT
{
	public const int featSTR = 1620; 
	public const int featDEX = 1621;

	public const int featEND = 1622;

	public const int featPER = 1623;

	public const int featLER = 1624; 
	public const int featSPD = 1629;

	public const int featMAG = 1625; 
	public const int featWIL = 1626;

	public const int featCHA = 1627;

	public const int featLuck = 1628;

	public const int featSTR = 1620; 
	public const int featMAG = 1625; 
	public const int featLER = 1624; 

	public const int featStamina = 1612;

	public const int featFairysan = 1413; 
	public const int featLuckyCat = 1412; 

	public const int featLife = 1610;

public class FEAT

cs

	public const int featWhiteVixen = 1414;

	public const int featFairysan = 1413; 
	public const int featHardy = 1630;

	public const int featMana = 1611;

public class FEAT

cs

	public const int featSpotting = 1633;

	public const int featLuckyCat = 1412; 
	public const int featEarthStrength = 1411; 

	public const int featLooter = 1660; 
	public const int featDismantler = 1661; 

	public const int featFisher = 1659;

public class FEAT

cs

	public const int featDefender = 1649;

	public const int featEarthStrength = 1411; 
	public const int featDismantler = 1661; 
	public const int featReboot = 1410; 

	public const int featBoost = 1409; 
	public const int featLooter = 1660; 

	public const int featServant = 1227; 
	public const int featPaladin2 = 1408; 

	public const int featDemigod = 1228;

public class FEAT

cs

	public const int featRoran = 1237;

	public const int featUnderground = 1226; 
	public const int featElder = 1238;

	public const int featMeatCushion = 1241; 
	public const int featServant = 1227; 
	public const int featDemon = 1239; 

	public const int featGeneSlot = 1242;

public class FEAT

cs

	public const int featLibra = 1247;

	public const int featGoodKarma = 1270; 
	public const int featBadKarma = 1271; 
	public const int featGod_element1 = 1300;

	public const int featGod_earth1 = 1305;

	public const int featGod_wind1 = 1310;

	public const int featGod_machine1 = 1315; 
	public const int featMassSummoner = 1240; 
	public const int featMeatCushion = 1241; 

	public const int featGod_healing1 = 1320; 
	public const int featUnderground = 1226; 

	public const int featLoyal = 1225;

	public const int featAcidBody = 1223; 
	public const int featShiva = 1224; 

	public const int featFastLearner = 1202;

public class FEAT

cs

	public const int featSlowFood = 1200;

	public const int featReboot = 1410; 
	public const int featBoost = 1409; 

	public const int featGrowParts = 1203;

public class FEAT

cs

	public const int featFluffyTail = 1209;

	public const int featShiva = 1224; 
	public const int featUndead = 1210;

	public const int featSnail = 1211; 
	public const int featFairyResist = 1212;

	public const int featElea = 1213;

public class FEAT

cs

	public const int featSplit = 1222;

	public const int featSnail = 1211; 
	public const int featGod_harvest1 = 1325; 
	public const int featAcidBody = 1223; 

	public const int featDemon = 1239; 
	public const int featGod_machine1 = 1315; 

	public const int featGod_harmony1 = 1335; 
	public const int featGod_healing1 = 1320; 

	public const int featArcher = 1404; 
	public const int featMassSummoner = 1240; 

	public const int featFarmer = 1403; 
	public const int featGod_luck1 = 1330; 

	public const int featWizard = 1402; 
	public const int featGod_harmony1 = 1335; 

	public const int featThief = 1401; 
	public const int featGod_oblivion1 = 1340; 

	public const int featWarrior = 1400; 
	public const int featPaladin = 1407; 

	public const int featGod_strife1 = 1355; 
	public const int featTourist = 1406; 

	public const int featGod_luck1 = 1330; 
	public const int featPianist = 1405; 

	public const int featTourist = 1406; 
	public const int featArcher = 1404; 

	public const int featPaladin = 1407; 
	public const int featGod_harvest1 = 1325; 

	public const int featPaladin2 = 1408; 
	public const int featGod_trickery1 = 1345; 

	public const int featGod_moonshadow1 = 1350;

	public const int featGod_trickery1 = 1345; 
	public const int featGod_strife1 = 1355; 

	public const int featGod_oblivion1 = 1340; 
	public const int featWarrior = 1400; 

	public const int featPianist = 1405; 
	public const int featThief = 1401; 
	public const int featWizard = 1402; 
	public const int featFarmer = 1403; 

	public static readonly int[] IDS = new int[125] 
	public static readonly int[] IDS = new int[127] 
	{
		1621, 1622, 1623, 1624, 1629, 1626, 1627, 1628, 1620, 1625, 
		1612, 1413, 1610, 1422, 1421, 1420, 1419, 1418, 1417, 1416, 
		1415, 1414, 1630, 1611, 1631, 1647, 1633, 1412, 1660, 1659, 
		1658, 1657, 1656, 1655, 1654, 1653, 1652, 1651, 1632, 1650, 
		1648, 1646, 1645, 1644, 1643, 1642, 1641, 1640, 1636, 1635, 
		1634, 1649, 1411, 1661, 1409, 1227, 1228, 1229, 1230, 1231, 
		1232, 1233, 1234, 1235, 1236, 1237, 1226, 1238, 1241, 1242, 
		1243, 1244, 1245, 1246, 1247, 1300, 1305, 1310, 1315, 1240, 
		1320, 1225, 1223, 1202, 1201, 1200, 1410, 1203, 1204, 1205, 
		1206, 1207, 1208, 1209, 1224, 1210, 1212, 1213, 1214, 1215, 
		1216, 1217, 1218, 1219, 1220, 1221, 1222, 1211, 1325, 1239, 
		1335, 1404, 1403, 1402, 1401, 1400, 1355, 1330, 1406, 1407, 
		1408, 1350, 1345, 1340, 1405
		1620, 1621, 1622, 1623, 1629, 1625, 1626, 1627, 1628, 1624, 
		1612, 1412, 1610, 1422, 1421, 1420, 1419, 1418, 1417, 1416, 
		1415, 1414, 1413, 1630, 1611, 1631, 1647, 1633, 1411, 1661, 
		1659, 1658, 1657, 1656, 1655, 1654, 1653, 1652, 1651, 1632, 
		1650, 1648, 1646, 1645, 1644, 1643, 1642, 1641, 1640, 1636, 
		1635, 1634, 1649, 1410, 1660, 1408, 1228, 1229, 1230, 1231, 
		1232, 1233, 1234, 1235, 1236, 1237, 1238, 1227, 1239, 1242, 
		1243, 1244, 1245, 1246, 1247, 1270, 1271, 1300, 1305, 1310, 
		1241, 1226, 1225, 1224, 1202, 1201, 1200, 1409, 1203, 1204, 
		1205, 1206, 1207, 1208, 1209, 1210, 1211, 1212, 1213, 1214, 
		1215, 1216, 1217, 1218, 1219, 1220, 1221, 1222, 1223, 1315, 
		1320, 1240, 1330, 1335, 1340, 1407, 1406, 1405, 1404, 1325, 
		1345, 1350, 1355, 1400, 1401, 1402, 1403
	};
}
public class Feat : Element

FOOD

public class FOOD

cs

	public const int food_poison = 702;

	public const int food_love = 703; 
	public const int food_CHA = 700; 

	public const int food_bug = 704;

	public const int creativeDish = 764; 
	public const int gainWeight = 705; 

	public const int food_god = 758; 
	public const int loseWeight = 706; 

	public const int justcooked = 757; 
	public const int kirimi = 707; 

	public const int food_undead = 709; 
	public const int food_human = 708; 

	public const int food_CHA = 700; 
	public const int food_undead = 709; 

	public const int kirimi = 707; 
	public const int justcooked = 757; 

	public const int loseWeight = 706; 
	public const int food_god = 758; 

	public const int gainWeight = 705; 
	public const int food_love = 703; 

	public const int food_human = 708; 
	public const int creativeDish = 764; 

	public static readonly int[] IDS = new int[13]
	{
		701, 702, 703, 704, 764, 758, 757, 709, 700, 707, 
		706, 705, 708
		701, 702, 700, 704, 705, 706, 707, 708, 709, 757, 
		758, 703, 764
	};
}

FactionBranch

void GetOutcome(Hobby h)

cs
			{
				string text = h.source.things[j];
				int num5 = Mathf.Max(1, h.source.things[j + 1].ToInt() * num3 / 1000);
				Debug.Log(i.Name + "/" + num3 + "/" + num5); 
				int num6 = num5 / 1000;
				if (num5 % 1000 > EClass.rnd(1000))
				{

FoodEffect

public static void Proc(Chara c, Thing food, bool consume = true)

cs
				{
					break;
				}
				goto IL_0f04; 
				goto IL_0f01; 
			case "love":
				ActEffect.LoveMiracle(c, EClass.pc, value.Value * 10);
				break;

public static void Proc(Chara c, Thing food, bool consume = true)

cs
					c.SetFeat(1230, c.elements.Base(1230) + 1);
				}
				c.SetInt(112, @int + 1);
				flag6 = false; 
				break;
			}
			}

public static void Proc(Chara c, Thing food, bool consume = true)

cs
		{
			food.trait.OnDrink(c);
		}
		goto IL_0f04; 
		IL_0f04: 
		if (consume) 
		goto IL_0f01; 
		IL_0f01: 
		if (!consume) 
		{
			num7 += 5f; 
			if (flag6 && (float)food.Evalue(10) > num7 + 10f) 
			{ 
				food.elements.SetTo(10, (int)Mathf.Max((float)food.Evalue(10) - num7, 1f)); 
				food.SetBool(125, enable: true); 
			} 
			else
			return; 
		} 
		num7 += 5f; 
		if (flag6 && (float)food.Evalue(10) > num7 + 10f) 
		{ 
			food.elements.SetTo(10, (int)Mathf.Max((float)food.Evalue(10) - num7, 1f)); 
			food.SetBool(125, enable: true); 
			if (food.HasElement(1229)) 
			{
				food.ModNum(-1); 
				food.elements.Remove(1229); 
			}
		}
		else
		{ 
			food.ModNum(-1); 
		} 
	}

	public static void ProcTrait(Chara c, Card t)

MUTATION

public class MUTATION

cs
public class MUTATION
{
	public const int mutationSpeed = 1518; 
	public const int mutationRegenN = 1517; 

	public const int mutationSkinN = 1511; 
	public const int mutationRegen = 1516; 

	public const int mutationEye = 1512; 
	public const int mutationDexN = 1515; 

	public const int mutationDex = 1514; 
	public const int mutationSkin = 1510; 

	public const int mutationDexN = 1515; 
	public const int mutationEyeN = 1513; 

	public const int mutationRegen = 1516; 
	public const int mutationSkinN = 1511; 

	public const int mutationRegenN = 1517; 
	public const int mutationDex = 1514; 

	public const int mutationSkin = 1510; 
	public const int mutationSpeed = 1518; 

	public const int mutationEyeN = 1513; 
	public const int mutationEye = 1512; 

	public const int mutationStr = 1520;

public class MUTATION

cs

	public static readonly int[] IDS = new int[40]
	{
		1518, 1511, 1512, 1514, 1515, 1516, 1517, 1510, 1513, 1520, 
		1517, 1516, 1515, 1510, 1513, 1511, 1514, 1518, 1512, 1520, 
		1565, 1564, 1563, 1562, 1561, 1560, 1559, 1519, 1557, 1556,
		1555, 1554, 1553, 1552, 1558, 1550, 1551, 1521, 1522, 1523,
		1524, 1526, 1527, 1525, 1529, 1530, 1531, 1532, 1533, 1528

POLICY

public class POLICY

cs

	public const int bed_quality = 2812;

	public const int resident_tax = 2512; 
	public const int self_sufficient = 2511; 

	public const int open_business = 2810;

public class POLICY

cs

	public const int ban_radio = 2510;

	public const int self_sufficient = 2511; 
	public const int legal_drug = 2505;

	public const int impressment = 2504;

public class POLICY

cs

	public const int tourist_safety = 2811;

	public const int resident_tax = 2512; 
	public const int inquisition = 2507;

	public const int resident_wanted = 2513;

public class POLICY

cs

	public const int energy_conservation = 2700;

	public const int border_watch = 2704; 
	public const int taxTransfer = 2705; 

	public const int weed_no = 2703;

	public const int taxTransfer = 2705; 
	public const int speed_growth = 2516;

	public const int auto_farm = 2707;

public class POLICY

cs

	public const int noMother = 2710;

	public const int border_watch = 2704; 
	public static readonly int[] IDS = new int[51]
	{
		2819, 2814, 2815, 2816, 2817, 2818, 2820, 2828, 2822, 2823,
		2824, 2825, 2826, 2827, 2813, 2821, 2812, 2512, 2810, 2508, 
		2509, 2510, 2511, 2505, 2504, 2503, 2502, 2501, 2500, 2811, 
		2507, 2513, 2514, 2515, 2506, 2700, 2704, 2703, 2705, 2516, 
		2707, 2708, 2709, 2706, 2711, 2712, 2715, 2800, 2702, 2701, 
		2710
		2824, 2825, 2826, 2827, 2813, 2821, 2812, 2511, 2810, 2508, 
		2509, 2510, 2505, 2504, 2503, 2502, 2501, 2500, 2811, 2512, 
		2507, 2513, 2514, 2515, 2506, 2700, 2705, 2703, 2516, 2707, 
		2708, 2709, 2706, 2711, 2712, 2715, 2800, 2702, 2701, 2710, 
		2704
	};
}
public class Policy : EClass

SKILL

public class SKILL

cs

	public const int weaponAxe = 102;

	public const int weaponDagger = 107; 
	public const int throwing = 108; 

	public const int END = 71;

public class SKILL

cs

	public const int WIL = 75;

	public const int weaponDagger = 107; 
	public const int weaponPolearm = 106;

	public const int weaponGun = 105;

public class SKILL

cs

	public const int INT = 80;

	public const int fishing = 245; 
	public const int LUC = 78;

	public const int CHA = 77;

	public const int MAG = 76;

	public const int throwing = 108; 
	public const int fishing = 245; 

	public const int gathering = 250;

public class SKILL

cs

	public const int eleNerve = 918;

	public const int eleHoly = 919; 
	public const int eleChaos = 920;

	public const int eleMagic = 921;

public class SKILL

cs

	public const int resLightning = 952;

	public const int resDarkness = 953; 
	public const int elePoison = 915;

	public const int resDarkness = 953; 
	public const int resMind = 954; 

	public const int resNether = 956;

public class SKILL

cs

	public const int carpentry = 255;

	public const int resMind = 954; 
	public const int resPoison = 955; 

	public const int eleMind = 914;

	public const int resPoison = 955; 
	public const int eleHoly = 919; 

	public const int eleLightning = 912;

	public const int eleDarkness = 913; 
	public const int alchemy = 257;

	public const int sculpture = 258;

public class SKILL

cs

	public const int cooking = 287;

	public const int building = 288; 
	public const int eleDarkness = 913; 
	public const int appraising = 289; 

	public const int anatomy = 290;

public class SKILL

cs

	public const int investing = 292;

	public const int appraising = 289; 
	public const int building = 288; 

	public const int fun = 312; 
	public const int regeneration = 300; 

	public const int eleFire = 910; 
	public const int eleCold = 911; 
	public const int disarmTrap = 293; 

	public const int env = 313;

	public const int disarmTrap = 293; 
	public const int fun = 312; 

	public const int bladder = 311;

	public const int hygine = 310;

	public const int eleCold = 911; 
	public const int eleFire = 910; 

	public const int faith = 306;

	public const int memorization = 307; 
	public const int magicDevice = 305; 

	public const int casting = 304;

public class SKILL

cs

	public const int meditation = 301;

	public const int regeneration = 300; 
	public const int magicDevice = 305; 
	public const int memorization = 307; 

	public static readonly int[] IDS = new int[133]
	{
		50, 109, 110, 111, 120, 122, 123, 130, 132, 133,
		242, 241, 240, 237, 235, 230, 227, 226, 225, 220,
		207, 200, 152, 151, 150, 135, 134, 131, 210, 102,
		107, 71, 70, 68, 67, 66, 65, 72, 64, 61, 
		60, 57, 56, 55, 51, 62, 73, 74, 75, 106, 
		105, 104, 103, 101, 100, 93, 92, 91, 90, 80, 
		245, 78, 77, 76, 108, 250, 79, 256, 916, 917, 
		918, 919, 920, 921, 922, 923, 924, 925, 926, 950, 
		951, 952, 915, 953, 956, 957, 958, 959, 960, 961, 
		962, 963, 964, 965, 970, 971, 972, 255, 954, 914, 
		955, 912, 913, 257, 258, 259, 260, 261, 280, 281, 
		285, 286, 287, 288, 290, 291, 292, 289, 312, 910, 
		313, 293, 311, 310, 911, 306, 307, 304, 303, 302, 
		301, 300, 305
		108, 71, 70, 68, 67, 66, 65, 72, 64, 61, 
		60, 57, 56, 55, 51, 62, 73, 74, 75, 107, 
		106, 105, 104, 103, 101, 100, 93, 92, 91, 90, 
		80, 78, 77, 76, 245, 250, 79, 256, 916, 917, 
		918, 920, 921, 922, 923, 924, 925, 926, 950, 951, 
		952, 953, 915, 954, 956, 957, 958, 959, 960, 961, 
		962, 963, 964, 965, 970, 971, 972, 255, 955, 914, 
		919, 912, 257, 258, 259, 260, 261, 280, 281, 285, 
		286, 287, 913, 289, 290, 291, 292, 288, 300, 911, 
		293, 313, 312, 311, 310, 910, 306, 305, 304, 303, 
		302, 301, 307
	};
}
public class Skill : Element

SLOT

public class SLOT

cs
public class SLOT
{
	public const int toolbelt = 44; 
	public const int neck = 31; 
	public const int tool = 40; 

	public const int leg = 38; 
	public const int torso = 32; 

	public const int tool = 40; 
	public const int lightsource = 45; 

	public const int back = 33;

	public const int lightsource = 45; 
	public const int leg = 38; 

	public const int arm = 34;

	public const int hand = 35;

	public const int torso = 32; 
	public const int waist = 37; 

	public const int range = 41; 
	public const int finger = 36; 
	public const int neck = 31; 

	public const int foot = 39;

	public const int waist = 37; 
	public const int toolbelt = 44; 

	public const int ammo = 42;

	public const int finger = 36; 
	public const int range = 41; 

	public const int head = 30;

public class SLOT

cs

	public static readonly int[] IDS = new int[16]
	{
		44, 31, 38, 40, 33, 45, 34, 35, 32, 41, 
		39, 37, 42, 36, 30, 43
		40, 32, 45, 33, 38, 34, 35, 37, 36, 31, 
		39, 44, 42, 41, 30, 43
	};
}

SPELL

public class SPELL

cs
public class SPELL
{
	public const int ball_Holy = 50109; 
	public const int hand_Sound = 50407; 
	public const int arrow_Sound = 50507; 
	public const int funnel_Sound = 50607;

	public const int miasma_Sound = 50707;

public class SPELL

cs

	public const int sword_Sound = 51007;

	public const int miasma_Holy = 50709; 
	public const int ball_Nerve = 50108;

	public const int arrow_Holy = 50509; 
	public const int hand_Mind = 50404; 

	public const int bolt_Nerve = 50308;

public class SPELL

cs

	public const int miasma_Nerve = 50708;

	public const int weapon_Nerve = 50808; 
	public const int hand_Holy = 50409; 
	public const int bolt_Mind = 50304; 

	public const int bolt_Holy = 50309; 
	public const int weapon_Nerve = 50808; 

	public const int puddle_Nerve = 50908;

	public const int sword_Nerve = 51008;

	public const int funnel_Holy = 50609; 
	public const int ball_Holy = 50109; 

	public const int bolt_Mind = 50304; 
	public const int miasma_Holy = 50709; 

	public const int ball_Sound = 50107; 
	public const int bolt_Holy = 50309; 

	public const int weapon_Holy = 50809; 
	public const int hand_Holy = 50409; 

	public const int hand_Mind = 50404; 
	public const int arrow_Holy = 50509; 

	public const int arrow_Mind = 50504; 
	public const int funnel_Holy = 50609; 

	public const int funnel_Mind = 50604; 
	public const int ball_Mind = 50104; 

	public const int miasma_Mind = 50704; 
	public const int arrow_Sound = 50507; 

	public const int weapon_Mind = 50804; 
	public const int bolt_Poison = 50305; 

	public const int puddle_Mind = 50904; 
	public const int hand_Sound = 50407; 

	public const int sword_Mind = 51004; 
	public const int arrow_Mind = 50504; 

	public const int ball_Poison = 50105;

	public const int bolt_Poison = 50305; 
	public const int sword_Mind = 51004; 

	public const int hand_Poison = 50405;

	public const int arrow_Poison = 50505;

	public const int bolt_Sound = 50307; 
	public const int funnel_Poison = 50605;

	public const int miasma_Poison = 50705; 
	public const int weapon_Poison = 50805;

	public const int puddle_Poison = 50905;

public class SPELL

cs

	public const int ball_Nether = 50106;

	public const int puddle_Mind = 50904; 
	public const int weapon_Mind = 50804; 
	public const int miasma_Mind = 50704; 
	public const int bolt_Nether = 50306;

	public const int hand_Nether = 50406;

public class SPELL

cs

	public const int weapon_Nether = 50806;

	public const int funnel_Mind = 50604; 
	public const int puddle_Nether = 50906;

	public const int sword_Nether = 51006;

	public const int miasma_Poison = 50705; 
	public const int ball_Sound = 50107; 

	public const int puddle_Holy = 50909; 
	public const int bolt_Sound = 50307; 

	public const int arrow_Acid = 50513; 
	public const int weapon_Holy = 50809; 

	public const int ball_Chaos = 50110; 
	public const int hand_Acid = 50413; 
	public const int sword_Holy = 51009; 

	public const int weapon_Acid = 50813;

public class SPELL

cs

	public const int hand_Impact = 50415;

	public const int sword_Holy = 51009; 
	public const int funnel_Acid = 50613;

	public const int hand_Acid = 50413; 
	public const int arrow_Acid = 50513; 
	public const int sword_Darkness = 51003; 
	public const int ball_Chaos = 50110; 

	public const int bolt_Chaos = 50310;

public class SPELL

cs

	public const int funnel_Magic = 50611;

	public const int ball_Mind = 50104; 
	public const int miasma_Magic = 50711;

	public const int weapon_Magic = 50811; 
	public const int puddle_Magic = 50911;

	public const int sword_Magic = 51011;

public class SPELL

cs

	public const int bolt_Acid = 50313;

	public const int weapon_Magic = 50811; 
	public const int puddle_Holy = 50909; 

	public const int sword_Darkness = 51003; 
	public const int puddle_Darkness = 50903; 

	public const int arrow_Fire = 50500;

	public const int weapon_Darkness = 50803; 
	public const int miasma_Darkness = 50703; 

	public const int SpHealHeavy = 8401;

public class SPELL

cs

	public const int SpMutation = 8380;

	public const int puddle_Darkness = 50903; 
	public const int weapon_Darkness = 50803; 

	public const int SpSpeedDown = 8710;

	public const int SpInvisibility = 8775;

	public const int hand_Fire = 50400; 
	public const int funnel_Fire = 50600;

	public const int miasma_Fire = 50700;

public class SPELL

cs

	public const int funnel_Darkness = 50603;

	public const int miasma_Darkness = 50703; 
	public const int hand_Fire = 50400; 
	public const int bolt_Fire = 50300; 

	public const int SpTelepathy = 8770;

	public const int bolt_Fire = 50300; 
	public const int puddle_Void = 50916; 

	public const int ball_Fire = 50100; 
	public const int SpDrawBacker = 9503; 

	public const int SpSeeInvisible = 8776;

public class SPELL

cs

	public const int SpMoonSpear = 9155;

	public const int SpMoonArrow = 9156; 
	public const int SpExterminate = 9160;

	public const int SpShutterHex = 9200;

public class SPELL

cs

	public const int SpDrawMetal = 9502;

	public const int SpDrawBacker = 9503; 
	public const int puddle_Void = 50916; 
	public const int ball_Fire = 50100; 

	public const int sword_Void = 51016;

	public static readonly int[] IDS = new int[248] 
	public static readonly int[] IDS = new int[249] 
	{
		50109, 50407, 50507, 50607, 50707, 50807, 50907, 51007, 50709, 50108, 
		50509, 50308, 50408, 50508, 50608, 50708, 50808, 50409, 50309, 50908, 
		51008, 50609, 50304, 50107, 50809, 50404, 50504, 50604, 50704, 50804, 
		50904, 51004, 50105, 50305, 50405, 50505, 50307, 50605, 50805, 50905, 
		51005, 50106, 50306, 50406, 50506, 50606, 50706, 50806, 50906, 51006, 
		50705, 50909, 50513, 50110, 50813, 50913, 51013, 50114, 50314, 50414, 
		50607, 50707, 50807, 50907, 51007, 50108, 50404, 50308, 50408, 50508, 
		50608, 50708, 50304, 50808, 50908, 51008, 50109, 50709, 50309, 50409, 
		50509, 50609, 50104, 50507, 50305, 50407, 50504, 50105, 51004, 50405, 
		50505, 50605, 50705, 50805, 50905, 51005, 50106, 50904, 50804, 50704, 
		50306, 50406, 50506, 50606, 50706, 50806, 50604, 50906, 51006, 50107, 
		50307, 50809, 50413, 51009, 50813, 50913, 51013, 50114, 50314, 50414, 
		50514, 50614, 50714, 50814, 50914, 51014, 50115, 50713, 50315, 50515,
		50615, 50715, 50815, 50915, 51015, 50116, 50316, 50416, 50516, 50616,
		50716, 50816, 50415, 51009, 50613, 50413, 50310, 50410, 50510, 50610, 
		50710, 50810, 50910, 51010, 50111, 50311, 50411, 50511, 50611, 50104, 
		50711, 50911, 51011, 50112, 50312, 50412, 50512, 50612, 50712, 50812, 
		50912, 51012, 50113, 50313, 50811, 51003, 50500, 50803, 8401, 8402, 
		8403, 8404, 8405, 8406, 8430, 8450, 8470, 8471, 8480, 8490, 
		8491, 8500, 8501, 8502, 8503, 8504, 8506, 8507, 8510, 8550, 
		8555, 8700, 8702, 8704, 8705, 8706, 8707, 8400, 8708, 8390, 
		8300, 7001, 7002, 7003, 7004, 7005, 7006, 7007, 7008, 7800, 
		8200, 8201, 8202, 8220, 8221, 8230, 8232, 8240, 8241, 8250, 
		8251, 8255, 8256, 8260, 8280, 8281, 8284, 8285, 8286, 8288, 
		8380, 50903, 8710, 8775, 50600, 50700, 50800, 50900, 51000, 50101, 
		50301, 50401, 50501, 50601, 50701, 50801, 50901, 51001, 50102, 50302, 
		50402, 50502, 50602, 50702, 50802, 50902, 51002, 50103, 50303, 50403, 
		50503, 50603, 50703, 50400, 8770, 50300, 50100, 8776, 8780, 8790, 
		8791, 8792, 8800, 8801, 9000, 9001, 9002, 9003, 9004, 9005, 
		9006, 9007, 9008, 9009, 9010, 9050, 9051, 9150, 9151, 9155, 
		9160, 9200, 9500, 9501, 9502, 9503, 50916, 51016
		50716, 50816, 50415, 50613, 50513, 51003, 50110, 50310, 50410, 50510, 
		50610, 50710, 50810, 50910, 51010, 50111, 50311, 50411, 50511, 50611, 
		50711, 50811, 50911, 51011, 50112, 50312, 50412, 50512, 50612, 50712, 
		50812, 50912, 51012, 50113, 50313, 50909, 50903, 50500, 50703, 8401, 
		8402, 8403, 8404, 8405, 8406, 8430, 8450, 8470, 8471, 8480, 
		8490, 8491, 8500, 8501, 8502, 8503, 8504, 8506, 8507, 8510, 
		8550, 8555, 8700, 8702, 8704, 8705, 8706, 8707, 8400, 8708, 
		8390, 8300, 7001, 7002, 7003, 7004, 7005, 7006, 7007, 7008, 
		7800, 8200, 8201, 8202, 8220, 8221, 8230, 8232, 8240, 8241, 
		8250, 8251, 8255, 8256, 8260, 8280, 8281, 8284, 8285, 8286, 
		8288, 8380, 50803, 8710, 8775, 50400, 50600, 50700, 50800, 50900, 
		51000, 50101, 50301, 50401, 50501, 50601, 50701, 50801, 50901, 51001, 
		50102, 50302, 50402, 50502, 50602, 50702, 50802, 50902, 51002, 50103, 
		50303, 50403, 50503, 50603, 50300, 8770, 50916, 9503, 8776, 8780, 
		8790, 8791, 8792, 8800, 8801, 9000, 9001, 9002, 9003, 9004, 
		9005, 9006, 9007, 9008, 9009, 9010, 9050, 9051, 9150, 9151, 
		9155, 9156, 9160, 9200, 9500, 9501, 9502, 50100, 51016
	};
}
public class Spell : Ability

Trait

public void OnBarter()

cs
	owner.c_dateStockExpire = EClass.world.date.GetRaw(24 * RestockDay);
	owner.isRestocking = true;
	t.things.DestroyAll((Thing _t) => _t.GetInt(101) != 0);
	foreach (Thing thing8 in t.things) 
	foreach (Thing thing9 in t.things) 
	{
		thing8.invX = -1; 
		thing9.invX = -1; 
	}
	switch (ShopType)
	{

public void OnBarter()

cs
		{
			break;
		}
		int num3 = 0; 
		foreach (Thing thing9 in c_copyContainer.things) 
		int num4 = 0; 
		foreach (Thing thing10 in c_copyContainer.things) 
		{
			if (!owner.trait.CanCopy(thing9)) 
			if (!owner.trait.CanCopy(thing10)) 
			{
				continue;
			}
			Thing thing4 = thing9.Duplicate(1); 
			thing4.isStolen = false; 
			thing4.isCopy = true; 
			thing4.c_priceFix = 0; 
			foreach (Element item in thing4.elements.dict.Values.Where((Element e) => e.HasTag("noInherit")).ToList()) 
			Thing thing5 = thing10.Duplicate(1); 
			thing5.isStolen = false; 
			thing5.isCopy = true; 
			thing5.c_priceFix = 0; 
			foreach (Element item in thing5.elements.dict.Values.Where((Element e) => e.HasTag("noInherit")).ToList()) 
			{
				thing4.elements.Remove(item.id); 
				thing5.elements.Remove(item.id); 
			}
			int num4 = 1; 
			int num5 = 1; 
			switch (owner.trait.CopyShop)
			{
			case CopyShopType.Item:
			{
				num4 = (1000 + owner.c_invest * 100) / (thing4.GetPrice(CurrencyType.Money, sell: false, PriceType.CopyShop) + 50); 
				num5 = (1000 + owner.c_invest * 100) / (thing5.GetPrice(CurrencyType.Money, sell: false, PriceType.CopyShop) + 50); 
				int[] array = new int[4] { 701, 704, 703, 702 };
				foreach (int ele in array)
				{
					if (thing4.HasElement(ele)) 
					if (thing5.HasElement(ele)) 
					{
						num4 = 1; 
						num5 = 1; 
					}
				}
				break;
			}
			case CopyShopType.Spellbook:
				thing4.c_charges = thing9.c_charges; 
				thing5.c_charges = thing10.c_charges; 
				break;
			}
			if (num4 > 1 && thing4.trait.CanStack) 
			if (num5 > 1 && thing5.trait.CanStack) 
			{
				thing4.SetNum(num4); 
				thing5.SetNum(num5); 
			}
			AddThing(thing4); 
			num3++; 
			if (num3 > owner.trait.NumCopyItem) 
			AddThing(thing5); 
			num4++; 
			if (num4 > owner.trait.NumCopyItem) 
			{
				break;
			}

public void OnBarter()

cs
		break;
	case ShopType.RedBook:
	{
		for (int num5 = 0; num5 < 30; num5++) 
		for (int num3 = 0; num3 < 30; num3++) 
		{
			AddThing(ThingGen.CreateFromCategory((EClass.rnd(2) == 0) ? "_book" : "book"));
		}

public void OnBarter()

cs
		AddThing(TraitSeed.MakeSeed("carrot")).SetNum(4 + EClass.rnd(4));
		AddThing(TraitSeed.MakeSeed("potato")).SetNum(4 + EClass.rnd(4));
		AddThing(TraitSeed.MakeSeed("corn")).SetNum(4 + EClass.rnd(4));
		for (int num6 = 0; num6 < EClass.rnd(3) + 1; num6++) 
		for (int num7 = 0; num7 < EClass.rnd(3) + 1; num7++) 
		{
			Add("462", 1, 0);
		}
		for (int num7 = 0; num7 < EClass.rnd(3) + 1; num7++) 
		for (int num8 = 0; num8 < EClass.rnd(3) + 1; num8++) 
		{
			Add("1167", 1, 0);
		}

public void OnBarter()

cs
				if (num2)
				{
					Add("littleball", 10, 0);
					if (owner.Chara.affinity.CanGiveCard()) 
					{ 
						if (!owner.Chara.HasElement(287)) 
						{ 
							owner.Chara.elements.SetBase(287, (!EClass.debug.enable) ? 1 : 50); 
						} 
						for (int l = 0; l < 20; l++) 
						{ 
							owner.Chara.ModExp(287, 1000); 
						} 
						Thing thing3 = CraftUtil.MakeLoveLunch(owner.Chara); 
						thing3.elements.SetBase(1229, 1); 
						AddThing(thing3); 
					} 
					break;
				}
				for (int l = 0; l < 10; l++) 
				for (int m = 0; m < 10; m++) 
				{
					Thing thing3 = ThingGen.Create(EClass._zone.IsFestival ? "1123" : ((EClass.rnd(3) == 0) ? "1169" : "1160")); 
					thing3.DyeRandom(); 
					AddThing(thing3); 
					Thing thing4 = ThingGen.Create(EClass._zone.IsFestival ? "1123" : ((EClass.rnd(3) == 0) ? "1169" : "1160")); 
					thing4.DyeRandom(); 
					AddThing(thing4); 
				}
				if (EClass._zone is Zone_Exile)
				{
					for (int m = 0; m < 30; m++) 
					for (int n = 0; n < 30; n++) 
					{
						Add("1235", 1, -1);
						Add("1236", 1, -1);

public void OnBarter()

cs
					continue;
				}
				string[] recipeKey = item3.row.recipeKey;
				for (int n = 0; n < recipeKey.Length; n++) 
				for (int num6 = 0; num6 < recipeKey.Length; num6++) 
				{
					if (recipeKey[n] == ShopType.ToString()) 
					if (recipeKey[num6] == ShopType.ToString()) 
					{
						NoRestock(ThingGen.CreateRecipe(item3.id));
						break;

public void OnBarter()

cs
			{
			case ShopType.Moyer:
			{
				for (int num10 = 1; num10 <= 12; num10++) 
				for (int num11 = 1; num11 <= 12; num11++) 
				{
					AddAdvWeek(num10); 
					AddAdvWeek(num11); 
				}
				break;
			}
			case ShopType.StrangeGirl:
			{
				int num11 = (EClass.debug.enable ? 20 : (EClass._zone.development / 10)); 
				if (num11 > 0) 
				int num12 = (EClass.debug.enable ? 20 : (EClass._zone.development / 10)); 
				if (num12 > 0) 
				{
					Add("syringe_gene", num11, 0); 
					Add("syringe_gene", num12, 0); 
					Add("diary_little", 1, 0);
				}
				if (num11 > 10) 
				if (num12 > 10) 
				{
					Add("syringe_heaven", num11 / 5, 0); 
					Add("syringe_heaven", num12 / 5, 0); 
				}
				break;
			}

public void OnBarter()

cs
					Add("ticket_armpillow", 1, 0);
					Add("ticket_champagne", 1, 0);
				}
				for (int num8 = 0; num8 < 3; num8++) 
				for (int num9 = 0; num9 < 3; num9++) 
				{
					if (EClass.rnd(5) == 0)
					{
						TreasureType treasureType = ((EClass.rnd(10) == 0) ? TreasureType.BossNefia : ((EClass.rnd(10) == 0) ? TreasureType.Map : TreasureType.RandomChest));
						int num9 = EClass.rnd(EClass.rnd(ShopLv + (EClass.debug.enable ? 200 : 50)) + 1) + 1; 
						Thing thing5 = ThingGen.Create(treasureType switch
						int num10 = EClass.rnd(EClass.rnd(ShopLv + (EClass.debug.enable ? 200 : 50)) + 1) + 1; 
						Thing thing6 = ThingGen.Create(treasureType switch
						{
							TreasureType.Map => "chest_treasure", 
							TreasureType.BossNefia => "chest_boss", 
							_ => "chest3", 
						});
						thing5.c_lockedHard = true; 
						thing5.c_lockLv = num9; 
						thing5.c_priceAdd = 2000 + num9 * 250 * ((treasureType == TreasureType.RandomChest) ? 1 : 5); 
						thing5.c_revealLock = true; 
						ThingGen.CreateTreasureContent(thing5, num9, treasureType, clearContent: true); 
						AddThing(thing5); 
						thing6.c_lockedHard = true; 
						thing6.c_lockLv = num10; 
						thing6.c_priceAdd = 2000 + num10 * 250 * ((treasureType == TreasureType.RandomChest) ? 1 : 5); 
						thing6.c_revealLock = true; 
						ThingGen.CreateTreasureContent(thing6, num10, treasureType, clearContent: true); 
						AddThing(thing6); 
					}
				}
				break;

public void OnBarter()

cs
			ShopType shopType = ShopType;
			if (shopType == ShopType.General || shopType == ShopType.Food)
			{
				for (int num12 = 0; num12 < (EClass.debug.enable ? 3 : 3); num12++) 
				for (int num13 = 0; num13 < (EClass.debug.enable ? 3 : 3); num13++) 
				{
					if (EClass.rnd(3) == 0)
					{

public void OnBarter()

cs
				}
				AddThing(ThingGen.CreateScroll(8780, EClass.rndHalf(5)));
			}
			foreach (Thing thing10 in t.things) 
			foreach (Thing thing11 in t.things) 
			{
				thing10.c_idBacker = 0; 
				thing11.c_idBacker = 0; 
				if (ShopType != ShopType.Copy)
				{
					thing10.TryMakeRandomItem(ShopLv); 
					if (thing10.Num == 1) 
					thing11.TryMakeRandomItem(ShopLv); 
					if (thing11.Num == 1) 
					{
						thing10.SetNum(thing10.trait.DefaultStock); 
						thing11.SetNum(thing11.trait.DefaultStock); 
					}
					if (thing10.trait is TraitFoodMeal) 
					if (thing11.trait is TraitFoodMeal) 
					{
						CraftUtil.MakeDish(thing10, ShopLv, owner.Chara); 
						CraftUtil.MakeDish(thing11, ShopLv, owner.Chara); 
					}
					if (thing10.IsFood && owner.id == "rodwyn") 
					if (thing11.IsFood && owner.id == "rodwyn") 
					{
						SourceElement.Row row = EClass.sources.elements.rows.Where((SourceElement.Row e) => !e.foodEffect.IsEmpty() && e.category != "feat" && e.chance > 0).RandomItem();
						thing10.elements.SetBase(row.id, 10 + EClass.rnd(10)); 
						thing11.elements.SetBase(row.id, 10 + EClass.rnd(10)); 
					}
				}
				if (CurrencyType == CurrencyType.Casino_coin)
				{
					thing10.noSell = true; 
					thing11.noSell = true; 
				}
				if (Guild.Thief.IsCurrentZone)
				{
					thing10.isStolen = true; 
					thing11.isStolen = true; 
				}
				if (!(thing10.trait is TraitErohon)) 
				if (!(thing11.trait is TraitErohon)) 
				{
					thing10.c_IDTState = 0; 
					thing11.c_IDTState = 0; 
				}
				if (CurrencyType == CurrencyType.Money && (thing10.category.IsChildOf("meal") || thing10.category.IsChildOf("preserved")) && thing10.id != "ration") 
				if (CurrencyType == CurrencyType.Money && (thing11.category.IsChildOf("meal") || thing11.category.IsChildOf("preserved")) && thing11.id != "ration") 
				{
					thing10.c_priceFix = -70; 
					thing11.c_priceFix = -70; 
				}
				if (thing10.trait is TraitErohon) 
				if (thing11.trait is TraitErohon) 
				{
					thing10.c_IDTState = 5; 
					thing11.c_IDTState = 5; 
				}
				if (thing10.IsContainer && !thing10.c_revealLock) 
				if (thing11.IsContainer && !thing11.c_revealLock) 
				{
					thing10.RemoveThings(); 
					thing11.RemoveThings(); 
					t.c_lockLv = 0;
				}
			}

public void OnBarter()

cs
			{
				return;
			}
			int num13 = t.things.width * 10; 
			if (t.things.Count > num13) 
			int num14 = t.things.width * 10; 
			if (t.things.Count > num14) 
			{
				int num14 = t.things.Count - num13; 
				for (int num15 = 0; num15 < num14; num15++) 
				int num15 = t.things.Count - num14; 
				for (int num16 = 0; num16 < num15; num16++) 
				{
					t.things.LastItem().Destroy();
				}

public void OnBarter()

cs
			Thing Add(string id, int a, int idSkin)
			{
				CardBlueprint.SetNormalRarity();
				Thing thing7 = ThingGen.Create(id, -1, ShopLv).SetNum(a); 
				thing7.idSkin = ((idSkin == -1) ? EClass.rnd(thing7.source.skins.Length + 1) : idSkin); 
				return t.AddThing(thing7); 
				Thing thing8 = ThingGen.Create(id, -1, ShopLv).SetNum(a); 
				thing8.idSkin = ((idSkin == -1) ? EClass.rnd(thing8.source.skins.Length + 1) : idSkin); 
				return t.AddThing(thing8); 
			}
			void AddAdvWeek(int i)
			{
				Thing thing6 = ThingGen.CreateRedBook("advweek_" + i); 
				thing6.c_priceFix = -90; 
				AddThing(thing6); 
				Thing thing7 = ThingGen.CreateRedBook("advweek_" + i); 
				thing7.c_priceFix = -90; 
				AddThing(thing7); 
			}
			Thing AddThing(Thing _t)
			{

Zone

public void TryGenerateOre()

cs

	public Chara TryGenerateEvolved(bool force = false, Point p = null)
	{
		if (!force && EvolvedChance <= EClass.rndf(1f)) 
		float num = EvolvedChance * (EClass.pc.HasElement(1270) ? 1.1f : 1f); 
		if (!force && num <= EClass.rndf(1f)) 
		{
			return null;
		}

public Chara TryGenerateEvolved(bool force = false, Point p = null)

cs

	public void TryGenerateBigDaddy()
	{
		if (!(BigDaddyChance <= EClass.rndf(1f))) 
		if (!(BigDaddyChance * (EClass.pc.HasElement(1270) ? 1.1f : 1f) <= EClass.rndf(1f))) 
		{
			int num = DangerLv * 125 / 100;
			if (num >= 30)

public void TryGenerateBigDaddy()

cs
					lv = num
				});
			}
			Chara t = CharaGen.Create("big_daddy"); 
			EClass._zone.AddCard(t, GetSpawnPos(SpawnPosition.Random, 10000)); 
			Chara chara = CharaGen.Create("big_daddy"); 
			if (EClass.pc.HasElement(1270)) 
			{ 
				chara.SetHostility(Hostility.Friend); 
			} 
			else if (EClass.pc.HasElement(1271)) 
			{ 
				chara.SetHostility(Hostility.Enemy); 
			} 
			EClass._zone.AddCard(chara, GetSpawnPos(SpawnPosition.Random, 10000)); 
			Msg.Say("sign_bigdaddy");
		}
	}

	public void TryGenerateShrine()
	{
		float num = ShrineChance * (EClass.pc.HasElement(1270) ? 1.1f : 1f); 
		for (int i = 0; i < 3; i++)
		{
			Rand.SetSeed(base.uid + i);
			if (ShrineChance <= EClass.rndf(1f)) 
			if (num <= EClass.rndf(1f)) 
			{
				continue;
			}

public Chara SpawnMob(Point pos = null, SpawnSetting setting = null)

cs
		num3 = (50 + cardRow.LV) * Mathf.Max(1, (num - 1) / 50);
	}
	num3 += DangerLvBoost;
	if (setting.rarity == Rarity.Random) 
	if (setting.rarity == Rarity.Random && cardRow.quality == 0) 
	{
		if (EClass.rnd(100) == 0) 
		if (EClass.rnd(EClass.pc.HasElement(1271) ? 80 : 100) == 0) 
		{
			cardBlueprint.rarity = Rarity.Legendary;
			num3 = num3 * 125 / 100;

public Chara SpawnMob(Point pos = null, SpawnSetting setting = null)

cs
		Hostility c_originalHostility = (chara.hostility = setting.forcedHostility.Value);
		chara.c_originalHostility = c_originalHostility;
	}
	else
	{ 
		switch (chara.id) 
		{ 
		case "santa": 
		case "silverwolf": 
		case "twintail": 
		case "test17": 
			if (EClass.pc.HasElement(1270)) 
			{ 
				chara.SetHostility(Hostility.Friend); 
			} 
			else if (EClass.pc.HasElement(1271)) 
			{ 
				chara.SetHostility(Hostility.Enemy); 
			} 
			break; 
		} 
	} 
	if (setting.isBoss)
	{
		chara.c_bossType = BossType.Boss;