void AddEventHandler(GameObject target){
		mTrackableBehaviour = target.GetComponent<TrackableBehaviour>();
		if (mTrackableBehaviour)
		{
			mTrackableBehaviour.RegisterTrackableEventHandler(this);
		}
	}
Esempio n. 2
0
 void Start()
 {
     figura = GetComponent<TrackableBehaviour>();
     if (figura) {
         figura.RegisterTrackableEventHandler (this);
     }
 }
Esempio n. 3
0
 // Use this for initialization
 void Start()
 {
     mTrackableBehaviour = GetComponent<TrackableBehaviour>();
     if (mTrackableBehaviour) {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
 }
		void Start () {
			Debug.Log("Pogas sakums");
				mTrackableBehaviour = GetComponent<TrackableBehaviour>();
				if (mTrackableBehaviour)
				{
						mTrackableBehaviour.RegisterTrackableEventHandler(this);
				}
		}
 void Start()
 {
     mTrackableBehaviour = GetComponent<TrackableBehaviour> ();
             if (mTrackableBehaviour) {
                     Debug.Log ("mTrackableBehaviour found in DefaultTrackableEventHandler");
                     mTrackableBehaviour.RegisterTrackableEventHandler (this);
             }
 }
		void Start()
		{
			//gameObject.AddComponent<EnemyAI> ();
			mTrackableBehaviour = GetComponent<TrackableBehaviour>();
			if (mTrackableBehaviour)
			{
				mTrackableBehaviour.RegisterTrackableEventHandler(this);
			}
		}
Esempio n. 7
0
 public Tracker2(TrackableBehaviour b, int i, ConcurQueue<int> q)
 {
     tr = b;
     me = i;
     queue = q;
     if (tr) {
         tr.RegisterTrackableEventHandler (this);
     }
 }
	void Awake()
	{
		_transform = transform;
		_trackableBehaviour = GetComponent<TrackableBehaviour>();
		if (_trackableBehaviour)
		{
			_trackableBehaviour.RegisterTrackableEventHandler(this);
		}
	}
 void Start()
 {
     // Get GameManager instance
     gameManager = GameManager.Instance();
     mTrackableBehaviour = GetComponent<TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
 }
Esempio n. 10
0
 void Start()
 {
     mTrackableBehaviour = GetComponent<TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
     //FindObjectOfType<Subtitles>().StartSubtitles();
     //FindObjectOfType<Subtitles2>().StartSubtitles();
 }
        void Start()
        {
            mTrackableBehaviour = GetComponent<TrackableBehaviour>();
            if (mTrackableBehaviour)
            {
                mTrackableBehaviour.RegisterTrackableEventHandler(this);
            }

            transform.SetParent(scene.transform);
        }
        void Start()
        {
            mTrackableBehaviour = GetComponent<TrackableBehaviour>();
            if (mTrackableBehaviour)
            {
                mTrackableBehaviour.RegisterTrackableEventHandler(this);
            }

        #endregion // UNTIY_MONOBEHAVIOUR_METHODS

		}
    void Start()
    {
        Dragon = GameObject.Find("Chair");

        mTrackableBehaviour = GetComponent<TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }

        OnTrackingLost();
    }
Esempio n. 14
0
    void Start()
    {
        Dragon = GameObject.Find("Chair");
        controls = (GameObject.Find("controls").GetComponent(typeof(GUITexture))) as GUITexture;
        mTrackableBehaviour = GetComponent<TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }

        OnTrackingLost();
    }
    void OnEnable()
    {
		// set up global events if needed

        mTrackableBehaviour = GetComponent<TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }else{
			Debug.LogError("PlayMakerVuforiaTrackableProxy required a TrackableBehaviour component",this);
		}
    }
Esempio n. 16
0
        void Start()
        {
            UnityChan= GameObject.Find("unitychan");

            mTrackableBehaviour = GetComponent<TrackableBehaviour>();
            if (mTrackableBehaviour)
            {
                mTrackableBehaviour.RegisterTrackableEventHandler(this);
            }

            OnTrackingLost();
        }
