Elin:解析/信仰
このページには正規のプレイによって得られた情報ではなく、Elinのデータ解析・デバッグモード・内部ファイル閲覧などによって得た情報が掲載されています。 ゲームの重大なネタバレや、プレイの楽しみを損なう情報が含まれている可能性があります。 閲覧は自己責任でお願いするとともに、通常ページに解析ページへのリンクを貼ることはお控えください。 また、このページの情報をWikiの他のページに記載する際は計算コードなどをそのまま掲示するのではなく、コードが読めない人にもわかりやすいように内容を要約して書いていただけると幸いです。 |
信仰心と捧げ物
Gift at which piety level?
int num = EClass.pc.Evalue(85);
if (giftRank == 0 && (num >= 15 || EClass.debug.enable))
{
Talk("pet");
Chara chara = CharaGen.Create(source.rewards[0]);
EClass._zone.AddCard(chara, point);
chara.MakeAlly();
chara.PlayEffect("aura_heaven");
giftRank = 1;
return true;
}
if (source.rewards.Length >= 2 && giftRank == 1 && (num >= 30 || EClass.debug.enable))
{
Talk("gift");
string[] array = source.rewards[1].Split('|');
string[] array2 = array;
foreach (string text in array2)
{
Reforge(text, point, text == array[0]);
}
giftRank = 2;
return true;
}
- As of EA23.61, there are two Gift ranks for each god, and each of them is hardcoded at piety level 15 and 30. You will recieve a gift after reach each of these levels then manually pray to the god.
What messages are shown at which threshold?
int num = Mathf.Max(c.Evalue(306), 1);
int num2 = 4;
if (orCreateElement.vBase >= num)
{
c.elements.SetBase(orCreateElement.id, num);
}
else
{
num2 = Mathf.Clamp(orCreateElement.vBase * 100 / num / 25, 0, 3);
}
if (num2 == 4 || orCreateElement.Value != value)
{
Msg.Say("piety" + num2, c, c.faith.TextGodGender);
}
- The above code controls the faith message when your piety levels up.
- There are 5 messages in all, determined by num2, ranging from (0~4).
- num2 will be calculated using your (Piety level / Faith level) * 4,rounded down to the nearest integer.
- So if <25%, num2 = 0; 25%~50%, num2 = 1, 50%~75%, num2 = 2, >75%, num2 = 3.
- If you are already at the maximum piety level, num2 = 4
- Then depend on num2, different message will be played.
- If you are at maximum piety (num2 = 4), then a message will always be shown.
What message is shown at which offer value?
public int GetOfferingValue(Thing t, int num = -1)
{
if (num == -1)
{
num = t.Num;
}
int num2 = 0;
if (t.source._origin == "meat")
{
num2 = Mathf.Clamp(t.SelfWeight / 10, 1, 1000);
if (t.refCard == null)
{
num2 /= 10;
}
}
else
{
string[] cat_offer = source.cat_offer;
foreach (string key in cat_offer)
{
if (t.category.IsChildOf(key))
{
num2 = Mathf.Clamp(t.SelfWeight / 10, 50, 1000);
num2 *= EClass.sources.categories.map[key].offer / 100;
break;
}
}
}
if (num2 == 0)
{
return 0;
}
if (t.IsDecayed)
{
num2 /= 10;
}
num2 = num2 * (100 + Mathf.Min(t.LV * 2, 100) + (t.HasElement(757) ? 50 : 0)) / 100;
return Mathf.Max(num2, 1) * num;
}
- The offer value is calculated with the following
- num is the number of items you offered.
- num2 will be the offering value per item, with minimum value of "1".
- If the item is meat, then;
- The weight of meat is divided by 10 (to know that 1000 weight = 1.0s), with minimum value of 1 and maximum value of 1000.
- If this meat is unlabelled (i.e. not being a meat drop by entity) the value is further divided by 10.
- Because the divide operator is rounding down to nearest int, this means it is possible to obtain 0 offer value if you are offering unlabelled meat lower than 0.1s.
- If the item is of category a god will take (not meat), then:
- The weight of item is divided by 10, but with a minimum value of 50 and maximum value of 1000.
- Therefore, the weight of item will still count, but anything less than 0.5s will count as 0.5s.
- The number is then multiplied by the category value.
- As of EA23.61, the multipler apply to instrument(*5), rod (*3), catalyst (*3), ancient book (*5), spell book (*4), skill book (*10), map (*4).
- The weight of item is divided by 10, but with a minimum value of 50 and maximum value of 1000.
- If the item is decayed (rotten), the offer value is further divided by 10.
- Because the decayed check is done after the 0 offer value check, you won't get 0 offer value if your item is only rotten, but lablled.
- For example a labelled, 0.7s non-rotten meat will generate a offer value of 70.
- The final value is modified by the following:
- The offer value will increase by 2% per each level of the item, at most 100% (for LV 50). (See in resource/things/LV. Meat and most items are LV 1, most equipments range from 10-20, rarest at lv 60)
- A further 50% additive modifier is applied if "Just cooked" state is on the offering item.
public void _OnOffer(Chara c, Thing t, int takeoverMod = 0)
{
bool @bool = t.GetBool(115);
int offeringValue = Deity.GetOfferingValue(t, t.Num);
offeringValue = offeringValue * (c.HasElement(1228) ? 130 : 100) / 100;
if (takeoverMod == 0)
{
if (offeringValue >= 200)
{
Msg.Say("god_offer1", t);
EClass.pc.faith.Talk("offer");
}
else if (offeringValue >= 100)
{
Msg.Say("god_offer2", t);
}
else if (offeringValue >= 50)
{
Msg.Say("god_offer3", t);
}
else
{
Msg.Say("god_offer4", t);
}
}
else
{
Msg.Say("god_offer1", t);
offeringValue += Deity.GetOfferingValue(t, 1) * takeoverMod;
}
int num = Mathf.Max(c.Evalue(306), 1);
Element orCreateElement = c.elements.GetOrCreateElement(85);
int value = orCreateElement.Value;
c.elements.ModExp(orCreateElement.id, offeringValue * 2 / 3);
- The previously calculated offeringValue will return to this function, then the message displayed will be determined.
- But first, if the character is demigod, the offeringValue will be further offset by 30%.
- The offering value threshold for each message is 200, 100, 50.
- So a piece of meat of 2.2s should generate the best possible message...but a 1.7s meat will not (tested).
- HOWEVER, the experience gained towards Piety is only calculated at two-thirds of the offering value.
- Thus to increase piety level by 1, you need to offer items with 1500 offer value, thus gaining 1000 piety experiences.
Piety level up
if (element.vExp >= element.ExpToNext)
{
int num = element.vExp - element.ExpToNext;
int vBase = element.vBase;
ModBase(ele, 1);
OnLevelUp(element, vBase);
element.vExp = Mathf.Clamp(num / 2, 0, element.ExpToNext / 2);
if (element.vTempPotential > 0)
{
element.vTempPotential -= element.vTempPotential / 4 + EClass.rnd(5) + 5;
if (element.vTempPotential < 0)
{
element.vTempPotential = 0;
}
}
else if (element.vTempPotential < 0)
{
element.vTempPotential += -element.vTempPotential / 4 + EClass.rnd(5) + 5;
if (element.vTempPotential > 0)
{
element.vTempPotential = 0;
}
}
}
- This, in fact, apply to all level ups.
- If you increased your piety level, the remaining experiences will be cut in half, then at most half to the next level can be retained.
- So if you gained 3000 piety exp, you leveled up from empty, remaining is 2000 exp, but you can only retain 500 exp (half to the next level)
- If you increased your piety level, the remaining experiences will be cut in half, then at most half to the next level can be retained.
エヘカトル流魔術
エヘカトルの信仰効果によるマナとスタミナ消費のランダム化に関するコードは以下のようになっています。
if (a < 0 && BaseStats.CC.HasElement(1330, 1)) { a = -EClass.rnd(-a * 130 / 100 + 2); }
つまり、マナやスタミナを消費する際、 0~(元の消費量の1.3倍+2)の範囲で乱数を取った値が新しい消費量になります。
例えば、ある魔法の消費MPが40だった場合、消費量は0~54の範囲に乱数化されます。