Elin Modding Docs Doc
Loading...
Searching...
No Matches
AI_Bladder.cs
1using System;
2using System.Collections.Generic;
3using UnityEngine;
4
5// Token: 0x020001F9 RID: 505
6public class AI_Bladder : AIAct
7{
8 // Token: 0x06000E76 RID: 3702 RVA: 0x0006D293 File Offset: 0x0006B493
9 public override IEnumerable<AIAct.Status> Run()
10 {
11 if (this.toilet == null)
12 {
13 this.toilet = (EClass._map.Installed.traits.GetTraitSet<TraitBath>().GetRandom() as TraitBath);
14 }
15 if (this.toilet == null)
16 {
17 yield return this.Cancel();
18 }
19 yield return base.DoGoto(this.toilet.owner, null);
21 {
22 onProgressBegin = delegate()
23 {
24 this.owner.SetTempHand(-1, -1);
25 this.owner.SetPCCState(PCCState.Naked);
26 this.owner.SetCensored(true);
27 this.owner.PlaySound("water", 1f, true);
28 this.owner.Kick(this.owner.pos, true);
29 this.owner.pos.TalkWitnesses(this.owner, "disgust", 4, WitnessType.everyone, null, 3);
30 },
31 onProgress = delegate(Progress_Custom p)
32 {
33 this.owner.renderer.PlayAnime(AnimeID.Shiver, default(Vector3), false);
34 },
35 onProgressComplete = delegate()
36 {
37 if (this.toilet == null || !this.toilet.ExistsOnMap || !this.toilet.owner.pos.Equals(this.owner.pos))
38 {
39 EClass._map.SetLiquid(this.owner.pos.x, this.owner.pos.z, 1, 3);
40 }
41 this.owner.ShowEmo(Emo.happy, 0f, true);
42 }
43 }.SetDuration(15, 5);
44 yield return base.Do(seq, null);
45 yield break;
46 }
47
48 // Token: 0x06000E77 RID: 3703 RVA: 0x0006D2A3 File Offset: 0x0006B4A3
49 public override void OnReset()
50 {
51 this.owner.SetPCCState(PCCState.Normal);
52 this.owner.SetCensored(false);
53 }
54
55 // Token: 0x04000D50 RID: 3408
56 public TraitBath toilet;
57}
Definition AIAct.cs:7