Esempio n. 17
0
    // Use this for initialization
    void Start()
    {
        lastTime = Time.time;
        enemies = new ArrayList();

        mTrackableBehaviour = GetComponent<TrackableBehaviour>();

        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
		t_mvida.text = "Vida : " + live;
    }
        IEnumerator Start()
        {
			yield return new WaitForSeconds (.1f);

			CurrentDiceImage = (DiceImageType) (MarkerID % 6);
			InteractionLayerIndex = LayerMask.NameToLayer (InteractionLayer.ToString());

            mTrackableBehaviour = GetComponent<TrackableBehaviour>();
            if (mTrackableBehaviour)
            {
                mTrackableBehaviour.RegisterTrackableEventHandler(this);
            }

        }
Esempio n. 19
0
 void Start()
 {
     mTrackableBehaviour = GetComponent <TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
     //get the screen's width
     sWidth = Screen.width;
     //calculate the scale ratio
     guiRatio = sWidth / 1920;
     //create a scale Vector3 with the above ratio
     GUIsF = new Vector3(guiRatio, guiRatio, 1);
 }
Esempio n. 20
0
    // Use this for initialization
    void Start()
    {
        //Set up the event handler for tracking from Vuforia
        mTrackableBehaviour = GameObject.Find("ImageTarget").GetComponent <TrackableBehaviour>();

        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }

        wholeHasp.SetActive(false);
        wholePadlock.SetActive(false);
        wholeTag.SetActive(false);
        SwitchStartPosition = Switch.gameObject.transform.position;
        SwitchEndPosition   = EndSwitch.gameObject.transform.position;
        SwitchStartRotation = Switch.gameObject.transform.rotation;
        SwitchEndRotation   = EndSwitch.gameObject.transform.rotation;

        OpeningHaspStartPosition = HaspFrontClosed.gameObject.transform.position;
        OpeningHaspStartRotation = HaspFrontClosed.gameObject.transform.rotation;

        OpeningHaspEndPosition = HaspFrontOpen.gameObject.transform.position;
        OpeningHaspEndRotation = HaspFrontOpen.gameObject.transform.rotation;

        OpenedHaspStartPosition = OpeningHaspEndPosition;
        OpenedHaspStartRotation = OpeningHaspEndRotation;
        OpenedHaspEndPosition   = HaspFrontOpenEnd.gameObject.transform.position;
        OpenedHaspEndRotation   = HaspFrontOpenEnd.gameObject.transform.rotation;

        HaspBackStartPosition = HaspBack.gameObject.transform.position;
        HaspBackStartRotation = HaspBack.gameObject.transform.rotation;
        HaspBackEndPosition   = HaspBackEnd.gameObject.transform.position;
        HaspBackEndRotation   = HaspBackEnd.gameObject.transform.rotation;

        FinalClosingHaspStartPosition = HaspFrontOpenEnd.gameObject.transform.position;
        FinalClosingHaspEndPosition   = HaspFrontClosedEnd.gameObject.transform.position;
        FinalClosingHaspStartRotation = HaspFrontOpenEnd.gameObject.transform.rotation;
        FinalClosingHaspEndRotation   = HaspFrontClosedEnd.gameObject.transform.rotation;

        LockClaspStartStartPosition = LockClaspStart.gameObject.transform.position;
        LockClaspStartEndPosition   = LockClaspOpenStart.gameObject.transform.position;
        LockStartPosition           = LockStart.gameObject.transform.position;
        LockEndPosition             = LockEnd.gameObject.transform.position;
        LockClaspOpenStartPosition  = LockClaspOpenStart.gameObject.transform.position;
        LockClaspOpenEndPosition    = LockClaspOpenEnd.gameObject.transform.position;
        LockClaspClosingEndPosition = LockClaspClosedEnd.gameObject.transform.position;

        TagStartPosition = TagStart.gameObject.transform.position;
        TagEndPosition   = TagEnd.gameObject.transform.position;
    }
 protected virtual void Start()
 {
     loadingImg = GameObject.Instantiate(Resources.Load <GameObject>("Prefabs/LoadingImg"));
     loadingImg.transform.SetParent(transform);
     loadingImg.transform.localEulerAngles = Vector3.zero;
     loadingImg.transform.localPosition    = Vector3.zero;
     loadingImg.transform.localScale       = Vector3.one * 0.03f;
     AssetBundle.UnloadAllAssetBundles(false);
     mTrackableBehaviour = GetComponent <TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
 }
