+  RHDN Forum Archive
|-+  Romhacking
| |-+  ROM Hacking Discussion
| | |-+  Phoenix Wright NDS Script to GBA: Last Updated Sept. 11, 2008
Pages: 1 2 3 [4] 5 6 ... 10
Author Topic: Phoenix Wright NDS Script to GBA: Last Updated Sept. 11, 2008  (Read 5 times)
cocomonk22
Guest
« Reply #45 on: March 16, 2008, 04:55:25 am »

I'm still not sure how to find the location in the rom of the starting address for the LZ compressed location graphic, though.
KC
Guest
« Reply #46 on: March 16, 2008, 05:26:28 am »

Due to the lack of bios emulation, it's still in register r0 (which is, as labmaster said, the source address).
So you subtract 0x8000000 (because the memory area of the rom starts at 0x8000000) and you have the absolute address in the rom. That would be 0x223c78 in this case.

Quote from: labmaster on March 14, 2008, 10:49:20 pm
[NB: Decompressing to an EWRAM buffer then transferring to VRAM via DMA is actually a pretty common pattern.]
Yes, of course. But it's pretty useless if used like this.  LZ77UnCompVram can write directly to VRAM, and it's faster than a combination of LZ77UnCompWram and a DMA transfer, too. So why waste time and space?
akadewboy
Guest
« Reply #47 on: March 16, 2008, 04:00:38 pm »

Whoa talk around here is starting to go way over my head, so forgive me if this doesn't help:

Using NLZ77 you can scan the ROM for compressed data. It will give you the offsets of everything that's compressed, but it wont tell you if it's graphics or text. Then you can use it to decompress that stuff. Here's all the offsets with compressed data:

http://www.fileden.com/files/5938/GS3%20Compressed%20Offsets.txt

Again I'm sorry if this isn't on topic, I'm not sure what you guys are talking about right now.  Wink
« Last Edit: March 16, 2008, 04:09:03 pm by akadewboy »
cocomonk22
Guest
« Reply #48 on: March 16, 2008, 05:59:31 pm »

Thanks for those compressed offsets.

There is a problem in case 2. After you talk to AA using either talk option, the game freezes. Looking in the script, there is a <jmp 173> at the end of both sections. <jmp 173> goes to pointer f3 (173-80). Here is pointer f3:
Code:
@PTRf3
<noop><35 2d00 16><35 a01 16><10 800a><jmp 127><hidetextbox 3><special_jmp>
<endjmp>

<jmp 127> goes to pointer a7:
Spoiler: (View)
Code:
@PTRa7

