public override SCENERESULT move() { switch (mPhase) { case CLEARPHASE.INIT: mPhase = CLEARPHASE.RUN; goto case CLEARPHASE.RUN; case CLEARPHASE.RUN: if (--mLifetime > 0) { break; } mPhase = CLEARPHASE.FADE; break; case CLEARPHASE.FADE: mFade++; if (mFade < 100) { break; } goto case CLEARPHASE.DONE; case CLEARPHASE.DONE: return(SCENERESULT.PROCEED); } return(SCENERESULT.DEFAULT); }
public Clear(Selector sys) : base(sys) { // 画像読み込み // カレントディレクトリは、bin/debugフォルダなので1つ上にたどってから // Media フォルダから画像 ファイルを読む string cwd = System.IO.Directory.GetCurrentDirectory(); string path = System.IO.Directory.GetParent(cwd) + "\\..\\Media\\Clear.png"; mTex = new BitmapImage(new Uri(path)); mPhase = CLEARPHASE.INIT; mFade = 0; mLifetime = 140; }