Elin Decompiled Documentation
EA 23.102 Nightly
Loading...
Searching...
No Matches
TraitFortuneCookie.cs
Go to the documentation of this file.
1
public
class
TraitFortuneCookie
:
TraitFood
2
{
3
public
override
void
OnEat
(
Chara
c)
4
{
5
if
(c.
IsPC
)
6
{
7
Msg
.
Say
(
"read_fortune"
, c);
8
bool
flag = owner.blessedState < BlessedState.Blessed && (owner.blessedState <= BlessedState.Cursed ||
EClass
.
rnd
(2) == 0);
9
string
text =
Lang
.
GetDialog
(
"rumor"
,
"fortune"
+ (flag ?
"_false"
:
""
)).RandomItem();
10
Msg
.
SetColor
(
Msg
.
colors
.
Talk
);
11
Msg
.
SayRaw
(text);
12
}
13
}
14
}
Chara
Definition:
Chara.cs:10
Chara.IsPC
override bool IsPC
Definition:
Chara.cs:597
EClass
Definition:
EClass.cs:5
EClass.rnd
static int rnd(int a)
Definition:
EClass.cs:50
Lang
Definition:
Lang.cs:6
Lang.GetDialog
static string[] GetDialog(string idSheet, string idTopic)
Definition:
Lang.cs:205
MsgColors.Talk
Color Talk
Definition:
MsgColors.cs:7
Msg
Definition:
Msg.cs:5
Msg.colors
static MsgColors colors
Definition:
Msg.cs:20
Msg.SayRaw
static string SayRaw(string text)
Definition:
Msg.cs:113
Msg.Say
static string Say(string idLang, string ref1, string ref2=null, string ref3=null, string ref4=null)
Definition:
Msg.cs:58
Msg.SetColor
static void SetColor()
Definition:
Msg.cs:22
TraitFood
Definition:
TraitFood.cs:2
TraitFortuneCookie
Definition:
TraitFortuneCookie.cs:2
TraitFortuneCookie.OnEat
override void OnEat(Chara c)
Definition:
TraitFortuneCookie.cs:3
Elin
TraitFortuneCookie.cs
Generated by
1.9.6