<noop><10 a><38 1><person 10 e34 b4c><name 1000><sound e 1>&0
/6あら‥‥。=10/3もう8時すぎ。
[&0/3Oh,=08 look!=10/2 It's already 8:00!<b>Have you all eaten yet?
<wait_noanim 24><person 10 144 0>
みなさん、=08お食事はまだですよね?
]
<nextpage_button><name 300>
ええ。=10まあ‥‥。
[Um,=0a well actually...]
<p><name 1000>
12階のレストランに、予約を入れていますの。
[I've already made a<b>reservation at the restaurant<p>on the 12th floor.]
<nextpage_button><person 10 550 4e8><music 131 3c>
ごいっしょにディナーを、=08と思いまして。
[Why don't we all dine<b>together?]
<nextpage_button><person 4 2750 2648><name 400><sound 7e 1>&0
*1/2わお。
[&0*3/2Ooh!&0=14 I like the sound of that!=14<b>"Dine"...=0c<p>It sounds so fancy!
&0
=14いいですねー、=0cでぃなー。
]
<nextpage_button><person 1e 3148 2f0c><name 1e00><hidetextbox 0><sound 7e 1>
&0
*1わたくし、
[&0*3I'll have&0 the "Kids&0 Lunch"!<b>
&0
=0cお子さまランチがいいです!
]
<nextpage_button><hidetextbox 1><personvanish 4 1>=10<person 4 aa4 aa4><personvanish 3 1>
=10<hidetextbox 0><name 400>
/6ふっふっふっ。=10/4
[/3Ha ha ha.=10/2 Pearly,=0a it's dinner,=0a<b>not lunch.<p>
<person 4 bd8 aa4>
はみちゃん。=0aランチはおヒルに食べるものだよ。
]
<p>
今夜はグッとオトナっぽく、=14
[*3/2Why don't you go for it and<b>really eat your fill with a<p>"Kid's Dinner"?
<person 4 2750 2648>
*0/3お子さまディナーで行こうよ!
]
<nextpage_button><hidetextbox 1><personvanish 4 1>=10<person 1e 2f0c 2f0c><personvanish 3 1>
=10<hidetextbox 0><person 1e 3148 2f0c><name 1e00>
*0はいっ! =10じゃあ、=08お子さまディナーで!
[*3OK!=10 In that case,=08 one<b>"Kid's Dinner" for me!]
<nextpage_button><hidetextbox 1><personvanish 4 1>=10<person 10 4e8 4e8><personvanish 3 1>
=10<hidetextbox 0><person 10 550 4e8><name 1000>
ふふ。
[Ha ha.<b>Shall we head upstairs,=08<p>then?
<wait_noanim 20><person 10 144 0>
じゃあ、=08行きましょうか。
]
<nextpage_button><hidetextbox 1><bgcolor 204 1 1f>=19<person 0 0 0><bg ff><name 300>
<bgcolor 101 1 1f>=07<hidetextbox 0><10 800a>
/4‥‥というわけで、=10あとは公開日を待つばかり。
[/2After that pleasant evening,=0a<b>all that remained was to wait<p>for the exhibition's opening.]
<nextpage_button>
霧緒さんの元気なカオも見られて、=0cそれは楽しい晩だった。
[It was wonderful seeing<b>Ms. Andrews looking so happy.]
<nextpage_button>
いったい/8‥‥=10/4だれが想像できただろう。
[/2None of us could have<b>imagined...]
<nextpage_button><fademusic 0 78>
‥‥その翌日、=10/5あんな事件が起こるなんて‥‥
[That the very next day,=0a<b>/3something terrible would<p>happen...]
<nextpage_button><hidetextbox 1>=3c<fadetoblack 0><special_jmp><endjmp>
« Last Edit: March 16, 2008, 06:05:55 pm by cocomonk22 »
RadioShadow
Guest
« Reply #49 on: March 16, 2008, 07:06:15 pm »

This is looking really good.  That title looks good in the GBA rom. 

I've had a look at the rom to see if there is a way to expand the text box so three lines can fit in.  I was expecting it to be a whole image the game loads but it turns out it just loads 8 x 8 squares to make the image which are uncompressed.  I just got to locate the data that tells the rom how to display the box and edit it.  Shouldn't be too hard.   

If that is successful, all that is required is to figure out how to move the name box up and allow the text to flow on three lines.  But let's worry about one step at a time. 

EDIT:

Well it wasn't as hard as I expected.  The data was uncompressed and there is plenty of space to expland the 'map' graphic:



Same height as in the Phoenix Wright game now. ^^

Now to figure out how to move the name graphics up. 
« Last Edit: March 16, 2008, 08:19:45 pm by RadioShadow »
andwhyisit
Guest
« Reply #50 on: March 16, 2008, 11:16:17 pm »

Quote from: RadioShadow on March 16, 2008, 07:06:15 pm
This is looking really good.  That title looks good in the GBA rom. 

I've had a look at the rom to see if there is a way to expand the text box so three lines can fit in.  I was expecting it to be a whole image the game loads but it turns out it just loads 8 x 8 squares to make the image which are uncompressed.  I just got to locate the data that tells the rom how to display the box and edit it.  Shouldn't be too hard.   

If that is successful, all that is required is to figure out how to move the name box up and allow the text to flow on three lines.  But let's worry about one step at a time. 

EDIT:

Well it wasn't as hard as I expected.  The data was uncompressed and there is plenty of space to expland the 'map' graphic:



Same height as in the Phoenix Wright game now. ^^

Now to figure out how to move the name graphics up. 
Look good, but...

Sorry to ruin this for you but you need to consider that the DS version had extra room to put a new line in (taller screen). By putting a new line in you risk obstructing something in the game since that textbox will now cover around 40% of the screen. A better solution would be to find a way to display 3 lines within the smaller textbox.
RadioShadow
Guest
« Reply #51 on: March 17, 2008, 02:25:03 am »

You think it won't work?  The only thing I found covering the taller text box was the Court Record but that can easily be moved up to the top part of the screen (or maybe even modify it to work like the English version but that would require some skilled hacking).   

It's not like the taller text box covers the sprites faces or anything.  Unless I'm missing something that you're concerned with.

The only other solution is to use a smaller font or stick to just two lines but I dislike those options. Tongue
RadioShadow
Guest
« Reply #52 on: March 17, 2008, 05:06:43 pm »

Well I'm on the right track:



Now just got to move it down 2 tiles and yes I'm aware it's PW1 but PW3 works in the same way the features can easily be transferred.

EDIT:



^^   
« Last Edit: March 17, 2008, 06:30:33 pm by RadioShadow »
andwhyisit
Guest
« Reply #53 on: March 17, 2008, 06:29:44 pm »

Quote from: RadioShadow on March 17, 2008, 02:25:03 am
You think it won't work?  The only thing I found covering the taller text box was the Court Record but that can easily be moved up to the top part of the screen (or maybe even modify it to work like the English version but that would require some skilled hacking).   

It's not like the taller text box covers the sprites faces or anything.  Unless I'm missing something that you're concerned with.

The only other solution is to use a smaller font or stick to just two lines but I dislike those options. Tongue
I still dislike this since it is turning the GBA version into the DS version, I prefer the smaller textbox of the GBA version. Also won't that name box get in the way of the court record box even if you move it up?

Also there is nothing wrong with having it as two lines. This is for people who don't have a DS and as such have never played the DS version. (Well at least that was the impression I got)
« Last Edit: March 17, 2008, 06:42:21 pm by andwhyisit »
KaioShin
Guest
« Reply #54 on: March 18, 2008, 11:18:33 am »

Quote from: andwhyisit on March 17, 2008, 06:29:44 pm
Also there is nothing wrong with having it as two lines. This is for people who don't have a DS and as such have never played the DS version. (Well at least that was the impression I got)

It's for people who are too cheap (stone age PCs) to use even an DS emulator, so they can pirate the game on GBA emulators.
andwhyisit
Guest
« Reply #55 on: March 18, 2008, 05:51:53 pm »

Quote from: KaioShin on March 18, 2008, 11:18:33 am
Quote from: andwhyisit on March 17, 2008, 06:29:44 pm
Also there is nothing wrong with having it as two lines. This is for people who don't have a DS and as such have never played the DS version. (Well at least that was the impression I got)

It's for people who are too cheap (stone age PCs) to use even an DS emulator, so they can pirate the game on GBA emulators.
Yes but this wasn't intended for those types of people right?
akadewboy
Guest
« Reply #56 on: March 18, 2008, 06:45:56 pm »

*waits for someone to say: "But teh text will cover up teh boobies!!!111"

>_>
<_<
*runs*


But seriously, I think the 3 lines might look good. The question is if it will make inserting the script easier, harder, or no difference.
andwhyisit
Guest
« Reply #57 on: March 18, 2008, 08:22:48 pm »

:banghead:

Seems I am outvoted. How does the court record box look with this?
KaioShin
Guest
« Reply #58 on: March 19, 2008, 04:28:07 am »

Quote from: akadewboy on March 18, 2008, 06:45:56 pm
*"But teh text will cover up teh boobies!!!111"

Yay for transparent message boxes!
cocomonk22
Guest
« Reply #59 on: March 20, 2008, 07:40:28 pm »

New patch up that translates to case 2-3 (see first post). Graphics still aren't translated, though I think I have all the locations for Location graphics. I just need to match up which ones are which, then replace the text.
List of location offsets: http://pw.scorpei.com/scripts/GS3/gs3_location_index.txt
Pages: 1 2 3 [4] 5 6 ... 10  


Powered by SMF 1.1.4 | SMF © 2006-2007, Simple Machines LLC