Esempio n. 22
0
    protected virtual void Start()
    {
        //音乐监听事件
        // musicbutton=GameObject.Find("/Canvas/music").GetComponent<Button>();
        // musicbutton.onClick.AddListener(closemusic);

        titletext           = title.GetComponent <Text>();
        text                = textcontent.GetComponent <Text>();
        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
    }
    void Start()
    {
        _trackableBehaviour = GetComponent <TrackableBehaviour>();

        if (_trackableBehaviour)
        {
            _trackableBehaviour.RegisterTrackableEventHandler(this);
        }

        if (onDetectImageTarget == null)
        {
            onDetectImageTarget = new OnDetectImageTarget();
        }
    }
Esempio n. 24
0
 // Use this for initialization
 void Start()
 {
     //GUI.Label(new Rect(0, 0, Screen.width, Screen.height), "ya rab yeshtaghal");
     //  GameObject newGO = new GameObject("ClickableText");
     //newGO.transform.SetParent(this.transform);
     AddTextToCanvas("TESSTT TESSST", new GameObject("ClickableText"));
     //Text myText = newGO.AddComponent<Text>();
     //myText.text = "Ta-dah!";
     mTrackableBehaviour = GetComponent <TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
 }
Esempio n. 25
0
    protected virtual void Start()
    {
        ipv4 = "http://";
        ipv4 = ipv4 + IPManager.GetIP(ADDRESSFAM.IPv4);

        Debug.Log(ipv4);
        setURL = ipv4 + "/Wdata.php?dados=";

        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
    }
Esempio n. 26
0
    void Start()
    {
        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }

        ship1OriginalPosition = ship1.transform.position;
        ship2OriginalPosition = ship2.transform.position;

        ship1.transform.position = outsidePosition.transform.position;
        ship2.transform.position = outsidePosition.transform.position;
    }
Esempio n. 27
0
 // Use this for initialization
 void Start()
 {
     targe.RegisterTrackableEventHandler(this);
     fly = transform.Find("Button").GetComponent <Button>();
     fly.onClick.AddListener(() =>
     {
         an.Play("Fly");
     });
     yow = transform.Find("Button (1)").GetComponent <Button>();
     yow.onClick.AddListener(() =>
     {
         an.Play("Yowl");
     });
 }
Esempio n. 28
0
    // Use this for initialization
    void Start()
    {
        gogo = gogoGameObject.GetComponent <GogoAPI>();


        if (theTrackable == null)
        {
            Debug.Log("Warning: Trackable not set !!");
        }
        if (theTrackable)
        {
            theTrackable.RegisterTrackableEventHandler(this);
        }
    }
Esempio n. 29
0
    void Start()
    {
        borboleta3 = GameObject.Find("borboleta3");
        placa3     = GameObject.Find("placa3");
        borboleta3.SetActive(false);
        placa3.SetActive(true);


        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
    }
