Elin Decompiled Documentation EA 23.102 Nightly
Loading...
Searching...
No Matches
CalcPlat Class Reference
Inheritance diagram for CalcPlat:
EClass

Static Public Member Functions

static int Learn (Chara c, Element e)
 
static int Train (Chara c, Element _e)
 
- Static Public Member Functions inherited from EClass
static int rnd (int a)
 
static int curve (int a, int start, int step, int rate=75)
 
static int rndHalf (int a)
 
static float rndf (float a)
 
static int rndSqrt (int a)
 
static void Wait (float a, Card c)
 
static void Wait (float a, Point p)
 
static int Bigger (int a, int b)
 
static int Smaller (int a, int b)
 

Additional Inherited Members

- Static Public Attributes inherited from EClass
static Core core
 
- Properties inherited from EClass
static Game game [get]
 
static bool AdvMode [get]
 
static Player player [get]
 
static Chara pc [get]
 
static UI ui [get]
 
static Map _map [get]
 
static Zone _zone [get]
 
static FactionBranch Branch [get]
 
static FactionBranch BranchOrHomeBranch [get]
 
static Faction Home [get]
 
static Faction Wilds [get]
 
static Scene scene [get]
 
static BaseGameScreen screen [get]
 
static GameSetting setting [get]
 
static GameData gamedata [get]
 
static ColorProfile Colors [get]
 
static World world [get]
 
static SourceManager sources [get]
 
static SourceManager editorSources [get]
 
static SoundManager Sound [get]
 
static CoreDebug debug [get]
 

Detailed Description

Definition at line 3 of file CalcPlat.cs.

Member Function Documentation

◆ Learn()

static int CalcPlat.Learn ( Chara  c,
Element  e 
)
inlinestatic

Definition at line 5 of file CalcPlat.cs.

6 {
7 int num = Mathf.Max(1, e.CostLearn * (c.HasElement(1202) ? 80 : 100) / 100);
8 if (e.source.tag.Contains("guild") && Guild.Current.relation.rank < 2)
9 {
10 return num * 2;
11 }
12 return num;
13 }
bool HasElement(int ele, int req=1)
Definition: Card.cs:5214
SourceElement.Row source
Definition: ELEMENT.cs:263
virtual int CostLearn
Definition: ELEMENT.cs:304
FactionRelation relation
Definition: FACTION.cs:124
Definition: Guild.cs:2
static Guild Current
Definition: Guild.cs:4

References Element.CostLearn, Guild.Current, Card.HasElement(), FactionRelation.rank, Faction.relation, and Element.source.

◆ Train()

static int CalcPlat.Train ( Chara  c,
Element  _e 
)
inlinestatic

Definition at line 15 of file CalcPlat.cs.

16 {
17 Element element = c.elements.GetElement(_e.id);
18 if (element.vTempPotential >= 1000)
19 {
20 return 0;
21 }
22 int num = Mathf.Max(1, element.CostTrain * (c.HasElement(1202) ? 80 : 100) / 100);
23 if (element.source.tag.Contains("guild") && Guild.Current.relation.rank < 2)
24 {
25 return num * 2;
26 }
27 return num;
28 }
ElementContainerCard elements
Definition: Card.cs:37
Element GetElement(string alias)
int id
Definition: ELEMENT.cs:240
virtual int CostTrain
Definition: ELEMENT.cs:302
int vTempPotential
Definition: ELEMENT.cs:248

References Element.CostTrain, Guild.Current, Card.elements, ElementContainer.GetElement(), Card.HasElement(), Element.id, FactionRelation.rank, Faction.relation, Element.source, and Element.vTempPotential.


The documentation for this class was generated from the following file: