News: 11 March 2016 - Forum Rules
Current Moderators - DarkSol, KingMike, MathOnNapkins, Azkadellia, Danke

Author Topic: [GB] Final Fantasy Legend II Hacking  (Read 3502 times)

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
[GB] Final Fantasy Legend II Hacking
« on: January 15, 2019, 07:06:29 pm »
Hello everyone, Break here

Reaching out today to ask about the Gameboy game "Final Fantasy Legend II"

Currently looking into was to hack/edit this game a bit

And was wondering if there are any resources available ?

I hear it is possible to use a hex editing program to edit saves

But I am looking to edit the base game.

Again, I hope our community can help me get started on this quest.

Will check back for replies each day around 5:00pm USA- Central Time 

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

Sliver X

  • Hero Member
  • *****
  • Posts: 1037
  • EX•CINERIBVS•IGNIS•EXCITABITVR
    • View Profile
    • Panicus - A Fragment of Memory
Re: [GB] Final Fantasy Legend II Hacking
« Reply #1 on: January 17, 2019, 09:53:42 pm »
There are extensive statistical charts out there for the game, but you'll have to track down and locate the data in ROM as there are no utilites that I know of for editing them.

And if I remember correctly from 20 years ago when I opened that game up, the text simply uses DTE encoding so it's not hard to deal with editing text.

But that's about all I can think of. There is a very nice editor for Final Fantasy Legend/SaGa, though.

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #2 on: January 18, 2019, 06:23:47 pm »
@Silver X

Thanks for the swift reply !

Yes, I just searched and found somethings on this site :

http://shenafu.com/ffl2/ffl2.php 

But it looks like I will have to brush up on Hex-Editing to be able to hack the game.

Also, what is DTE encoding ?

I am interested in editing the text in the game.

Oh wow, that editor does look nice (too bad not compatible with FFL2)

Currently working on understanding the offsets and how they are read and such.

So for now, just trying to figure out how to edit the "Human M"

More or less the starting stats, equipment, and stat growth rate.

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

Q

  • RHDN Patreon Supporter!
  • Full Member
  • *****
  • Posts: 114
  • Meow, busy hackers!
    • View Profile
Re: [GB] Final Fantasy Legend II Hacking
« Reply #3 on: January 18, 2019, 06:41:11 pm »
I hear it is possible to use a hex editing program to edit saves

But I am looking to edit the base game.

You can use a hex editor to edit ROMs in the same manner that you would a save file. If you want to learn the basics of hex editing, search the site for an intro to text editing. There should be a few documents that walk you through the process of using a relative search to locate the text, create a text table, view and edit the text, and save your changes in the ROM. I think most of the documents use NES games as examples. I suggest trying to follow one of these guides instead of immediately trying to find the text in FFL2, since it uses a form of compression (see your next question) that makes finding the text a little more difficult.

I'll send you a text table for FFL2 so you don't have to figure out the hex values, but you should definitely learn how to do it as it's a pretty important skill for ROM hacking. It isn't too hard to get the hang of, though.

Also, what is DTE encoding ?

It stands for "dual-tile encoding." Normally a byte in a script represents one character, but when DTE is used, certain hex values can represent two characters. It's a very simple form of compression (i.e., a way of saving space so more text can be fit in the game). I think some games also use MTE (multi-tile encoding), where a hex value can represent three or more characters—but FFL2 uses DTE.
« Last Edit: January 18, 2019, 06:47:35 pm by Q »
Sneko, the Super Nintendo Entertainment Kitty, wishes you luck.

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #4 on: January 19, 2019, 12:01:13 pm »
@Q

Thanks for the heads up !!

So here is a progress update.

So I am using the hex-editor program HxD

And I have opened the ROM file with it.

Now that I sort of understand Offsets and the like

I want to edit 'Human M' starting equipment/items :

Human M Item/Equipment slot #1

Offset -- 0x37E7F

Long Sword Hex Value -- 01

Human M Item/Equipment slot #2

Offset -- 0x37E80

Bronze Armor Hex Value -- 35

Question #1,

If I change the Hex Value at these Offsets

Will it change the equipment/items in these slots ?

Question #2,

How would I add more equipment/items to this character ?

Next I want to edit 'Human M's starting/base stats :

