mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-06-05 10:47:27 -04:00
Merge branch 'main' of https://github.com/TakaRikka/dusk
This commit is contained in:
Vendored
+1
-1
Submodule extern/aurora updated: 5d420c9f73...26da4c6bb0
@@ -77,6 +77,7 @@ struct UserSettings {
|
||||
ConfigVar<bool> enableFrameInterpolation;
|
||||
ConfigVar<int> internalResolutionScale;
|
||||
ConfigVar<int> shadowResolutionMultiplier;
|
||||
ConfigVar<bool> enableDepthOfField;
|
||||
|
||||
// Audio
|
||||
ConfigVar<bool> noLowHpSound;
|
||||
|
||||
@@ -30,6 +30,10 @@ static char* l_arcName = "Mirror";
|
||||
static char* l_arcName2 = "MR-Table";
|
||||
|
||||
dMirror_packet_c::dMirror_packet_c() {
|
||||
#ifdef TARGET_PC
|
||||
GXInitTexObj(&mTexObj, nullptr, 0, 0, static_cast<GXTexFmt>(-1), GX_MAX_TEXWRAPMODE,
|
||||
GX_MAX_TEXWRAPMODE, GX_FALSE);
|
||||
#endif
|
||||
reset();
|
||||
}
|
||||
|
||||
|
||||
@@ -70,11 +70,7 @@ dFs_HIO_c::dFs_HIO_c() {
|
||||
select_icon_appear_frames = 5;
|
||||
appear_display_wait_frames = 15;
|
||||
field_0x000d = 15;
|
||||
#if TARGET_PC
|
||||
card_wait_frames = 0;
|
||||
#else
|
||||
card_wait_frames = 90;
|
||||
#endif
|
||||
test_frame_counts[0] = 1.11f;
|
||||
test_frame_counts[1] = 1.11f;
|
||||
test_frame_counts[2] = 1.11f;
|
||||
@@ -2367,7 +2363,7 @@ void dFile_select_c::CommandExec() {
|
||||
break;
|
||||
}
|
||||
|
||||
mWaitTimer = g_fsHIO.card_wait_frames;
|
||||
mWaitTimer = IF_DUSK(dusk::getSettings().game.instantSaves ? 0 :) g_fsHIO.card_wait_frames;
|
||||
}
|
||||
|
||||
void dFile_select_c::DataEraseWait() {
|
||||
@@ -4759,7 +4755,7 @@ void dFile_select_c::MemCardFormatYesSel2Disp() {
|
||||
bool isErrorTxtChange = errorTxtChangeAnm();
|
||||
bool isYnMenuMove = yesnoMenuMoveAnm();
|
||||
if (isErrorTxtChange == true && isYnMenuMove == true) {
|
||||
mWaitTimer = g_fsHIO.card_wait_frames;
|
||||
mWaitTimer = IF_DUSK(dusk::getSettings().game.instantSaves ? 0 :) g_fsHIO.card_wait_frames;
|
||||
mDoMemCd_Format();
|
||||
mCardCheckProc = MEMCARDCHECKPROC_FORMAT;
|
||||
}
|
||||
@@ -4830,7 +4826,7 @@ void dFile_select_c::MemCardMakeGameFileSelDisp() {
|
||||
|
||||
if (isErrorTxtChange == true && isYnMenuMove == true && isKetteiTxtDisp == true) {
|
||||
if (field_0x0268 != 0) {
|
||||
mWaitTimer = g_fsHIO.card_wait_frames;
|
||||
mWaitTimer = IF_DUSK(dusk::getSettings().game.instantSaves ? 0 :) g_fsHIO.card_wait_frames;
|
||||
setInitSaveData();
|
||||
dataSave();
|
||||
mCardCheckProc = MEMCARDCHECKPROC_MAKE_GAMEFILE;
|
||||
|
||||
@@ -984,7 +984,36 @@ void dMenu_DmapBg_c::update() {
|
||||
JUT_ASSERT(2323, mpBackTexture != NULL);
|
||||
|
||||
void* spec = mpArchive->getResource("spec/spec.dat");
|
||||
#if TARGET_PC
|
||||
struct dmap_spec {
|
||||
/* 0x00 */ BE(f32) field_0x0;
|
||||
/* 0x04 */ BE(f32) field_0x4;
|
||||
/* 0x08 */ BE(f32) field_0x8;
|
||||
/* 0x0C */ u8 field_0xc;
|
||||
/* 0x0D */ u8 field_0xd;
|
||||
/* 0x0E */ u8 field_0xe;
|
||||
/* 0x0F */ u8 field_0xf;
|
||||
/* 0x10 */ u8 field_0x10;
|
||||
/* 0x11 */ u8 field_0x11;
|
||||
/* 0x12 */ u8 field_0x12;
|
||||
/* 0x13 */ u8 field_0x13;
|
||||
};
|
||||
dmap_spec* dspec = (dmap_spec*)spec;
|
||||
|
||||
field_0xd80 = dspec->field_0x0;
|
||||
field_0xd84 = dspec->field_0x4;
|
||||
field_0xd88 = dspec->field_0x8;
|
||||
field_0xd8c = dspec->field_0xc;
|
||||
field_0xd8d = dspec->field_0xd;
|
||||
field_0xd8e = dspec->field_0xe;
|
||||
field_0xd8f = dspec->field_0xf;
|
||||
field_0xd90 = dspec->field_0x10;
|
||||
field_0xd91 = dspec->field_0x11;
|
||||
field_0xd92 = dspec->field_0x12;
|
||||
field_0xd93 = dspec->field_0x13;
|
||||
#else
|
||||
memcpy(&field_0xd80, spec, 20);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -67,7 +67,7 @@ namespace dusk {
|
||||
ToggleFullscreen();
|
||||
}
|
||||
|
||||
if (ImGui::MenuItem("Restore Default Window Size")) {
|
||||
if (ImGui::Button("Restore Default Window Size")) {
|
||||
getSettings().video.enableFullscreen.setValue(false);
|
||||
VISetWindowFullscreen(false);
|
||||
VISetWindowSize(FB_WIDTH * 2, FB_HEIGHT * 2);
|
||||
@@ -75,6 +75,8 @@ namespace dusk {
|
||||
}
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
bool vsync = getSettings().video.enableVsync;
|
||||
if (ImGui::Checkbox("Enable VSync", &vsync)) {
|
||||
getSettings().video.enableVsync.setValue(vsync);
|
||||
@@ -163,6 +165,8 @@ namespace dusk {
|
||||
|
||||
ImGui::Checkbox("Enable LOD Bias", &aurora::gx::enableLodBias);
|
||||
|
||||
config::ImGuiCheckbox("Enable Depth of Field", getSettings().game.enableDepthOfField);
|
||||
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
}
|
||||
@@ -312,14 +316,14 @@ namespace dusk {
|
||||
|
||||
void ImGuiMenuGame::drawAudioMenu() {
|
||||
if (ImGui::BeginMenu("Audio")) {
|
||||
|
||||
ImGui::SeparatorText("Volume");
|
||||
|
||||
ImGui::Text("Master Volume");
|
||||
if (config::ImGuiSliderInt("##masterVolume", getSettings().audio.masterVolume, 0, 100)) {
|
||||
dusk::audio::SetMasterVolume(getSettings().audio.masterVolume / 100.0f);
|
||||
}
|
||||
|
||||
if (config::ImGuiCheckbox("Enable Reverb", getSettings().audio.enableReverb)) {
|
||||
dusk::audio::SetEnableReverb(getSettings().audio.enableReverb);
|
||||
}
|
||||
/*
|
||||
// TODO: Implement additional settings
|
||||
ImGui::Text("Main Music Volume");
|
||||
@@ -339,6 +343,13 @@ namespace dusk {
|
||||
}
|
||||
*/
|
||||
|
||||
ImGui::SeparatorText("Effects");
|
||||
|
||||
if (config::ImGuiCheckbox("Enable Reverb", getSettings().audio.enableReverb)) {
|
||||
dusk::audio::SetEnableReverb(getSettings().audio.enableReverb);
|
||||
}
|
||||
|
||||
|
||||
ImGui::SeparatorText("Tweaks");
|
||||
|
||||
config::ImGuiCheckbox("No Low HP Sound", getSettings().game.noLowHpSound);
|
||||
@@ -359,7 +370,11 @@ namespace dusk {
|
||||
if (ImGui::BeginMenu("Input")) {
|
||||
ImGui::SeparatorText("Controller");
|
||||
|
||||
ImGui::MenuItem("Configure Controller", nullptr, &m_showControllerConfig);
|
||||
if (ImGui::Button("Configure Controller")){
|
||||
m_showControllerConfig = !m_showControllerConfig;
|
||||
}
|
||||
|
||||
ImGui::SeparatorText("Camera");
|
||||
|
||||
config::ImGuiCheckbox("Invert Camera X Axis", getSettings().game.invertCameraXAxis);
|
||||
|
||||
|
||||
@@ -51,6 +51,7 @@ UserSettings g_userSettings = {
|
||||
.enableFrameInterpolation = {"game.enableFrameInterpolation", false},
|
||||
.internalResolutionScale {"game.internalResolutionScale", 0},
|
||||
.shadowResolutionMultiplier {"game.shadowResolutionMultiplier", 1},
|
||||
.enableDepthOfField {"game.enableDepthOfField", true},
|
||||
|
||||
// Audio
|
||||
.noLowHpSound {"game.noLowHpSound", false},
|
||||
@@ -143,6 +144,7 @@ void registerSettings() {
|
||||
Register(g_userSettings.game.disableWaterRefraction);
|
||||
Register(g_userSettings.game.internalResolutionScale);
|
||||
Register(g_userSettings.game.shadowResolutionMultiplier);
|
||||
Register(g_userSettings.game.enableDepthOfField);
|
||||
Register(g_userSettings.game.enableFastIronBoots);
|
||||
Register(g_userSettings.game.canTransformAnywhere);
|
||||
Register(g_userSettings.game.freeMagicArmor);
|
||||
|
||||
@@ -1155,6 +1155,9 @@ static void drawDepth2(view_class* param_0, view_port_class* param_1, int param_
|
||||
GXSetProjection(ortho, GX_ORTHOGRAPHIC);
|
||||
GXSetCurrentMtx(0);
|
||||
|
||||
#ifdef TARGET_PC
|
||||
if (dusk::getSettings().game.enableDepthOfField)
|
||||
#endif
|
||||
if (l_tevColor0.a > -255 && sp8 == 1) {
|
||||
GXBegin(GX_QUADS, GX_VTXFMT0, 4);
|
||||
GXPosition3s16(x_orig, y_orig_pos, -5);
|
||||
|
||||
Reference in New Issue
Block a user