Esempio n. 30
0
 // Start is called before the first frame update
 void Start()
 {
     if (measurement == null)
     {
         measurement = this;
     }
     answer = GameObject.Find("answerText").GetComponent <Text>();
     origin = GetComponent <Camera>();
     if (imageTarget.GetComponent <TrackableBehaviour>())
     {
         mTrackableBehaviour = imageTarget.GetComponent <TrackableBehaviour>();
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
 }
    // Use this for initialization
    void Start()
    {
        mTrackableBehaviour.RegisterTrackableEventHandler(this);

        Button btn = seePictureButton.GetComponent <Button>();

        btn.onClick.AddListener(TaskOnClick);
        foto.SetActive(false);
        deathText.SetActive(false);
        winText.SetActive(false);

        api         = gameObject.AddComponent <APICaller>();
        levelLoader = gameObject.AddComponent <LevelLoader>();
    }
    protected virtual void Start()
    {
        //  m_texto_inicio.text = "Mire no Marcador";
        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }

        var vuforia = VuforiaARController.Instance;

        vuforia.RegisterVuforiaStartedCallback(OnVuforiaStarted);
//        vuforia.RegisterOnPauseCallback(OnPause());
    }
    protected virtual void Start()
    {
        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
        //Register / add the AudioSource as object
        soundTarget = (AudioSource)gameObject.AddComponent <AudioSource>();

        LandButtonFalse.gameObject.SetActive(false);
        LavaButtonFalse.gameObject.SetActive(false);
        SmokeButtonTrue.gameObject.SetActive(false);
        RockButtonTrue.gameObject.SetActive(false);
        WaterButtonFalse.gameObject.SetActive(false);
        FireButtonTrue.gameObject.SetActive(false);
        WaterButtonTrue.gameObject.SetActive(false);
        SmokeButtonFalse.gameObject.SetActive(false);
        FireButtonFalse.gameObject.SetActive(false);
        LandButtonTrue.gameObject.SetActive(false);
        PatternText1.gameObject.SetActive(false);

        OrangeButtonFalse.gameObject.SetActive(false);
        RedButtonFalse.gameObject.SetActive(false);
        BlueButtonTrue.gameObject.SetActive(false);
        YellowButtonTrue.gameObject.SetActive(false);
        BlueButtonFalse.gameObject.SetActive(false);
        RedButtonTrue.gameObject.SetActive(false);
        OrangeButtonTrue.gameObject.SetActive(false);
        GreenButtonFalse.gameObject.SetActive(false);
        YellowButtonFalse.gameObject.SetActive(false);
        GreenButtonTrue.gameObject.SetActive(false);
        PatternText2.gameObject.SetActive(false);

        BananaButtonFalse.gameObject.SetActive(false);
        AvocadoButtonFalse.gameObject.SetActive(false);
        AppleButtonTrue.gameObject.SetActive(false);
        BananaButtonTrue.gameObject.SetActive(false);
        AppleButtonFalse.gameObject.SetActive(false);
        WatermelonButtonTrue.gameObject.SetActive(false);
        AvocadoButtonTrue.gameObject.SetActive(false);
        StrawberryButtonFalse.gameObject.SetActive(false);
        WatermelonButtonFalse.gameObject.SetActive(false);
        StrawberryButtonTrue.gameObject.SetActive(false);
        PatternText3.gameObject.SetActive(false);
        Score.gameObject.SetActive(false);


        fumaca = 0;
    }
Esempio n. 34
0
    void OnEnable()
    {
        // set up global events if needed

        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
        else
        {
            Debug.LogError("PlayMakerVuforiaTrackableProxy required a TrackableBehaviour component", this);
        }
    }
Esempio n. 35
0
    // Use this for initialization
    void Start()
    {
        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        mTrackableBehaviour.RegisterTrackableEventHandler(this);
        completed = false;

        // testing quest state
        questState = 0;

        // init
        trackableFairyAnim = trackableFairy.GetComponent <Animator>();
        bearAnim           = bear.GetComponent <Animator>();
        bearOriginalPos    = bear.transform.position;
    }
Esempio n. 36
0
    void Start()
    {
        isTracking = false;

        mTrackableBehaviour = GetComponent <TrackableBehaviour>();

        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }

        OnTrackingFound += HandleTrackingFound;
        OnTrackingLost  += HandleTrackingLost;
    }
Esempio n. 37
0
 // Use this for initialization
 void Start()
 {
     imageTarget    = gameObject;
     _gameOverPopup = GameObject.Find("GameOverPopup");
     _gameOverPopup.SetActive(false);
     _trackableBehaviour = GetComponent <TrackableBehaviour>();
     _outOfFocusPopup    = GameObject.Find("OutOfFocusImg");
     _outOfFocusPopup.SetActive(false);
     _scoreText = GameObject.Find("ScoreText").GetComponent <Text>();
     if (_trackableBehaviour)
     {
         _trackableBehaviour.RegisterTrackableEventHandler(this);
     }
 }
Esempio n. 38
0
    // Start is called before the first frame update
    void Start()
    {
        imageTarget  = GameObject.Find("ImageTarget");
        anim         = this.GetComponent <Animator>();
        anim.enabled = false;

        // Get the image target's trackable
        _trackableBehaviour = imageTarget.GetComponent <TrackableBehaviour>();
        if (_trackableBehaviour)
        {
            // Register it with the handler
            _trackableBehaviour.RegisterTrackableEventHandler(this);
        }
    }
Esempio n. 39
0
    private GameObject Spark, Cyclone;                       //effects, monsters

    void Start()
    {
        Spark = transform.FindChild("Spark").gameObject;         // effects
        Spark.SetActive(false);
        // effects
        Cyclone = transform.FindChild("Cyclone").gameObject;         // effects
        Cyclone.SetActive(false);


        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
    }
