Elin Modding Docs Doc
Loading...
Searching...
No Matches
World.cs
1using System;
2using Newtonsoft.Json;
3
4// Token: 0x020006EC RID: 1772
5public class World : Spatial
6{
7 // Token: 0x17000F72 RID: 3954
8 // (get) Token: 0x06003380 RID: 13184 RVA: 0x00119208 File Offset: 0x00117408
9 public Region region
10 {
11 get
12 {
13 return this.children[0] as Region;
14 }
15 }
16
17 // Token: 0x06003381 RID: 13185 RVA: 0x0011921C File Offset: 0x0011741C
18 public override void OnCreate()
19 {
20 Prologue prologue = EClass.game.Prologue;
21 this.date.year = prologue.year;
22 this.date.month = prologue.month;
23 this.date.day = prologue.day;
24 this.date.hour = prologue.hour;
25 for (int i = 0; i < 5; i++)
26 {
27 this.schedule.list.Add(new Schedule.Item
28 {
29 date = this.date.Copy()
30 });
31 }
32 this.weather._currentCondition = prologue.weather;
33 this.CreateDayData();
34 }
35
36 // Token: 0x06003382 RID: 13186 RVA: 0x001192C4 File Offset: 0x001174C4
37 public void CreateDayData()
38 {
39 this.dayData = new DayData();
40 int num = EClass.rnd(100);
41 for (int i = 0; i < DayData.LuckRange.Length; i++)
42 {
43 if (num >= DayData.LuckRange[i])
44 {
45 this.dayData.luck = i.ToEnum<DayData.Luck>();
46 break;
47 }
48 }
49 this.dayData.seed = EClass.rnd(100000);
50 }
51
52 // Token: 0x06003383 RID: 13187 RVA: 0x00119328 File Offset: 0x00117528
53 public void ModEther(int a = 3)
54 {
55 this.ether += a;
56 if (this.ether >= 100)
57 {
58 this.ether = 0;
59 this.weather.SetCondition(Weather.Condition.Ether, 24, false);
60 }
61 }
62
63 // Token: 0x06003384 RID: 13188 RVA: 0x00119358 File Offset: 0x00117558
64 public void SendPackage(Thing p)
65 {
66 EClass.game.cards.listPackage.Add(p);
67 }
68
69 // Token: 0x04001C13 RID: 7187
70 [JsonProperty]
71 public GameDate date = new GameDate();
72
73 // Token: 0x04001C14 RID: 7188
74 [JsonProperty]
75 public Season season = new Season();
76
77 // Token: 0x04001C15 RID: 7189
78 [JsonProperty]
79 public Weather weather = new Weather();
80
81 // Token: 0x04001C16 RID: 7190
82 [JsonProperty]
83 public Schedule schedule = new Schedule();
84
85 // Token: 0x04001C17 RID: 7191
86 [JsonProperty]
87 public DayData dayData;
88
89 // Token: 0x04001C18 RID: 7192
90 [JsonProperty]
91 public int ether;
92}
Definition Thing.cs:10
Definition World.cs:6