/// フレーム処理 public bool Frame() { if (effId == EffId.Non) { effActiveFlg = false; return(false); } switch (effId) { case EffId.FadeIn: fadeAlpha -= fadeSpeed; if (fadeAlpha < 0) { effId = EffId.Non; } break; case EffId.FadeOut: fadeAlpha += fadeSpeed; if (fadeAlpha > 0xff) { fadeAlpha = 0xff; effId = EffId.FadeWait; effActiveFlg = true; } break; } return(!effActiveFlg); }
/// フェードアウトのセット public void SetFadeOut(uint col, int speed, bool active) { effId = EffId.FadeOut; fadeColor = col; fadeAlpha = 0x0; fadeSpeed = speed; effActiveFlg = active; }
/// フレーム処理 public bool Frame() { if( effId == EffId.Non ){ effActiveFlg = false; return false; } switch( effId ){ case EffId.FadeIn: fadeAlpha -= fadeSpeed; if( fadeAlpha < 0 ){ effId = EffId.Non; } break; case EffId.FadeOut: fadeAlpha += fadeSpeed; if( fadeAlpha > 0xff ){ fadeAlpha = 0xff; effId = EffId.FadeWait; effActiveFlg = true; } break; } return !effActiveFlg; }
/// フェードアウトのセット public void SetFadeOut( uint col, int speed, bool active ) { effId = EffId.FadeOut; fadeColor = col; fadeAlpha = 0x0; fadeSpeed = speed; effActiveFlg = active; }
/// public メソッド ///--------------------------------------------------------------------------- /// 初期化 public bool Init() { effId = EffId.Non; effActiveFlg = false; return true; }
/// public メソッド ///--------------------------------------------------------------------------- /// 初期化 public bool Init() { effId = EffId.Non; effActiveFlg = false; return(true); }