Esempio n. 40
0
    // Use this for initialization
    void Start()
    {
        pipe = GameObject.Find("Bottom Pipe");

        Debug.Log(pipe.ToString());

        trackableBehaviour = GetComponent <TrackableBehaviour> ();

        if (trackableBehaviour)
        {
            trackableBehaviour.RegisterTrackableEventHandler(this);
        }

        OnTracking(false);
    }
Esempio n. 41
0
 void Start()
 {
     mTrackableBehaviour = GetComponent <TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
     try {
         create_dict.animal_list.Add(mTrackableBehaviour.name, false);
     }
     catch (System.ArgumentException e)
     {
         return;
     }
 }
Esempio n. 42
0
    void Start()
    {
        audio                      = GetComponent <AudioSource> ();
        viewer                     = Camera.main.transform;
        Physics.gravity            = new Vector3(0f, 9.81f, 0f);
        normScale                  = cube.transform.localScale;
        cube.transform.localScale *= 0.5f;
        wR = dandelionTop.transform.GetComponent <WindReciever> ();

        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
    }
        int mPictureIndexNumber = 0;//Variable for Gallery

        #endregion // PRIVATE_MEMBER_VARIABLES

        #region UNTIY_MONOBEHAVIOUR_METHODS

        void Start()
        {
        //  mMainMenu = true;

            mTrackableBehaviour = GetComponent<TrackableBehaviour>();
            if (mTrackableBehaviour)
            {
                mTrackableBehaviour.RegisterTrackableEventHandler(this);
            }

            for (int i = 0; i < pictures.Length; i++)
            {
              Debug.Log("Bildes numurs: "+i+"is named "+pictures[i].name);
            }
        }
    protected virtual void Start()
    {
        data = null;

        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }

        JSParser parser = new JSParser();

        parser.OverlayDataGenerated += HandleEvent;
        parser.StartCalculating();
    }
Esempio n. 45
0
    void Start()
    {
        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
        GameObject compCamera = GameObject.Find("ComputerCamera");

        if (compCamera != null && compCamera.activeSelf)
        {
            Debug.Log("TrackableBehaviour not found, activating myself");
            OnTrackingFound();
        }
    }
Esempio n. 46
0
    // Use this for initialization
    void Start()
    {
        _trackableBehaviour = GetComponent <TrackableBehaviour>();

        if (_trackableBehaviour)
        {
            _trackableBehaviour.RegisterTrackableEventHandler(this);
        }

        canvas = GameObject.FindGameObjectWithTag("Canvas");
        SetUpTransitionImage();


        //GameControllerScript.gameManagerInstance = GameObject.Find("gameManager").GetComponent<GameControllerScript>();
    }
    // Use this for initialization
    void Start()
    {
        bridgePart1Obj = GameObject.Find("Cwood1");
        bridgePart2Obj = GameObject.Find("Cwood2");
        bridgePart3Obj = GameObject.Find("Cwood3");
        bridgePart1Obj.SetActive(false);
        bridgePart2Obj.SetActive(false);
        bridgePart3Obj.SetActive(false);

        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
    }
Esempio n. 48
0
    private void Start()
    {
        mTrackableBehaviour = GetComponent <TrackableBehaviour>();

        //Register this class as an event handler so you can get the informaiton
        // about the status change of the cube (if it is tracked or lost)
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }

        // Find the direction of the turn every time the cube is turned or found
        OnTurn  += DirectionFinder;
        OnFound += DirectionFinder;
    }
Esempio n. 49
0
    private GameObject puzzleResult;        //拼图成功后的对象持有

//    private bool b_firstFound = true;//是否是第一次发现目标对象,默认是true,表示是
    #endregion // PRIVATE_MEMBER_VARIABLES

    #region UNTIY_MONOBEHAVIOUR_METHODS

    protected virtual void Start()
    {
        if (!ConfigureClass.isreadGameData)//如果不继续拼图,则拼图步骤初始化为1
        {
            _currentCodeOfPuzzle = 1;
        }

        _endCodeOfPuzzle = ConfigureClass.puzzleStep[currentSceneName];//初始化完成时的拼图编号

        mTrackableBehaviour = GetComponent <TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
    }
