1
Fork 0

Compare commits

...

6 Commits

  1. BIN
      Enderal - Forgotten Stories.esm
  2. BIN
      Skyrim.esm
  3. BIN
      interface/startmenu.swf
  4. BIN
      scripts/_00E_ContainerBonusControl.pex
  5. BIN
      scripts/_00E_MQ101_QuickStart.pex
  6. BIN
      scripts/_00e_mqp01_startsc.pex
  7. BIN
      scripts/_00e_nq06_functions.pex
  8. BIN
      scripts/qf_mq101.pex
  9. 2
      scripts/scriptarchiveorder.txt
  10. 2
      source/Enderal DLL/src/Main.cpp
  11. 73
      source/Enderal DLL/src/Patches/MainMenuPatch.h
  12. 4
      source/scripts/_00E_ContainerBonusControl.psc
  13. 39
      source/scripts/_00E_MQ101_QuickStart.psc
  14. 47
      source/scripts/_00e_mqp01_startsc.psc
  15. 5
      source/scripts/_00e_nq06_functions.psc
  16. 16
      source/scripts/qf_mq101.psc

Binary file not shown.

Binary file not shown.

BIN
interface/startmenu.swf (Stored with Git LFS)

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -263,6 +263,7 @@ scripts\fs_nq05_tochterdeadscript.pex
scripts\fs_nqr04_secretslot_sc.pex
scripts\fs_nqr05_bossfightabnormalitysc.pex
scripts\fs_nqr05_questfragments.pex
scripts\_00E_MQ101_QuickStart.pex
scripts\_00_complexsetstageonread.pex
scripts\_00e_38e_uniyogoshsc.pex
scripts\_00e_a0_actiontrigger_myradflight.pex
@ -1100,7 +1101,6 @@ scripts\_00e_mq18b_showthoughtmessagesc.pex
scripts\_00e_mqp01_carbossc.pex
scripts\_00e_mqp01_functions.pex
scripts\_00e_mqp01_playertranslationscript.pex
scripts\_00e_mqp01_startsc.pex
scripts\_00e_mqp02_combatfailsafesc.pex
scripts\_00e_mqp02_functions.pex
scripts\_00e_mqp02_lanternscript.pex

