mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-07-30 15:43:19 -04:00
add some cheats
This commit is contained in:
+57
-21
@@ -732,6 +732,62 @@ static void fapGm_AfterRecord() {
|
||||
dusk::frame_interp::end_record();
|
||||
fapGm_After();
|
||||
}
|
||||
|
||||
static void duskExecute() {
|
||||
if (mDoCPd_c::getHoldR(PAD_1) && mDoCPd_c::getTrigX(PAD_1)) {
|
||||
if (const auto link = g_dComIfG_gameInfo.play.getPlayer(0)) {
|
||||
dynamic_cast<daAlink_c*>(link)->handleWolfHowl();
|
||||
}
|
||||
}
|
||||
|
||||
if (mDoCPd_c::getHoldR(PAD_1) && mDoCPd_c::getTrigY(PAD_1)) {
|
||||
if (const auto link = g_dComIfG_gameInfo.play.getPlayer(0)) {
|
||||
dynamic_cast<daAlink_c*>(link)->handleQuickTransform();
|
||||
}
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.moonJump && (mDoCPd_c::getHoldR(PAD_1) && mDoCPd_c::getHoldA(PAD_1))) {
|
||||
if (const auto link = g_dComIfG_gameInfo.play.getPlayer(0)) {
|
||||
link->speed.y = 56.0f;
|
||||
}
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.fastSpinner && mDoCPd_c::getHoldR(PAD_1)) {
|
||||
if (const auto link = g_dComIfG_gameInfo.play.getPlayer(0)) {
|
||||
auto spinnerActor = (fopAc_ac_c*)dynamic_cast<daAlink_c*>(link)->getSpinnerActor();
|
||||
if (spinnerActor) {
|
||||
if (spinnerActor->speedF < 60.f)
|
||||
spinnerActor->speedF += 2.f;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.infiniteHearts) {
|
||||
dComIfGs_setLife((dComIfGs_getMaxLife() / 5) * 4);
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.infiniteArrows) {
|
||||
dComIfGs_setArrowNum(dComIfGs_getArrowMax());
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.infiniteBombs) {
|
||||
dComIfGs_setBombNum(0, 99);
|
||||
dComIfGs_setBombNum(1, 99);
|
||||
dComIfGs_setBombNum(2, 99);
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.infiniteOil) {
|
||||
dComIfGs_setOil(dComIfGs_getMaxOil());
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.infiniteRupees) {
|
||||
dComIfGs_setRupee(9999);
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.infiniteOxygen) {
|
||||
dComIfGp_setOxygen(dComIfGp_getMaxOxygen());
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
void fapGm_Execute() {
|
||||
@@ -747,27 +803,7 @@ void fapGm_Execute() {
|
||||
#endif
|
||||
|
||||
#if TARGET_PC
|
||||
if (mDoCPd_c::getHoldR(PAD_1) && mDoCPd_c::getTrigX(PAD_1)) {
|
||||
if (const auto link = g_dComIfG_gameInfo.play.getPlayer(0)) {
|
||||
dynamic_cast<daAlink_c*>(link)->handleWolfHowl();
|
||||
}
|
||||
}
|
||||
|
||||
if (mDoCPd_c::getHoldR(PAD_1) && mDoCPd_c::getTrigY(PAD_1)) {
|
||||
if (const auto link = g_dComIfG_gameInfo.play.getPlayer(0)) {
|
||||
dynamic_cast<daAlink_c*>(link)->handleQuickTransform();
|
||||
}
|
||||
}
|
||||
|
||||
if (dusk::getSettings().game.fastSpinner && mDoCPd_c::getHoldR(PAD_1)) {
|
||||
if (const auto link = g_dComIfG_gameInfo.play.getPlayer(0)) {
|
||||
auto spinnerActor = (fopAc_ac_c*)dynamic_cast<daAlink_c*>(link)->getSpinnerActor();
|
||||
if (spinnerActor) {
|
||||
if (spinnerActor->speedF < 60.f)
|
||||
spinnerActor->speedF += 2.f;
|
||||
}
|
||||
}
|
||||
}
|
||||
duskExecute();
|
||||
#endif
|
||||
|
||||
#ifdef TARGET_PC
|
||||
|
||||
Reference in New Issue
Block a user