Skeetendo

’Cause all games were better on the GBC

You are not logged in.

#1 2014-11-30 11:40:39

frz hax
Member
Registered: 2014-08-06
Post 36/43

SHIFT/SET

How do I make the battle style set by default and remove the shift option. It's the last thing I have to do in my hack and it would make more sense for me if you mentioned offsets and the bytes to change.

Thanks!

P.S What is up with all these spam bots these days? They make up 90% of all new posts. Is there a way to minimise them? Maybe some other forums have solved the problem.

Offline

#2 2014-11-30 20:31:27

Mateo
Member
From: The Sims 4
Registered: 2009-11-25
Post 2,928/3,508

Re: SHIFT/SET

I know that Miksy91 figured out a way to do this (Ironically, he was unaware that SET as a style existed at the time and implemented it independently of that option if I remember).

You can check out Miksy's thread here.


As for the spambot issue, that has been a recurring thing for years. Nothing seems to actually stop them, it just makes a temporary dent in their numbers. Most of them are deleted rather quickly once a staff member comes online and sees them. At least that's how it was when I was on staff here and it seems to still be that way now.

Offline

#3 2014-11-30 21:48:46

frz hax
Member
Registered: 2014-08-06
Post 37/43

Re: SHIFT/SET

Thanks for your help, but I need to know where the routine is in gold. Crystal is doing what I want in Crystal but I'm hacking gold.

Offline

#4 2014-11-30 22:02:46

Mateo
Member
From: The Sims 4
Registered: 2009-11-25
Post 2,929/3,508

Re: SHIFT/SET

The thread I linked you to has a link to download a .zip file. Inside you will find 2 patch files. One applies this to Gold or Silver, the other applies it to Crystal.

Offline

#5 2014-11-30 23:35:19

Crystal_
Member
From: Spain
Registered: 2012-09-16
Post 229/437
Website

Re: SHIFT/SET

Look, according to Miksy's thread, the bit that controls the battle style status is bit 6 of memory address D199. Just hack the v-blank interrupt (0040) to fit in ld hl,D199 and set 6, (hl) instructions right after the registers are pushed. Easily the worst possible way to do it, but should do the trick.
Oh, and edit the "SHIFT" text to "SET", wherever it is.

Offline

#6 2014-12-01 09:27:43

frz hax
Member
Registered: 2014-08-06
Post 38/43

Re: SHIFT/SET

It's nice how you're all helping but none of the above really makes sense to me (yes I'm dumb). I've seen D199 change in VBA's memory viewer when I change the battle style in game but what I don't understand is:

'Just hack the v-blank interrupt (0040) to fit in ld hl,D199 and set 6, (hl) instructions right after the registers are pushed.'

I can change the text but literally none of that sentence maks sense.

Thank You

Offline

#7 2014-12-01 13:05:00

Miksy91
Member
Registered: 2010-10-16
Post 2,148/2,317

Re: SHIFT/SET

Mateo wrote:

I know that Miksy91 figured out a way to do this (Ironically, he was unaware that SET as a style existed at the time and implemented it independently of that option if I remember).

You can check out Miksy's thread here.

Yeah... I was unaware of that alright :D

Anyway, just saying that I remember implementing "Active" mode for DE differently than how I originally made it like linked to that thread.
As for what comes to your problem (frz hax), there are plenty of ways for changing the SHIFT mode to work like SET. Probably the easiest option to go for is what Crystal had suggested but you can also implement it by hacking the routine that checks the 6th bit (or 7th counting from 1) from of address "D199" during battle and no matter what the value is, act like SET mode is turned on. I think my "active battle system" did just that but there was some minor bug out there (= that check was passed in some occasions).

But debugger is your friend if you want to go with implementing it better.
If you're fine with my "ABS" mode the way it is, just patch the gold -patch file over your rom hack (and maybe before doing it, check with IPS Peek (http://www.romhacking.net/utilities/1038/) that it does nothing unwanted to your hack rom although it shouldn't).

Last edited by Miksy91 (2014-12-01 13:08:02)

Offline

#8 2014-12-02 05:04:05

Chamber_
Member
Registered: 2013-12-31
Post 92/119

Re: SHIFT/SET

The things are more simples.

In $3D5E4 the game check the bit option for a "BATTLE_SHIFT":

$3D5E4

ld a,[$D199]//Options
bit 6,a//BATTLE_SHIFT
jr nz,$5604

The only that you need es change the jr nz,$5604 to jr $5604 and that you can do it in a hex editor to change the 0x20 to 0x18 in the address $3D5E9.

PS: These offsets are for Pokemon Gold.

Last edited by Chamber_ (2014-12-02 05:06:02)

Offline

Board footer

Powered by FluxBB