Author Topic: [PSX/PC] Scarlet - Battle Data Editor (kernel.bin, scene.bin, EXE)  (Read 6906 times)

petfriendamy

  • *
  • Posts: 29
    • View Profile


Download here:
https://github.com/petfriendamy/ff7-scarlet/releases

Canary: https://github.com/petfriendamy/ff7-scarlet/releases/tag/canary

This is the big project I've been working on on-and-off for the past couple years, finally in a (mostly) usable state!

Scarlet is a combination kernel/scene editor that allows you to edit both of these files at once and keep them perfectly in-sync. It also incorporates my old FF7.exe editor, which will now also be properly synced with kernel.bin. It can also modify limit breaks now!

The crowning jewel in my opinion is the A.I. editor. I wanted to incorporate a GUI-based editor similar to Makou Reactor, so you can view and edit scripts in a much more intuitive manner.



Of course I cannot test every single scenario, so there is a chance of data loss/corruption when using this tool! Please use with caution. I recommend backing up your files before editing them. There are also some things that Scarlet currently can't edit, which will be coming as soon as I figure out how to handle them.

Huge shoutout to all of the modders who have put so much work into reverse engineering the game, and for everyone who helped me code this monstrosity. This project wouldn't be possible without you!

Happy modding!
« Last Edit: 2025-03-03 17:18:55 by petfriendamy »

nfitc1

  • *
  • Posts: 3012
  • I just don't know what went wrong.
    • View Profile
    • WM/PrC Blog
I willl want to see this in action.

petfriendamy

  • *
  • Posts: 29
    • View Profile
Pushed a new release with some new stuff:
  • You can actually edit stat curves now
  • Added the ability to edit some of the EXE text
  • Added a toggle switch that allows you to use features from Postscriptthree Tweaks (thanks PS3)
  • Various bug fixes
You can get it here: https://github.com/petfriendamy/ff7-scarlet/releases/tag/0.9.1
« Last Edit: 2024-06-11 18:09:43 by petfriendamy »

Kaiseran

  • *
  • Posts: 27
  • My best games is the RPGs and top is FF7 !
    • View Profile
Thank you for the new update :)

Hopefully to see also a program including  features to moving and replace or even editing the field models for PSX version.

Vordane

  • *
  • Posts: 6
    • View Profile
When I try to raise the power of Vincent's limit breaks or remove an elemental effect, it doesn't seem to work when I test it out.  The hex locations appear to match the decimal values.  So, it looks like it should work.  This also happens with Tifa's limit breaks.  Are Vincent and Tifa limit breaks editable?

Superbledur

  • *
  • Posts: 1
    • View Profile
Same as Vodane here. Works also for modifying a spell or an enemy attack, doesn't seem to work.
Also seem to be quite buggy when modifying kernel data (esp. Kernel2, some texts are replaced without warning).

Despite this, your tool is user friendly and easy to manipulate, I think that if you manage to correct the bugs it could be very useful.

petfriendamy

  • *
  • Posts: 29
    • View Profile
The limit data is provided as-is; unfortunately I don't know a whole lot about how it works. I fixed a bug with attack power not being set properly, so maybe that helps?

I'm not sure what you mean about kernel2 text being replaced without warning. If you could give me more detail on the issue, I could look into it. I'm also more likely to notice bug reports on Discord or Github since I don't check this forum super often.

In the meantime, I went ahead and did another stable release. It fixes a bunch of bugs, and adds a bunch more EXE text (some of which only work with the English EXE at the moment):

https://github.com/petfriendamy/ff7-scarlet/releases/tag/0.9.2

jwlee8707

  • *
  • Posts: 4
    • View Profile
Hello, developer.
Could you modify the program so that the char opcode it loads can be changed separately?

For example, there's something called touphscript's char.txt

https://drive.google.com/file/d/1q4Rm7Vplv3E4NhJ7ZFxwuNrpxRPRcfvy/view?usp=drive_link

If you look inside the compressed file, you'll see “char.txt” and “char fix.txt.”
The “char fix.txt” file is one I’ve modified for my own use.
However, from what I understand, Scarlet - Battle Data Editor seems to use the original “char” file for text.

