Exemplo n.º 1
0
        /// Override this to describe what happens when the object gets picked
        /// </summary>
        protected override void Pick()
        {
            base.Pick();
            _animator     = _collider.GetComponent <Animator> ();
            _health       = _collider.GetComponent <LucyHealth> ();
            _sprite       = gameObject.GetComponent <SpriteRenderer> ();
            _magnetEffect = _collider.GetComponent <LucyMagnet>();

            _health.SuperSuitAquired();
            _animator.runtimeAnimatorController = Resources.Load("SuperSuitAnimator") as RuntimeAnimatorController;
            _magnetEffect.AbilityPermitted      = true;
            _sprite.enabled = false;

            //if we haven't already obtained it
            if (!GameManager.Instance.MagnetSuitObtained)
            {
                if (!GameManager.Instance.DebugMode)
                {
                    RunSplashScreen();
                }
                GameManager.Instance.MagnetSuitObtained = true;
                RetroAdventureProgressManager.Instance.SaveProgress();
            }
        }
Exemplo n.º 2
0
        protected override void Setup()
        {
            base.Setup();
            _animator      = GetComponent <Animator>(); 
 _characterHandleEMP = GetComponent <CharacterHandleEMP>(); 
 _lucyHealth = GetComponent <LucyHealth>(); 
 _magnetEffect = GetComponent <LucyMagnet>(); 
 _characterHandleMelee = GetComponent <CharacterHandleMelee>(); 
 _walljump = GetComponent <LucyWallJump>(); 
 _wallcling = GetComponent <LucyWallClinging>(); 
 _lucyFlamethrower = GetComponent <LucyFlamethrower>();
            _characterRun  = GetComponent <CharacterRun>();
            _plasmaRainbow = GetComponent <_2dxFX_PlasmaRainbow>();

            PowerNodesCollected = 0;

            StartCoroutine(AddItemsToInventory());

            StartCoroutine(GetTheRightSuitOn());
        }
Exemplo n.º 3
0
 // Use this for initialization
 void Start()
 {
     _lucyMagnet = GetComponentInParent <LucyMagnet>();
 }