protected void Init() { this.numver = new int[this.numberDigit]; this.massage = this.text; this.nowscene = NumberSet.SCENE.printing; this.fasepattern = NumberSet.FACEPATTERN.neutral; this.endprint = 0; this.printfonts = 0; this.arrowprint = false; this.faseflame = 0; this.frame = 0; this.manyopen = 0; this.fasewait = 0; this.wait = 0; this.shortmassage = new string[3]; this.canskip = true; this.longwaiting = false; this.nowDigit = this.numberDigit - 1; this.shortmassage = new string[3] { "", "", "" }; }
public override void Update() { if (!this.enginit) { this.Init(); this.enginit = true; } if (this.printfase && !this.mono) { this.FaseAnimation(); } string[][] strArray = new string[3][] { this.ToDecomposition(this.massage[0]), this.ToDecomposition(this.massage[1]), this.ToDecomposition(this.massage[2]) }; if (this.manager.alpha <= 0 && this.canskip && this.massage[0].Length > 0 && (Input.IsPress(Button._B) || Input.IsPress(Button._A) || this.fastprint)) { this.endprint = strArray.Length - 1; this.printfonts = strArray[strArray.Length - 1].Length + 1; this.shortmassage = this.massage; } switch (this.nowscene) { case NumberSet.SCENE.printing: ++this.printfonts; if (this.printfonts > strArray[this.endprint].Length) { this.printfonts = 0; ++this.endprint; if (this.endprint < this.massage.Length) { break; } this.arrowprint = true; this.nowscene = NumberSet.SCENE.pushA; break; } // ISSUE: explicit reference operation this.shortmassage[this.endprint] += strArray[this.endprint][this.printfonts - 1]; if (strArray[this.endprint][this.printfonts - 1] == "・" && !this.mono) { this.sound.PlaySE(SoundEffect.message); this.wait = 30; this.longwaiting = true; } else if (strArray[this.endprint][this.printfonts - 1] == "、" && !this.mono) { this.sound.PlaySE(SoundEffect.message); this.wait = 15; this.longwaiting = true; } else if (strArray[this.endprint][this.printfonts - 1] == "#") { string s = ""; for (int index = 2; index < 100 && (this.printfonts + index < strArray[this.endprint].Length && !(strArray[this.endprint][this.printfonts + index] == "#")); ++index) { s += strArray[this.endprint][this.printfonts + index]; } string str = strArray[this.endprint][this.printfonts]; if (!(str == "s")) { if (!(str == "w")) { if (!(str == "b")) { if (!(str == "u")) { if (str == "e") { this.Init(); this.EndCommand(); break; } } else { this.manager.parent.main.FolderReset(); var saveThread = new Thread(new ThreadStart(() => this.savedata.SaveFile(this.manager.parent.parent))); saveThread.Start(); this.saving = true; } } else { try { this.canskip = bool.Parse(s); } catch { } } } else { try { this.wait = int.Parse(s); this.longwaiting = true; } catch { } } } else { try { this.sound.PlaySE((SoundEffect)Enum.Parse(typeof(SoundEffect), s)); } catch { } } do { ++this.printfonts; // ISSUE: explicit reference operation this.shortmassage[this.endprint] += strArray[this.endprint][this.printfonts - 1]; }while (strArray[this.endprint][this.printfonts - 1] != "#"); } else { this.sound.PlaySE(SoundEffect.message); this.wait = 0; this.longwaiting = false; } this.nowscene = NumberSet.SCENE.wait; break; case NumberSet.SCENE.wait: --this.wait; if (this.wait > 0) { break; } this.wait = 0; this.nowscene = NumberSet.SCENE.printing; break; case NumberSet.SCENE.pushA: this.FlameControl(4); if (this.savedata != null) { if (!this.savedata.saveEnd) { break; } if (!this.endok) { if (this.frame <= 1) { break; } this.frame = 0; this.endok = true; break; } if (this.frame > 2) { this.frame = 0; } if (this.manager.alpha <= 0) { this.Control(); } break; } if (!this.endok) { if (this.frame > 1) { this.frame = 0; this.endok = true; } } else { if (this.frame > 2) { this.frame = 0; } if (this.manager.alpha <= 0) { this.Control(); } } break; } }