Human M Hp Value(DEC) = 59

Offset -- 0x378E2 - 0x378E3 (Backwards ?)

Human M Str Value(DEC) = 06

Offset -- 0x378E4

Human M Agl Value(DEC) = 05

Offset -- 0x378E5

Human M Mana Value(DEC) = 03

Offset -- 0x378E6

Human M Def Value(DEC) =  03

Offset -- 0x378E7

Question #3,

So similar question, I would change the values in this offset to change this character's staring/base stats ?

Question #4,

Would it be possible to modify the growth-rate stats of this character ?
« Last Edit: January 19, 2019, 12:07:53 pm by break »

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

Jorpho

  • Hero Member
  • *****
  • Posts: 4161
  • The cat screams with the voice of a man.
    • View Profile
Re: [GB] Final Fantasy Legend II Hacking
« Reply #5 on: January 19, 2019, 04:25:50 pm »
Your posts are kind of hard to read with so many line breaks.

Question #1,

If I change the Hex Value at these Offsets, Will it change the equipment/items in these slots ?
Why don't you try it and find out?  This sort of thing is going to require a lot of experimentation.  Just make sure you make backups of your ROM before you start changing things.

Quote
Question #2,

How would I add more equipment/items to this character ?
If there are only two slots for starting equipment, you might have to start re-arranging the data in the ROM significantly to make room for more – and then you'd have to find and change whatever part of the code that only expects there to be two item slots.  It's all possible, but not at all easy.

Quote
Question #3,

So similar question, I would change the values in this offset to change this character's staring/base stats ?
Similar answer: try it and find out.

Quote
Question #4,

Would it be possible to modify the growth-rate stats of this character ?
You would have to find where the "growth-rate stats" are stored or calculated.
This signature is an illusion and is a trap devised by Satan. Go ahead dauntlessly! Make rapid progres!

KingMike

  • Forum Moderator
  • Hero Member
  • *****
  • Posts: 6907
  • *sigh* A changed avatar. Big deal.
    • View Profile
Re: [GB] Final Fantasy Legend II Hacking
« Reply #6 on: January 19, 2019, 07:20:07 pm »
I do recall that human/mutant's growth in FFL2 was based on weapons usage (that is, which of STR/AGL/MANA is raised depending on the weapon, and the frequency based on RNG like seeming everything else in SaGa games :P )
Like I think giving one a Rapier and killing enemies and they'll randomly get AGL boosts.

I do remember that in FFL1 Humans and Mutants were more different but I think in FFL2 they were basically the same except Mutants start with higher MANA and get skills randomly (but I recall it was the last? skill that was replaced when they learned a new skill, so that unlike FFL1 you could keep skills you liked by rearranging them in the menu).
"My watch says 30 chickens" Google, 2018

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #7 on: January 19, 2019, 10:28:04 pm »
@Jorpho 

Ah, I do apologize !
I will try to keep things spaced a bit tighter.
Cool, I have now found each items/attacks HEX value thanks to this site :
http://shenafu.com/
I have made a backup will start testing this out.

Okay, so when you say "re-arrange the data"
Do you mean like finding unused space in the same memory back ?
Currently looking into how to do this (very new to me)
And I am interested in starting the game with an extra item or two.

For growth rates, I believe 'Human M/F' and 'Mutant M/F' have different rates
But the math is a little tricky for me to understand.
Like a Human M/F has a 1-in-5 chance to increase Mana after a battle
And a Mutant M/F has a 1-in-8 chance to increase Mana after a battle
I am unsure how this is read or calculated in HEX
This information should be stored around Offset range 0x33F90 ~ 0x33FAF
But I am unsure about the calculations.


@KingMike

Yes, I may have to dive deeper into the different weapon types
To see what stat they can increase upon use.
But I believe that Human M/F and Mutant M/F
Have a certain range for the RNG for gaining stats after battle

I may hold off on the growth rates for now (unless I have a breakthrough)
And focus editing starting/base stats
While learning how to add additional items/skills to party members and enemies.

Again, really appreciate all the support from everyone here !!
I feel like I am getting closer to what I really want hack in this game

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

Jorpho

  • Hero Member
  • *****
  • Posts: 4161
  • The cat screams with the voice of a man.
    • View Profile
