mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-07-05 03:29:45 -04:00
Compare commits
36 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 1a7c853d9b | |||
| 9a3428983b | |||
| 15a846478b | |||
| ff3eb9aa48 | |||
| 513fdd2312 | |||
| f33c3bdf72 | |||
| e08b427650 | |||
| 9f0fa12c6e | |||
| ad4f75bbb6 | |||
| 5d2811955c | |||
| 3b30c09e79 | |||
| 8adc40708e | |||
| 2541c3f293 | |||
| 30b003c9d9 | |||
| c77ed40208 | |||
| af8300a77c | |||
| 1ce1003e1a | |||
| 10e2181692 | |||
| 424d1d7b71 | |||
| 26be454999 | |||
| cf89da811a | |||
| f02c7bd1ac | |||
| 53abb8b96d | |||
| 6a27fa23c8 | |||
| 025a425884 | |||
| 5064385c8c | |||
| e52d9e9b71 | |||
| 3520bb746c | |||
| 1e10d95936 | |||
| a923aa24e1 | |||
| 9c4f61678e | |||
| 7967ee1f66 | |||
| 2bdc7b6c09 | |||
| 232f73365c | |||
| 00704ad838 | |||
| f52c715364 |
@@ -276,6 +276,12 @@ if (DUSK_ENABLE_SENTRY_NATIVE)
|
||||
endif ()
|
||||
endif ()
|
||||
|
||||
# Use signed char on ARM to match the original game (and x86)
|
||||
string(TOLOWER "${CMAKE_SYSTEM_PROCESSOR}" _arch)
|
||||
if(_arch MATCHES "^(arm|aarch64)" AND CMAKE_CXX_COMPILER_FRONTEND_VARIANT STREQUAL "GNU")
|
||||
add_compile_options(-fsigned-char)
|
||||
endif()
|
||||
|
||||
if (CMAKE_SYSTEM_NAME STREQUAL Windows)
|
||||
set(PLATFORM_NAME win32)
|
||||
elseif (CMAKE_SYSTEM_NAME STREQUAL Darwin)
|
||||
|
||||
@@ -1,33 +1,40 @@
|
||||
# Installing Dusklight on iOS via AltStore
|
||||
# Installing Dusklight on iOS via iloader
|
||||
|
||||
## Prerequisites
|
||||
|
||||
- Mac with Homebrew installed
|
||||
- iPhone connected via USB
|
||||
- A Windows, Linux, or macOS device
|
||||
- iOS device connected to computer via USB
|
||||
- Dusklight IPA file (download the latest `Dusklight-vX.X.X-ios-arm64.ipa` from the [releases page](https://github.com/TwilitRealm/dusk/releases))
|
||||
- Game disc - `GZ2E01` (Gamecube USA) or `GZ2PE01` (Gamecube PAL)
|
||||
|
||||
## 1. Install AltServer
|
||||
|
||||
```sh
|
||||
brew install altserver
|
||||
open -a AltServer
|
||||
```
|
||||
|
||||
AltServer will appear in your menu bar.
|
||||
- Executable bundles can be installed from [iloader's main page](https://iloader.app/) or [their GitHub](https://github.com/nab138/iloader) for Windows, Linux, and macOS.
|
||||
- Windows WILL require iTunes to be installed
|
||||
- Linux WILL require usbmuxd to be installed, this is installed by default in most distros though
|
||||
|
||||
## 2. Enable Developer Mode (iOS 16+)
|
||||
|
||||
- On your iPhone, go to **Settings > Privacy & Security > Developer Mode**
|
||||
- Toggle it on and restart when prompted
|
||||
|
||||
## 3. Install AltStore on Your iPhone
|
||||
## 3. Install Dusklight on Your iPhone
|
||||
|
||||
- Click AltServer in the menu bar
|
||||
- Click **Install AltStore > [Your iPhone]**
|
||||
- Enter your Apple ID credentials when prompted
|
||||
- On your iPhone, go to **Settings > General > VPN & Device Management**
|
||||
- Tap your Apple ID under "Developer App" and tap **Trust**
|
||||
1. Sign into your Apple ID (this is required for registering app IDs, it is sent securely and not stored by iloader)
|
||||
* You may be prompted to put in a code from your iOS device, do so
|
||||
2. Plug in your iOS device via USB into your PC. If you're missing a dependency, an error pop-up will tell you to install it
|
||||
* You will need to hit `Refresh` after plugging it in at this stage so that it can be detected, it does not automatically refresh
|
||||
3. Leave settings unchanged (the Anisette server should stay Sidestore (.io))
|
||||
3.(a) Installing SideStore directly is not required, but provides you a way to install Dusklight on your phone without being plugged into a computer later
|
||||
4. Press `Import IPA` and choose your downloaded `Dusk-v.X.X.X-ios-arm64.ipa`, it will begin installing on your device
|
||||
|
||||
**NOTE:** *At various stages, you may be prompted to trust your device, do so*
|
||||
|
||||
## 3. Getting Dusk trusted
|
||||
When installing sideloaded iOS applications, at first you will need to manually trust the app due to Apple's security policies
|
||||
* Go to **Settings > General > VPN & Device Management**
|
||||
* Tap the Apple ID you signed into iloader with under "Developer App" and tap **Trust**
|
||||
* Tap **Allow** on the pop-up
|
||||
|
||||
## 4. Copy Files to Your iPhone
|
||||
|
||||
@@ -38,9 +45,4 @@ Transfer the IPA and game disc to your iPhone so they're accessible in the Files
|
||||
- **USB transfer** - Connect your iPhone and drag files via Finder's sidebar
|
||||
- **Cloud storage** - Upload to Google Drive, Dropbox, etc. and download on your iPhone
|
||||
|
||||
## 5. Install via AltStore
|
||||
|
||||
- Open **AltStore** on your iPhone
|
||||
- Go to the **My Apps** tab
|
||||
- Tap the **+** button (top left)
|
||||
- Open the **Files** app and select the `.ipa` file
|
||||
You may now use Dusklight on iOS, iPadOS!
|
||||
Vendored
+1
-1
Submodule extern/aurora updated: 3643a369ad...40913d532e
@@ -1733,9 +1733,6 @@ public:
|
||||
int checkNewItemChange(u8 i_selItemIdx);
|
||||
void deleteEquipItem(BOOL i_isPlaySound, BOOL i_isDeleteKantera);
|
||||
void setLight();
|
||||
#if TARGET_PC
|
||||
void setGhostLanternLight();
|
||||
#endif
|
||||
void setFrontRollCrashShock(u8);
|
||||
void changeWarpMaterial(daAlink_c::daAlink_WARP_MAT_MODE i_matMode);
|
||||
void commonProcInit(daAlink_c::daAlink_PROC i_procID);
|
||||
@@ -2659,14 +2656,8 @@ public:
|
||||
void checkWaterInKandelaar(f32);
|
||||
void offKandelaarModel();
|
||||
int kandelaarModelCallBack();
|
||||
int ghostLanternModelCallBack();
|
||||
BOOL checkKandelaarEquipAnime() const;
|
||||
void preKandelaarDraw();
|
||||
void preGhostLanternDraw();
|
||||
static void* srchPoe(void*, void*);
|
||||
#if TARGET_PC
|
||||
void setGhostLanternModel();
|
||||
#endif
|
||||
void setKandelaarModel();
|
||||
void resetOilBottleModel();
|
||||
void commonKandelaarPourInit();
|
||||
@@ -3986,9 +3977,6 @@ public:
|
||||
/* 0x006FC */ J3DModel* mpKanteraModel;
|
||||
/* 0x00700 */ J3DModel* mpKanteraGlowModel;
|
||||
/* 0x00704 */ J3DAnmTextureSRTKey* mpKanteraGlowBtk;
|
||||
/* 0x006FC */ J3DModel* mpGhostLanternModel;
|
||||
/* 0x00700 */ J3DModel* mpGhostLanternGlowModel;
|
||||
/* 0x00704 */ J3DAnmTextureSRTKey* mpGhostLanternGlowBtk;
|
||||
/* 0x00708 */ J3DModel* mHeldItemModel;
|
||||
/* 0x0070C */ J3DModel* mpHookTipModel; // related to held item
|
||||
/* 0x00710 */ J3DModel* field_0x0710; // related to held item
|
||||
@@ -4385,7 +4373,6 @@ public:
|
||||
/* 0x03194 */ int field_0x3194;
|
||||
/* 0x03198 */ int field_0x3198;
|
||||
/* 0x0319C */ int field_0x319c;
|
||||
/* 0x0319C */ s32 ghostLanternFlameEffect[2];
|
||||
/* 0x031A0 */ u32 mModeFlg;
|
||||
/* 0x031A4 */ int field_0x31a4;
|
||||
/* 0x031A8 */ u32 field_0x31a8[2];
|
||||
@@ -4455,9 +4442,6 @@ public:
|
||||
/* 0x033F4 */ f32 field_0x33f4;
|
||||
/* 0x033F8 */ f32 field_0x33f8;
|
||||
/* 0x033FC */ f32 field_0x33fc;
|
||||
#if TARGET_PC
|
||||
/* 0x033FC */ f32 current_ghost_lantern_light_power;
|
||||
#endif
|
||||
/* 0x03400 */ f32 field_0x3400;
|
||||
/* 0x03404 */ f32 field_0x3404;
|
||||
/* 0x03408 */ f32 field_0x3408;
|
||||
@@ -4525,13 +4509,9 @@ public:
|
||||
/* 0x035F4 */ cXyz mMidnaAtnPos;
|
||||
/* 0x03600 */ cXyz mMidnaHairAtnPos;
|
||||
/* 0x0360C */ cXyz mKandelaarFlamePos;
|
||||
/* 0x0360C */ cXyz mGhostLanternFlamePos;
|
||||
/* 0x03618 */ cXyz field_0x3618;
|
||||
/* 0x03624 */ cXyz field_0x3624;
|
||||
/* 0x03630 */ cXyz field_0x3630;
|
||||
/* 0x03618 */ cXyz ghost_lantern_0x3618;
|
||||
/* 0x03624 */ cXyz ghost_lantern_0x3624;
|
||||
/* 0x03630 */ cXyz ghost_lantern_0x3630;
|
||||
/* 0x0363C */ cXyz field_0x363c[4];
|
||||
/* 0x0366C */ cXyz field_0x366c[4];
|
||||
/* 0x0369C */ cXyz field_0x369c;
|
||||
@@ -6841,9 +6821,6 @@ public:
|
||||
static daAlinkHIO_boom_c0 const mBoomerang;
|
||||
static daAlinkHIO_bomb_c0 const mBomb;
|
||||
static daAlinkHIO_huLight_c0 const mLanternPL;
|
||||
#if TARGET_PC
|
||||
static daAlinkHIO_huLight_c0 const mGhostLanternPL;
|
||||
#endif
|
||||
static daAlinkHIO_kandelaar_c0 const mLantern;
|
||||
static daAlinkHIO_fmChain_c0 const mFmChain;
|
||||
static daAlinkHIO_magneBoots_c0 const mIronBoots;
|
||||
|
||||
@@ -71,7 +71,6 @@ void item_func_WOOD_STICK();
|
||||
void item_func_BOOMERANG();
|
||||
void item_func_SPINNER();
|
||||
void item_func_IRONBALL();
|
||||
void item_func_GHOST_LANTERN();
|
||||
void item_func_BOW();
|
||||
void item_func_HOOKSHOT();
|
||||
void item_func_HVY_BOOTS();
|
||||
@@ -261,7 +260,6 @@ int item_getcheck_func_WOOD_STICK();
|
||||
int item_getcheck_func_BOOMERANG();
|
||||
int item_getcheck_func_SPINNER();
|
||||
int item_getcheck_func_IRONBALL();
|
||||
int item_getcheck_func_GHOST_LANTERN();
|
||||
int item_getcheck_func_BOW();
|
||||
int item_getcheck_func_HOOKSHOT();
|
||||
int item_getcheck_func_HVY_BOOTS();
|
||||
|
||||
@@ -317,7 +317,7 @@ enum {
|
||||
/* 0xDE */ dItemNo_NOENTRY_222_e,
|
||||
/* 0xDF */ dItemNo_NOENTRY_223_e,
|
||||
/* 0xE0 */ dItemNo_POU_SPIRIT_e,
|
||||
/* 0xE1 */ dItemNo_GHOST_LANTERN_e,
|
||||
/* 0xE1 */ dItemNo_NOENTRY_225_e,
|
||||
/* 0xE2 */ dItemNo_NOENTRY_226_e,
|
||||
/* 0xE3 */ dItemNo_NOENTRY_227_e,
|
||||
/* 0xE4 */ dItemNo_NOENTRY_228_e,
|
||||
|
||||
@@ -86,8 +86,8 @@ public:
|
||||
/* 0x047 */ u8 field_0x47;
|
||||
/* 0x048 */ u8 mPoes;
|
||||
/* 0x049 */ u8 mPoesCopy;
|
||||
/* 0x04A */ u8 mItems[25];
|
||||
/* 0x062 */ u8 mItemsCopy[25];
|
||||
/* 0x04A */ u8 mItems[24];
|
||||
/* 0x062 */ u8 mItemsCopy[24];
|
||||
/* 0x07A */ u8 field_0x7a[24];
|
||||
/* 0x092 */ u8 mSwords[4];
|
||||
/* 0x096 */ u8 mShields[3];
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include <m_Do/m_Do_MemCardRWmng.h>
|
||||
#include <m_Do/m_Do_MemCard.h>
|
||||
#include <d/actor/d_a_alink.h>
|
||||
|
||||
void noAutoSave();
|
||||
void triggerAutoSave();
|
||||
|
||||
@@ -17,6 +17,7 @@ void ensure_initialized();
|
||||
void begin_record();
|
||||
void end_record();
|
||||
void begin_sim_tick();
|
||||
uint64_t sim_tick_seq();
|
||||
void begin_frame(bool enabled, bool is_sim_frame, float step);
|
||||
void interpolate();
|
||||
float get_interpolation_step();
|
||||
|
||||
@@ -108,7 +108,7 @@ struct fopAcM_search_prm {
|
||||
struct fOpAcm_HIO_entry_c : public mDoHIO_entry_c {
|
||||
virtual ~fOpAcm_HIO_entry_c() {}
|
||||
|
||||
#if DEBUG
|
||||
#if DEBUG && !TARGET_PC
|
||||
void removeHIO(const fopAc_ac_c* i_this) { removeHIO(*i_this); }
|
||||
void removeHIO(const fopAc_ac_c& i_this) { removeHIO(i_this.base); }
|
||||
void removeHIO(const fopEn_enemy_c& i_this) { removeHIO(i_this.base); }
|
||||
|
||||
@@ -28,7 +28,9 @@
|
||||
<string>${MACOSX_BUNDLE_SHORT_VERSION_STRING}</string>
|
||||
<key>NSHighResolutionCapable</key>
|
||||
<true/>
|
||||
<key>LSApplicationCategoryType</key>
|
||||
<string>public.app-category.adventure-games</string>
|
||||
<key>LSSupportsGameMode</key>
|
||||
<true/>
|
||||
<true/>
|
||||
</dict>
|
||||
</plist>
|
||||
|
||||
@@ -58,6 +58,10 @@ toast:active {
|
||||
background-color: rgba(45, 43, 26, 80%);
|
||||
}*/
|
||||
|
||||
b {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
toast heading {
|
||||
display: flex;
|
||||
gap: 18dp;
|
||||
|
||||
@@ -14,6 +14,10 @@ body {
|
||||
color: #E0DBC8;
|
||||
}
|
||||
|
||||
b {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
window {
|
||||
display: flex;
|
||||
flex-flow: column;
|
||||
|
||||
+6
-122
@@ -6100,21 +6100,6 @@ void daAlink_c::setItemMatrix(int param_0) {
|
||||
modelCalc(mpKanteraGlowModel);
|
||||
}
|
||||
|
||||
if (mEquipItem == dItemNo_GHOST_LANTERN_e) {
|
||||
simpleAnmPlay(mpGhostLanternGlowBtk);
|
||||
|
||||
mDoMtx_stack_c::copy(mpLinkModel->getAnmMtx(mLeftItemJntNo));
|
||||
mDoMtx_stack_c::transM(-2.0f, -0.1f, -0.7f);
|
||||
mDoMtx_stack_c::XYZrotM(cM_deg2s(100.0f), cM_deg2s(9.3f), cM_deg2s(183.0f));
|
||||
mDoMtx_stack_c::scaleM(0.75f, 0.75f, 0.75f);
|
||||
mpGhostLanternModel->setBaseTRMtx(mDoMtx_stack_c::get());
|
||||
|
||||
modelCalc(mpGhostLanternModel);
|
||||
mDoMtx_stack_c::transS(mGhostLanternFlamePos);
|
||||
mpGhostLanternGlowModel->setBaseTRMtx(mDoMtx_stack_c::get());
|
||||
modelCalc(mpGhostLanternGlowModel);
|
||||
}
|
||||
|
||||
setSwordPos();
|
||||
simpleAnmPlay(m_mSwordBtk);
|
||||
simpleAnmPlay(m_mSwordBrk);
|
||||
@@ -6935,7 +6920,7 @@ const daAlink_BckData* daAlink_c::getMainBckData(daAlink_c::daAlink_ANM i_anmID)
|
||||
{dRes_ID_ALANM_BCK_WAITHS_e, dRes_ID_ALANM_BCK_WAITHK_e},
|
||||
};
|
||||
|
||||
if (mEquipItem == dItemNo_KANTERA_e || mEquipItem == dItemNo_GHOST_LANTERN_e) {
|
||||
if (mEquipItem == dItemNo_KANTERA_e) {
|
||||
if (i_anmID == ANM_WAIT) {
|
||||
return &kandelaarAnm[0];
|
||||
}
|
||||
@@ -7577,12 +7562,7 @@ void daAlink_c::setBlendMoveAnime(f32 i_morf) {
|
||||
f32 sp2C;
|
||||
f32 sp28 = mpHIO->mMove.m.mFootPositionRatio;
|
||||
BOOL sp24 = checkEventRun();
|
||||
BOOL sp20 = checkBootsMoveAnime(1);
|
||||
#if TARGET_PC
|
||||
if (dusk::getSettings().game.enableFastIronBoots) {
|
||||
sp20 = FALSE;
|
||||
}
|
||||
#endif
|
||||
BOOL sp20 = checkBootsMoveAnime(1) IF_DUSK(&& !dusk::getSettings().game.enableFastIronBoots);
|
||||
|
||||
f32 var_f29;
|
||||
|
||||
@@ -8095,7 +8075,7 @@ void daAlink_c::setBlendAtnBackMoveAnime(f32 i_morf) {
|
||||
daAlink_ANM var_r27;
|
||||
daAlink_ANM var_r29;
|
||||
|
||||
if (checkBootsMoveAnime(1)) {
|
||||
if (checkBootsMoveAnime(1) IF_DUSK(&& !dusk::getSettings().game.enableFastIronBoots)) {
|
||||
mMaxSpeed = mpHIO->mAtnMove.m.mMaxBackwardsSpeed;
|
||||
var_f27 = mpHIO->mAtnMove.m.mMinBackWalkFrame;
|
||||
var_f31 = mpHIO->mAtnMove.m.mBackWalkChangeRate;
|
||||
@@ -12082,8 +12062,7 @@ void daAlink_c::itemUnequip(u16 i_itemID, f32 i_playSpeed) {
|
||||
u16 anm_id;
|
||||
const daAlinkHIO_anm_c* anm_data;
|
||||
|
||||
if (i_itemID == dItemNo_BOOMERANG_e || i_itemID == dItemNo_COPY_ROD_e ||
|
||||
i_itemID == dItemNo_KANTERA_e || i_itemID == dItemNo_GHOST_LANTERN_e ||
|
||||
if (i_itemID == dItemNo_BOOMERANG_e || i_itemID == dItemNo_COPY_ROD_e || i_itemID == dItemNo_KANTERA_e ||
|
||||
i_itemID == dItemNo_HOOKSHOT_e || checkBottleItem(i_itemID))
|
||||
{
|
||||
anm_id = dRes_ID_ALANM_BCK_TAKEL_e;
|
||||
@@ -14173,11 +14152,6 @@ BOOL daAlink_c::setItemModel() {
|
||||
}
|
||||
}
|
||||
|
||||
if (mEquipItem == dItemNo_GHOST_LANTERN_e) {
|
||||
setGhostLanternModel();
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (mEquipItem == dItemNo_KANTERA_e) {
|
||||
setKandelaarModel();
|
||||
return 1;
|
||||
@@ -14519,7 +14493,6 @@ enum daAlink_ItemProc {
|
||||
/* 13 */ ITEM_PROC_BOTTLE_SWING,
|
||||
/* 14 */ ITEM_PROC_NOT_USE_ITEM,
|
||||
/* 15 */ ITEM_PROC_GRASS_WHISTLE,
|
||||
/* 16 */ ITEM_PROC_GHOST_LANTERN,
|
||||
};
|
||||
|
||||
int daAlink_c::changeItemTriggerKeepProc(u8 i_selItemIdx, int i_procType) {
|
||||
@@ -14544,8 +14517,7 @@ int daAlink_c::changeItemTriggerKeepProc(u8 i_selItemIdx, int i_procType) {
|
||||
} else {
|
||||
procKandelaarPourInit();
|
||||
}
|
||||
}
|
||||
else if (i_procType == ITEM_PROC_FISHING_FOOD) {
|
||||
} else if (i_procType == ITEM_PROC_FISHING_FOOD) {
|
||||
procFishingFoodInit();
|
||||
} else if (i_procType == ITEM_PROC_BOOTS_EQUIP) {
|
||||
procBootsEquipInit();
|
||||
@@ -14850,43 +14822,6 @@ void daAlink_c::deleteEquipItem(BOOL i_isPlaySound, BOOL i_isDeleteKantera) {
|
||||
}
|
||||
}
|
||||
|
||||
#if TARGET_PC
|
||||
void daAlink_c::setGhostLanternLight() {
|
||||
const daAlinkHIO_huLight_c1* light_m = &mpHIO->mItem.mGhostLanternPL.m;
|
||||
|
||||
BOOL var_r28 = false;
|
||||
|
||||
f32 lightPower = 0.0f;
|
||||
daE_HP_c* foundPoe = (daE_HP_c*)fopAcM_Search(srchPoe, this);
|
||||
if (mEquipItem == dItemNo_GHOST_LANTERN_e && foundPoe != NULL) {
|
||||
lightPower = 1.0f;
|
||||
}
|
||||
|
||||
cLib_chaseF(¤t_ghost_lantern_light_power, lightPower, 0.25f);
|
||||
|
||||
cXyz spB8;
|
||||
f32 var_f27;
|
||||
if (current_ghost_lantern_light_power > 0.0f) {
|
||||
GXColor sp30 = {(u8)light_m->mColorR, (u8)light_m->mColorG, (u8)light_m->mColorB, 0xFF};
|
||||
sp30.r = 120;
|
||||
sp30.g = 150;
|
||||
sp30.b = 150;
|
||||
|
||||
Vec sp5C = {0.0f, light_m->mYOffset, light_m->mZOffset};
|
||||
|
||||
f32 var_f26;
|
||||
spB8 = mGhostLanternFlamePos;
|
||||
var_f27 = 0.0f;
|
||||
var_f26 = cM_sht2d(-shape_angle.y);
|
||||
|
||||
dKy_WolfEyeLight_set(&spB8, var_f27 + light_m->mXAngle, var_f26,
|
||||
(light_m->mWidth * current_ghost_lantern_light_power) / light_m->mPower, &sp30, current_ghost_lantern_light_power,
|
||||
light_m->mAngleAttenuationType,
|
||||
light_m->mDistanceAttenuationType);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
void daAlink_c::setLight() {
|
||||
const daAlinkHIO_huLight_c1* light_m = &mpHIO->mItem.mLanternPL.m;
|
||||
BOOL var_r28 = false;
|
||||
@@ -18325,8 +18260,7 @@ int daAlink_c::execute() {
|
||||
resetUpperAnime(UPPER_2, 5.0f);
|
||||
}
|
||||
|
||||
if ((mEquipItem == dItemNo_KANTERA_e || mEquipItem == dItemNo_GHOST_LANTERN_e) &&
|
||||
checkNoUpperAnime() && !checkKandelaarEquipAnime() &&
|
||||
if (mEquipItem == dItemNo_KANTERA_e && checkNoUpperAnime() && !checkKandelaarEquipAnime() &&
|
||||
(checkModeFlg(MODE_UNK_1000) || mProcID == PROC_CROUCH))
|
||||
{
|
||||
if (checkReinRide()) {
|
||||
@@ -18677,29 +18611,8 @@ int daAlink_c::execute() {
|
||||
setCollision();
|
||||
setAttentionPos();
|
||||
setLight();
|
||||
#if TARGET_PC
|
||||
setGhostLanternLight();
|
||||
#endif
|
||||
setEffect();
|
||||
|
||||
if (mEquipItem == dItemNo_GHOST_LANTERN_e) {
|
||||
cXyz effscale(0.75f, 0.75f, 0.75f);
|
||||
|
||||
static u16 particleNmaeDt[2] = {
|
||||
0x8789,
|
||||
0x878A,
|
||||
};
|
||||
|
||||
for (s32 i = 0; i < 2; i++) {
|
||||
ghostLanternFlameEffect[i] = dComIfGp_particle_set(ghostLanternFlameEffect[i], particleNmaeDt[i],
|
||||
&mGhostLanternFlamePos, 0, &effscale);
|
||||
}
|
||||
} else {
|
||||
for (s32 i = 0; i < 2; i++) {
|
||||
stopDrawParticle(ghostLanternFlameEffect[i]);
|
||||
}
|
||||
}
|
||||
|
||||
if (mClothesChangeWaitTimer != 0) {
|
||||
mDoMtx_stack_c::copy(mpLinkModel->getBaseTRMtx());
|
||||
|
||||
@@ -19401,10 +19314,6 @@ void daAlink_c::shadowDraw() {
|
||||
dComIfGd_addRealShadow(shadowID, mpKanteraModel);
|
||||
}
|
||||
|
||||
if (mEquipItem == dItemNo_GHOST_LANTERN_e) {
|
||||
dComIfGd_addRealShadow(shadowID, mpGhostLanternModel);
|
||||
}
|
||||
|
||||
if (checkEquipHeavyBoots()) {
|
||||
for (int i = 0; i < 2; i++) {
|
||||
dComIfGd_addRealShadow(shadowID, mpLinkBootModels[i]);
|
||||
@@ -19565,22 +19474,6 @@ int daAlink_c::draw() {
|
||||
}
|
||||
}
|
||||
|
||||
if (mEquipItem == dItemNo_GHOST_LANTERN_e) {
|
||||
daE_HP_c* foundPoe = (daE_HP_c*)fopAcM_Search(srchPoe, this);
|
||||
|
||||
for (s32 i = 0; i < 2; i++) {
|
||||
JPABaseEmitter* emitter_gl = dComIfGp_particle_getEmitter(ghostLanternFlameEffect[i]);
|
||||
if (emitter_gl != NULL) {
|
||||
emitter_gl->setLocalTranslation({2.5f, -15.0f, 0.0f});
|
||||
if (checkPlayerNoDraw() || foundPoe == NULL) {
|
||||
emitter_gl->stopDrawParticle();
|
||||
} else {
|
||||
emitter_gl->playDrawParticle();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (mClothesChangeWaitTimer != 0) {
|
||||
if (mProcID == PROC_METAMORPHOSE) {
|
||||
if (mProcVar3.field_0x300e > 0) {
|
||||
@@ -19906,15 +19799,6 @@ int daAlink_c::draw() {
|
||||
basicModelDraw(mpKanteraGlowModel);
|
||||
}
|
||||
|
||||
if (mEquipItem == dItemNo_GHOST_LANTERN_e) {
|
||||
daE_HP_c* foundPoe = (daE_HP_c*)fopAcM_Search(srchPoe, this);
|
||||
modelDraw(mpGhostLanternModel, isPlayerNoDraw);
|
||||
if (foundPoe != NULL) {
|
||||
preGhostLanternDraw();
|
||||
modelDraw(mpGhostLanternGlowModel, isPlayerNoDraw);
|
||||
}
|
||||
}
|
||||
|
||||
if (checkEquipHeavyBoots()) {
|
||||
GXColorS10 color = tevStr.TevColor;
|
||||
for (int i = 0; i < 2; i++) {
|
||||
|
||||
@@ -2184,7 +2184,7 @@ void daAlink_c::setGetSubBgm(int i_itemNo) {
|
||||
/* dItemNo_NOENTRY_222_e */ SETYPE_NONE,
|
||||
/* dItemNo_NOENTRY_223_e */ SETYPE_NONE,
|
||||
/* dItemNo_POU_SPIRIT_e */ SETYPE_ITEM_GET_POU,
|
||||
/* dItemNo_GHOST_LANTERN_e */ SETYPE_ITEM_GET,
|
||||
/* dItemNo_NOENTRY_225_e */ SETYPE_NONE,
|
||||
/* dItemNo_NOENTRY_226_e */ SETYPE_NONE,
|
||||
/* dItemNo_NOENTRY_227_e */ SETYPE_NONE,
|
||||
/* dItemNo_NOENTRY_228_e */ SETYPE_NONE,
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
#include "d/actor/d_a_tag_ss_drink.h"
|
||||
#include "m_Do/m_Do_lib.h"
|
||||
#include "SSystem/SComponent/c_math.h"
|
||||
#include "d/actor/d_a_e_hp.h"
|
||||
|
||||
static fopAc_ac_c* daAlink_searchTagKandelaar(fopAc_ac_c* i_actor, void* i_data) {
|
||||
UNUSED(i_data);
|
||||
@@ -139,50 +138,6 @@ int daAlink_c::kandelaarModelCallBack() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
int daAlink_c::ghostLanternModelCallBack() {
|
||||
cXyz sp44;
|
||||
mDoMtx_multVecZero(J3DSys::mCurrentMtx, &sp44);
|
||||
|
||||
ghost_lantern_0x3630 = ghost_lantern_0x3624;
|
||||
ghost_lantern_0x3624 = mGhostLanternFlamePos;
|
||||
|
||||
cXyz sp38 = (mGhostLanternFlamePos - sp44) + ghost_lantern_0x3618;
|
||||
sp38.y -= 3.0f;
|
||||
|
||||
cXyz sp2C;
|
||||
mDoMtx_multVec(J3DSys::mCurrentMtx, &cXyz::BaseZ, &sp2C);
|
||||
|
||||
s16 var_r29 = sp2C.atan2sX_Z();
|
||||
mDoMtx_stack_c::YrotS(-var_r29);
|
||||
mDoMtx_stack_c::multVec(&sp38, &sp38);
|
||||
|
||||
s16 var_r28 = cLib_minMaxLimit<s16>(cM_atan2s(-sp38.z, -sp38.y), -0x1800, 0x1800);
|
||||
s16 var_r27 = cLib_minMaxLimit<s16>(cM_atan2s(sp38.x, JMAFastSqrt(SQUARE(sp38.y) + SQUARE(sp38.z))), -0x1800, 0x1800);
|
||||
|
||||
mDoMtx_stack_c::transS(sp44);
|
||||
if (mProcID != PROC_OPEN_TREASURE && (mProcID != PROC_GET_ITEM || mProcVar4.field_0x3010 == 0)) {
|
||||
mDoMtx_stack_c::ZXYrotM(var_r28, var_r29, var_r27);
|
||||
}
|
||||
|
||||
static Vec const ghostLanternOffset = {0.0f, -20.0f, 0.0f};
|
||||
mDoMtx_stack_c::multVec(&ghostLanternOffset, &mGhostLanternFlamePos);
|
||||
|
||||
ghost_lantern_0x3618 = (mGhostLanternFlamePos - ghost_lantern_0x3624) * 0.9f;
|
||||
|
||||
if (!checkEndResetFlg1(ERFLG1_UNK_8) && mpGhostLanternModel != nullptr) {
|
||||
f32 scale = JMAFastSqrt(SQUARE(J3DSys::mCurrentMtx[0][0]) + SQUARE(J3DSys::mCurrentMtx[1][0]) + SQUARE(J3DSys::mCurrentMtx[2][0]));
|
||||
mDoMtx_stack_c::transS(J3DSys::mCurrentMtx[0][3], J3DSys::mCurrentMtx[1][3], J3DSys::mCurrentMtx[2][3]);
|
||||
mDoMtx_stack_c::ZXYrotM(var_r28, var_r29, var_r27);
|
||||
mDoMtx_stack_c::ZXYrotM(0, 0, -16384);
|
||||
mDoMtx_stack_c::scaleM(scale, scale, scale);
|
||||
|
||||
mpGhostLanternModel->setAnmMtx(1, mDoMtx_stack_c::get());
|
||||
cMtx_copy(mDoMtx_stack_c::get(), J3DSys::mCurrentMtx);
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
static int daAlink_kandelaarModelCallBack(J3DJoint* i_joint, int param_1) {
|
||||
UNUSED(i_joint);
|
||||
|
||||
@@ -195,18 +150,6 @@ static int daAlink_kandelaarModelCallBack(J3DJoint* i_joint, int param_1) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
static int daAlink_ghostLanternModelCallBack(J3DJoint* i_joint, int param_1) {
|
||||
UNUSED(i_joint);
|
||||
|
||||
daAlink_c* player_p = (daAlink_c*)j3dSys.getModel()->getUserArea();
|
||||
|
||||
if (param_1 == 0) {
|
||||
player_p->ghostLanternModelCallBack();
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
cXyz* daAlink_c::getKandelaarFlamePos() {
|
||||
if ((!checkNoResetFlg2(daPy_FLG2(FLG2_UNK_20000 | FLG2_UNK_1)) && !checkEndResetFlg1(ERFLG1_UNK_4)) ||
|
||||
checkWolf() || !checkNoResetFlg1(FLG1_UNK_80))
|
||||
@@ -221,60 +164,6 @@ BOOL daAlink_c::checkKandelaarEquipAnime() const {
|
||||
return checkUpperAnime(dRes_ID_ALANM_BCK_WAITHK_e) || checkUpperAnime(dRes_ID_ALANM_BCK_WAITK_e);
|
||||
}
|
||||
|
||||
void* daAlink_c::srchPoe(void* i_actor, void* i_this) {
|
||||
if (i_actor != NULL && i_actor != i_this) {
|
||||
if (fopAcM_IsExecuting(fopAcM_GetID(i_actor)) && fopAcM_GetName(i_actor) == fpcNm_E_HP_e) {
|
||||
return i_actor;
|
||||
}
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void daAlink_c::preGhostLanternDraw() {
|
||||
J3DMaterial* mat_p = mpGhostLanternGlowModel->getModelData()->getMaterialNodePointer(0);
|
||||
|
||||
J3DGXColorS10 color;
|
||||
color.r = 120;
|
||||
color.g = 150;
|
||||
color.b = 150;
|
||||
color.a = 255;
|
||||
mat_p->setTevColor(1, &color);
|
||||
|
||||
color.r = 0;
|
||||
color.g = 60;
|
||||
color.b = 101;
|
||||
mat_p->setTevColor(2, &color);
|
||||
|
||||
cXyz proj;
|
||||
mDoLib_project(&mGhostLanternFlamePos, &proj);
|
||||
|
||||
camera_process_class* camera_p = dComIfGp_getCamera(0);
|
||||
f32 trimHeight;
|
||||
if (camera_p != NULL) {
|
||||
trimHeight = camera_p->mCamera.TrimHeight();
|
||||
} else {
|
||||
trimHeight = 0.0f;
|
||||
}
|
||||
|
||||
if (proj.x > 0.0f && proj.x < FB_WIDTH && proj.y > trimHeight && proj.y < FB_HEIGHT - trimHeight) {
|
||||
dComIfGd_peekZ(proj.x, proj.y, &field_0x32c8);
|
||||
} else {
|
||||
field_0x32c8 = 0;
|
||||
}
|
||||
|
||||
f32 near_ = dComIfGd_getView()->near_;
|
||||
f32 far_ = dComIfGd_getView()->far_;
|
||||
|
||||
mDoLib_pos2camera(&mGhostLanternFlamePos, &proj);
|
||||
|
||||
proj.z += 30.0f;
|
||||
if (proj.z > -0.01f) {
|
||||
proj.z = -0.01f;
|
||||
}
|
||||
|
||||
field_0x344c = ((near_ + (far_ * near_) / proj.z) / (far_ - near_) + 1.0f) * 1.6777215E7f;
|
||||
}
|
||||
|
||||
void daAlink_c::preKandelaarDraw() {
|
||||
J3DMaterial* mat_p = mpKanteraGlowModel->getModelData()->getMaterialNodePointer(0);
|
||||
|
||||
@@ -319,16 +208,6 @@ void daAlink_c::preKandelaarDraw() {
|
||||
field_0x344c = ((near_ + (far_ * near_) / proj.z) / (far_ - near_) + 1.0f) * 1.6777215E7f;
|
||||
}
|
||||
|
||||
void daAlink_c::setGhostLanternModel() {
|
||||
field_0x2f94 = 0;
|
||||
|
||||
mDoMtx_multVecZero(mpLinkModel->getAnmMtx(mLeftItemJntNo), &mGhostLanternFlamePos);
|
||||
|
||||
ghost_lantern_0x3630 = ghost_lantern_0x3624;
|
||||
ghost_lantern_0x3624 = mGhostLanternFlamePos;
|
||||
ghost_lantern_0x3618 = cXyz::Zero;
|
||||
}
|
||||
|
||||
void daAlink_c::setKandelaarModel() {
|
||||
field_0x2f94 = 0;
|
||||
|
||||
|
||||
@@ -300,7 +300,6 @@ void daAlink_c::changeWolf() {
|
||||
mAtSph.SetR(40.0f);
|
||||
|
||||
mpKanteraModel = NULL;
|
||||
mpGhostLanternModel = NULL;
|
||||
mpLinkHatModel = NULL;
|
||||
mpLinkFaceModel = NULL;
|
||||
mpLinkHandModel = NULL;
|
||||
@@ -407,20 +406,12 @@ void daAlink_c::changeLink(int param_0) {
|
||||
|
||||
modelData = static_cast<J3DModelData*>(dComIfG_getObjectRes(mArcName, "ef_ktGlow.bmd"));
|
||||
mpKanteraGlowModel = initModel(modelData, 0x200);
|
||||
|
||||
mpKanteraGlowBtk = static_cast<J3DAnmTextureSRTKey*>(dComIfG_getObjectRes(mArcName, "ef_ktGlow.btk"));
|
||||
mpKanteraGlowBtk->setFrame(0.0f);
|
||||
mpKanteraGlowBtk->searchUpdateMaterialID(modelData);
|
||||
modelData->entryTexMtxAnimator(mpKanteraGlowBtk);
|
||||
|
||||
mpGhostLanternModel = initModelEnv(static_cast<J3DModelData*>(dComIfG_getObjectRes("E_HP", "hp_ori.bmd")), 0);
|
||||
|
||||
modelData = static_cast<J3DModelData*>(dComIfG_getObjectRes(mArcName, "ef_ktGlow.bmd"));
|
||||
mpGhostLanternGlowModel = initModel(modelData, 0x200);
|
||||
mpGhostLanternGlowBtk = static_cast<J3DAnmTextureSRTKey*>(dComIfG_getObjectRes(mArcName, "ef_ktGlow.btk"));
|
||||
mpGhostLanternGlowBtk->setFrame(0.0f);
|
||||
mpGhostLanternGlowBtk->searchUpdateMaterialID(modelData);
|
||||
modelData->entryTexMtxAnimator(mpGhostLanternGlowBtk);
|
||||
|
||||
mWoodSwordModel = initModel(static_cast<J3DModelData*>(dComIfG_getObjectRes(mArcName, "al_SWB.bmd")), 0);
|
||||
|
||||
mDoExt_setCurrentHeap(current_heap);
|
||||
@@ -513,10 +504,6 @@ void daAlink_c::changeLink(int param_0) {
|
||||
|
||||
mpKanteraModel->setUserArea((uintptr_t)this);
|
||||
mpKanteraModel->getModelData()->getJointNodePointer(1)->setCallBack(daAlink_kandelaarModelCallBack);
|
||||
|
||||
mpGhostLanternModel->setUserArea((uintptr_t)this);
|
||||
mpGhostLanternModel->getModelData()->getJointNodePointer(1)->setCallBack(daAlink_ghostLanternModelCallBack);
|
||||
|
||||
mZ2Link.setLinkState(var_r27);
|
||||
|
||||
#if VERSION != VERSION_SHIELD_DEBUG
|
||||
|
||||
@@ -157,6 +157,21 @@ static void* s_h_sub(void* i_actor, void* i_data) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
#if TARGET_PC
|
||||
static void sort_target_info_by_id() {
|
||||
for (int i = 1; i < target_info_count; i++) {
|
||||
void* key = target_info[i];
|
||||
fpc_ProcID key_id = fopAcM_GetID(key);
|
||||
int j = i - 1;
|
||||
while (j >= 0 && fopAcM_GetID(target_info[j]) > key_id) {
|
||||
target_info[j + 1] = target_info[j];
|
||||
j--;
|
||||
}
|
||||
target_info[j + 1] = key;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
static daPillar_c* search_hasira(e_mk_class* i_this) {
|
||||
fopEn_enemy_c* actor = (fopEn_enemy_c*)&i_this->actor;
|
||||
daPillar_c* pillar_p;
|
||||
@@ -170,6 +185,9 @@ static daPillar_c* search_hasira(e_mk_class* i_this) {
|
||||
|
||||
if (i_this->firstHasiraFlag == 0) {
|
||||
i_this->firstHasiraFlag++;
|
||||
#if TARGET_PC
|
||||
sort_target_info_by_id();
|
||||
#endif
|
||||
return (daPillar_c*)target_info[TREG_S(7) + 5];
|
||||
}
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
|
||||
#if TARGET_PC
|
||||
#include "dusk/dusk.h"
|
||||
#include "dusk/frame_interpolation.h"
|
||||
|
||||
namespace {
|
||||
// FRAME INTERP NOTE: Sim tick control point snapshots for interpolation
|
||||
@@ -32,6 +33,7 @@ int s_horseReinSimNumPrev;
|
||||
int s_horseReinSimNumCurr;
|
||||
bool s_horseReinSimPrevValid;
|
||||
bool s_horseReinSimCurrValid;
|
||||
uint64_t s_horseReinSimRolledSeq;
|
||||
} // namespace
|
||||
#endif
|
||||
|
||||
@@ -3033,10 +3035,14 @@ void daHorse_c::copyReinPos() {
|
||||
}
|
||||
#if TARGET_PC
|
||||
if (field_0x1204 > 0) {
|
||||
if (s_horseReinSimCurrValid && s_horseReinSimNumCurr > 0) {
|
||||
memcpy(s_horseReinSimPrev, s_horseReinSimCurr, s_horseReinSimNumCurr * sizeof(cXyz));
|
||||
s_horseReinSimNumPrev = s_horseReinSimNumCurr;
|
||||
s_horseReinSimPrevValid = true;
|
||||
const uint64_t simSeq = dusk::frame_interp::sim_tick_seq();
|
||||
if (simSeq != s_horseReinSimRolledSeq) {
|
||||
s_horseReinSimRolledSeq = simSeq;
|
||||
if (s_horseReinSimCurrValid && s_horseReinSimNumCurr > 0) {
|
||||
memcpy(s_horseReinSimPrev, s_horseReinSimCurr, s_horseReinSimNumCurr * sizeof(cXyz));
|
||||
s_horseReinSimNumPrev = s_horseReinSimNumCurr;
|
||||
s_horseReinSimPrevValid = true;
|
||||
}
|
||||
}
|
||||
memcpy(s_horseReinSimCurr, m_reinLine.getPos(0), field_0x1204 * sizeof(cXyz));
|
||||
s_horseReinSimNumCurr = field_0x1204;
|
||||
|
||||
@@ -1967,7 +1967,11 @@ static void demo_camera_shop(npc_henna_class* i_this) {
|
||||
i_this->mMsgFlow.init(actor, 0x365, 0, NULL);
|
||||
/* dSv_event_flag_c::KORO2_ALLCLEAR - Fishing - After all stages (8-8) of roll goal game cleared */
|
||||
dComIfGs_onEventBit(dSv_event_flag_c::saveBitLabels[0x335]);
|
||||
#if TARGET_PC
|
||||
dComIfGp_setItemRupeeCount(dComIfGs_getRupeeMax());
|
||||
#else
|
||||
dComIfGp_setItemRupeeCount(1000);
|
||||
#endif
|
||||
} else if ((lbl_82_bss_91 & 0x38) == 0) {
|
||||
i_this->mMsgFlow.init(actor, 0x34f, 0, NULL);
|
||||
/* dSv_event_flag_c::F_0469 - Fishing Pond - Reserved for fishing */
|
||||
|
||||
@@ -299,7 +299,8 @@ int daObjDrop_c::modeParentWait() {
|
||||
|
||||
#if TARGET_PC
|
||||
static inline BOOL checkGetCargoRide() {
|
||||
if ((daPy_getPlayerActorClass()->checkCargoCarry() && strcmp(dComIfGp_getStartStageName(), "F_SP112") == 0) ||
|
||||
if (daPy_getPlayerActorClass()->checkCargoCarry() &&
|
||||
strcmp(dComIfGp_getStartStageName(), "F_SP112") == 0 &&
|
||||
dComIfGs_isLightDropGetFlag(dComIfGp_getStartStageDarkArea()))
|
||||
{
|
||||
return true;
|
||||
|
||||
+10
-10
@@ -13,7 +13,7 @@ const u16 l_J_Ohana00_64TEX__height = 63;
|
||||
#if TARGET_PC
|
||||
#include "dusk/dvd_asset.hpp"
|
||||
using GameVersion = dusk::version::GameVersion;
|
||||
static u8* l_J_Ohana00_64TEX_get() { static u8 buf[0x800]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x9060}, {GameVersion::GcnPal, 0x9060}}, 0x800), true); return buf; }
|
||||
static u8* l_J_Ohana00_64TEX_get() { static u8 buf[0x800]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x9060}, {GameVersion::GcnPal, 0x9060}, {GameVersion::GcnJpn, 0x9060}}, 0x800), true); return buf; }
|
||||
#define l_J_Ohana00_64TEX (l_J_Ohana00_64TEX_get())
|
||||
#else
|
||||
#include "assets/l_J_Ohana00_64TEX.h"
|
||||
@@ -111,10 +111,10 @@ static u8 l_flowerTexCoord[] = {
|
||||
#if TARGET_PC
|
||||
using GameVersion = dusk::version::GameVersion;
|
||||
|
||||
static u8* l_J_hana00DL_get() { static u8 buf[0x150]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x9D20}, {GameVersion::GcnPal, 0x9D20}}, 0x150), true); return buf; }
|
||||
static u8* l_J_hana00_cDL_get() { static u8 buf[0xDE]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x9E80}, {GameVersion::GcnPal, 0x9E80}}, 0xDE), true); return buf; }
|
||||
static u8* l_matDL_get() { static u8 buf[0x99]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x9F60}, {GameVersion::GcnPal, 0x9F60}}, 0x99), true); return buf; }
|
||||
static u8* l_matLight4DL_get() { static u8 buf[0x99]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xA000}, {GameVersion::GcnPal, 0xA000}}, 0x99), true); return buf; }
|
||||
static u8* l_J_hana00DL_get() { static u8 buf[0x150]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x9D20}, {GameVersion::GcnPal, 0x9D20}, {GameVersion::GcnJpn, 0x9D20}}, 0x150), true); return buf; }
|
||||
static u8* l_J_hana00_cDL_get() { static u8 buf[0xDE]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x9E80}, {GameVersion::GcnPal, 0x9E80}, {GameVersion::GcnJpn, 0x9E80}}, 0xDE), true); return buf; }
|
||||
static u8* l_matDL_get() { static u8 buf[0x99]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x9F60}, {GameVersion::GcnPal, 0x9F60}, {GameVersion::GcnJpn, 0x9F60}}, 0x99), true); return buf; }
|
||||
static u8* l_matLight4DL_get() { static u8 buf[0x99]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xA000}, {GameVersion::GcnPal, 0xA000}, {GameVersion::GcnJpn, 0xA000}}, 0x99), true); return buf; }
|
||||
#define l_J_hana00DL (l_J_hana00DL_get())
|
||||
#define l_J_hana00_cDL (l_J_hana00_cDL_get())
|
||||
#define l_matDL (l_matDL_get())
|
||||
@@ -270,11 +270,11 @@ static u8 l_flowerTexCoord2[] = {
|
||||
#if TARGET_PC
|
||||
using GameVersion = dusk::version::GameVersion;
|
||||
|
||||
static u8* l_J_hana01DL_get() { static u8 buf[0x138]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xB7C0}, {GameVersion::GcnPal, 0xB7C0}}, 0x138), true); return buf; }
|
||||
static u8* l_J_hana01_c_00DL_get() { static u8 buf[0xDE]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xB900}, {GameVersion::GcnPal, 0xB900}}, 0xDE), true); return buf; }
|
||||
static u8* l_J_hana01_c_01DL_get() { static u8 buf[0x128]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xB9E0}, {GameVersion::GcnPal, 0xB9E0}}, 0x128), true); return buf; }
|
||||
static u8* l_mat2DL_get() { static u8 buf[0x99]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xBB20}, {GameVersion::GcnPal, 0xBB20}}, 0x99), true); return buf; }
|
||||
static u8* l_mat2Light4DL_get() { static u8 buf[0x99]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xBBC0}, {GameVersion::GcnPal, 0xBBC0}}, 0x99), true); return buf; }
|
||||
static u8* l_J_hana01DL_get() { static u8 buf[0x138]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xB7C0}, {GameVersion::GcnPal, 0xB7C0}, {GameVersion::GcnJpn, 0xB7C0}}, 0x138), true); return buf; }
|
||||
static u8* l_J_hana01_c_00DL_get() { static u8 buf[0xDE]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xB900}, {GameVersion::GcnPal, 0xB900}, {GameVersion::GcnJpn, 0xB900}}, 0xDE), true); return buf; }
|
||||
static u8* l_J_hana01_c_01DL_get() { static u8 buf[0x128]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xB9E0}, {GameVersion::GcnPal, 0xB9E0}, {GameVersion::GcnJpn, 0xB9E0}}, 0x128), true); return buf; }
|
||||
static u8* l_mat2DL_get() { static u8 buf[0x99]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xBB20}, {GameVersion::GcnPal, 0xBB20}, {GameVersion::GcnJpn, 0xBB20}}, 0x99), true); return buf; }
|
||||
static u8* l_mat2Light4DL_get() { static u8 buf[0x99]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0xBBC0}, {GameVersion::GcnPal, 0xBBC0}, {GameVersion::GcnJpn, 0xBBC0}}, 0x99), true); return buf; }
|
||||
#define l_J_hana01DL (l_J_hana01DL_get())
|
||||
#define l_J_hana01_c_00DL (l_J_hana01_c_00DL_get())
|
||||
#define l_J_hana01_c_01DL (l_J_hana01_c_01DL_get())
|
||||
|
||||
@@ -21,8 +21,8 @@ const u16 l_M_kusa05_RGBATEX__height = 31;
|
||||
#if TARGET_PC
|
||||
#include "dusk/dvd_asset.hpp"
|
||||
using GameVersion = dusk::version::GameVersion;
|
||||
static u8* l_M_kusa05_RGBATEX_get() { static u8 buf[0x800]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x7680}, {GameVersion::GcnPal, 0x7680}}, 0x800), true); return buf; }
|
||||
static u8* l_M_Hijiki00TEX_get() { static u8 buf[0x800]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x7E80}, {GameVersion::GcnPal, 0x7E80}}, 0x800), true); return buf; }
|
||||
static u8* l_M_kusa05_RGBATEX_get() { static u8 buf[0x800]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x7680}, {GameVersion::GcnPal, 0x7680}, {GameVersion::GcnJpn, 0x7680}}, 0x800), true); return buf; }
|
||||
static u8* l_M_Hijiki00TEX_get() { static u8 buf[0x800]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x7E80}, {GameVersion::GcnPal, 0x7E80}, {GameVersion::GcnJpn, 0x7E80}}, 0x800), true); return buf; }
|
||||
#define l_M_kusa05_RGBATEX (l_M_kusa05_RGBATEX_get())
|
||||
#define l_M_Hijiki00TEX (l_M_Hijiki00TEX_get())
|
||||
#else
|
||||
@@ -116,12 +116,12 @@ static u8 l_texCoord[160] = {
|
||||
#if TARGET_PC
|
||||
using GameVersion = dusk::version::GameVersion;
|
||||
|
||||
static u8* l_M_Kusa_9qDL_get() { static u8 buf[0xCB]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8B00}, {GameVersion::GcnPal, 0x8B00}}, 0xCB), true); return buf; }
|
||||
static u8* l_M_Kusa_9q_cDL_get() { static u8 buf[0xCB]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8BE0}, {GameVersion::GcnPal, 0x8BE0}}, 0xCB), true); return buf; }
|
||||
static u8* l_M_TenGusaDL_get() { static u8 buf[0xD4]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8CC0}, {GameVersion::GcnPal, 0x8CC0}}, 0xD4), true); return buf; }
|
||||
static u8* l_Tengusa_matDL_get() { static u8 buf[0xA8]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8DA0}, {GameVersion::GcnPal, 0x8DA0}}, 0xA8), true); return buf; }
|
||||
static u8* l_kusa9q_matDL_get() { static u8 buf[0xA8]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8E60}, {GameVersion::GcnPal, 0x8E60}}, 0xA8), true); return buf; }
|
||||
static u8* l_kusa9q_l4_matDL_get() { static u8 buf[0xA8]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8F20}, {GameVersion::GcnPal, 0x8F20}}, 0xA8), true); return buf; }
|
||||
static u8* l_M_Kusa_9qDL_get() { static u8 buf[0xCB]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8B00}, {GameVersion::GcnPal, 0x8B00}, {GameVersion::GcnJpn, 0x8B00}}, 0xCB), true); return buf; }
|
||||
static u8* l_M_Kusa_9q_cDL_get() { static u8 buf[0xCB]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8BE0}, {GameVersion::GcnPal, 0x8BE0}, {GameVersion::GcnJpn, 0x8BE0}}, 0xCB), true); return buf; }
|
||||
static u8* l_M_TenGusaDL_get() { static u8 buf[0xD4]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8CC0}, {GameVersion::GcnPal, 0x8CC0}, {GameVersion::GcnJpn, 0x8CC0}}, 0xD4), true); return buf; }
|
||||
static u8* l_Tengusa_matDL_get() { static u8 buf[0xA8]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8DA0}, {GameVersion::GcnPal, 0x8DA0}, {GameVersion::GcnJpn, 0x8DA0}}, 0xA8), true); return buf; }
|
||||
static u8* l_kusa9q_matDL_get() { static u8 buf[0xA8]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8E60}, {GameVersion::GcnPal, 0x8E60}, {GameVersion::GcnJpn, 0x8E60}}, 0xA8), true); return buf; }
|
||||
static u8* l_kusa9q_l4_matDL_get() { static u8 buf[0xA8]; static bool _ = (dusk::LoadArchivedRelAsset(buf, 'AMEM', "d_a_grass.rel", {{GameVersion::GcnUsa, 0x8F20}, {GameVersion::GcnPal, 0x8F20}, {GameVersion::GcnJpn, 0x8F20}}, 0xA8), true); return buf; }
|
||||
#define l_M_Kusa_9qDL (l_M_Kusa_9qDL_get())
|
||||
#define l_M_Kusa_9q_cDL (l_M_Kusa_9q_cDL_get())
|
||||
#define l_M_TenGusaDL (l_M_TenGusaDL_get())
|
||||
|
||||
@@ -143,13 +143,12 @@ void dBrightCheck_c::modeMove() {
|
||||
if (mDoCPd_c::getTrigA(PAD_1) || mDoCPd_c::getTrigStart(PAD_1)) {
|
||||
mDoAud_seStart(Z2SE_ENTER_GAME, NULL, 0, 0);
|
||||
#ifdef TARGET_PC
|
||||
dusk::speedrun::start();
|
||||
|
||||
if (dusk::getSettings().game.speedrunMode && !dusk::getSettings().game.hideTvSettingsScreen) {
|
||||
// start a new run if a run isn't already in progress
|
||||
if (!dusk::m_speedrunInfo.m_isRunStarted) {
|
||||
dusk::resetForSpeedrunMode();
|
||||
dusk::m_speedrunInfo.startRun();
|
||||
dusk::speedrun::start();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
#include "d/d_timer.h"
|
||||
#include "f_op/f_op_msg_mng.h"
|
||||
#include "f_op/f_op_scene_mng.h"
|
||||
#include "m_Do/m_Do_MemCard.h"
|
||||
#include "m_Do/m_Do_Reset.h"
|
||||
#include "m_Do/m_Do_controller_pad.h"
|
||||
#include "m_Do/m_Do_graphic.h"
|
||||
@@ -1238,6 +1239,13 @@ BOOL dComIfG_resetToOpening(scene_class* i_scene) {
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef TARGET_PC
|
||||
if (!mDoMemCd_isCardCommNone()) {
|
||||
return 0;
|
||||
}
|
||||
g_mDoMemCd_control.SaveSync();
|
||||
#endif
|
||||
|
||||
dComIfG_changeOpeningScene(i_scene, fpcNm_OPENING_SCENE_e);
|
||||
mDoAud_bgmStop(30);
|
||||
mDoAud_resetProcess();
|
||||
|
||||
+2
-10
@@ -236,7 +236,7 @@ static void (*item_func_ptr[256])() = {
|
||||
item_func_noentry,
|
||||
item_func_noentry,
|
||||
item_func_POU_SPIRIT,
|
||||
item_func_GHOST_LANTERN,
|
||||
item_func_noentry,
|
||||
item_func_noentry,
|
||||
item_func_noentry,
|
||||
item_func_noentry,
|
||||
@@ -504,7 +504,7 @@ static int (*item_getcheck_func_ptr[256])() = {
|
||||
item_getcheck_func_noentry,
|
||||
item_getcheck_func_noentry,
|
||||
item_getcheck_func_POU_SPIRIT,
|
||||
item_getcheck_func_GHOST_LANTERN,
|
||||
item_getcheck_func_noentry,
|
||||
item_getcheck_func_noentry,
|
||||
item_getcheck_func_noentry,
|
||||
item_getcheck_func_noentry,
|
||||
@@ -791,10 +791,6 @@ void item_func_IRONBALL() {
|
||||
dComIfGs_setItem(SLOT_6, dItemNo_IRONBALL_e);
|
||||
}
|
||||
|
||||
void item_func_GHOST_LANTERN() {
|
||||
dComIfGs_setItem(SLOT_7, dItemNo_GHOST_LANTERN_e);
|
||||
}
|
||||
|
||||
void item_func_BOW() {
|
||||
dComIfGs_setItem(SLOT_4, dItemNo_BOW_e);
|
||||
dComIfGs_setArrowNum(30);
|
||||
@@ -1457,10 +1453,6 @@ int item_getcheck_func_IRONBALL() {
|
||||
return dComIfGs_getItem(SLOT_6, true) == dItemNo_IRONBALL_e ? TRUE : FALSE;
|
||||
}
|
||||
|
||||
int item_getcheck_func_GHOST_LANTERN() {
|
||||
return dComIfGs_getItem(SLOT_7, true) == dItemNo_GHOST_LANTERN_e ? TRUE : FALSE;
|
||||
}
|
||||
|
||||
int item_getcheck_func_BOW() {
|
||||
return dComIfGs_getItem(SLOT_4, false) == dItemNo_BOW_e ? TRUE : FALSE;
|
||||
}
|
||||
|
||||
@@ -26,6 +26,10 @@
|
||||
#include "f_op/f_op_overlap_mng.h"
|
||||
#include "m_Do/m_Do_controller_pad.h"
|
||||
|
||||
#ifdef TARGET_PC
|
||||
#include "dusk/frame_interpolation.h"
|
||||
#endif
|
||||
|
||||
class dDlst_MENU_CAPTURE_c : public dDlst_base_c {
|
||||
public:
|
||||
virtual void draw() {
|
||||
@@ -1088,6 +1092,10 @@ void dMw_c::dMw_ring_create(u8 i_origin) {
|
||||
}
|
||||
|
||||
mpCapture->setCaptureFlag();
|
||||
|
||||
#ifdef TARGET_PC
|
||||
dusk::frame_interp::request_presentation_sync();
|
||||
#endif
|
||||
}
|
||||
|
||||
bool dMw_c::dMw_ring_delete() {
|
||||
|
||||
+67
-7
@@ -17,6 +17,62 @@ static bool isPalOrJpn() {
|
||||
return dusk::version::isRegionPal() || dusk::version::isRegionJpn();
|
||||
}
|
||||
|
||||
#if TARGET_PC
|
||||
static const char* l_mojiHira[65] = {
|
||||
"\x82\xA0", "\x82\xA2", "\x82\xA4", "\x82\xA6", "\x82\xA8", "\x82\xA9", "\x82\xAB", "\x82\xAD", "\x82\xAF", "\x82\xB1", "\x82\xB3", "\x82\xB5", "\x82\xB7",
|
||||
"\x82\xB9", "\x82\xBB", "\x82\xBD", "\x82\xBF", "\x82\xC2", "\x82\xC4", "\x82\xC6", "\x82\xC8", "\x82\xC9", "\x82\xCA", "\x82\xCB", "\x82\xCC", "\x82\xCD",
|
||||
"\x82\xD0", "\x82\xD3", "\x82\xD6", "\x82\xD9", "\x82\xDC", "\x82\xDD", "\x82\xDE", "\x82\xDF", "\x82\xE0", "\x82\xE2", "\x81\x40", "\x82\xE4", "\x81\x40",
|
||||
"\x82\xE6", "\x82\xE7", "\x82\xE8", "\x82\xE9", "\x82\xEA", "\x82\xEB", "\x82\xED", "\x81\x40", "\x82\xF0", "\x81\x40", "\x82\xF1", "\x82\x9F", "\x82\xA1",
|
||||
"\x82\xA3", "\x82\xA5", "\x82\xA7", "\x82\xE1", "\x81\x40", "\x82\xE3", "\x81\x40", "\x82\xE5", "\x82\xC1", "\x81\x40", "\x81\x5B", "\x81\x4A", "\x81\x4B",
|
||||
};
|
||||
|
||||
static const char* l_mojiHira2[65] = {
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x82\xAA", "\x82\xAC", "\x82\xAE", "\x82\xB0", "\x82\xB2", "\x82\xB4", "\x82\xB6", "\x82\xB8",
|
||||
"\x82\xBA", "\x82\xBC", "\x82\xBE", "\x82\xC0", "\x82\xC3", "\x82\xC5", "\x82\xC7", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x82\xCE",
|
||||
"\x82\xD1", "\x82\xD4", "\x82\xD7", "\x82\xDA", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
};
|
||||
|
||||
static const char* l_mojiHira3[65] = {
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x82\xCF",
|
||||
"\x82\xD2", "\x82\xD5", "\x82\xD8", "\x82\xDB", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
};
|
||||
|
||||
static const char* l_mojikata[65] = {
|
||||
"\x83\x41", "\x83\x43", "\x83\x45", "\x83\x47", "\x83\x49", "\x83\x4A", "\x83\x4C", "\x83\x4E", "\x83\x50", "\x83\x52", "\x83\x54", "\x83\x56", "\x83\x58",
|
||||
"\x83\x5A", "\x83\x5C", "\x83\x5E", "\x83\x60", "\x83\x63", "\x83\x65", "\x83\x67", "\x83\x69", "\x83\x6A", "\x83\x6B", "\x83\x6C", "\x83\x6D", "\x83\x6E",
|
||||
"\x83\x71", "\x83\x74", "\x83\x77", "\x83\x7A", "\x83\x7D", "\x83\x7E", "\x83\x80", "\x83\x81", "\x83\x82", "\x83\x84", "\x81\x40", "\x83\x86", "\x81\x40",
|
||||
"\x83\x88", "\x83\x89", "\x83\x8A", "\x83\x8B", "\x83\x8C", "\x83\x8D", "\x83\x8F", "\x81\x40", "\x83\x93", "\x81\x40", "\x83\x93", "\x83\x40", "\x83\x42"
|
||||
"\x83\x44", "\x83\x46", "\x83\x48", "\x83\x83", "\x81\x40", "\x83\x85", "\x81\x40", "\x83\x87", "\x83\x62", "\x81\x40", "\x81\x5B", "\x81\x4A", "\x81\x4B",
|
||||
};
|
||||
|
||||
static const char* l_mojikata2[65] = {
|
||||
"\x81\x8F", "\x81\x8F", "\x83\x94", "\x81\x8F", "\x81\x8F", "\x83\x4B", "\x83\x4D", "\x83\x4F", "\x83\x51", "\x83\x53", "\x83\x55", "\x83\x57", "\x83\x59",
|
||||
"\x83\x5B", "\x83\x5D", "\x83\x5F", "\x83\x61", "\x83\x64", "\x83\x66", "\x83\x68", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x83\x6F",
|
||||
"\x83\x72", "\x83\x75", "\x83\x78", "\x83\x7B", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
};
|
||||
|
||||
static const char* l_mojikata3[65] = {
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x83\x70",
|
||||
"\x83\x73", "\x83\x76", "\x83\x79", "\x83\x7C", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
"\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F", "\x81\x8F",
|
||||
};
|
||||
|
||||
static const char* l_mojiEisu[65] = {
|
||||
"A", "N", "a", "n", "1", "B", "O", "b", "o", "2", "C", "P", "c", "p", "3", "D", "Q",
|
||||
"d", "q", "4", "E", "R", "e", "r", "5", "F", "S", "f", "s", "6", "G", "T", "g", "t",
|
||||
"7", "H", "U", "h", "u", "8", "I", "V", "i", "v", "9", "J", "W", "j", "w", "0", "K",
|
||||
"X", "k", "x", ",", "L", "Y", "l", "y", ".", "M", "Z", "m", "z", " ",
|
||||
};
|
||||
#else
|
||||
static const char* l_mojiHira[65] = {
|
||||
"あ", "い", "う", "え", "お", "か", "き", "く", "け", "こ", "さ", "し", "す",
|
||||
"せ", "そ", "た", "ち", "つ", "て", "と", "な", "に", "ぬ", "ね", "の", "は",
|
||||
@@ -71,22 +127,23 @@ static const char* l_mojiEisu[65] = {
|
||||
"7", "H", "U", "h", "u", "8", "I", "V", "i", "v", "9", "J", "W", "j", "w", "0", "K",
|
||||
"X", "k", "x", ",", "L", "Y", "l", "y", ".", "M", "Z", "m", "z", " ",
|
||||
};
|
||||
#endif
|
||||
|
||||
#if TARGET_PC
|
||||
// The game normally mutates this string list to fill in the real character codes.
|
||||
// That can't work on a modern platform, so instead I've filled them out ahead of time.
|
||||
static const char* l_mojiEisuPal_1[65] = {
|
||||
"A", "N", "\xC0", "\xCF", "1", "B", "O", "\xC1", "\xD0", "2", "C", "P", "\xC2", "\xD1", "3", "D", "Q",
|
||||
"\xC3", "\xD2", "4", "E", "R", "\xC4", "\xD3", "5", "F", "S", "\xC5", "\xD4", "6", "G", "T", "\xC6", "\xD5",
|
||||
"7", "H", "U", "\xC7", "\xD6", "8", "I", "V", "\xC8", "\xD7", "9", "J", "W", "\xC9", "\xD8", "0", "K",
|
||||
"X", "\xCA", "\xD9", ",", "L", "Y", "\xCB", "\xDA", ".", "M", "Z", "\xCC", "\xDB", " ",
|
||||
"\xC4", "\xD2", "4", "E", "R", "\xC6", "\xD3", "5", "F", "S", "\xC7", "\xD4", "6", "G", "T", "\xC8", "\xD6",
|
||||
"7", "H", "U", "\xC9", "\x8C", "8", "I", "V", "\xCA", "\xD9", "9", "J", "W", "\xCB", "\xDA", "0", "K",
|
||||
"X", "\xCC", "\xDB", ",", "L", "Y", "\xCD", "\xDC", ".", "M", "Z", "\xCE", "\x2D", " ",
|
||||
};
|
||||
|
||||
static const char* l_mojiEisuPal_2[65] = {
|
||||
"a", "n", "\xE0", "\xEF", "1", "b", "o", "\xE1", "\xF0", "2", "c", "p", "\xE2", "\xF1", "3", "d", "q",
|
||||
"\xE3", "\xF2", "4", "e", "r", "\xE4", "\xF3", "5", "f", "s", "\xE5", "\xF4", "6", "g", "t", "\xE6",
|
||||
"\xF5", "7", "h", "u", "\xE7", "\xF6", "8", "i", "v", "\xE8", "\xF7", "9", "j", "w", "\xE9", "\xF8", "0",
|
||||
"k", "x", "\xEA", "\xF9", ",", "l", "y", "\xEB", "\xFA", ".", "m", "z", "\xEC", "\xFB", " ",
|
||||
"\xE4", "\xF2", "4", "e", "r", "\xE6", "\xF3", "5", "f", "s", "\xE7", "\xF4", "6", "g", "t", "\xE8",
|
||||
"\xF6", "7", "h", "u", "\xE9", "\x9C", "8", "i", "v", "\xEA", "\xF9", "9", "j", "w", "\xEB", "\xFA", "0",
|
||||
"k", "x", "\xEC", "\xFB", ",", "l", "y", "\xED", "\xFC", ".", "m", "z", "\xEE", "\xDF", " ",
|
||||
};
|
||||
#elif REGION_PAL
|
||||
static const char* l_mojiEisuPal_1[65] = {
|
||||
@@ -295,6 +352,7 @@ void dName_c::_move() {
|
||||
}
|
||||
} else {
|
||||
#endif
|
||||
#if !TARGET_PC
|
||||
if (mDoCPd_c::getTrigRight(PAD_1)) {
|
||||
// BUG: this check only fails if the cursor is at exactly 7
|
||||
// setMoji allows the cursor to reach 8, which is out of bounds here
|
||||
@@ -311,7 +369,9 @@ void dName_c::_move() {
|
||||
mCurPos--;
|
||||
nameCursorMove();
|
||||
}
|
||||
} else if (mDoCPd_c::getTrigB(PAD_1)) {
|
||||
} else
|
||||
#endif
|
||||
if (mDoCPd_c::getTrigB(PAD_1)) {
|
||||
if (mCurPos == 0) {
|
||||
mDoAud_seStart(Z2SE_SY_MENU_BACK, 0, 0, 0);
|
||||
field_0x2ac = mSelProc;
|
||||
|
||||
+8
-4
@@ -907,7 +907,14 @@ dScnLogo_c::~dScnLogo_c() {
|
||||
mDoExt_getRubyFont();
|
||||
mDoExt_setAraCacheSize(free_size - aram_heap->getTotalFreeSize());
|
||||
|
||||
#if VERSION == VERSION_GCN_JPN
|
||||
#if TARGET_PC
|
||||
if (getGameVersion() == GameVersion::GcnJpn) {
|
||||
if (dComIfGp_getFontArchive() != NULL) {
|
||||
dComIfGp_getFontArchive()->unmount();
|
||||
dComIfGp_setFontArchive(NULL);
|
||||
}
|
||||
}
|
||||
#elif VERSION == VERSION_GCN_JPN
|
||||
if (dComIfGp_getFontArchive() != NULL) {
|
||||
dComIfGp_getFontArchive()->unmount();
|
||||
dComIfGp_setFontArchive(NULL);
|
||||
@@ -1481,9 +1488,6 @@ void dScnLogo_c::dvdDataLoad() {
|
||||
OS_REPORT("\x1b[32m%d archiveHeap->getTotalFreeSize %08x\n\x1b[m", 2421, archiveHeap->getTotalFreeSize());
|
||||
archiveHeap->dump_sort();
|
||||
|
||||
rt = dComIfG_setObjectRes("E_HP", (u8)0, NULL);
|
||||
JUT_ASSERT(2425, rt == 1);
|
||||
|
||||
rt = dComIfG_setObjectRes("Alink", (u8)0, NULL);
|
||||
JUT_ASSERT(2429, rt == 1);
|
||||
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "d/d_meter2_info.h"
|
||||
#include "d/d_s_name.h"
|
||||
#include "dusk/imgui/ImGuiConsole.hpp"
|
||||
#include "dusk/livesplit.h"
|
||||
#include "dusk/memory.h"
|
||||
#include "dusk/speedrun.h"
|
||||
#include "dusk/settings.h"
|
||||
@@ -422,6 +423,7 @@ void dScnName_c::changeGameScene() {
|
||||
if (!dusk::m_speedrunInfo.m_isRunStarted) {
|
||||
dusk::resetForSpeedrunMode();
|
||||
dusk::m_speedrunInfo.startRun();
|
||||
dusk::speedrun::start();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+8
-10
@@ -30,7 +30,9 @@
|
||||
#if TARGET_PC
|
||||
#include "dusk/settings.h"
|
||||
#include <f_ap/f_ap_game.h>
|
||||
#include <dusk/autosave.h>
|
||||
|
||||
#include "dusk/string.hpp"
|
||||
#define strcpy dusk::SafeStringCopy
|
||||
#endif
|
||||
|
||||
static u8 dSv_item_rename(u8 i_itemNo) {
|
||||
@@ -349,10 +351,6 @@ void dSv_player_item_c::setItem(int i_slotNo, u8 i_itemNo) {
|
||||
dComIfGp_setSelectItem(i);
|
||||
}
|
||||
}
|
||||
|
||||
#if TARGET_PC
|
||||
triggerAutoSave();
|
||||
#endif
|
||||
}
|
||||
|
||||
u8 dSv_player_item_c::getItem(int i_slotNo, bool i_checkCombo) const {
|
||||
@@ -432,11 +430,11 @@ u8 dSv_player_item_c::getItem(int i_slotNo, bool i_checkCombo) const {
|
||||
}
|
||||
|
||||
void dSv_player_item_c::setLineUpItem() {
|
||||
static u8 i_item_lst[24] = {
|
||||
static u8 i_item_lst[23] = {
|
||||
10, 8, 6, 2, 9, 4, 3,
|
||||
0, 1, 7, 23, 20, 5, 15,
|
||||
16, 17, 11, 12, 13, 14, 19,
|
||||
18, 22, 21
|
||||
0, 1, 23, 20, 5, 15, 16,
|
||||
17, 11, 12, 13, 14, 19, 18,
|
||||
22, 21
|
||||
};
|
||||
|
||||
int slot_idx = 0;
|
||||
@@ -445,7 +443,7 @@ void dSv_player_item_c::setLineUpItem() {
|
||||
mItemSlots[i] = dItemNo_NONE_e;
|
||||
}
|
||||
|
||||
for (int i = 0; i < 24; i++) {
|
||||
for (int i = 0; i < 23; i++) {
|
||||
u8 current = i_item_lst[i];
|
||||
if (mItems[current] != dItemNo_NONE_e) {
|
||||
mItemSlots[slot_idx] = current;
|
||||
|
||||
@@ -191,13 +191,17 @@ std::vector<AchievementSystem::Entry> AchievementSystem::makeEntries() {
|
||||
}
|
||||
|
||||
bool hasJewelRod = false;
|
||||
for (int slot = 0; slot < 24 && !hasJewelRod; ++slot) {
|
||||
bool hasAncientDoc = false;
|
||||
for (int slot = 0; slot < 24; ++slot) {
|
||||
const u8 item = dComIfGs_getItem(slot, false);
|
||||
if (item == dItemNo_JEWEL_ROD_e || item == dItemNo_JEWEL_BEE_ROD_e || item == dItemNo_JEWEL_WORM_ROD_e) {
|
||||
hasJewelRod = true;
|
||||
}
|
||||
if (item == dItemNo_ANCIENT_DOCUMENT_e || item == dItemNo_ANCIENT_DOCUMENT2_e || item == dItemNo_AIR_LETTER_e) {
|
||||
hasAncientDoc = true;
|
||||
}
|
||||
}
|
||||
if (!hasJewelRod) {
|
||||
if (!hasJewelRod || !hasAncientDoc) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -212,7 +216,6 @@ std::vector<AchievementSystem::Entry> AchievementSystem::makeEntries() {
|
||||
dItemNo_KANTERA_e,
|
||||
dItemNo_PACHINKO_e,
|
||||
dItemNo_HAWK_EYE_e,
|
||||
dItemNo_ANCIENT_DOCUMENT_e,
|
||||
dItemNo_HORSE_FLUTE_e,
|
||||
};
|
||||
for (u8 required : requiredWheelItems) {
|
||||
|
||||
+16
-2
@@ -14,9 +14,23 @@ static AutoSaveFuncs AutoSaveFuncsProc[] = {
|
||||
|
||||
void noAutoSave() {}
|
||||
|
||||
bool canAutoSave() {
|
||||
daAlink_c* player = (daAlink_c*)daAlink_getAlinkActorClass();
|
||||
if (player == nullptr) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (player->checkCargoCarry() || player->checkCanoeRide()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return dusk::getSettings().game.autoSave && shouldAutoSave && mAutoSaveProc == 0 &&
|
||||
strcmp(dComIfGp_getStartStageName(), "F_SP102") != 0 &&
|
||||
strcmp(dComIfGp_getStartStageName(), "F_SP112") != 0;
|
||||
}
|
||||
|
||||
void triggerAutoSave() {
|
||||
if (dusk::getSettings().game.autoSave && shouldAutoSave && mAutoSaveProc == 0 &&
|
||||
strcmp(dComIfGp_getStartStageName(), "F_SP102") != 0)
|
||||
if (canAutoSave())
|
||||
{
|
||||
mAutoSaveProc = 1;
|
||||
}
|
||||
|
||||
@@ -21,6 +21,7 @@ bool g_sync_presentation = false;
|
||||
float g_step = 0.0f;
|
||||
bool g_is_sim_frame = false;
|
||||
bool g_ui_tick_pending = false;
|
||||
uint64_t g_sim_tick_seq = 0;
|
||||
|
||||
Recording g_current_recording;
|
||||
Recording g_previous_recording;
|
||||
@@ -66,19 +67,18 @@ void copy_view_to_snap(CameraSnapshot* dst, const view_class& v) {
|
||||
}
|
||||
|
||||
inline void lerp_matrix(Mtx out, const Mtx lhs, const Mtx rhs, float step) {
|
||||
const float old_weight = 1.0f - step;
|
||||
for (size_t row = 0; row < 3; ++row) {
|
||||
for (size_t col = 0; col < 4; ++col) {
|
||||
out[row][col] = lhs[row][col] * old_weight + rhs[row][col] * step;
|
||||
const float l = lhs[row][col];
|
||||
out[row][col] = l + (rhs[row][col] - l) * step;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
inline void lerp_xyz(cXyz* out, const cXyz& lhs, const cXyz& rhs, float step) {
|
||||
const float old_weight = 1.0f - step;
|
||||
out->x = lhs.x * old_weight + rhs.x * step;
|
||||
out->y = lhs.y * old_weight + rhs.y * step;
|
||||
out->z = lhs.z * old_weight + rhs.z * step;
|
||||
out->x = lhs.x + (rhs.x - lhs.x) * step;
|
||||
out->y = lhs.y + (rhs.y - lhs.y) * step;
|
||||
out->z = lhs.z + (rhs.z - lhs.z) * step;
|
||||
}
|
||||
|
||||
static s16 lerp_bank(s16 a, s16 b, f32 t) {
|
||||
@@ -135,6 +135,11 @@ void begin_sim_tick() {
|
||||
|
||||
s_interpolationCallBackWork.clear();
|
||||
s_cam_prev = std::move(s_cam_curr);
|
||||
++g_sim_tick_seq;
|
||||
}
|
||||
|
||||
uint64_t sim_tick_seq() {
|
||||
return g_sim_tick_seq;
|
||||
}
|
||||
|
||||
void begin_frame(bool enabled, bool is_sim_frame, float step) {
|
||||
|
||||
@@ -263,7 +263,7 @@ namespace dusk {
|
||||
}
|
||||
|
||||
if (getSettings().game.enableResetKeybind && ImGui::GetIO().KeyCtrl &&
|
||||
ImGui::IsKeyPressed(ImGuiKey_R) && !fpcM_SearchByName(fpcNm_LOGO_SCENE_e))
|
||||
ImGui::IsKeyReleased(ImGuiKey_R) && !fpcM_SearchByName(fpcNm_LOGO_SCENE_e))
|
||||
{
|
||||
JUTGamePad::C3ButtonReset::sResetSwitchPushing = true;
|
||||
}
|
||||
@@ -322,8 +322,8 @@ namespace dusk {
|
||||
}
|
||||
ImGui::PushFont(ImGuiEngine::fontLarge);
|
||||
ImGuiTextCenter("Failed to initialize any graphics backend.");
|
||||
ImGuiTextCenter("\nYour system may be misconfigured, or your hardware may not support the required versions of any of the available backends.");
|
||||
ImGuiTextCenter("\nA clean reinstall of Dusklight may help. For further assistance, please visit #tech-support on the Twilit Realm Discord server.");
|
||||
ImGuiTextCenter("\nDusklight requires Vulkan 1.1+, or Direct X 12.0.");
|
||||
ImGuiTextCenter("\nTry updating your Operating System and GPU drivers.");
|
||||
const auto& style = ImGui::GetStyle();
|
||||
const auto retrySize = ImGui::CalcTextSize("Retry (Auto backend)");
|
||||
const auto quitSize = ImGui::CalcTextSize("Quit");
|
||||
|
||||
@@ -251,7 +251,7 @@ namespace dusk {
|
||||
{ dItemNo_NOENTRY_222_e, {"Reserved"} },
|
||||
{ dItemNo_NOENTRY_223_e, {"Reserved"} },
|
||||
{ dItemNo_POU_SPIRIT_e, {"Poe Soul"} },
|
||||
{ dItemNo_GHOST_LANTERN_e, {"Ghost Lantern", ITEMTYPE_EQUIP_e} },
|
||||
{ dItemNo_NOENTRY_225_e, {"Reserved"} },
|
||||
{ dItemNo_NOENTRY_226_e, {"Reserved"} },
|
||||
{ dItemNo_NOENTRY_227_e, {"Reserved"} },
|
||||
{ dItemNo_NOENTRY_228_e, {"Reserved"} },
|
||||
@@ -393,7 +393,6 @@ namespace dusk {
|
||||
{ SLOT_4, dItemNo_BOW_e },
|
||||
{ SLOT_5, dItemNo_HAWK_EYE_e },
|
||||
{ SLOT_6, dItemNo_IRONBALL_e },
|
||||
{ SLOT_7, dItemNo_GHOST_LANTERN_e},
|
||||
{ SLOT_8, dItemNo_COPY_ROD_e },
|
||||
{ SLOT_9, dItemNo_HOOKSHOT_e },
|
||||
{ SLOT_10, dItemNo_W_HOOKSHOT_e },
|
||||
|
||||
@@ -60,18 +60,6 @@ const char* verification_state_name(dusk::DiscVerificationState state) noexcept
|
||||
|
||||
namespace dusk::iso {
|
||||
|
||||
enum class Platform : u8 {
|
||||
GameCube,
|
||||
Wii,
|
||||
};
|
||||
|
||||
enum class Region : u8 {
|
||||
NorthAmerica,
|
||||
Europe,
|
||||
Japan,
|
||||
Korea,
|
||||
};
|
||||
|
||||
struct KnownDisc {
|
||||
std::string_view id;
|
||||
Platform platform;
|
||||
@@ -88,7 +76,7 @@ struct KnownDisc {
|
||||
|
||||
constexpr auto KNOWN_DISCS = std::to_array<KnownDisc>({
|
||||
{"GZ2E01", Platform::GameCube, Region::NorthAmerica, "14e886f08e548a000afde98a3195e788"},
|
||||
{"GZ2J01", Platform::GameCube, Region::Japan},
|
||||
{"GZ2J01", Platform::GameCube, Region::Japan, "5967dc7a6a553652f4d2050aeef6f368"},
|
||||
{"GZ2P01", Platform::GameCube, Region::Europe, "9ef597588b0035ca9e91b333fa9a8a7e"},
|
||||
{"RZDE01", Platform::Wii, Region::NorthAmerica},
|
||||
{"RZDJ01", Platform::Wii, Region::Japan},
|
||||
@@ -216,7 +204,9 @@ ValidationError validate(const char* path, VerificationStatus& status, DiscInfo&
|
||||
return ValidationError::WrongGame;
|
||||
}
|
||||
status.knownDisc = knownDisc;
|
||||
info.isPal = knownDisc->region == Region::Europe;
|
||||
|
||||
info.platform = knownDisc->platform;
|
||||
info.region = knownDisc->region;
|
||||
if (!knownDisc->supported) {
|
||||
return ValidationError::WrongVersion;
|
||||
}
|
||||
@@ -251,7 +241,9 @@ ValidationError inspect(const char* path, DiscInfo& info) {
|
||||
if (!knownDisc) {
|
||||
return ValidationError::WrongGame;
|
||||
}
|
||||
info.isPal = knownDisc->region == Region::Europe;
|
||||
|
||||
info.platform = knownDisc->platform;
|
||||
info.region = knownDisc->region;
|
||||
if (!knownDisc->supported) {
|
||||
return ValidationError::WrongVersion;
|
||||
}
|
||||
@@ -260,7 +252,7 @@ ValidationError inspect(const char* path, DiscInfo& info) {
|
||||
|
||||
bool isPal(const char* path) {
|
||||
DiscInfo info{};
|
||||
return inspect(path, info) == ValidationError::Success && info.isPal;
|
||||
return inspect(path, info) == ValidationError::Success && info.region == Region::Europe;
|
||||
}
|
||||
|
||||
void log_verification_state(std::string_view path, DiscVerificationState state) {
|
||||
|
||||
@@ -17,6 +17,18 @@ enum class ValidationError : u8 {
|
||||
Success
|
||||
};
|
||||
|
||||
enum class Platform : u8 {
|
||||
GameCube,
|
||||
Wii,
|
||||
};
|
||||
|
||||
enum class Region : u8 {
|
||||
NorthAmerica,
|
||||
Europe,
|
||||
Japan,
|
||||
Korea,
|
||||
};
|
||||
|
||||
struct VerificationStatus {
|
||||
std::atomic_size_t bytesRead = 0;
|
||||
std::atomic_size_t bytesTotal = 0;
|
||||
@@ -25,7 +37,8 @@ struct VerificationStatus {
|
||||
};
|
||||
|
||||
struct DiscInfo {
|
||||
bool isPal = false;
|
||||
Platform platform = Platform::GameCube;
|
||||
Region region = Region::NorthAmerica;
|
||||
};
|
||||
|
||||
ValidationError inspect(const char* path, DiscInfo& info);
|
||||
|
||||
@@ -450,7 +450,7 @@ std::map<int, itemInfo> itemMap = {
|
||||
{dItemNo_NOENTRY_222_e, {"Reserved"}},
|
||||
{dItemNo_NOENTRY_223_e, {"Reserved"}},
|
||||
{dItemNo_POU_SPIRIT_e, {"Poe Soul"}},
|
||||
{dItemNo_GHOST_LANTERN_e, {"Reserved"}},
|
||||
{dItemNo_NOENTRY_225_e, {"Reserved"}},
|
||||
{dItemNo_NOENTRY_226_e, {"Reserved"}},
|
||||
{dItemNo_NOENTRY_227_e, {"Reserved"}},
|
||||
{dItemNo_NOENTRY_228_e, {"Reserved"}},
|
||||
|
||||
@@ -147,7 +147,7 @@ Rml::String back_button_name() {
|
||||
#if defined(TARGET_ANDROID) || (defined(__APPLE__) && TARGET_OS_IOS && !TARGET_OS_MACCATALYST)
|
||||
constexpr auto kMenuNotificationPrefix = "3-finger tap or";
|
||||
#else
|
||||
constexpr auto kMenuNotificationPrefix = "Press F1 or";
|
||||
constexpr auto kMenuNotificationPrefix = "Press <b>F1</b> or";
|
||||
#endif
|
||||
|
||||
Rml::Element* create_menu_notification(Rml::Element* parent) {
|
||||
@@ -169,7 +169,7 @@ Rml::Element* create_menu_notification(Rml::Element* parent) {
|
||||
append(row, "span")->SetInnerRML(kMenuNotificationPrefix);
|
||||
auto* icon = append(row, "icon");
|
||||
icon->SetClass("controller", true);
|
||||
append(row, "span")->SetInnerRML(escape(padButton));
|
||||
append(row, "span")->SetInnerRML("<b>" + escape(padButton) + "</b>");
|
||||
append(row, "span")->SetInnerRML("to open menu");
|
||||
|
||||
return elem;
|
||||
|
||||
@@ -877,8 +877,36 @@ void Prelaunch::update() {
|
||||
if (mDiscDetail != nullptr) {
|
||||
if (activeDiscLoaded) {
|
||||
mDiscDetail->SetProperty(Rml::PropertyId::Display, Rml::Style::Display::Block);
|
||||
Rml::String innerRML = "GameCube • ";
|
||||
innerRML += state.activeDiscInfo.isPal ? "EUR" : "USA";
|
||||
Rml::String innerRML = "";
|
||||
|
||||
switch (state.activeDiscInfo.platform) {
|
||||
case iso::Platform::GameCube:
|
||||
innerRML += "GameCube";
|
||||
break;
|
||||
case iso::Platform::Wii:
|
||||
innerRML += "Wii";
|
||||
break;
|
||||
}
|
||||
|
||||
innerRML += " • ";
|
||||
|
||||
switch (state.activeDiscInfo.region) {
|
||||
case iso::Region::Japan:
|
||||
innerRML += "JPN";
|
||||
break;
|
||||
case iso::Region::Europe:
|
||||
innerRML += "EUR";
|
||||
break;
|
||||
case iso::Region::NorthAmerica:
|
||||
innerRML += "USA";
|
||||
break;
|
||||
case iso::Region::Korea:
|
||||
innerRML += "KOR";
|
||||
break;
|
||||
default:
|
||||
innerRML += "Unknown";
|
||||
break;
|
||||
}
|
||||
mDiscDetail->SetInnerRML(innerRML);
|
||||
} else {
|
||||
mDiscDetail->SetProperty(Rml::PropertyId::Display, Rml::Style::Display::None);
|
||||
|
||||
@@ -562,7 +562,7 @@ SettingsWindow::SettingsWindow(bool prelaunch) : mPrelaunch(prelaunch) {
|
||||
.getValue =
|
||||
[] {
|
||||
const auto& state = prelaunch_state();
|
||||
if (!state.configuredDiscCanLaunch || !state.configuredDiscInfo.isPal) {
|
||||
if (!state.configuredDiscCanLaunch || state.configuredDiscInfo.region != iso::Region::Europe) {
|
||||
return kLanguageNames[0];
|
||||
}
|
||||
const u8 idx = static_cast<u8>(getSettings().game.language.getValue());
|
||||
@@ -572,7 +572,7 @@ SettingsWindow::SettingsWindow(bool prelaunch) : mPrelaunch(prelaunch) {
|
||||
[] {
|
||||
const auto& state = prelaunch_state();
|
||||
return !state.configuredDiscCanLaunch ||
|
||||
!state.configuredDiscInfo.isPal;
|
||||
state.configuredDiscInfo.region != iso::Region::Europe;
|
||||
},
|
||||
.isModified =
|
||||
[] {
|
||||
@@ -1068,8 +1068,7 @@ SettingsWindow::SettingsWindow(bool prelaunch) : mPrelaunch(prelaunch) {
|
||||
addOption("Faster Tears of Light", getSettings().game.fastTears,
|
||||
"Tears of Light dropped by Shadow Insects pop out faster like the HD version.");
|
||||
addSpeedrunDisabledOption("Autosave", getSettings().game.autoSave,
|
||||
"Autosaves the game when going to a new area, opening a dungeon door, "
|
||||
"or getting a new item.");
|
||||
"Autosaves the game when going to a new area or opening a dungeon door.");
|
||||
addOption("Instant Saves", getSettings().game.instantSaves,
|
||||
"Skips the delay when writing to the Memory Card.");
|
||||
addOption("Hold B for Instant Text", getSettings().game.instantText,
|
||||
@@ -1166,7 +1165,7 @@ SettingsWindow::SettingsWindow(bool prelaunch) : mPrelaunch(prelaunch) {
|
||||
addCheat("Always Greatspin", getSettings().game.alwaysGreatspin,
|
||||
"Allows the Great Spin attack without requiring full health.");
|
||||
addCheat("Fast Iron Boots", getSettings().game.enableFastIronBoots,
|
||||
"Speeds up movement while wearing the Iron Boots.");
|
||||
"Speeds up movement while heavy, including wearing the Iron Boots, holding the Ball and Chain, wearing Magic Armor without rupees, etc.");
|
||||
addCheat("Can Transform Anywhere", getSettings().game.canTransformAnywhere,
|
||||
"Allows transforming even if NPCs are looking.");
|
||||
addCheat("Fast Roll", getSettings().game.fastRoll,
|
||||
@@ -1301,7 +1300,7 @@ SettingsWindow::SettingsWindow(bool prelaunch) : mPrelaunch(prelaunch) {
|
||||
config_bool_select(leftPane, rightPane, getSettings().game.enableDiscordPresence,
|
||||
{
|
||||
.key = "Enable Discord Rich Presence",
|
||||
.helpText = "Enable Dusk to integrate with Discord Rich Presence. This allows Discord to show your status in-game.",
|
||||
.helpText = "Enable Dusklight to integrate with Discord Rich Presence. This allows Discord to show your status in-game.",
|
||||
.onChange = [](bool enabled) {
|
||||
if (enabled) {
|
||||
dusk::discord::initialize();
|
||||
|
||||
@@ -28,6 +28,8 @@ void init() {
|
||||
gameVersion = GameVersion::GcnUsa;
|
||||
} else if (game == "GZ2P") {
|
||||
gameVersion = GameVersion::GcnPal;
|
||||
} else if (game == "GZ2J") {
|
||||
gameVersion = GameVersion::GcnJpn;
|
||||
} else {
|
||||
// TODO: Handle remaining valid versions.
|
||||
DuskLog.fatal("Unknown/unsupported game version in disc: {}", game);
|
||||
|
||||
+1
-13
@@ -29,8 +29,6 @@
|
||||
#include "tracy/Tracy.hpp"
|
||||
#include <dusk/gamepad_color.h>
|
||||
#include <dusk/autosave.h>
|
||||
#include <d/actor/d_a_npc.h>
|
||||
#include <d/d_item.h>
|
||||
#endif
|
||||
|
||||
fapGm_HIO_c::fapGm_HIO_c() {
|
||||
@@ -743,21 +741,11 @@ static void fapGm_AfterRecord() {
|
||||
}
|
||||
|
||||
BOOL isRecording = false;
|
||||
BOOL gotGhostLantern = false;
|
||||
|
||||
static void duskExecute() {
|
||||
handleGamepadColor();
|
||||
updateAutoSave();
|
||||
|
||||
if (daNpcT_chkEvtBit(0x2B6) && !gotGhostLantern) {
|
||||
execItemGet(dItemNo_GHOST_LANTERN_e);
|
||||
gotGhostLantern = true;
|
||||
} else if (!daNpcT_chkEvtBit(0x2B6) && gotGhostLantern) {
|
||||
dComIfGs_offItemFirstBit(dItemNo_GHOST_LANTERN_e);
|
||||
dComIfGp_setItem(SLOT_7, dItemNo_NONE_e);
|
||||
gotGhostLantern = false;
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.recordingMode) {
|
||||
Z2GetSoundMgr()->getSeqMgr()->getParams()->moveVolume(0.0f, 0);
|
||||
Z2GetSoundMgr()->getStreamMgr()->getParams()->moveVolume(0.0f, 0);
|
||||
@@ -819,7 +807,7 @@ static void duskExecute() {
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.infiniteRupees) {
|
||||
dComIfGs_setRupee(9999);
|
||||
dComIfGs_setRupee(dComIfGs_getRupeeMax());
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.infiniteOxygen) {
|
||||
|
||||
+17
-2
@@ -26,6 +26,7 @@
|
||||
#include <cstring>
|
||||
#include "dusk/logging.h"
|
||||
#include "dusk/frame_interpolation.h"
|
||||
#include "dusk/version.hpp"
|
||||
|
||||
u8 mDoExt::CurrentHeapAdjustVerbose;
|
||||
u8 mDoExt::HeapAdjustVerbose;
|
||||
@@ -3701,7 +3702,15 @@ static ResFONT* mDoExt_resfont0;
|
||||
|
||||
static void mDoExt_initFont0() {
|
||||
static char const fontdata[] = "rodan_b_24_22.bfn";
|
||||
#if REGION_JPN
|
||||
#if TARGET_PC
|
||||
if (dusk::version::getGameVersion() == dusk::version::GameVersion::GcnJpn) {
|
||||
mDoExt_initFontCommon(&mDoExt_font0, &mDoExt_resfont0, mDoExt_getZeldaHeap(),
|
||||
fontdata, dComIfGp_getFontArchive(), 0, 200, 512);
|
||||
} else {
|
||||
mDoExt_initFontCommon(&mDoExt_font0, &mDoExt_resfont0, mDoExt_getZeldaHeap(),
|
||||
fontdata, dComIfGp_getFontArchive(), 1, 0, 0);
|
||||
}
|
||||
#elif REGION_JPN
|
||||
mDoExt_initFontCommon(&mDoExt_font0, &mDoExt_resfont0, mDoExt_getZeldaHeap(),
|
||||
fontdata, dComIfGp_getFontArchive(), 0, 200, 512);
|
||||
#else
|
||||
@@ -3728,7 +3737,13 @@ void mDoExt_removeMesgFont() {
|
||||
JKR_DELETE(mDoExt_font0);
|
||||
mDoExt_font0 = NULL;
|
||||
if (mDoExt_resfont0 != NULL) {
|
||||
#if REGION_JPN
|
||||
#if TARGET_PC
|
||||
if (dusk::version::getGameVersion() == dusk::version::GameVersion::GcnJpn) {
|
||||
JKRFileLoader::removeResource(mDoExt_resfont0, NULL);
|
||||
} else {
|
||||
JKRFree(mDoExt_resfont0);
|
||||
}
|
||||
#elif REGION_JPN
|
||||
JKRFileLoader::removeResource(mDoExt_resfont0, NULL);
|
||||
#else
|
||||
JKRFree(mDoExt_resfont0);
|
||||
|
||||
@@ -96,8 +96,8 @@ void mDoLib_project(Vec* src, Vec* dst) {
|
||||
xSize = FB_WIDTH;
|
||||
} else {
|
||||
#if TARGET_PC
|
||||
xOffset = mDoGph_gInf_c::getSafeMinXF();
|
||||
xSize = viewPort->width * mDoGph_gInf_c::hudAspectScaleUp;
|
||||
xOffset = mDoGph_gInf_c::getMinXF();
|
||||
xSize = mDoGph_gInf_c::getWidthF();
|
||||
#else
|
||||
xOffset = viewPort->x_orig;
|
||||
xSize = viewPort->width;
|
||||
|
||||
Reference in New Issue
Block a user