From b1d0eb1581e2f10253c416638cf03bbcaa677ef4 Mon Sep 17 00:00:00 2001 From: collett Date: Sun, 8 Aug 2021 01:30:03 +0900 Subject: [PATCH] lighting and fabric color workaround --- src/common/Network/CommonActorControl.h | 2 ++ src/scripts/quest/subquest/gridania/SubCts999.cpp | 11 +++++++++++ 2 files changed, 13 insertions(+) diff --git a/src/common/Network/CommonActorControl.h b/src/common/Network/CommonActorControl.h index f95dbbdc..cc5a56b5 100644 --- a/src/common/Network/CommonActorControl.h +++ b/src/common/Network/CommonActorControl.h @@ -111,6 +111,8 @@ namespace Sapphire::Network::ActorControl ScreenFadeOut = 0xAA, + CeremonyDecoration = 0xB9, + ZoneIn = 0xC8, ZoneInDefaultPos = 0xC9, diff --git a/src/scripts/quest/subquest/gridania/SubCts999.cpp b/src/scripts/quest/subquest/gridania/SubCts999.cpp index f9f3019f..23bc47a4 100644 --- a/src/scripts/quest/subquest/gridania/SubCts999.cpp +++ b/src/scripts/quest/subquest/gridania/SubCts999.cpp @@ -8,6 +8,8 @@ #include #include "Manager/TerritoryMgr.h" #include "Manager/EventMgr.h" +#include "Network/CommonActorControl.h" +#include "Network/PacketWrappers/ActorControlSelfPacket.h" using namespace Sapphire; @@ -414,6 +416,7 @@ private: } if( type == 4 ) // BASE_ID_TERRITORY_TYPE = unknown { + player.queuePacket( Sapphire::Network::Packets::Server::makeActorControlSelf( getId(), Sapphire::Network::ActorControl::ActorControlType::CeremonyDecoration, player.getQuestUI8FH( getId() ), player.getQuestUI8FL( getId() ), 0, 0 ) ); Scene00067( player ); // Scene00067: Normal(SetWeddingFestivalParam), id=unknown break; } @@ -448,6 +451,7 @@ private: } if( type == 4 ) // BASE_ID_TERRITORY_TYPE = unknown { + player.queuePacket( Sapphire::Network::Packets::Server::makeActorControlSelf( getId(), Sapphire::Network::ActorControl::ActorControlType::CeremonyDecoration, player.getQuestUI8FH( getId() ), player.getQuestUI8FL( getId() ), 0, 0 ) ); Scene00073( player ); // Scene00073: Normal(FadeIn, SetWeddingFestivalParam), id=unknown break; } @@ -508,6 +512,10 @@ public: player.setQuestUI8CL( getId(), data.params[5] ); player.setQuestUI8DH( getId(), data.params[6] ); player.setQuestUI8DL( getId(), data.params[7] ); + + // retail does not save these two values here, we borrow them since they are unused. + player.setQuestUI8FH( getId(), data.params[8] ); + player.setQuestUI8FL( getId(), data.params[9] ); player.sendDebug( "Ceremony settings saved." ); } } @@ -1294,6 +1302,9 @@ private: player.setQuestUI8EH( getId(), plan ); + player.setQuestUI8FH( getId(), 1 ); // see onSaveData() for detail + player.setQuestUI8FL( getId(), 1 ); // see onSaveData() for detail + player.eventFinish( getId(), 1 ); player.enterPredefinedPrivateInstance( 393 ); }