Jovani poe reward checks

This commit is contained in:
gymnast86
2026-05-01 01:11:21 -07:00
parent d0cb0c001a
commit 5a5004793a
3 changed files with 43 additions and 5 deletions
+15 -1
View File
@@ -8,6 +8,12 @@
#include "d/actor/d_a_npc_pouya.h"
#include <cstring>
#if TARGET_PC
#include "dusk/randomizer/game/flags.h"
#include "dusk/randomizer/game/randomizer_context.hpp"
#include "dusk/randomizer/game/verify_item_functions.h"
#endif
const daNpc_Pouya_HIOParam daNpc_Pouya_Param_c::m = {
120.0f, // attention_offset
-3.0f, // gravity
@@ -555,7 +561,7 @@ BOOL daNpc_Pouya_c::checkChangeEvt() {
return TRUE;
}
// In randomizer, only get the 60 reward if we've already gotten the 20 reward
if (dComIfGs_getPohSpiritNum() >= 60 IF_DUSK(&& randomizer_IsActive() && dComIfGs_isEventBit(0x4D80))) {
if (dComIfGs_getPohSpiritNum() >= 60 IF_DUSK(&& randomizer_IsActive() && dComIfGs_isEventBit(GOT_BOTTLE_FROM_JOVANI))) {
/* dSv_event_flag_c::F_0458 - Coversation with Jovani after collecting 60 ghosts
*/
if (!daNpcT_chkEvtBit(0x1CA)) {
@@ -959,6 +965,14 @@ int daNpc_Pouya_c::cutHaveFavorToAsk(int param_0) {
switch (evt_id) {
case 1:
if (mItemPartnerId == fpcM_ERROR_PROCESS_ID_e) {
#if TARGET_PC
if (randomizer_IsActive()) {
if (local_64 == dItemNo_Randomizer_DROP_BOTTLE_e)
local_64 = verifyProgressiveItem(randomizer_getItemAtLocation("Jovani 20 Poe Soul Reward"));
else if (local_64 == dItemNo_Randomizer_SILVER_RUPEE_e)
local_64 = verifyProgressiveItem(randomizer_getItemAtLocation("Jovani 60 Poe Soul Reward"));
}
#endif
mItemPartnerId = fopAcM_createItemForPresentDemo(&current.pos, local_64, 0,
-1, -1, 0, 0);
}
+24
View File
@@ -16,6 +16,7 @@
#include <cstring>
#if TARGET_PC
#include "dusk/randomizer/game/flags.h"
#include "dusk/randomizer/game/tools.h"
#include "dusk/randomizer/game/stages.h"
#endif
@@ -795,6 +796,22 @@ u16 dMsgFlow_c::query001(mesg_flow_node_branch* i_flowNode_p, fopAc_ac_c* i_spea
const u16 prm0 = i_flowNode_p->param;
u16 ret = dComIfGs_isEventBit(dSv_event_flag_c::saveBitLabels[prm0]) == false;
#if TARGET_PC
if (randomizer_IsActive()) {
switch (prm0) {
case 0xFA: // MDH Completed
{
// Check to see if currently in Jovani's house
if (playerIsInRoomStage(5, allStages[Castle_Town_Shops])) {
return 0; // Return 0 to be able to turn souls into Jovani pre MDH
}
break;
}
default:
break;
}
}
#endif
if (param_2 != 0) {
// "Flag Check"
OS_REPORT("\x1B[44;33mフラグチェック           \x1B[m|:");
@@ -1698,6 +1715,13 @@ u16 dMsgFlow_c::query049(mesg_flow_node_branch* i_flowNode_p, fopAc_ac_c* i_spea
ret = 4;
}
#if TARGET_PC
// Split up getting both rewards in randomizer
if (randomizer_IsActive() && ret == 4 && !dComIfGs_isEventBit(GOT_BOTTLE_FROM_JOVANI)) {
ret = 3;
}
#endif
if (param_2 != 0) {
// "Collected Souls count"
OS_REPORT("\x1B[44;33m:集めた魂の数  \x1B[m|:");
@@ -2329,7 +2329,6 @@
- Flag: 0x47
Stage: 57
# TODO
- Name: Jovani 20 Poe Soul Reward
Original Item: Bottle with Great Fairies Tears
# HD Original Item: Ghost Lantern
@@ -2338,10 +2337,9 @@
- Npc
- Castle Town
- ARC
Metadata:
- None
- Location Name Lookup
Metadata: Jovani 20 Poe Soul Reward
# TODO
- Name: Jovani 60 Poe Soul Reward
Original Item: Silver Rupee
#HD Original Item: Bottle with Great Fairies Tears
@@ -2350,6 +2348,8 @@
- Npc
- Castle Town
- ARC
- Location Name Lookup
Metadata: Jovani 60 Poe Soul Reward
# HD Only Location
# - Name: Gengle 60 Poe Soul Reward