Author Topic: Character Graphics Swap hack.  (Read 17911 times)

Mauron

  • Guru of Reason Emeritus
  • Errare Explorer (+1500)
  • *
  • Posts: 1763
  • Nu-chan
    • View Profile
    • Maurtopia
Re: Character Graphics Swap hack.
« Reply #75 on: May 30, 2021, 03:39:34 pm »
This should get things working, just make sure your Glenn graphics are in the same bank (if they start at 40xxxx, they must end at 40xxxx).

IHBP

  • Architect of Kajar
  • Chronopolitan (+300)
  • *
  • Posts: 379
    • View Profile
Re: Character Graphics Swap hack.
« Reply #76 on: May 30, 2021, 07:23:58 pm »
Just gave it a try but it doesn't seem to work, and getting in a battle freezes it.

The graphics should all be in the 43xxxxx range
« Last Edit: May 30, 2021, 08:40:20 pm by IHBP »

IHBP

  • Architect of Kajar
  • Chronopolitan (+300)
  • *
  • Posts: 379
    • View Profile
Re: Character Graphics Swap hack.
« Reply #77 on: May 31, 2021, 08:32:05 pm »
Looks like they aren't all in the 43xxxx range, my notes at home are the correct ones the one I was checking here on this board is wrong so I'll have to move the graphics further down.

IHBP

  • Architect of Kajar
  • Chronopolitan (+300)
  • *
  • Posts: 379
    • View Profile
Re: Character Graphics Swap hack.
« Reply #78 on: May 31, 2021, 09:03:13 pm »
Progress! Moved the graphics to 00450000 and repointed them. They now work perfect on the field but still crash instantly when battle tries to start.

Mauron

  • Guru of Reason Emeritus
  • Errare Explorer (+1500)
  • *
  • Posts: 1763
  • Nu-chan
    • View Profile
    • Maurtopia
Re: Character Graphics Swap hack.
« Reply #79 on: July 05, 2021, 10:34:41 pm »
I fixed the bug on my end.

IHBP

  • Architect of Kajar
  • Chronopolitan (+300)
  • *
  • Posts: 379
    • View Profile
Re: Character Graphics Swap hack.
« Reply #80 on: July 06, 2021, 08:24:42 am »
Human Glenn turns invisible in battle now, but other than that battles are working correctly again.

Does the sprite assembly need to begin and end in the same bank as well?
« Last Edit: July 06, 2021, 08:33:38 am by IHBP »

Mauron

  • Guru of Reason Emeritus
  • Errare Explorer (+1500)
  • *
  • Posts: 1763
  • Nu-chan
    • View Profile
    • Maurtopia
Re: Character Graphics Swap hack.
« Reply #81 on: July 06, 2021, 01:55:22 pm »
Everything* needs to stay in one bank.

*technically there are a few things that can overlap bank boundaries, but they're special edge cases that even then only kinda work.

IHBP

  • Architect of Kajar
  • Chronopolitan (+300)
  • *
  • Posts: 379
    • View Profile
Re: Character Graphics Swap hack.
« Reply #82 on: July 06, 2021, 06:39:12 pm »
Alright that one was already good.

IHBP

  • Architect of Kajar
  • Chronopolitan (+300)
  • *
  • Posts: 379
    • View Profile
Re: Character Graphics Swap hack.
« Reply #83 on: February 08, 2022, 09:23:53 pm »
Is it necessary for both the graphics and the sprite assembly to be in the same bank together? I tried that to see if it would fix the problem with Glenn turning invisible in battle, but it did nothing.


Mauron

  • Guru of Reason Emeritus
  • Errare Explorer (+1500)
  • *
  • Posts: 1763
  • Nu-chan
    • View Profile
    • Maurtopia
Re: Character Graphics Swap hack.
« Reply #84 on: February 09, 2022, 03:35:21 am »
Send me your latest ROM, I'll see what's going on.

IHBP

  • Architect of Kajar
  • Chronopolitan (+300)
  • *
  • Posts: 379
    • View Profile
Re: Character Graphics Swap hack.
« Reply #85 on: August 18, 2022, 02:17:18 pm »
I've done all my homework on my end that's within my skill set,  human Glenn works fine for every animation, I also adjusted his techs so the animation for them works for both skins (no more adult man licking people).

All that remains to be completely done is move the 35 bytes of character data stored in the rom at x24F000 to 7E28A4-7E28C7 (there's still tons of free bytes here.) This would not only allow human Glenn but full or partial costume changes for every character.

Zakyrus

  • Entity
  • Magical Dreamer (+1250)
  • *
  • Posts: 1351
  • "Bouncy, bouncy, bouncy... --!!"
    • View Profile
Re: Character Graphics Swap hack.
« Reply #86 on: August 18, 2022, 02:27:44 pm »
All that remains to be completely done is move the 35 bytes of character data stored in the rom at x24F000 to 7E28A4-7E28C7 (there's still tons of free bytes here.) This would not only allow human Glenn but full or partial costume changes for every character.

Hooray so the new era is about to begin! The 8th characters nearly done.
But partial or full costume change in what context?

~Z

IHBP

  • Architect of Kajar
  • Chronopolitan (+300)
  • *
  • Posts: 379
    • View Profile
Re: Character Graphics Swap hack.
« Reply #87 on: August 18, 2022, 04:41:52 pm »
All that remains to be completely done is move the 35 bytes of character data stored in the rom at x24F000 to 7E28A4-7E28C7 (there's still tons of free bytes here.) This would not only allow human Glenn but full or partial costume changes for every character.

Hooray so the new era is about to begin! The 8th characters nearly done.
But partial or full costume change in what context?

~Z


This isn't the 8th character, but by moving the character data to ram we could change their graphics (if we make them) or palettes very easily in game at any time.

IHBP

  • Architect of Kajar
  • Chronopolitan (+300)
  • *
  • Posts: 379
    • View Profile
Re: Character Graphics Swap hack.
« Reply #88 on: September 08, 2022, 10:54:59 pm »
Another hacker posted this as a possible solution for moving the character data to ram.

"In 65816 assembly, you'd load the value you want (LDA $E4F000 I assume, since Chrono Trigger is probably hirom), and then store it with a command STA $7E28A4.  You'd need to do this in a loop, because even in 16 bit mode that only moves two bytes at a time.  So you (or someone writing assembly for you) would create a loop that loads the data and stores it to the RAM, place that loop in a subroutine, and then call that subroutine whenever you want to change what data is stored in the RAM (so somewhere in the event code for the costume change).
I don't know anything about Chrono Trigger's ROM, though, so I don't know where you'd place that loop and where you'd call it from."

justin3009

  • Fan Project Leader
  • God of War (+3000)
  • *
  • Posts: 3296
    • View Profile
Re: Character Graphics Swap hack.
« Reply #89 on: September 10, 2022, 07:10:37 am »
Likely, at start-up or something you'd want their main graphics offset stored right away to whatever RAM was necessary. Storing the pointers and stuff shouldn't be that hard, I think the more tedious aspect would be having to alter everything in the game to READ from the RAM locations.

Overworld, battle, all menus, etc.. I'm not sure if they all use a similar function or it's generally a single one used. But it would require, definitely, that anything that even remotely touches PC graphics to have to load the RAM instead. Likely a very tedious process.

...But there's also the fact of having to change Sprite Assembly and Animation Data as well. If it's just a swap over of the same size and everything that's fine, but if you're wanting to change the ENTIRETY of the character, yeah it's going to be need a lot more to be done.
« Last Edit: September 10, 2022, 07:11:54 am by justin3009 »