// Start is called before the first frame update
 void Awake()
 {
     objectiveArrow = GetComponent <ObjectiveArrow>();
     data           = new ObjectiveArrowsData {
         objectiveEnabled      = objectiveArrow.objectiveEnabled,
         objectiveKeepDisabled = objectiveArrow.objectiveKeepDisabled,
         enableArrows          = objectiveArrow.enableArrows,
         objectiveList         = objectiveArrow.objectiveList
     }; //get/set
 }
    public override void setLoadData(object obj)
    {
        if (objectiveArrow == null)
        {
            objectiveArrow = GetComponent <ObjectiveArrow>();
        }

        data = (ObjectiveArrowsData)obj;
        objectiveArrow.objectiveEnabled      = data.objectiveEnabled;
        objectiveArrow.objectiveKeepDisabled = data.objectiveKeepDisabled;
        objectiveArrow.enableArrows          = data.enableArrows;
        objectiveArrow.objectiveList         = data.objectiveList;
    }
Ejemplo n.º 3
0
        public SpaceCamera(Objective objective, AbilitySelector selector, ObjectiveArrow objectiveArrow, Image objectiveCircle,
                           Camera camera, CameraFlash cameraFlash, SceneChanger sceneChanger, Text level)
        {
            this.objective       = objective;
            this.selector        = selector;
            this.objectiveArrow  = objectiveArrow;
            this.objectiveCircle = objectiveCircle;
            this.camera          = camera;
            this.cameraFlash     = cameraFlash;
            this.sceneChanger    = sceneChanger;
            this.level           = level;

            // By default, off
            this.objectiveCircle.gameObject.SetActive(false);
            this.objectiveArrow.gameObject.SetActive(false);
        }