Golden Sun Hacking Community
December 14, 2017, 10:22:29 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News:
 
  Home   Forum   DC Wiki Help Search Calendar Downloads Login Register  
Pages: [1] 2 3   Go Down
  Print  
Author Topic: One-off Question Topic  (Read 25361 times)
0 Members and 1 Guest are viewing this topic.
Charon
On Probation
Veteran Member
*

Coins: 11
Offline Offline

Emblems: GBA Music Expert
Clan Position: Trickster Goddess of Luna
Posts: 1758

« on: March 04, 2009, 11:56:00 PM »

Well, we need one of these anyhow, and I didn't want to make a new topic for every problem I come across. (pin?)

BAH.

Atrius, one-off question. What kind of file do I have to save my .wav as (like, which Hz frequency, 8 or 16 bit, mono/stereo) to import sounds with, and how many bytes at the begining should I cut off from the wav file to make it work?

I know how to add the bytes at the begining of the .wav in the rom to make it play the right frequencies and length ect., but I really want to know how to import these. If I know, I could import the drum set/synth instruments from TLA from trimmed recordings.

EDIT: Please note that this is for hacking, nothing else. You can ask other kinds of questions in the Feedback section.
Logged
View Profile
Atrius
Programmer Extraordinaire
Web Host

Fear my blades

Veteran Member
*

Coins: 1
Offline Offline

Gender: Male
Emblems: Website Founder
Clan Position: Creation God of Sol
Posts: 1756

« Reply #1 on: March 05, 2009, 12:50:00 AM »

Well... The GBA uses signed 8 bit mono audio, but you can only save WAV files as unsigned 8 bit, so they don't quite sound right after importing them unless you can convert it first.  As for frequency, theoretically any should work as long as you set the right value in the header for the data after you copy it over, but practically I don't think I'd go above 22050 Hz.  (The GBA's direct sound channels can generate sound at about 16780 Hz max, having your audio sample's frequency higher than that can still help for lower notes though)

The location of the actual sound data in a WAV file typically starts at the 44th byte, but it can vary depending on if your audio program adds extra data to the header or not.  If you were to view it as text, you could find it by looking for the word "data", and skipping the 4 bytes after it (Although they're useful too, they specify the amount of data in bytes, which you'll need also)


You should be able to just copy the data for the drum sets over.  If you look at it, it's just like another set of instruments.
Logged

I'm shaking my head in general disapproval of everything
View Profile WWW
Charon
On Probation
Veteran Member
*

Coins: 11
Offline Offline

Emblems: GBA Music Expert
Clan Position: Trickster Goddess of Luna
Posts: 1758

« Reply #2 on: March 05, 2009, 01:06:00 AM »

Wha wha wha??

I spent all day yesterday and today looking for the snare! I couldn't find it! Do you know the offsets to the begining of the drum set data and the end of the drum set data? I could probably find it via trial error methods.

And a converter is where?...
Logged
View Profile
Atrius
Programmer Extraordinaire
Web Host

Fear my blades

Veteran Member
*

Coins: 1
Offline Offline

Gender: Male
Emblems: Website Founder
Clan Position: Creation God of Sol
Posts: 1756

« Reply #3 on: March 05, 2009, 01:38:00 AM »

In the instrument table, the entry for the drum kit would have a pointer to it's instrument set in the same place a regular instrument would have a pointer to it's WAV sample.

The drum kit instrument set starts at 0x081C3B70.


I had to program my own converter...
Logged

I'm shaking my head in general disapproval of everything
View Profile WWW
Charon
On Probation
Veteran Member
*

Coins: 11
Offline Offline

Emblems: GBA Music Expert
Clan Position: Trickster Goddess of Luna
Posts: 1758

« Reply #4 on: March 05, 2009, 02:55:00 AM »

I was going through the individual wav files to see if I could find anything...

Atrius, it's still not working. Some of those pointers lead to the system created instruments, and I really don't want to rewire anything. I tried to use your download link from my Jupiter topic on GSR, but I keep on getting an error. Do you have a fixed link by any chance? Or is it just my computer being stupid again?
Logged
View Profile
Atrius
Programmer Extraordinaire
Web Host

Fear my blades

Veteran Member
*

Coins: 1
Offline Offline

Gender: Male
Emblems: Website Founder
Clan Position: Creation God of Sol
Posts: 1756

« Reply #5 on: March 05, 2009, 01:33:00 PM »

I haven't released the converter yet.  If you're talking about my audio data ripping tool it's here now.  I'll try to polish up the converter so I can release it sometime soon.

EDIT:

Here you go, it'll automatically convert WAV files to 8-bit mono too if they aren't already, but It doesn't touch the sample rate.  It also automatically creates the bare essentials of the 16 extra bytes of data before the actual audio data that the GBA needs too.

If you're gonna record the instrument samples from the game playing it, it's good to know that a note with the value of 0x3C is played at the exact frequency the audio data is stored as.  This doesn't apply to drum kits where each note is actually a different instrument, and will be played at it's actual frequency regardless.

