Пример #1
0
 public void Awake()
 {
     questService = Service.Get <QuestService>();
     dispatcher   = Service.Get <EventDispatcher>();
     dispatcher.AddListener <QuestEvents.QuestUpdated>(onQuestUpdated);
     dispatcher.AddListener <HudEvents.HudInitComplete>(onHudInitCompleted);
 }
Пример #2
0
 protected override void OnEnable()
 {
     if (Owner.CompareTag("Player"))
     {
         QuestService questService = Service.Get <QuestService>();
         questService.SendEvent(QuestEvent);
     }
 }
Пример #3
0
 public void Awake()
 {
     animator      = GetComponent <Animator>();
     dispatcher    = Service.Get <EventDispatcher>();
     questService  = Service.Get <QuestService>();
     mascotService = Service.Get <MascotService>();
     indicatorData = new DActionIndicator();
     indicatorData.TargetTransform     = base.transform;
     indicatorData.IndicatorContentKey = QuestIndicatorContentKey;
     indicatorData.TargetOffset        = QuestIndicatorOffset;
     speechData = new DCinematicSpeech();
 }
Пример #4
0
 private void Start()
 {
     questService = Service.Get <QuestService>();
     for (int i = 0; i < nodes.Length; i++)
     {
         nodes[i].ColliderRadius = NodeRadius;
         nodes[i].NodeIndex      = i;
         if (i > 0)
         {
             nodes[i - 1].NextNode = nodes[i];
         }
     }
 }
Пример #5
0
        private void SendEvent(string evt)
        {
            QuestService questService = Service.Get <QuestService>();
            Quest        activeQuest  = questService.ActiveQuest;

            if (activeQuest != null && activeQuest.Definition.name == QuestName)
            {
                questService.SendEvent(evt);
                if (eventHook != null)
                {
                    eventHook(evt);
                }
            }
        }
Пример #6
0
        private void getReferences()
        {
            minigameService            = Service.Get <MinigameService>();
            eventDispatcher            = Service.Get <EventDispatcher>();
            questService               = Service.Get <QuestService>();
            player                     = SceneRefs.ZoneLocalPlayerManager.LocalPlayerGameObject;
            locomotionBroadcaster      = player.GetComponent <LocomotionEventBroadcaster>();
            fishingRod                 = getChildByName(player, "FishingRodProp(Clone)");
            _rodPropLineEndTransform   = getChildByName(fishingRod, "string_end_jnt").transform;
            playerAnimator             = player.GetComponent <Animator>();
            fishingRodAnimator         = fishingRod.GetComponent <Animator>();
            prizeDropContainerAnimator = prizeDropContainer.GetComponentInChildren <Animator>();
            _bobberAnimator            = bobberRootTransform.GetComponentInChildren <Animator>();
            GameObject gameObject = GameObject.Find("CinematicFishing");

            cinematicCameraFishingController = gameObject.GetComponent <CameraController>();
            GameObject gameObject2 = GameObject.Find("CinematicFishingZoom");

            cinematicCameraFishingControllerZoom = gameObject2.GetComponent <CameraController>();
            for (int i = 0; i < cinematicCameraFishingController.GoalPlanners.Length; i++)
            {
                RailDollyGoalPlanner railDollyGoalPlanner = cinematicCameraFishingController.GoalPlanners[i] as RailDollyGoalPlanner;
                if (railDollyGoalPlanner != null)
                {
                    _cameraDolly = railDollyGoalPlanner.Dolly;
                    break;
                }
            }
            RailDollyFramer railDollyFramer = cinematicCameraFishingController.Framer as RailDollyFramer;

            if (railDollyFramer != null)
            {
                _cameraDollyFocus = railDollyFramer.Dolly;
            }
            userControl = player.GetComponent <PenguinUserControl>();
        }
Пример #7
0
 private void Start()
 {
     questService = Service.Get <QuestService>();
 }