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

Static Public Member Functions

static int Negotiate (int a, float mod=1.5f)
 
static int Invest (int a, float mod=2f)
 
static int Meal (Chara c)
 
static int Heal (Chara c)
 
static int Picklock (Chara c, Thing t)
 
static int Identify (Chara c, bool superior)
 
static int Revive (Chara c)
 
static int BuySlave (Chara c)
 
static int SellSlave (Chara c)
 
static int Whore (Chara seller, Chara buyer)
 
static int InvestShop (Chara c, Chara tc)
 
static int InvestZone (Chara c)
 
- 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 CalcMoney.cs.

Member Function Documentation

◆ BuySlave()

static int CalcMoney.BuySlave ( Chara  c)
inlinestatic

Definition at line 40 of file CalcMoney.cs.

41 {
42 return Negotiate((c.LV + 5) * (c.LV + 5) * 20 + Rand.rndSeed(c.LV * 20, c.uid));
43 }
static int Negotiate(int a, float mod=1.5f)
Definition: CalcMoney.cs:5
int uid
Definition: Card.cs:118
int LV
Definition: Card.cs:370
Definition: Rand.cs:4
static int rndSeed(int a, int seed)
Definition: Rand.cs:29

References Card.LV, Negotiate(), Rand.rndSeed(), and Card.uid.

Referenced by ListPeopleBuySlave.Cost().

◆ Heal()

static int CalcMoney.Heal ( Chara  c)
inlinestatic

Definition at line 20 of file CalcMoney.cs.

21 {
23 }
int ServicePrice(int a)
Definition: GuildFighter.cs:17
Definition: Guild.cs:2
static GuildFighter Fighter
Definition: Guild.cs:23

References Guild.Fighter, Negotiate(), and GuildFighter.ServicePrice().

◆ Identify()

static int CalcMoney.Identify ( Chara  c,
bool  superior 
)
inlinestatic

Definition at line 30 of file CalcMoney.cs.

31 {
32 return Negotiate(Guild.Fighter.ServicePrice(superior ? 750 : 50));
33 }

References Guild.Fighter, Negotiate(), and GuildFighter.ServicePrice().

◆ Invest()

static int CalcMoney.Invest ( int  a,
float  mod = 2f 
)
inlinestatic

Definition at line 10 of file CalcMoney.cs.

11 {
12 return (int)Mathf.Max((long)a * 100L / (long)(100f + (float)Mathf.Max(0, EClass.pc.CHA / 2 + EClass.pc.Evalue(292)) * mod), 1f);
13 }
int CHA
Definition: Card.cs:2207
int Evalue(int ele)
Definition: Card.cs:2431
Definition: EClass.cs:5
static Chara pc
Definition: EClass.cs:14

References Card.CHA, Card.Evalue(), and EClass.pc.

Referenced by InvestShop(), and InvestZone().

◆ InvestShop()

static int CalcMoney.InvestShop ( Chara  c,
Chara  tc 
)
inlinestatic

Definition at line 62 of file CalcMoney.cs.

63 {
64 return Invest(Guild.Merchant.InvestPrice(Mathf.Max(tc.c_invest * 700, Mathf.Min(tc.c_invest, 4000) * Mathf.Min(tc.c_invest, 4000) * 80) + 200));
65 }
static int Invest(int a, float mod=2f)
Definition: CalcMoney.cs:10
int c_invest
Definition: Card.cs:1229
int InvestPrice(int a)
Definition: GuildMerchant.cs:7
static GuildMerchant Merchant
Definition: Guild.cs:29

References Card.c_invest, Invest(), GuildMerchant.InvestPrice(), and Guild.Merchant.

◆ InvestZone()

static int CalcMoney.InvestZone ( Chara  c)
inlinestatic

Definition at line 67 of file CalcMoney.cs.

68 {
69 return Invest((int)Mathf.Max((long)EClass._zone.development * 50L, Mathf.Min(EClass._zone.development, 80000) * Mathf.Min(EClass._zone.development, 80000) / 4) + 500);
70 }
static Zone _zone
Definition: EClass.cs:20
int development
Definition: Spatial.cs:238

References EClass._zone, Spatial.development, and Invest().

◆ Meal()

static int CalcMoney.Meal ( Chara  c)
inlinestatic

Definition at line 15 of file CalcMoney.cs.

16 {
18 }

References Guild.Fighter, Negotiate(), and GuildFighter.ServicePrice().

◆ Negotiate()

static int CalcMoney.Negotiate ( int  a,
float  mod = 1::5f 
)
inlinestatic

Definition at line 5 of file CalcMoney.cs.

6 {
7 return (int)Mathf.Max((long)a * 100L / (long)(100f + (float)Mathf.Max(0, EClass.pc.CHA / 2 + EClass.pc.Evalue(291)) * mod), 1f);
8 }

References Card.CHA, Card.Evalue(), and EClass.pc.

Referenced by BuySlave(), Heal(), Identify(), Meal(), Picklock(), and Revive().

◆ Picklock()

static int CalcMoney.Picklock ( Chara  c,
Thing  t 
)
inlinestatic

Definition at line 25 of file CalcMoney.cs.

26 {
27 return Negotiate(Guild.Fighter.ServicePrice(t.c_lockLv * 65 + 75));
28 }
int c_lockLv
Definition: Card.cs:924

References Card.c_lockLv, Guild.Fighter, Negotiate(), and GuildFighter.ServicePrice().

◆ Revive()

static int CalcMoney.Revive ( Chara  c)
inlinestatic

Definition at line 35 of file CalcMoney.cs.

36 {
37 return Negotiate((c.LV + 5) * (c.LV + 5) * 3);
38 }

References Card.LV, and Negotiate().

Referenced by ListPeopleRevive.OnClick(), and ListPeopleRevive.OnInstantiate().

◆ SellSlave()

static int CalcMoney.SellSlave ( Chara  c)
inlinestatic

Definition at line 45 of file CalcMoney.cs.

46 {
47 return (c.LV + 5) * (c.LV + 5) * 5;
48 }

References Card.LV.

◆ Whore()

static int CalcMoney.Whore ( Chara  seller,
Chara  buyer 
)
inlinestatic

Definition at line 50 of file CalcMoney.cs.

51 {
52 int num = Mathf.Max(seller.CHA * 6, 20) * ((!buyer.IsWealthy) ? 1 : 2);
53 int num2 = Mathf.Max(buyer.CHA * 12, 20) * ((!buyer.IsWealthy) ? 1 : 2);
54 Debug.Log("seller:" + num + " buyer:" + num2 + " wealthy:" + buyer.IsWealthy);
55 if (num > num2)
56 {
57 num = num2;
58 }
59 return num;
60 }
bool IsWealthy
Definition: Chara.cs:878

References Card.CHA, Debug, and Chara.IsWealthy.

Referenced by AI_Fuck.Finish().


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