• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • Our weekly protagonist poll is now up! Vote for your favorite Trading Card Game 2 protagonist in the poll by clicking here.
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

[Other✓] Displaying time in the start menu

  • 5
    Posts
    2
    Years
    • Seen Nov 11, 2023
    Hello, I would like to display the current time while you are in the start menu. So far I have I managed to display the time. However, it is stuck on the time you open the menu. A second problem is when speeding the game up, it no longer displays the correct time, as more game time has passed compared to regular time. Does someone know how to solve this?

    This is what I have done so far:
    Spoiler:

    Hopefully someone could help me with this, thanks in advance!
     
    However, it is stuck on the time you open the menu.
    Instead of only drawing the time when the menu opens, you could probably use a task to repeatedly draw the time, so that it changes as time advances.

    A second problem is when speeding the game up, it no longer displays the correct time, as more game time has passed compared to regular time. Does someone know how to solve this?
    How speed up interacts with rtc depends on the emulator and its settings. You can't really change that by editing the ROM.
     
    Instead of only drawing the time when the menu opens, you could probably use a task to repeatedly draw the time, so that it changes as time advances.

    Thanks for the quick response!
    I have looked into how tasks work but couldn't really figure it out but hadn't read the guide you linked, so I'll look at it again!

    How speed up interacts with rtc depends on the emulator and its settings. You can't really change that by editing the ROM.

    So it is not possible to load the system time instead of the internal game clock?
    Thanks again!
     
    How speed up interacts with rtc depends on the emulator and its settings. You can't really change that by editing the ROM.
    While you can't modify how an emulatior's Fast Forward feature interacts with the game, you can work around the core problem.
    If you synchronize the game's play time with the real time that's coming from the RTC, the game's Play Time will be naturally unaffected by speeding up functions of any kind.
    https://github.com/TaTaTaZJJ/tioth/commit/e8a0cab7b01391198a57933c11bba65b9c8d0392
     
    While you can't modify how an emulatior's Fast Forward feature interacts with the game, you can work around the core problem.
    If you synchronize the game's play time with the real time that's coming from the RTC, the game's Play Time will be naturally unaffected by speeding up functions of any kind.
    https://github.com/TaTaTaZJJ/tioth/commit/e8a0cab7b01391198a57933c11bba65b9c8d0392

    Thanks for this!

    I still can't manage to figure out how to make a task that handles the redrawing of the time. I've also looked at the cfru files and that contains a ForceClockUpdate function in the HandleInputs section. but looking further into this leads me nowhere. I hope someone can help/show me how to actually make the task and where I should create it. Thanks in advance
     
    Thanks for this!

    I still can't manage to figure out how to make a task that handles the redrawing of the time. I've also looked at the cfru files and that contains a ForceClockUpdate function in the HandleInputs section. but looking further into this leads me nowhere. I hope someone can help/show me how to actually make the task and where I should create it. Thanks in advance
    Personally, I implemented the feature in my personal branch through one of Citrus Bolt's public commits, and it works nicely.
    https://github.com/citrusbolt/pokeheliodor/commit/af4a247b71bdf6cca75ed6719b3ae7c6f8aec78c
     
    Back
    Top