@ -1,6 +1,7 @@
#include "EventListener.h"
#include "Util.h"
#include "Papyrus.h"
#include "Patches/MainMenuPatch.h"
#include "Patches/FlatMapMarkers.h"
#include "Patches/StayAtSystemPage.h"
#include "Patches/MapMarkerPlacement.h"
@ -168,6 +169,7 @@ SKSEPluginLoad(const LoadInterface* skse) {
GetPapyrusInterface()->Register(Papyrus::Bind);
MainMenuPatch::Install();
DialogueMenuPatch::Install();
HeroMenuPatch::Install();
TweenMenuPatch::Install();

@ -0,0 +1,73 @@
#pragma once
class MainMenuPatch : public RE::MainMenu
{
public:
static void Install()
{
REL::Relocation<uintptr_t> vtbl(RE::VTABLE_MainMenu[0]);
_ProcessMessage = vtbl.write_vfunc(0x4, &ProcessMessageEx);
}
private:
void ProcessEx(RE::GPtr<RE::GFxMovieView> a_movie)
{
RE::GFxValue entryList;
if (!uiMovie->Invoke("_root.MenuHolder.Menu_mc.MainList.__get__entryList", &entryList, nullptr, 0)) {
return;
}
std::array values{
"$CREATIONS",
"$CREATION CLUB",
"$DOWNLOADABLE CONTENT",
"$MOD MANAGER",
"$HELP",
};
bool bUpdated = false;
const auto size = entryList.GetArraySize();
for (uint32_t i = size; i > 0; i--) {
RE::GFxValue entry;
if (!entryList.GetElement(i - 1, &entry))
continue;
RE::GFxValue entryText;
if (!entry.GetMember("text", &entryText))
continue;
const std::string text = entryText.GetString();
if (text.empty())
continue;
for (const auto name : values) {
if (text == name) {
bUpdated = true;
entryList.RemoveElement(i - 1);
}
}
}
if (bUpdated) {
uiMovie->Invoke("_root.MenuHolder.Menu_mc.MainList.InvalidateData", nullptr, nullptr, 0);
}
}
RE::UI_MESSAGE_RESULTS ProcessMessageEx(RE::UIMessage* a_message)
{
if (a_message->type == RE::UI_MESSAGE_TYPE::kShow) {
_show = true;
} else if (_show && (iIterations < 15) && a_message->type == RE::UI_MESSAGE_TYPE::kUpdate) {
iIterations++;
ProcessEx(uiMovie);
}
return _ProcessMessage(this, a_message);
}
inline static REL::Relocation<decltype(&ProcessMessageEx)> _ProcessMessage;
inline static bool _show{ false };
inline static uint32_t iIterations{ 0 };
};

@ -23,8 +23,8 @@ function OnOpenContainer(ObjectReference targetContainer)
; Wait for it to open
int i
while i < 20 && targetContainer.GetOpenState() == 2
Utility.WaitMenuMode(0.1)
while i < 20 && targetContainer.GetOpenState() == 2 && ! Utility.IsInMenuMode()
Utility.Wait(0.1)
i += 1
endwhile

@ -0,0 +1,39 @@
Scriptname _00E_MQ101_QuickStart extends Quest
function Init()
MQP01.CompleteAllObjectives()
MQP01.CompleteQuest()
MQP01.Stop()
MQP02.CompleteAllObjectives()
MQP02.CompleteQuest()
MQP02.Stop()
Utility.wait(0.5)
If _00E_VideoSkip.GetValueInt() == 0 && EnderalFunctions.VideoSupport()
Game.PlayBink("MQP03NearDeathExperience.bik", true)
EndIf
Actor PlayerREF = Game.GetForm(0x14) as Actor
PlayerREF.MoveTo(_00E_ClassMenuOrigin)
Debug.SendAnimationEvent(PlayerRef, "IdleForceDefaultState")
Game.ShowRaceMenu()
(MQP02 as _00E_MQP02_Functions).AddRacialAbilites()
bool bDisableFighting = SKSE.GetVersion() > 0 && ! EnderalFunctions.IsVR()
Game.DisablePlayerControls(false, bDisableFighting, true, false, true, false, false, true)
MQP03.SetCurrentStageID(15)
endfunction
Quest Property MQP01 Auto
Quest Property MQP02 Auto
Quest Property MQP03 Auto
GlobalVariable Property _00E_VideoSkip Auto
ObjectReference Property _00E_ClassMenuOrigin Auto

@ -1,47 +0,0 @@
Scriptname _00E_MQP01_StartSC extends ObjectReference
Event OnTriggerEnter (ObjectReference akActionREF)
if akActionRef == PlayerREF && !bDone
bDone = true
Disable()
If ! MQP01.IsCompleted() && MQ10a.GetCurrentStageID() != 5 && !MQ10a.IsRunning() && !MQ12c.IsRunning()
if _00E_QuickStartPrompt.Show() > 0
MQP01.CompleteAllObjectives()
MQP01.CompleteQuest()
MQP02.CompleteAllObjectives()
MQP02.CompleteQuest()
Utility.wait(0.5)
If _00E_VideoSkip.GetValueInt() == 0 && EnderalFunctions.VideoSupport()
Game.PlayBink("MQP03NearDeathExperience.bik", true)
EndIf
PlayerREF.MoveTo(_00E_ClassMenuOrigin)
Debug.SendAnimationEvent(PlayerRef, "IdleForceDefaultState")
Game.ShowRaceMenu()
bool bDisableFighting = SKSE.GetVersion() > 0 && ! EnderalFunctions.IsVR()
Game.DisablePlayerControls(false, bDisableFighting, true, false, true, false, false, true)
MQP03.SetCurrentStageID(15)
(MQP02 as _00E_MQP02_Functions).AddRacialAbilites()
else
MQP01.SetCurrentStageID(10)
endif
EndIf
EndIf
EndEvent
bool bDone
Quest Property MQP01 Auto
Quest Property MQP02 Auto
Quest Property MQP03 Auto
Quest Property MQ12c Auto
Quest Property MQ10a Auto
Actor Property PlayerREF Auto
Message Property _00E_QuickStartPrompt Auto
ObjectReference Property _00E_ClassMenuOrigin Auto
GlobalVariable Property _00E_VideoSkip Auto

@ -95,7 +95,7 @@ EndFunction
Function ReturnToSelection(bool _bReturnToSelection)
If _bReturnToSelection
((Self as Quest).GetAliasByName("HorseFlute") as _00E_HorseFlute_SC).PrepareTeleport()
HorseFlute.PrepareTeleport()
EndIf
EndFunction
@ -167,6 +167,7 @@ Message Property _00E_NQ06_RenameMountSelection Auto
ReferenceAlias Property PlayerHorse Auto
ReferenceAlias Property Bonni Auto
ReferenceAlias Property FS_NQR05_FatherShadow Auto
_00E_HorseFlute_SC Property HorseFlute Auto
Armor Property _00E_HorseFlute_New Auto
@ -175,4 +176,4 @@ Faction Property ArkYrintoMerchantFaction Auto
Message Property _00E_HorseName Auto
Message Property _00E_MuleName Auto
Message Property _00E_FathersShadowName Auto
Message Property _00E_FathersShadowName Auto

@ -17,11 +17,21 @@ Actor PlayerREF = Game.GetForm(0x14) as Actor
PlayerREF.RemoveAllItems(none, false, false)
PlayerREF.MoveTo(PlayerStartMarkerNew)
PlayerStartMarkerNew = None
Utility.Wait(0.2)
if SKSE.GetVersion() > 0 && EnderalFunctions.GetNewGameCount() > 1
Game.QuitToMainMenu()
Debug.MessageBox("Due to an engine bug, new game should not be started after quitting to the main menu. Please, restart Enderal first.")
return
endif
if _00E_QuickStartPrompt.Show() > 0
QuickStartQuest.Init()
else
MQP01.SetCurrentStageID(10)
endif
Stop()
;END CODE
EndFunction
;END FRAGMENT
@ -29,3 +39,9 @@ EndFunction
;END FRAGMENT CODE - Do not edit anything between this and the begin comment
ObjectReference Property PlayerStartMarkerNew Auto
Quest Property MQP01 Auto
Message Property _00E_QuickStartPrompt Auto
_00E_MQ101_QuickStart Property QuickStartQuest Auto

Loading…
Cancel
Save