Re: [GB] Final Fantasy Legend II Hacking
« Reply #8 on: January 20, 2019, 12:31:25 am »
Okay, so when you say "re-arrange the data"
Do you mean like finding unused space in the same memory back ?
Currently looking into how to do this (very new to me)
And I am interested in starting the game with an extra item or two.
If there is unused space next to where those two values are stored, then you can use that space – but it seems unlikely there would be space available there.  Otherwise, you will have to find more space somewhere else, and find out how to change the code to read data from that other place.
This signature is an illusion and is a trap devised by Satan. Go ahead dauntlessly! Make rapid progres!

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #9 on: January 20, 2019, 01:34:11 am »
@Jorpho

Well, I say that because there is a large chunk of ZEROs after the last equipment entry.
But it sounds like even if I enter a value in that space
I would need a way to make the game point/read there
Which I am unsure how to do.

Hmm...it is important for me to be able to learn how to do this
Because I want to also expand on how many attacks/abilities enemies and guest members have.
For now I will just have to work with editing what ever item/ability slots are in use
Along with the stats I can find.

So while this does limit the scope of what I want to hack/modify
I will focus on what I can do now and try to figure out a solution.
Again, I really appreciate the direction
And will think about this over the next few days.

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

Jorpho

  • Hero Member
  • *****
  • Posts: 4161
  • The cat screams with the voice of a man.
    • View Profile
Re: [GB] Final Fantasy Legend II Hacking
« Reply #10 on: January 20, 2019, 02:07:56 pm »
Well, I say that because there is a large chunk of ZEROs after the last equipment entry.
But it sounds like even if I enter a value in that space
I would need a way to make the game point/read there
Which I am unsure how to do.
Like I suggested before: why not try entering a value in there, and see what happens?  If there's already empty space there, it's possible the game just loads up the two values and all the empty space when it assigns starting equipment.
This signature is an illusion and is a trap devised by Satan. Go ahead dauntlessly! Make rapid progres!

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #11 on: January 24, 2019, 12:01:46 am »
@Jorpho

Whew, feeling much better now !
So I have successfully edited party member 'Human M' starting/base stats :

**Human M

--Offset 0x378E2 ~ 0x378E3 (read backwards xE3 - xE2)
HP Value (DEC *HEX) 59 *3B 00 ~ 80 *50 00
--Offset 0x378E4
STR Value (DEC *HEX) 6 *06 ~ 9 *09
--Offset 0x378E5
AGL Value (DEC *HEX) 5 *05 ~ 7 *07
--Offset 0x378E6
MANA Value (DEC *HEX) 3 *03 ~ 5 *05
--Offset 0x378E7
DEF Value (DEC *HEX) 3 ~ 03 ~ 5 *05

Also, able to modify what type and how many equipped items 'Human M' starts with :

--Offset 0x378E8 ~ 0x378E9 (read backwards xE9 - xE8)
Skills Pointer Value 7F 7E ~ B5 7E
Skill Pointer Update 0x37E7F ~ 0x37EB5
--Offset 0x378E0
Race & Number of Skill Slots Value 01 ~ 03 (0 = Human & 3 = 4 slots)
--Offset  0x37EB5
Item Slot 0  00 ~ 4F  Punch
--Offset  0x37EB6
Item Slot 1  00 ~ 17  Bronze Shield
--Offset  0x37EB7
Item Slot 2  00 ~ 35  Bronze Armor
--Offset  0x37EB8
Item Slot 3  00 ~ 1D  Cure Potion


So big thanks to everyone here that has been pushing me in the right direction !!
Where I am stuck now is the stat growth rates.
This section is very confusing to me...unsure how these values are read and calculated.
I believe it starts around Offset 0x33F90
Will continue to look into this, but open to advice and direction about this issue.


January 29, 2019, 07:12:55 pm - (Auto Merged - Double Posts are not allowed before 7 days.)
**UPDATE**

Okay, so I have just completed the following :
-Updated party & guest members base/starting stats
-Updated party & guest items/skills 

Tested this for the First World and everything is looking and working right.
My next step/plans are as follows :
-Change what monster/group appears in boss/un-skippable battles
-Change the type of skills mutants learn at each "DS Level"
-Change what items are sold at shops 
-Change what items or monsters appear in treasure chests 

