Elin Decompiled Documentation EA 23.153 Nightly
Loading...
Searching...
No Matches
GrowSystemWheat.cs
Go to the documentation of this file.
2{
3 protected override bool UseGenericFirstStageTile => false;
4
5 public override int HarvestStage => 3;
6
7 public override int AutoMineStage => 3;
8
9 public virtual bool GenerateStraw => true;
10
11 public override string GetSoundProgress()
12 {
13 return source.DefaultMaterial.GetSoundImpact();
14 }
15
16 public override int GetStageTile()
17 {
19 {
20 return harvestTile + 1;
21 }
22 return base.GetStageTile();
23 }
24
25 public override void OnMineObj(Chara c = null)
26 {
27 if (GenerateStraw && (IsWithered() || IsHarvestStage(base.stage.idx)))
28 {
29 TryPick(GrowSystem.cell, ThingGen.Create("grass", "straw"), c);
30 }
31 else
32 {
33 base.OnMineObj(c);
34 }
35 }
36}
bool isHarvested
Definition: Cell.cs:330
Definition: Chara.cs:10
override void OnMineObj(Chara c=null)
override string GetSoundProgress()
override int GetStageTile()
virtual bool GenerateStraw
override int HarvestStage
override int AutoMineStage
override bool UseGenericFirstStageTile
virtual int StageLength
Definition: GrowSystem.cs:65
virtual bool IsHarvestStage(int idx)
Definition: GrowSystem.cs:110
static Stage currentStage
Definition: GrowSystem.cs:47
void TryPick(Cell cell, Thing t, Chara c, bool applySeed=false)
Definition: GrowSystem.cs:547
bool IsWithered()
Definition: GrowSystem.cs:492
SourceObj.Row source
Definition: GrowSystem.cs:49
static Cell cell
Definition: GrowSystem.cs:45
int harvestTile
Definition: GrowSystem.cs:55
static Thing Create(string id, int idMat=-1, int lv=-1)
Definition: ThingGen.cs:53