Elin Modding Docs Doc
Loading...
Searching...
No Matches
InvOwnerChangeMaterial.cs
1using System;
2
3// Token: 0x02000576 RID: 1398
5{
6 // Token: 0x17000B7A RID: 2938
7 // (get) Token: 0x06002634 RID: 9780 RVA: 0x000D7EB4 File Offset: 0x000D60B4
8 public override bool CanTargetAlly
9 {
10 get
11 {
12 return true;
13 }
14 }
15
16 // Token: 0x17000B7B RID: 2939
17 // (get) Token: 0x06002635 RID: 9781 RVA: 0x000D7EB7 File Offset: 0x000D60B7
18 public override string langTransfer
19 {
20 get
21 {
22 return "invChangeMaterial";
23 }
24 }
25
26 // Token: 0x17000B7C RID: 2940
27 // (get) Token: 0x06002636 RID: 9782 RVA: 0x000D7EBE File Offset: 0x000D60BE
28 public override string langWhat
29 {
30 get
31 {
32 return "changeMaterial_what";
33 }
34 }
35
36 // Token: 0x06002637 RID: 9783 RVA: 0x000D7EC5 File Offset: 0x000D60C5
37 public override Thing CreateDefaultContainer()
38 {
39 return ThingGen.Create("mathammer", this.mat.alias);
40 }
41
42 // Token: 0x06002638 RID: 9784 RVA: 0x000D7EDC File Offset: 0x000D60DC
43 public override bool ShouldShowGuide(Thing t)
44 {
45 return t.trait is TraitGodStatue || (!t.category.IsChildOf("currency") && !t.IsUnique && t.trait.CanBeDropped && !t.source.fixedMaterial && !(t.trait is TraitCatalyst) && !(t.trait is TraitTile) && !(t.trait is TraitMaterialHammer) && !(t.trait is TraitSeed));
46 }
47
48 // Token: 0x06002639 RID: 9785 RVA: 0x000D7F68 File Offset: 0x000D6168
49 public override void _OnProcess(Thing t)
50 {
51 ActEffect.Proc(this.idEffect, 100, this.state, t.GetRootCard(), t, new ActRef
52 {
53 n1 = this.mat.alias
54 });
55 if (this.consume != null)
56 {
57 this.consume.ModNum(-1, true);
58 }
59 TraitGodStatue traitGodStatue = t.trait as TraitGodStatue;
60 if (traitGodStatue != null)
61 {
62 traitGodStatue.OnChangeMaterial();
63 }
64 }
65
66 // Token: 0x0600263A RID: 9786 RVA: 0x000D7FD4 File Offset: 0x000D61D4
67 public InvOwnerChangeMaterial() : base(null, null, CurrencyType.Money)
68 {
69 }
70
71 // Token: 0x04001505 RID: 5381
72 public SourceMaterial.Row mat;
73
74 // Token: 0x04001506 RID: 5382
75 public Thing consume;
76}
Definition Thing.cs:10