Exemplo n.º 1
0
Arquivo: Way.cs Projeto: Cdrix/SM
 void InitializeBigBoxPrev()
 {
     if (verticBigBox == null || horizBigBox == null)
     {
         verticBigBox = (BigBoxPrev)CreatePlane.CreatePlan(Root.bigBoxPrev, Root.matGreenSel2);
         verticBigBox.transform.name = "verticBigBox:" + MyId;
         horizBigBox = (BigBoxPrev)CreatePlane.CreatePlan(Root.bigBoxPrev, Root.matGreenSel2);
         horizBigBox.transform.name = "horizBigBox:" + MyId;
     }
 }
Exemplo n.º 2
0
    // Use this for initialization
    private void Start()
    {
        base.Start();

        //if is not position fixed alredy we create the preview
        //when is Position Fixed already here mean that was loaded from file
        if (!PositionFixed)
        {
            farmPrev = (BigBoxPrev)CreatePlane.CreatePlan(Root.bigBoxPrev, Root.matGreenSel2);
            farmPrev.transform.name = "Farm Preview: " + MyId;
        }

        if (HType == H.Road)
        {
            maxSizeOfFarm = 500;
        }
    }
Exemplo n.º 3
0
    void Start()
    {
        _animator = gameObject.GetComponent <Animator>();
        _hover    = GetChildCalled("Hover");
        _hover.gameObject.SetActive(false);

        var poly = U2D.FromRectToPoly(Region);

        buildingPrev = (BigBoxPrev)CreatePlane.CreatePlan(Root.bigBoxPrev, Root.dashedLinedSquare, container: transform);
        buildingPrev.UpdatePos(poly, .25f);
        buildingPrev.transform.position = U2D.FromV2ToV3(Region.center);

        //MeshController.CrystalManager1.CrystalRegions[Index].StartWithAudioReport();
        Name  = "Buy region";
        HType = H.BuyRegion;

        transform.position += new Vector3(0, 10000, 0);
    }