Advertiser Content

[DECOMP] Simple Modifications Directory Page 2

Started by Avara December 30th, 2018 2:48 PM
  • 5396 views
  • 31 replies

Lunos

Random Uruguayan User

Male
Montevideo (Uruguay)
Seen 3 Hours Ago
Posted 3 Hours Ago
2,060 posts
11 Years
Gen. 6 styled Exp. Share
Blurose implemented this mechanic from the newer pokémon games on Pokeruby sometime ago.
Today, I took some time to port his version to Pokeemerald.
You can find all the relevant changes in this commit I uploaded to a branch of my Pokeemerald repository on GitHub.
Note: Red = Original Line | Green = Modified Line

Video:
Seen 1 Day Ago
Posted August 27th, 2019
770 posts
12.6 Years
Wrapping Summary Screen [EM]

In XY and later games, the Summary Screen wraps around. By that I mean if you press down on the summary screen of the last Pokémon in your party, you'll be taken back to the first Pokémon in your party (in earlier games, it would just do nothing). Similarly, if you press up while on the first Pokémon in your party, you'll go to the last.

To copy this behavior in In pokeemerald, in src/pokemon_summary_screen.c, change sub_81C08F8 to the following:

static s8 sub_81C08F8(s8 delta)
{
    struct Pokemon *mon = sMonSummaryScreen->monList.mons;
    u8 index = sMonSummaryScreen->curMonIndex;
    u8 numMons = sMonSummaryScreen->maxMonIndex + 1;
    delta += numMons;

    index = (index + delta) % numMons;

    // skip over any Eggs unless on the Info Page
    if (sMonSummaryScreen->currPageIndex != PSS_PAGE_INFO)
        while (GetMonData(&mon[index], MON_DATA_IS_EGG))
            index = (index + delta) % numMons;

    // to avoid "scrolling" to the same Pokemon
    if (index == sMonSummaryScreen->curMonIndex)
        return -1;
    else
        return index;
}

Avara

Female
Izantine
Seen 3 Hours Ago
Posted 3 Hours Ago
1,085 posts
7.9 Years
Updated the first post! Thanks a lot for sharing your contributions, troops x

AsparagusEdu

AsparagusEduardo

Age 26
Male
Seen 15 Hours Ago
Posted 1 Week Ago
17 posts
5.6 Years
White out money calculation [EM]

In Gen I & II and RSE, you lose half of your money when defeated. However, in FLRG & Gen IV onwards the amount you lose is calculated by a formula based on the amount of badges and the highest level in your Pokémon's Party.
[Bulbapedia source]

This mod implements that formula (using the FLRG values).



GitHub link:
https://github.com/AsparagusEduardo/pokeemerald/tree/WhiteOutMoney

To-Do:
  • Add in-battle message to show how much money was lost.
Male
Seen 4 Weeks Ago
Posted September 9th, 2019
3 posts
6.3 Years
About "Surviving poison outside of battle with 1hp":
It looks like the code there's an error in the code, or did I did something wrong ?

Error:
src/field_poison.c: In function `DoPoisonFieldEffect':
src/field_poison.c:135: `EventScript_PoisonSurvial' undeclared (first use in this function)
src/field_poison.c:135: (Each undeclared identifier is reported only once
src/field_poison.c:135: for each function it appears in.)
make: *** [Makefile:242: build/emerald/src/field_poison.o] Error 1

Lunos

Random Uruguayan User

Male
Montevideo (Uruguay)
Seen 3 Hours Ago
Posted 3 Hours Ago
2,060 posts
11 Years
About "Surviving poison outside of battle with 1hp":
It looks like the code there's an error in the code, or did I did something wrong ?

Error:
src/field_poison.c: In function `DoPoisonFieldEffect':
src/field_poison.c:135: `EventScript_PoisonSurvial' undeclared (first use in this function)
src/field_poison.c:135: (Each undeclared identifier is reported only once
src/field_poison.c:135: for each function it appears in.)
make: *** [Makefile:242: build/emerald/src/field_poison.o] Error 1
Yeah, it doesn't seem to work. I asked TheXaman about this on his profile back in March and he never really answered.
I guess this is a good time to post this. I really should have done it sooner, but I kind of forgot :P

Overworld 1HP Poison Survival [EM]
Some time ago, Blurose made his own version of this mechanic for his project in Pokeruby.
Some months ago, I ported it to Pokeemerald, and this seems to be a good time to post it here as an alternative.

The relevant modifications can be seen in this commit, it's veery simple.
https://github.com/LOuroboros/pokeemerald/commit/c162100fdc5439ebd7eefabc5890dae56d1a88f7

Pics:
Advertiser Content