Exemplo n.º 1
0
 private void CompleteFuWei()
 {
     for (int i = 0; i < 6; i++)
     {
         SinglePlatFormControl.P2P_runing_StopOne(m_ControlData.mSinglePlatFormControl.thisplatform.g_handle, i);
     }
     WaitForTime tm = new WaitForTime(1.0f, TCaculator);
 }
Exemplo n.º 2
0
 private void TCaculator()
 {
     m_ControlData.mSinglePlatFormControl.thisplatform.CaculatorBili(m_ControlData.mConfigXML.P_XingC);
     m_ControlData.mSinglePlatFormControl.thisplatform.SetOrigPosAll();
     for (int i = 0; i < 6; i++)
     {
         SinglePlatFormControl.P2P_runing_start(m_ControlData.mSinglePlatFormControl.thisplatform.g_handle, i, m_ControlData.mConfigXML.FU_Acc, m_ControlData.mConfigXML.FU_speed, m_ControlData.mConfigXML.FU_speed, 0);
     }
     WaitForTime tm = new WaitForTime(1.0f, ToClear);
     //   m_ControlData.mSinglePlatFormControl.Set_Limitswitch(0);
 }
Exemplo n.º 3
0
    //this is called before start
    void Awake()
    {
        wait = GameObject.Find("Space Invader Start").GetComponent("WaitForTime") as WaitForTime;
        //set the number of rows and columns of invaders
        manHPLeft           = 3;
        noOfInvaders        = 0;
        numberOfInvadersCol = 5;
        numberOfInvadersRow = 11;
        invaders            = new GameObject[numberOfInvadersCol, numberOfInvadersRow];
        manHP    = GameObject.Find("man").GetComponent("Damagable") as Damagable;
        gameOver = GameObject.Find("GameOver").GetComponent("GameOver") as GameOver;

        placeInvaders();
    }
Exemplo n.º 4
0
 private void ConnectAndPrepare()
 {
     EnabledReadybutton(false);
     //usemanual = true;
     GlobalClass.NowCarType = CardType.iMC4xxE_A;
     if (IsPreparing)
     {
         return;
     }
     IsPreparing = true;
     if (m_ControlData.mSinglePlatFormControl.ConnectToMachine() == false)
     {
         MessageBox.Show("控制卡连接失败,请检查接线");
         IsPreparing = false;
         return;
     }
     WaitForTime tmpw = new WaitForTime(1.0f, Config);
 }
        private IEnumerator RemoveCoroutine()
        {
            WaitForTime wait = new WaitForTime(m_effectDefinition.endAnimationDuration);
            List <FloatingCounterFloatingObject> floatingObjects = m_floatingObjects;
            int num;

            for (int i = floatingObjects.Count - 1; i >= m_objectsCount; i = num)
            {
                floatingObjects[i].Clear();
                floatingObjects.RemoveAt(i);
                yield return(wait);

                wait.Reset();
                num = i - 1;
            }
            yield return(null);

            Reposition();
        }
Exemplo n.º 6
0
    public void CreateLine(List <Cell> points)
    {
        List <Transform> path = fromPointsToTransform(points);
        WaitForTime      wait = Line[0].gameObject.GetComponent <WaitForTime>();

        LR = Line[0].gameObject.GetComponent <LineRenderer>();
        wait.StartTimer();
        LR.material.color   = UnityEngine.Color.red;
        LR.sortingOrder     = 4;
        LR.sortingLayerName = "Cell";
        LR.useWorldSpace    = true;
        LR.startWidth       = 0.1f;
        LR.endWidth         = 0.1f;

        if (path.Count != 0)
        {
            // Set some positions
            Vector3[] positions = new Vector3[path.Count];
            LR.positionCount = path.Count;
            for (int i = 0; i < path.Count; i++)
            {
                var pointPath = new Vector3(path[i].position.x, path[i].position.y, 100);
                positions[i] = pointPath;

                //Debug.Log(path[i].position);
            }


            LR.SetPositions(positions);



            //ResetLine(LR);
            //waiter();
        }
    }
Exemplo n.º 7
0
 private void Config()
 {
     int         res  = m_ControlData.mSinglePlatFormControl.thisplatform.DoConfigCard();
     WaitForTime tmpw = new WaitForTime(1.0f, /*prepareres*/ BeginRes);
 }