Esempio n. 1
0
        void ProgressDiseaseAfterSleepOrTravel()
        {
            const string dreamVideoName = "ANIM0004.VID";   // Vampire dream video
            const string deathVideoName = "ANIM0012.VID";   // Death video

            // Get current day and number of days that have passed (e.g. fast travel can progress time several days)
            uint currentDay = DaggerfallUnity.Instance.WorldTime.DaggerfallDateTime.ToClassicDaggerfallTime() / DaggerfallDateTime.MinutesPerDay;
            int  daysPast   = (int)(currentDay - startingDay);

            // Always allow dream to play on first rest or travel event
            // In current implementation, disease will not progress to stage 2 effect until player has experienced dream then rests or travels a second time
            if (daysPast > 0 && !warningDreamVideoPlayed)
            {
                // Play infection warning dream video
                DaggerfallVidPlayerWindow vidPlayerWindow = new DaggerfallVidPlayerWindow(DaggerfallUI.UIManager, dreamVideoName);
                DaggerfallUI.UIManager.PushWindow(vidPlayerWindow);
                warningDreamVideoPlayed = true;
            }
            else if (daysPast > 3 && warningDreamVideoPlayed && !fakeDeathVideoPlayed)
            {
                // Play "death" video ahead of final stage of infection
                DaggerfallVidPlayerWindow vidPlayerWindow = new DaggerfallVidPlayerWindow(DaggerfallUI.UIManager, deathVideoName);
                DaggerfallUI.UIManager.PushWindow(vidPlayerWindow);
                vidPlayerWindow.OnClose += DeployFullBlownVampirism;
                fakeDeathVideoPlayed     = true;
            }
        }
Esempio n. 2
0
        void ProgressDiseaseAfterSleepOrTravel()
        {
            const string dreamVideoName = "ANIM0002.VID";   // Lycanthropy dream video

            // Get current day and number of days that have passed (e.g. fast travel can progress time several days)
            uint currentDay = DaggerfallUnity.Instance.WorldTime.DaggerfallDateTime.ToClassicDaggerfallTime() / DaggerfallDateTime.MinutesPerDay;
            int  daysPast   = (int)(currentDay - startingDay);

            // Always allow dream to play on first rest or travel event
            // In current implementation, disease will not progress to stage 2 effect until player has experienced dream then rests or travels a second time
            if (daysPast > 0 && !warningDreamVideoPlayed)
            {
                // Play infection warning dream video
                DaggerfallVidPlayerWindow vidPlayerWindow = new DaggerfallVidPlayerWindow(DaggerfallUI.UIManager, dreamVideoName);
                DaggerfallUI.UIManager.PushWindow(vidPlayerWindow);
                warningDreamVideoPlayed = true;
            }
            else if (daysPast > 3 && warningDreamVideoPlayed)
            {
                // TODO: Shared handling

                // Deploy full-blown lycanthropy
                DeployFullBlownLycanthropy();
            }
        }
Esempio n. 3
0
        public override void Update(Task caller)
        {
            base.Update(caller);

            DaggerfallVidPlayerWindow vidPlayerWindow = new DaggerfallVidPlayerWindow(DaggerfallUI.UIManager, videoName);

            DaggerfallUI.UIManager.PushWindow(vidPlayerWindow);

            SetComplete();
        }
Esempio n. 4
0
        public override void Update(Task caller)
        {
            base.Update(caller);

            DaggerfallVidPlayerWindow vidPlayerWindow = (DaggerfallVidPlayerWindow)
                                                        UIWindowFactory.GetInstanceWithArgs(UIWindowType.VidPlayer, new object[] { DaggerfallUI.UIManager, videoName });

            vidPlayerWindow.EndOnAnyKey = false;
            DaggerfallUI.UIManager.PushWindow(vidPlayerWindow);

            SetComplete();
        }
Esempio n. 5
0
        void ProgressDisease()
        {
            const string dreamVideoName = "ANIM0002.VID";   // Lycanthropy dream video

            // Do nothing if not incumbent or effect ended
            if (!IsIncumbent || forcedRoundsRemaining == 0 || daysOfSymptomsLeft == completedDiseaseValue)
            {
                return;
            }

            // Get current day and number of days that have passed (e.g. fast travel can progress time several days)
            uint currentDay = DaggerfallUnity.Instance.WorldTime.DaggerfallDateTime.ToClassicDaggerfallTime() / DaggerfallDateTime.MinutesPerDay;
            int  daysPast   = (int)(currentDay - startingDay);

            // Show dream after 1 day has passed, progress to full-blown lycanthropy after 3 days have passed
            if (daysPast > 0 && !warningDreamVideoScheduled && !warningDreamVideoPlayed)
            {
                // Play infection warning dream video
                DaggerfallVidPlayerWindow vidPlayerWindow = (DaggerfallVidPlayerWindow)
                                                            UIWindowFactory.GetInstanceWithArgs(UIWindowType.VidPlayer, new object[] { DaggerfallUI.UIManager, dreamVideoName });
                vidPlayerWindow.EndOnAnyKey = false;
                DaggerfallUI.UIManager.PushWindow(vidPlayerWindow);
                vidPlayerWindow.OnClose   += WarningDreamVideoCompleted;
                warningDreamVideoScheduled = true;
            }
            else if (daysPast > 3 && warningDreamVideoPlayed && !deployedFullBlownLycanthropy)
            {
                // Assign Lycanthropy spell to spellbook
                GameManager.Instance.PlayerEntity.AssignPlayerLycanthropySpell();

                // Deploy full-blown lycanthropy
                DeployFullBlownLycanthropy();
                deployedFullBlownLycanthropy = true;

                // Terminate custom disease lifecycle
                EndDisease();
            }
        }