This post has been edited by Atrius on Mar 5 2009, 09:02 PM
Logged

I'm shaking my head in general disapproval of everything
View Profile WWW
Charon
On Probation
Veteran Member
*

Coins: 11
Offline Offline

Emblems: GBA Music Expert
Clan Position: Trickster Goddess of Luna
Posts: 1758

« Reply #6 on: March 08, 2009, 02:36:00 AM »

Thanks, Atrius, that will be extremely useful. I was getting worried that I'd have to transfer Song.gba's instruments *shudder*

Now that I've got that over with, I'm just gonna say that this topic is for anyone, not just the wonderful Charon, with one-off questions. SO ASK AWAY FIENDS!!

This topic was pinned for all members to use as a one question help thread. - Charon
Logged
View Profile
Nicktallica
Guest
« Reply #7 on: May 13, 2009, 01:35:00 AM »

I feel extremely stupid asking this, but how do I go about finding some free space in Golden Sun:TLA?  Mercury Djinni Set  
Logged
Charon
On Probation
Veteran Member
*

Coins: 11
Offline Offline

Emblems: GBA Music Expert
Clan Position: Trickster Goddess of Luna
Posts: 1758

« Reply #8 on: May 17, 2009, 04:57:00 PM »

I feel extremely stupid asking this, but how do I go about finding some free space in Golden Sun:TLA?  Mercury Djinni Set
There are some programs, known as "Free Space Finders", that can help you do that. Golden Sun's free space is filled with 0x00 bytes, so you could also go into a hex editor or tile viewer to search. Some pockets of free space are before 0x1C0000, and they're relatively small (ranging from about 6-40 KB) and the two big pockets are around 0x6322B4 (around 320 KB or so) and 0xF7964C (end-of-rom free space; about 550 KB).

Atrius said that Golden Sun: The Lost Age has a sufficient amount of free space (if I remember correctly, somewhere around 1-2 MB), but as I pointed out, it's scattered all over the place.
Logged
View Profile
Rolina
The Fulminous Witch
Jupiter Clan

Template maker turned lurker

Alchemist
*

Coins: 10
Offline Offline

Gender: Female
I am: wondering if we can get our clan position changed...
Clan Position: Grand Overlady of Jupiter
Posts: 6050

« Reply #9 on: May 17, 2009, 05:35:00 PM »

That's a good question, I'd like to know this too.  It'd be nice to have an option to let us max out the GBA capable space for the file, and perhaps a little gauge to let us know how full it is with content.  I don't think such a thing exists in the editor at the moment (if it does, SWEET!), but it'd be nice to have in v0.3
Logged

View Profile WWW
Nicktallica
Guest
« Reply #10 on: May 29, 2009, 12:23:00 AM »

Thank you so much Charon. Now I can insert music easily without overwriting the game's memory!

 
Logged
Atrius
Programmer Extraordinaire
Web Host

Fear my blades

Veteran Member
*

Coins: 1
Offline Offline

Gender: Male
Emblems: Website Founder
Clan Position: Creation God of Sol
Posts: 1756

« Reply #11 on: May 29, 2009, 01:04:00 AM »

Once I get my hard drives hooked up I can give you an exact list of all the free space in the ROM.

Charon, if I remember correctly, at 0x08680000 there's a list of pointers.  There are blocks of space before the majority of the first several locations.
Logged

I'm shaking my head in general disapproval of everything
View Profile WWW
Charon
On Probation
Veteran Member
*

Coins: 11
Offline Offline

Emblems: GBA Music Expert
Clan Position: Trickster Goddess of Luna
Posts: 1758

« Reply #12 on: July 03, 2009, 07:46:00 PM »

Hey, Atrius.

NEW QUESTION.

How do you do simple 16 colour palatte rotation via ASM? I can load an ASM code via scripting, but I want to make a palatte rotation occur similar to that in the animation of certain Pokemon attacks like Magical Leaf or Psychic, or like Golden Sun's Mind Read background.
Logged
View Profile
Salanewt
His Sexiness
Mercury Clan

Oh yeah, baby!

Prodigy
*

Coins: 32
Offline Offline

I am: A part of the organization of Cool Cats, but more of a dog person in reality.
Emblems: Have a nice day.
Posts: 4565

« Reply #13 on: July 03, 2009, 09:40:00 PM »

Oh yeah, I forgot about the colour rotating for Mind Read. I would also like to know how to do this, please?

Also, I was wondering. This is just a question, based out of curiosity, but is there any other way to raise the defense of a monster? The defense editor does not currently work, so this is why I ask this now.

Have a nice day.
 Mercury Djinni Set  
Logged

Oh yeah baby, £ me harder.

Fusion is just a cheap tactic to make weak Adepts stronger.

Yoshi's Lighthouse is a hacking website in progress. Why not check it out if you like Yoshi or the Mario & Luigi games?
View Profile WWW
JamietheFlameUser
Diamond Pokémon
Mars Clan

Does this look like the face of mercy?

Prodigy
*