A bit in the dark on how to accomplish this, but open to suggestion and direction while check out the data.
I really want to make the boss encounters a bit more challenging (More HP)
Which is possible...but I really want to learn how to chose what "group" of monsters show up in a boss battle.
I know you have 3 Slots (Left, Middle, Right) for monsters encounters
And each type of monster can come as a group
But again, still uncertain how to edit this with a Hex-Editor.
« Last Edit: January 29, 2019, 07:12:55 pm by break »

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #12 on: February 02, 2019, 10:50:39 am »
**UPDATE**

Okay, so I was able to learn more about how Mutants learn skills after battle
Along with how to edit the type of skills they can learn based on the 'DS Level' of the encounter
With that said, I have finished editing those learnable skills.

Next, was able to locate and learn about the weapon/item shops Offsets
And how to edit the Hex value to change what they sell.
Should be done with the shop edits today.

So the last two things I have been unable to figure out are :
-- Treasures
-- Encounters

It looks like the Treasures are stored somewhere between Offset '0x1C82C ~ 0x1E5F8'
But the order of the Hex values have me puzzled.
Will continue to look into this...but if anyone here can give me some hints
I would really appreciate it.

Finally, Encounters...this is where I am really in the dark.
May have to leave this alone and just release my progress if I do not have a breakthrough this month.
I really wanted to edit which enemies you encounter at different locations in the game.
But looking through the data...I have not been able to solve how enemy grouping works.

Anyhow, once I get the Shops and Treasures finished
I will release my hack here (unless I figure out the random encounters)
Again, thanks for all the support !

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #13 on: February 16, 2019, 10:07:02 am »
**UPDATE**

Had some computer problems and almost lost my progress.
A buddy help me recover everything ^_^"
Even with that long set back, I have completed my shop edits.
Currently working on editing the boss battles in the game (stats and items)
Also, I think I have figured out how treasure chests work
And plan on tackling that next.
As far as the random encounters
I do not believe, at my current skill level, that I can tackle these edits.
So once the boss and treasure chest edits are complete
I will do some gameplay testing and release my progress.
Again, thanks to everyone for their continued support !

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #14 on: March 09, 2019, 10:54:47 pm »
**UPDATE**

 Been offline for about two weeks now
 Everything that I want to change is now done.
 Will take the next week or so to walk through the game and test things out (boss battles and town shops)
 While testing, I plan on making small edits to make the game flow the way I want.
 Again, I plan to have things ready in the coming week...so thanks for everyone's help !!

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #15 on: March 24, 2019, 08:04:50 pm »
**UPDATE**

Hello everyone, I have now finished my second test run of the game
And very happy with the changes made along the way.
I have been having a blast testing everything out
But currently debating if I want to do a little more editing with the monsters.
As of now, it should take around 4~5 hours to beat the game instead of 2~3 hours.
I will be taking this next week to review a few things and then release what I have.

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube

break

  • Jr. Member
  • **
  • Posts: 68
  • Teaching the unteachable
    • View Profile
    • breaktube's youtube account
Re: [GB] Final Fantasy Legend II Hacking
« Reply #16 on: August 27, 2019, 07:03:17 pm »
Hello everyone, I hope you all had a fun summer !
So my hack of this game is now completed.
But I would like to edit the title/intro screen of the game.
Since this is an old-Gameboy game,
Are their any tools available to do this ?
If not, I am willing to learn how to do this
And I just would need direction on where to start.
I would like to know what is possible with this...
Like something as simple as "Hacked By..." under Start/Continue
Or something like a new image above "Start/Continue"
I hope I can get some help with this matter soon
Looking forward to people checking this hack out !!

September 01, 2019, 02:16:01 am - (Auto Merged - Double Posts are not allowed before 7 days.)
Alright, I have submitted my hack of this game !
Hope you all enjoy it
And I am open to any feedback.

**EDIT**

Project is now live :

http://www.romhacking.net/hacks/4659/
« Last Edit: September 01, 2019, 12:32:31 pm by break »

Pokemon Red 3DS-XL friend code : 1864-9639-1699 (Zeheart)
http://steamcommunity.com/id/breaktube
http://www.youtube.com/user/breaktube