Esempio n. 50
0
		void Start()
		{
			mTrackableBehaviour = GetComponent<TrackableBehaviour>();
			if (mTrackableBehaviour)
			{
				mTrackableBehaviour.RegisterTrackableEventHandler(this);
			}

			 if (mTrackableBehaviour.TrackableName.StartsWith( "Passive" ) ){

				gameObject.transform.GetChild(0).gameObject.SetActive(false);
				Debug.Log ("Turn that shit off " + gameObject.GetComponent<ImageTargetBehaviour>().ImageTarget.Name+ " "  );
		
			}



		}
    protected override void doAwake()
    {
        GameObject go = GameObject.Find("ARTargetRoot");

        if (go != null)
        {
            mTrackableBehaviour = go.GetComponent<TrackableBehaviour>();
            if (mTrackableBehaviour != null)
                mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }

        go = GameObject.Find("ARContentRoot");

        if (go != null)
        {
            mObjectsParent = go.transform != null ? go.transform : null;
        }
    }
Esempio n. 52
0
    // Use this for initialization
    void Start()
    {
        _imageTarget = GameObject.Find("VegasStripTarget");
                if (_imageTarget != null) {
                        _targetPlane = new Plane (_imageTarget.transform.up, _imageTarget.transform.position);
                        _mTrackableBehaviour = _imageTarget.GetComponent<TrackableBehaviour> ();

                        if (_mTrackableBehaviour) {
                                Debug.Log ("mTrackableBehaviour eventHandler registered...");
                                _mTrackableBehaviour.RegisterTrackableEventHandler (this);
                        }
                }

                _vegasObject = GameObject.Find("VegasContainer");
                if (_vegasObject != null) {
                        _defaultVegasPosition = _vegasObject.transform.position;
                        _defaultVegasRotation = _vegasObject.transform.rotation;
                        _defaultVegasScale = _vegasObject.transform.localScale;
                }
    }
Esempio n. 53
0
    void Start()
    {
        Spark = transform.FindChild("Spark").gameObject; // effects
        Spark.SetActive(false);

        Blast = transform.FindChild("Blast").gameObject; // effects
        Blast.SetActive(false);
        // effects
        Cyclone = transform.FindChild("Cyclone").gameObject; // effects
        Cyclone.SetActive(false);

        mTrackableBehaviour = GetComponent<TrackableBehaviour>();
        if (mTrackableBehaviour)
        {
            mTrackableBehaviour.RegisterTrackableEventHandler(this);
        }
    }
 void Start()
 {
     mTrackableBehaviour = GetComponent<TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
     //		nguiobject.SetActive(false);
 }
Esempio n. 55
0
 void Start()
 {
     mTrackableBehaviour = GetComponent<TrackableBehaviour>();
     //foundModels = new ArrayList();
     //foundModelsC = new ArrayList();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
 }
Esempio n. 56
0
 void Start()
 {
     mTrackableBehaviour = GetComponent<TrackableBehaviour>();
     _isActive = false;
     _isSetup = false;
     _translateUV = new Vector3[4];
     if (mTrackableBehaviour) {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
 }
 void Start()
 {
     field = GameObject.Find("FieldTarget");
     mTrackableBehaviour = GetComponent<TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
 }
 void Start()
 {
     mTrackableBehaviour = GetComponent<TrackableBehaviour>();
     if (mTrackableBehaviour)
     {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
     axe = GameObject.Find ("RightHanditem_Axe");
     axe.SetActive (false);
 }
Esempio n. 59
0
 void Start()
 {
     mTrackableBehaviour = GetComponent<TrackableBehaviour>();
     if (mTrackableBehaviour) {
         mTrackableBehaviour.RegisterTrackableEventHandler(this);
     }
     Dictionary<string, string> param = new Dictionary<string, string>();
     param.Add("flag[claimed]", "0");
     param.Add("_method", "patch");
     Server.POST("flags/3", param);
     found = false;
 }
        void Start()
        {
            game = SharedInfo.getCurrGame ();

            mTrackableBehaviour = GetComponent<TrackableBehaviour>();
            if (mTrackableBehaviour)
            {
                mTrackableBehaviour.RegisterTrackableEventHandler(this);
            }
        }