Would it be possible to set up the program so that it can read from a separate file like “char,” allowing us to replace or modify it as needed?

petfriendamy

  • *
  • Posts: 29
    • View Profile
Scarlet doesn't use a "char.txt" file, it has its own custom implementation for reading FFText. If there are errors with it, feel free to let me know so I can fix them. If you want to completely change the char lookup table for some reason (custom characters maybe), you might be better off making your own fork of Scarlet for those changes, unless a lot of people really want that.

Raine Magnus

  • *
  • Posts: 2
    • View Profile
First of all, thank you for making this.  I'm currently working on a simple difficulty mod for the PC version as none of the ones I could find did what I wanted them to.  I have next to no knowledge of coding and can't read Japanese at all, but these editors should let me do what I need to.

Is there anyway using one of these editors to change how the Steal command works for characters?  I know Steal is dependent on level and since I'm going to be decreasing enemy EXP values that will be affecting the difficulty, which I'd rather not do.  I can't decrease enemy levels without affecting a LOT of things, and that would turn a relatively simple enemy stat mod into an absolute nightmare.  So I'd like to alter the Steal formula if possible.

One quirk I did notice with the Kernel Editor is that when adding stat modifications to Weapons, Armor, and Accessories that don't already have them is that once you select a stat from the drop down menu, the text for the amount of the modification stays greyed out and you can't change the value.  However, if you click on another item on the list and then click back on the item you were editing, you can now change the value.

Another thing I've seen is that if I click on an empty slot in the Attack Data tab in the Scene Editor and then attempt to make a new one, I get the following error message:



I'm not brave or knowledgeable enough to try making new enemy attacks to actually use at this point, but I thought it was worth mentioning.  I'm working on a Windows 11 PC if that matters.

Anyhow, I'm enjoying working with this so far.  Will post any further feedback I have in the future.

EDIT 2/27/25:

So I've begun work on my first mod using this, which as I said is a simple difficulty mod.  To make a long story short, I'm giving enemies stat boosts and modest reductions in EXP reward.  Will possibly tweak the power of specific attacks, but no firm plans for that just yet.  Anyhow, I've been using your Scene Editor and it makes that super easy.  As I said before, I'm no programmer, but I did mess around with RPG Maker way back when, so having a GUI editor like this lets me work on this project in a manner I'm familiar with.  I particularly appreciate the search function that allows me to look up every scene with a specific enemy.

I have encountered an issue with my modding causing the game to crash in battles though.  I'm using the 7th Heaven Mod manager with the SYW Unified Battle Textures, Field Textures, Minigames Textures, Worldmap Textures, and UI mods as well as the 60/30 FPS, Mouth Replacer, and Wizard Staff mods.  The crashing happens regardless of whether the mods are on or off, so I don't think it's those.  I know 7th Heaven uses FFNx which is something I don't know much about but I know it's not vanilla FF7.  Maybe that has something to do with the issue?

I did find a way to prevent the crashing though - at least so far (this mod is very much WIP), and it comes down to how I save my work after making edits.  When I tried to save with only scene.bin loaded in Scarlet, it gave me the following message:



