Exemple #1
0
        void Start()
        {
//			if (refCamera == null)
//				refCamera = Camera.main;
            selectedColor = ColorManager.Instance.color;
            SelectInnerColor(Vector2.zero);
            finalColorSprite.color = finalColor;
            PMD = GameObject.FindGameObjectWithTag("PMD").GetComponent <PaintMeshDeformer> ();
        }
Exemple #2
0
 // Use this for initialization
 void Start()
 {
     SpawnPosition = GameObject.FindGameObjectWithTag("SpawnPosition").transform;
     PMD           = GameObject.FindGameObjectWithTag("PMD").GetComponent <PaintMeshDeformer>();
     undoNredo     = GameObject.FindGameObjectWithTag("SLUR").GetComponent <UndoAndRedo> ();
     UIref         = GameObject.FindGameObjectWithTag("UINref").GetComponent <UINavigationSystem> ();
     dm            = GameObject.FindGameObjectWithTag("SM").GetComponent <VRSmooth> ();
     tooltip       = GameObject.FindGameObjectWithTag("tooltip").GetComponent <VRTK_ControllerTooltips> ();
 }
        // Use this for initialization
        void Start()
        {
            for (int i = 0; i < Tools.Length; i++)
            {
                ToolList.Push(Tools [i]);
            }

            PMD = GameObject.FindGameObjectWithTag("PMD").GetComponent <PaintMeshDeformer> ();

            foreach (GameObject tl in Tools)
            {
                tl.SetActive(false);
            }

            Tools [0].SetActive(true);
        }
Exemple #4
0
        // Use this for initialization
        void Start()
        {
            for (int i = 0; i < MainTools.Length; i++)
            {
                ToolList.Push(MainTools [i]);
            }

            PMD   = GameObject.FindGameObjectWithTag("PMD").GetComponent <PaintMeshDeformer> ();
            UINAV = GameObject.FindGameObjectWithTag("UINref").GetComponent <UINavigationSystem>();
            foreach (GameObject tl in MainTools)
            {
                tl.SetActive(false);
            }


            MainTools [0].SetActive(true);

            //goals = GameObject.FindGameObjectsWithTag ("goals");
            foreach (GameObject gl in goals)
            {
                gl.SetActive(false);
            }
            goals [0].SetActive(true);

            //required points to moved to next goal, then new tools get unlock
            Exp.RequiredsculptEXP   = ExpGlobalAmount;
            Exp.RequiredscaleEXP    = ExpGlobalAmount / 2;
            Exp.RequiredrotateEXP   = ExpGlobalAmount / 2;
            Exp.RequiredcreaseEXP   = ExpGlobalAmount / 2;
            Exp.RequiredgrabEXP     = ExpGlobalAmount / 2;
            Exp.RequiredsymmetryEXP = ExpGlobalAmount / 2;
            Exp.RequiredsmoothEXP   = ExpGlobalAmount / 2;
            Exp.RequiredpaintEXP    = ExpGlobalAmount;

            foreach (Slider sli in expPointsliders)
            {
                sli.maxValue = ExpGlobalAmount;
            }

            for (int i = 0; i < toolsboolean.Length; i++)
            {
                toolsboolean [i] = false;
            }
        }
Exemple #5
0
 public void AssignedMeshTrasformReference()
 {
     sphere         = GameObject.FindGameObjectWithTag("Mesh");
     _rotation      = Vector3.zero;
     PMD            = GameObject.FindGameObjectWithTag("PMD").GetComponent <PaintMeshDeformer>();
     _controllerPos = GameObject.FindGameObjectWithTag("controllerRight").GetComponent <Transform>();
     scriptRef      = sphere.GetComponent <VRTK_InteractableObject> ();
     PointerRef     = GameObject.FindGameObjectWithTag("controllerRight").GetComponent <VRTK_UIPointer> ();
     UIref          = GameObject.FindGameObjectWithTag("UINref").GetComponent <UINavigationSystem> ();
     if (UIref == null)
     {
         UIref = GameObject.FindGameObjectWithTag("UINref").GetComponent <UINavigationSystem> ();
     }
     controllerPos     = GameObject.FindGameObjectWithTag("controllerRight");
     sculpt            = UIref.Scalexyz;
     rotate            = UIref.Rotatexyz;
     UniformScale      = UIref.uniformScale;
     GrabToggle        = UIref.Grab;
     CheckingReference = true;
 }
Exemple #6
0
        void Awake()
        {
            ToolsArray     = new GameObject[6];
            ToolsArray [0] = GameObject.FindGameObjectWithTag("sculpt");
            ToolsArray [1] = GameObject.FindGameObjectWithTag("scale");
            ToolsArray [2] = GameObject.FindGameObjectWithTag("rotate");
            ToolsArray [3] = GameObject.FindGameObjectWithTag("Crease");
            ToolsArray [4] = GameObject.FindGameObjectWithTag("smooth");
            ToolsArray [5] = GameObject.FindGameObjectWithTag("paint");
            grab           = GameObject.FindGameObjectWithTag("grab");
            symmetry       = GameObject.FindGameObjectWithTag("symmetry");
            CreaseStrength = ToolsArray [3].GetComponentInChildren <Slider> ();

            foreach (GameObject tools in ToolsArray)
            {
                tools.SetActive(false);
            }
            PMD  = GameObject.FindGameObjectWithTag("PMD").GetComponent <PaintMeshDeformer>();
            VRTP = GameObject.FindGameObjectWithTag("TP").GetComponent <VRTexturePainter> ();

            tooltip = GameObject.FindGameObjectWithTag("tooltip").GetComponent <VRTK_ControllerTooltips> ();
        }
Exemple #7
0
 void Start()
 {
     PMD = GameObject.FindGameObjectWithTag("PMD").GetComponent <PaintMeshDeformer> ();
 }
Exemple #8
0
 // Use this for initialization
 void Start()
 {
     halfMesh = GameObject.FindGameObjectWithTag("mesh").GetComponent <PaintMeshDeformer>();
 }