Coins: 0
Offline Offline

Gender: Male
I am: Poke poke poke poke... I can't stop it...
Posts: 2633

« Reply #14 on: July 04, 2009, 12:54:00 AM »

Can VisualBoy Advance cope with ROMs bigger than can fit in a GBA cartridge? Is there room in Golden Sun 2 for extra characters, Psynergies, musics, sprites, enemies, etc.?
Logged

:P

Lloyd: Easy as pie.
Genis: Sweet!
Presea: ...Sweetie pie...
Zelos: Let's not start on this again...

Spoiler for epic mindscrew:
View Profile
Pages: [1] 2 3   Go Up
  Print  
 
Jump to:  

Cbox
Yesterday at 09:19:38 PM
Fox: Okay, so that Summon Night games adds the fram number to the seed, before generating another seed via mul/add....  (GS1-GS3 never adds the fram number.) ... So um, that makes sense! ;  Summon Night:  ((seed + frame) * 0x343FD + 0x269E3C) >> 0x10 ; Which is also on the list here: https://en.wikipedia.org/wiki/Linear_congruential_generator
December 12, 2017, 11:10:45 PM
Fox: Yes, and there could be contests. Maybe ones where 1st/2nd/3rd place get a cash reward, but eh. Dunno.... Kind of thinking about making a topic about how people got their job, and what was their experience. (e.g. Did they use references of people already working in the job, and various other things.)
December 09, 2017, 04:24:14 AM
Majora: Import old forum posts for reference, perhaps take posts containing important info like documentation away from the old stickied forum post model and make them into their own pages on a site with an in-built search bar. Might help with SEO, too. If nothing else, perhaps whipping them into PDFs and hosting them via Scribd? The possibilities are boundless when it comes to restructuring a site
December 09, 2017, 04:20:02 AM
Majora: Just a nice idea to have even if it doesn't come to fruition. Updating, modernizing, always a good idea. Could probably do something pretty nifty using a good Wordpress theme
December 09, 2017, 04:15:45 AM
Majora: Would be kind of neat to do something like that for GSHC. Could change it up a bit to show all tweets/instagram posts/facebook posts/golden sun subreddit posts all in one sidebar. It would be cool in that it gives the site it's on (and the topic in general) appear more lively and active, which is a plus
December 09, 2017, 04:14:19 AM
Majora: That does sound interesting. One cool thing I've seen some sites use is a sort of unique take on a sidebar option that acts like a social media integration (like, "See GSHC's latest Tweets"). It displays activity from a variety of related sites, such as Reddit, Twitter, Instagram, etc.
December 09, 2017, 12:58:53 AM
Fox: And the way it'd work via code is not that all users would instantly get nicknames the minute you register... but rather, the moment you view a name if it doesn't have a nickname, it gets one. (My Thoughts.)
December 09, 2017, 12:53:55 AM
Fox: (I was thinking that it would be "Name (Nickname)" ... The nickname is what you first known the user as, and you can change that yourself... and the Name is what the user wants to be called... Something like that.
December 09, 2017, 12:47:56 AM
Fox: So like... for starters, one idea I had was to make it so anyone can name anyone... much like how it works on Skype, and you (the namer) would be the only one to see it, and such...
December 09, 2017, 12:45:02 AM
Fox: Would need to be carefully thought out and tested, though.
December 09, 2017, 12:43:02 AM
Fox: I'm thinking I could make it so that name changes can happen whenever... (Without any limit)... Since I believe there's a way to do it with minimum confusion. (I think.) Hmm....
December 09, 2017, 12:31:36 AM
Fox: (I mean an offline version... at least initially.)
December 09, 2017, 12:25:01 AM
Fox: Now that I have thought about it a bit more, would I be right to assume that GSHC would be one of the most interesting websites to administrate, or no? It's sad to see not much going on with it. == I almost want to make a concept website at some point. :D Anyway, how is everyone doing today?
December 06, 2017, 12:12:59 AM
Fox: Like... Start using Github or something... Do like how many of those other projects such as Citra (WIP 3DS Emulator) does. Etc.
December 06, 2017, 12:08:12 AM
Fox: No idea. I just wish OpenGoldenSun would release it as unfinished, but oh well.
December 05, 2017, 06:52:09 AM
MaxiPower: Bummed out that the open golden sun project is dead it seems with no actitivy in close to a year at this point. Is there any hope left in any other projects?
November 27, 2017, 10:25:28 AM
Fox: (When I say research, mainly refering to the data in the game, though checking websites can count to a degree.)
November 27, 2017, 09:52:27 AM
Fox: Maybe. But Dark Dawn is meh, hahah... I still research it, though, because data can be interesting.
November 27, 2017, 05:28:36 AM
Portakin: I'm here! This game is underrated!
November 25, 2017, 08:03:23 PM
Fox: .... and the email listed in that post makes me think we should just make a new rules topic with most of the same information. (So the old ones can be sort o archived.)

Affiliates
Temple of Kraden Golden Sunrise
Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.051 seconds with 22 queries.