Exemplo n.º 1
0
    void DoorOpenFinish()
    {
        // check ugradeOrNot
        if (LevelManager.upgradeReadyOrNot)
        {
            pauseBeforeMove = true;
            StationForButton.UpdateCollectionUI();
            LevelManager.StageTrasiting();
        }

        // 门完全开之后:
        // 1.产生包
        // 2.丢l&f衣服,发post(包含在3里)
        // 3.更新posture(ad)
        GenerateBag(currentStation);

        if (LevelManager.stage < 2)
        {
            return;                         // 如果stage 1 只产生包,不考虑其他
        }
        //衣服丢太快可能不能满足UI RATE 出现条件
        if (roundNum > 2)
        {
            LostAndFound.DropLostFoundClothes(currentStation);               //转完一圈 丢衣服+更post
        }
        else if (LevelManager.stage > 2 && !atInitailStation)
        {
            InstagramController.RefreshPost("", FinalCameraController.RatingSys.rating);
        }
    }
Exemplo n.º 2
0
    public void ChangeToSubway()
    {
        //if (LevelManager.isInstruction) return;
        //if(LevelManager.stageTransiting)
        //{
        //    LevelManager.UpdateStage();
        //}

        phone.SetActive(true);
        CameraMovement.atInventory = false;
        CameraMovement.JumpToPreviousPage();
        if (!isTutorial)
        {
            CheckInstructionButton.SetActive(false);
        }
        Mask.alpha = 1;



        Hide(TakePhoto);
        Posture.SetActive(false);
        //transform.position = new Vector3(0, 0, -10);
        if (myCameraState == CameraState.Closet || myCameraState == CameraState.Map ||
            myCameraState == CameraState.App || myCameraState == CameraState.Ad)
        {
            if (lastCameraState != CameraState.Closet && lastCameraState != CameraState.Map &&
                lastCameraState != CameraState.App && myCameraState != CameraState.Ad)
            {
                myCameraState = lastCameraState;
                RatingSys.GoBackToSubway();
                //todo: kind of connfused
            }
            else
            {
                myCameraState = CameraState.Subway;
                RatingSys.GoBackToSubway();
            }
        }


        //hide everything
        Hide(Inventory);
        //Show(subwayBackground);
        Hide(frontPage);
        Hide(appBackground);
        //Hide(NPCPage);
        Hide(SubwayMap);
        //Hide(postpage);


        if (InstagramController.waitingForRefresh && LevelManager.stage > 2)
        {
            InstagramController.RefreshPost();
        }
    }
Exemplo n.º 3
0
    public void DropLostFoundClothes(int stationNum)
    {
        int    dropNum  = 0;
        int    maxDrop  = -1;
        string maxOwner = "";

        foreach (NPC owner in ClothesOwners)
        {
            if (owner.homeStation == stationNum)
            {
                int num = owner.myClothesInLF.Count;
                if (num > maxDrop)
                {
                    maxDrop = num;
                }
                dropNum += num;
                owner.myClothesInLF.Clear();
            }
        }

        dropNumThisStation = dropNum;
        totalCount        -= dropNum;
        InstagramController.RefreshPost(maxOwner, RatingSys.rating);
    }