Esempio n. 6
0
        void ProgressDisease()
        {
            const string dreamVideoName = "ANIM0004.VID";   // Vampire dream video
            const string deathVideoName = "ANIM0012.VID";   // Death video

            // Do nothing if not incumbent or effect ended
            if (!IsIncumbent || forcedRoundsRemaining == 0 || daysOfSymptomsLeft == completedDiseaseValue)
            {
                return;
            }

            // Get current day and number of days that have passed (e.g. fast travel can progress time several days)
            uint currentDay = DaggerfallUnity.Instance.WorldTime.DaggerfallDateTime.ToClassicDaggerfallTime() / DaggerfallDateTime.MinutesPerDay;
            int  daysPast   = (int)(currentDay - startingDay);

            // Show dream after 1 day has passed, progress to full-blown vampirism after 3 days have passed
            if (daysPast > 0 && !warningDreamVideoScheduled && !warningDreamVideoPlayed)
            {
                // Play infection warning dream video
                DaggerfallVidPlayerWindow vidPlayerWindow = (DaggerfallVidPlayerWindow)
                                                            UIWindowFactory.GetInstanceWithArgs(UIWindowType.VidPlayer, new object[] { DaggerfallUI.UIManager, dreamVideoName });
                vidPlayerWindow.EndOnAnyKey = false;
                DaggerfallUI.UIManager.PushWindow(vidPlayerWindow);
                vidPlayerWindow.OnClose   += WarningDreamVideoCompleted;
                warningDreamVideoScheduled = true;
            }
            else if (daysPast > 3 && warningDreamVideoPlayed && !fakeDeathVideoPlayed)
            {
                // Play "death" video ahead of final stage of infection
                DaggerfallVidPlayerWindow vidPlayerWindow = (DaggerfallVidPlayerWindow)
                                                            UIWindowFactory.GetInstanceWithArgs(UIWindowType.VidPlayer, new object[] { DaggerfallUI.UIManager, deathVideoName });
                vidPlayerWindow.EndOnAnyKey = false;
                DaggerfallUI.UIManager.PushWindow(vidPlayerWindow);
                vidPlayerWindow.OnClose += DeployFullBlownVampirism;
                fakeDeathVideoPlayed     = true;
            }
        }
        void ProgressDiseaseAfterSleepOrTravel()
        {
            const string dreamVideoName = "ANIM0002.VID";   // Lycanthropy dream video

            // Do nothing if not incumbent or effect ended
            if (!IsIncumbent || forcedRoundsRemaining == 0 || daysOfSymptomsLeft == completedDiseaseValue)
            {
                return;
            }

            // Get current day and number of days that have passed (e.g. fast travel can progress time several days)
            uint currentDay = DaggerfallUnity.Instance.WorldTime.DaggerfallDateTime.ToClassicDaggerfallTime() / DaggerfallDateTime.MinutesPerDay;
            int  daysPast   = (int)(currentDay - startingDay);

            // Always allow dream to play on first rest or travel event
            // In current implementation, disease will not progress to stage 2 effect until player has experienced dream then rests or travels a second time
            if (daysPast > 0 && !warningDreamVideoPlayed)
            {
                // Play infection warning dream video
                DaggerfallVidPlayerWindow vidPlayerWindow = new DaggerfallVidPlayerWindow(DaggerfallUI.UIManager, dreamVideoName);
                DaggerfallUI.UIManager.PushWindow(vidPlayerWindow);
                warningDreamVideoPlayed = true;
            }
            else if (daysPast > 3 && warningDreamVideoPlayed && !deployedFullBlownLycanthropy)
            {
                // Assign Lycanthropy spell to spellbook
                GameManager.Instance.PlayerEntity.AssignPlayerLycanthropySpell();

                // Deploy full-blown lycanthropy
                DeployFullBlownLycanthropy();
                deployedFullBlownLycanthropy = true;

                // Terminate custom disease lifecycle
                EndDisease();
            }
        }