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

Public Member Functions

void Remove (Chara c, DNA item)
 
int GetTotalCost ()
 
int GetGeneSlot (Chara c)
 

Public Attributes

List< DNAitems = new List<DNA>()
 
int inferior
 

Additional Inherited Members

- 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)
 
- 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 4 of file CharaGenes.cs.

Member Function Documentation

◆ GetGeneSlot()

int CharaGenes.GetGeneSlot ( Chara  c)
inline

Definition at line 30 of file CharaGenes.cs.

31 {
32 int num = 0;
33 foreach (DNA item in items)
34 {
35 int num2 = item.slot;
36 if (num2 > 1 && c.HasElement(1237))
37 {
38 num2--;
39 }
40 num += num2;
41 }
42 return num;
43 }
bool HasElement(int ele, int req=1)
Definition: Card.cs:5214
List< DNA > items
Definition: CharaGenes.cs:7
Definition: DNA.cs:8

References item, and items.

◆ GetTotalCost()

int CharaGenes.GetTotalCost ( )
inline

Definition at line 20 of file CharaGenes.cs.

21 {
22 int num = 0;
23 foreach (DNA item in items)
24 {
25 num += item.cost;
26 }
27 return num;
28 }

References item, and items.

Referenced by WindowCharaMini.Refresh().

◆ Remove()

void CharaGenes.Remove ( Chara  c,
DNA  item 
)
inline

Definition at line 12 of file CharaGenes.cs.

13 {
14 items.Remove(item);
15 c.feat += item.cost;
16 item.Apply(c, reverse: true);
17 c.Refresh();
18 }
void Refresh(bool calledRecursive=false)
Definition: Chara.cs:1504

References item, items, and Chara.Refresh().

Member Data Documentation

◆ inferior

int CharaGenes.inferior

Definition at line 10 of file CharaGenes.cs.

Referenced by DNA.Apply(), and WindowCharaMini.Refresh().

◆ items

List<DNA> CharaGenes.items = new List<DNA>()

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