Add OW_FLAG_PAUSE_TIME, pausefakertc, resumefakertc and togglefakertc #4954
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
OW_FLAG_PAUSE_TIME
, allowing users to designate a flag for stopping and starting the flow of time whenOW_USE_FAKE_RTC
is enabled.STATIC_ASSERT
to prevent users from attempting to pause time unless FakeRtc is enabled.pausefakertc
,resumefakertc
, andtogglefakertc
allowing users to pause, resume and toggle the flow of time whenOW_USE_FAKE_RTC
is enabled.Usage
OW_FLAG_PAUSE_TIME
In
include/config/overworld.h
, developers must assign a flag toOW_FLAG_PAUSE_TIME
.Set Flag
Setting the flag will pause the flow of time.
Clear Flag
Clearing the flag will resume the flow of time.
Toggle Flag
If time is paused, the flag will be cleared. If time is not paused, the flag will be set.
Testing
Clean Branch
You can recreate this branch by applying a patch or pulling the repo. From a clean version of expansion's upcoming, you can either:
Patch
wget https://files.catbox.moe/igk1yp.patch -O fakeRTC.patch ; git apply fakeRTC.patch ; rm fakeRTC.patch
Repo
git remote add psf-expansion https://github.com/PokemonSanFran/pokeemerald-expansion/ ; git pull psf-expansion fakeRTC_branch
Manual Tests
After replicating the branch, to recreate my testing environment, you can either directly download the debug script and config file, or manually create the changes.
Download
OW_USE_FAKE_RTC
OW_FLAG_PAUSE_TIME
FALSE
FLAG_UNUSED_0x264
wget https://files.catbox.moe/h8ef5x.h -O include/config/overworld.h && wget https://files.catbox.moe/7sgzz3.inc -O data/scripts/debug.inc
FALSE
0
wget https://files.catbox.moe/lxkglx.h -O include/config/overworld.h && wget https://files.catbox.moe/7sgzz3.inc -O data/scripts/debug.inc
TRUE
FLAG_UNUSED_0x264
wget https://files.catbox.moe/g1t68r.h -O include/config/overworld.h && wget https://files.catbox.moe/7sgzz3.inc -O data/scripts/debug.inc
TRUE
0
wget https://files.catbox.moe/xfvd8h.h -O include/config/overworld.h && wget https://files.catbox.moe/7sgzz3.inc -O data/scripts/debug.inc
Manual Testing
OW_USE_FAKE_RTC
andOW_ALTERED_TIME_RATIO
to their desired values.Verified Scenarios
All videos attempt to show:
pausefakertc
is runTRAINER_RONALD
and wins in 6 turns.OW_USE_FAKE_RTC
==FALSE
&&OW_FLAG_PAUSE_TIME
==FLAG_UNUSED_0x264
Does not compile
OW_USE_FAKE_RTC
==FALSE
&&OW_FLAG_PAUSE_TIME
==0
false0.mp4
OW_USE_FAKE_RTC
==TRUE
&&OW_FLAG_PAUSE_TIME
==FLAG_UNUSED_0x264
trueset.mp4
OW_USE_FAKE_RTC
==TRUE
&&OW_FLAG_PAUSE_TIME
==0
true0.mp4
Discord Contact Info
I am
pkmnsnfrn
on Discord.