// Update is called once per frame
 void Update()
 {
     if (showStaticNotice)
     {
         return;
     }
     lastTime += Time.deltaTime;
     if (moveNotCD)
     {
         if (nowstep == updateStep.NOTICESTAY &&
             lastTime > step2Time &&
             !animationPlaying)
         {
             aInfo.Play("RollingNoticeOut");
             animationPlaying = true;
             lastTime         = 0;
             nowstep          = updateStep.NOTICEOUT;
         }
     }
     else
     {
         if (nowstep == updateStep.NONE &&
             lastTime > CDTime &&
             !animationPlaying)
         {
             aInfo.Play("RollingNoticeIn");
             animationPlaying = true;
             lastTime         = 0;
             nowstep          = updateStep.NOTICEIN;
             moveNotCD        = true;
         }
     }
     //lastCDTime += Time.deltaTime;
 }
 public void StepNone()
 {
     nowstep          = updateStep.NONE;
     lastTime         = 0;
     moveNotCD        = false;
     animationPlaying = false;
 }
    public void Init()
    {
        noticeID1        = 0;
        noticeID2        = RandomNotice();
        backgd           = background.GetComponent <UISprite>();
        animationPlaying = false;

        moveNotCD = false;
        nowstep   = updateStep.NONE;
        lastTime  = CDTime - 5.0f;       //延迟5秒,进行界面加载
        HideAll();
        ChangeInfoLabel();

        Time.timeScale = 1;        //防止战斗结束后时间过快
    }
    public void ShowStaticNotice(int noticeID)
    {
        showStaticNotice = true;
        //Stop Animation
        aInfo.Stop();
        //Init Label-Info
        noticeID1 = noticeID2;
        noticeID2 = noticeID;
        UILabel labelInfo = info.transform.GetComponent <UILabel>();

        labelInfo.text = TableManager.GetRollingnoticeByID(noticeID2).Content;

        animationPlaying = false;
        moveNotCD        = true;
        nowstep          = updateStep.NOTICESTAY;
        lastTime         = step2Time;
        //Set inof's location & background' alpha
        info.transform.localPosition = Vector3.zero;
        backgd.alpha = 1;
    }
 public void StepStay()
 {
     nowstep          = updateStep.NOTICESTAY;
     lastTime         = 0;
     animationPlaying = false;
 }