I started over after loading up KERNEL.BIN and kernel2.bin as well as the exe file just in case, then made some edits again.  No problems until I go to test them out in game, and then it would crash whenever I entered a battle with edited enemies (not sure if it would be the cases with non-edited ones as I didn't try that).  I didn't think to screencap the crash message, but I remember it was very nonspecific and gave a link that looked to be the FFNx github page.

I then replaced my files with unedited ones and made edits again, this time without loading anything but scene.bin and ignoring the warning when saving.  Went back to try the game again and so far, so good.  Seems to do everything I wanted it too, and no crashes yet.  The game runs fine with the mods I listed too.
« Last Edit: 2025-02-27 23:53:32 by Raine Magnus »

petfriendamy

  • *
  • Posts: 29
    • View Profile
Thanks for the feedback!

Is there anyway using one of these editors to change how the Steal command works for characters?
No; I imagine that functionality is baked into the EXE.

One quirk I did notice with the Kernel Editor is that when adding stat modifications to Weapons, Armor, and Accessories that don't already have them is that once you select a stat from the drop down menu, the text for the amount of the modification stays greyed out and you can't change the value.  However, if you click on another item on the list and then click back on the item you were editing, you can now change the value.

Another thing I've seen is that if I click on an empty slot in the Attack Data tab in the Scene Editor and then attempt to make a new one, I get the following error message:



I'm not brave or knowledgeable enough to try making new enemy attacks to actually use at this point, but I thought it was worth mentioning.  I'm working on a Windows 11 PC if that matters.
I'll fix these when I get a chance, thanks!

I have encountered an issue with my modding causing the game to crash in battles though.  I'm using the 7th Heaven Mod manager with the SYW Unified Battle Textures, Field Textures, Minigames Textures, Worldmap Textures, and UI mods as well as the 60/30 FPS, Mouth Replacer, and Wizard Staff mods.  The crashing happens regardless of whether the mods are on or off, so I don't think it's those.  I know 7th Heaven uses FFNx which is something I don't know much about but I know it's not vanilla FF7.  Maybe that has something to do with the issue?

I did find a way to prevent the crashing though - at least so far (this mod is very much WIP), and it comes down to how I save my work after making edits.  When I tried to save with only scene.bin loaded in Scarlet, it gave me the following message:



I started over after loading up KERNEL.BIN and kernel2.bin as well as the exe file just in case, then made some edits again.  No problems until I go to test them out in game, and then it would crash whenever I entered a battle with edited enemies (not sure if it would be the cases with non-edited ones as I didn't try that).  I didn't think to screencap the crash message, but I remember it was very nonspecific and gave a link that looked to be the FFNx github page.

I then replaced my files with unedited ones and made edits again, this time without loading anything but scene.bin and ignoring the warning when saving.  Went back to try the game again and so far, so good.  Seems to do everything I wanted it too, and no crashes yet.  The game runs fine with the mods I listed too.
I'm having a little trouble following—it doesn't work if you save both the scene.bin and the kernel files? Have you tried on the canary version?

Raine Magnus

  • *
  • Posts: 2
    • View Profile
No; I imagine that functionality is baked into the EXE.

That’s ok.  Since my initial post, I've decided against lowering the EXP values, so the regular steal mechanics will be fine.

I'm having a little trouble following—it doesn't work if you save both the scene.bin and the kernel files? Have you tried on the canary version?

Sorry for not explaining things well.  I’m very new at this.  To give you some idea of how little I know, I had to Google what a canary build is.  I'm not exactly the best person to be giving feedback on this sort of thing.    ;D

Yes, saving both the scene.bin and the kernel files is what I meant.  As long as I just edit the scene file and save that alone, things have been running fine.

The problem seems to happen whenever I do anything that modifies the kernel files.  Whether it’s saving an edited scene file along with the kernels, or following this prompt….



…..to (if I’m interpreting that correctly) sync the lookup tables if I haven’t saved both together, the end result is the game crashing in battle.  When I enter a battle the screen goes black and I get this message:



Unless I start a new game instead of testing from a save file, in which case something a bit different occurs.  If I do that, when I engage the two MP’s at the train station in the first battle, the background and the enemy are both wrong (I didn’t change either of those).  Once Cloud tries to take an action, the game crashes, giving the same error message.



I downloaded the canary build and tried that.  After editing and saving, the game doesn’t load at all using 7th Heaven  - Gives me a black screen for a while until it tells me the program isn’t responding..  If I launch it from the exe, it doesn’t crash but battles play out weirdly.  When I try to attack one enemy, it looks like nothing happens, but I take out the other enemy and then the battle ends even though the first one is still on the screen.  There aren’t error messages when I’m doing this and I can otherwise continue playing normally.

When I have a chance, I may try a fresh install from Steam on another computer and see if the same thing happens there.  In the meantime, this still allows me to do what I need to do.
« Last Edit: 2025-03-05 03:28:56 by Raine Magnus »

petfriendamy

  • *
  • Posts: 29
    • View Profile
Hm, sounds like it's not syncing the lookup table correctly. I'll have to look into that. Thanks!