Language…
24 users online: Aclais,  Ahrion, Batata Douce, crm0622,  Eden_, Ekimnoid, Gamet2004, Golden Yoshi, Hidincuzimsmokin, koffe190,  MarioFanGamer, masl, Mischievous Marc, neidoodle, Rauf,  Ringo, RZRider, Scags, schema_tuna, shaoshao, sinseiga, StarWolf3000, sugarfish456, TheXander - Guests: 264 - Bots: 256
Users: 64,795 (2,376 active)
Latest user: mathew

Official Hex/ASM/Etc. Help Thread

  • Pages:
  • 1
  • 2
  • 3
  • 4
  • 5
  • 407
  • 408
  • 409
  • 410
  • 411
  • 412
  • 413
  • 414
  • 415
  • 416
  • 417
  • 418
  • 419
  • 420
Originally posted by KevinM
Kind of a hacky solution but you can use this uberasm, which forces the game to load the palette from the freeram address rather than from ROM. What you need to do is to edit the colors table with the 10 colors (from 6 to F in the palette) you want. The values you put there are the SNES RGB values, which you can see in the palette editor when you hover over a color (the default values I put set it to Luigi's colors, just for testing).

My savior! This is exactly what I needed, and it works like a charm. Thank you so much KevinM! #w{<3}
Originally posted by SKKiro
I just need one little bit of clarification about rom maps adresses and Asar.

I know already which adress I need to change a value of and what to input. Is it just making the adress and it's bit value change into an asm file and using Asar to patch my rom file with?

Yes, the format is "org $XXXXXX : db $YY", where $XXXXXX is the address you want to modify, and $YY what (8 bit) value to insert. If you have multiple values to insert at an address, use "db $YY,$ZZ,...". You can also insert 16 bit values with "dw $YYYY" or 24 bit values with "dl $YYYYYY". Then the asm file needs to be patched with Asar as you said.
When i try to install this patch in Asar 1.7.1 i get this error:
Code
sidestepper.asm:47 (called from sidestepper.asm:47): error: (E5094): Macro 'SubHorzPos' wasn't found. [%SubHorzPos()]
sidestepper.asm:48 (called from sidestepper.asm:47): warning: (W1008): Missing org or freespace command. [TYA]
sidestepper.asm:49 (called from sidestepper.asm:47): error: (E5088): Define '157C' wasn't found.
sidestepper.asm:51 (called from sidestepper.asm:47): error: (E5088): Define '7FAB10' wasn't found.
sidestepper.asm:54 (called from sidestepper.asm:47): error: (E5088): Define 'E4' wasn't found.
sidestepper.asm:58 (called from sidestepper.asm:47): error: (E5088): Define '1594' wasn't found.
sidestepper.asm:71 (called from sidestepper.asm:71): error: (E5094): Macro 'SubOffScreen' wasn't found. [%SubOffScreen()]
sidestepper.asm:74 (called from sidestepper.asm:71): error: (E5088): Define 'C2' wasn't found.
sidestepper.asm:77 (called from sidestepper.asm:71): error: (E5088): Define '163E' wasn't found.
sidestepper.asm:87 (called from sidestepper.asm:71): error: (E5088): Define '14C8' wasn't found.
sidestepper.asm:90 (called from sidestepper.asm:71): error: (E5088): Define '163E' wasn't found.
sidestepper.asm:92 (called from sidestepper.asm:71): error: (E5088): Define 'BankB' wasn't found.
sidestepper.asm:93 (called from sidestepper.asm:71): error: (E5088): Define 'BankB' wasn't found.
sidestepper.asm:94 (called from sidestepper.asm:71): error: (E5088): Define '1570' wasn't found.
sidestepper.asm:95 (called from sidestepper.asm:71): error: (E5088): Define '1570' wasn't found.
sidestepper.asm:99 (called from sidestepper.asm:71): error: (E5088): Define 'C2' wasn't found.
sidestepper.asm:105 (called from sidestepper.asm:71): error: (E5088): Define '1602' wasn't found.
sidestepper.asm:106 (called from sidestepper.asm:71): error: (E5088): Define '157C' wasn't found.
sidestepper.asm:108 (called from sidestepper.asm:71): error: (E5088): Define 'B6' wasn't found.
sidestepper.asm:116 (called from sidestepper.asm:71): error: (E5088): Define 'C2' wasn't found.
sidestepper.asm:119 (called from sidestepper.asm:71): error: (E5088): Define '161A' wasn't found.
sidestepper.asm:125 (called from sidestepper.asm:71): error: (E5088): Define '1938' wasn't found.
sidestepper.asm:125 (called from sidestepper.asm:71): error: (E5001): Over 20 errors detected. Aborting.
A fatal error was detected while assembling the patch. Assembling aborted. Your ROM has not been modified.

What can i do?
That's a custom sprite meant to be inserted with PIXI, not Asar.
Asar doesn't support such defines and macros.
Windowless ride, feeling alive
Are you alive or just breathing?
Originally posted by Katerpie
That's meant to be inserted with PIXI, not Asar. It's a custom sprite, and Asar doesn't support such defines and macros.

Thanks, this helped out a lot! #wario{^_^}
How do I check if a No Yoshi intro is currently running or not? I can't seem to find anything in the RAM Map except for this address, but that didn't really help me.


YY-CHR > Photoshop.
Try checking if $7E0071 is #$0A. According to the ROM map, this triggers $00C870, which handles the No Yoshi cutscenes.
Originally posted by Telinc1
Try checking if $7E0071 is #$0A. According to the ROM map, this triggers $00C870, which handles the No Yoshi cutscenes.


I tried it just now, it worked! Thanks!


YY-CHR > Photoshop.
Hey there. I need help regarding MFG's scroll HDMA kit and Kaizoman's SMB scroll. I tried to merge those into an .asm file. The thing is that the level does work, but it won't stop scrolling to the left at all. It does stop scrolling to the right. Just to know, the ScrollHDNA.asm and SMBScroll.asn are in the library folder and the .asm file that has the HDMA code and the code that jumps to the SMBScroll code in the level folder.
Here's the whole code:


Here's also the SMBScroll code:

Some help would do.
I think the HDMA code should be in the level folder and SMB scroll in the library.

Also, I have a question of my own: I can't find a way to detect if the intro messsage is running or not. Does someone know how to do it?


YY-CHR > Photoshop.
Originally posted by BlueToad
I think the HDMA code should be in the level folder and SMB scroll in the library.

Also, I have a question of my own: I can't find a way to detect if the intro messsage is running or not. Does someone know how to do it?

Originally posted by RAM map
$7E1DF5:
Timer to used for multiple purposes:
- How long a particular input during the intro sequence will remain pressed.
- How long the Nintendo Presents screen will remain active.
- How long a Switch Palace message will remain active.
- How long the player has to wait before he can dismiss the intro message.


Benny Harvey RIP, miss you big man.

Burning Loaf, thanks for the input, but I have solved my problem already.

I originally tried using the RAM address you supplied but that didn't work because it didn't account for the time for the 38 or so frames the player was in the level without the message on-screen (I should have worded that better...).

I just ended up coding a check for level C5 instead.


YY-CHR > Photoshop.
I have been trying to make a quicksand block that pokeys can "walk" across. Can anyone tell me what's wrong with the code?
Filler
Can you tell anyone what's wrong with the block? It's a lot easier to help when we know what results you were expecting, and what results you get instead. Did you write all of the code yourself?

For now, the two things that look suspicious to me is that you forgot an RTL at the end, and that $3F should probably be #$3F instead.


 
Sorry I had posted the wrong block. It has been fixed. What I what the block to do is act Solid to pokeys but like quicksand to everything else.
I have fixed it.
Filler
I have a question involving RAM addresses:

What's the difference between High Byte
and Low Byte address?
An address is usually 8 bits. But you can combine two addresses to use them as 16 bits, which allows for values upto #$FFFF.

High byte is the first two digits of the 16-bit address and low byte is the last two. For example in #$1234 the high byte is #$12 and the low byte is #$34.


YY-CHR > Photoshop.
Thanks so much for your help!
This is supposed to change level every time level 1/2 is loaded
but instead it does nothing. Does anyone know what's wrong with
it? (I inserted it in game mode 12)

Code
main:

	REP  #$20       ; Make the accumulator 16-bit.
	LDA  $010B      ; Load a 16-Bit address.
	XBA             ; The high byte is the level number,
        SEP  #$20       ; so get rid of the useless low byte.
	CMP  #$01       ; Check if the level = 1.
	BEQ  Lvl_1      ; If so, increment the level number.	
	DEC             ; If not, decrement the level number.
	XBA
	STA  $010B      ; Put the address back.
	RTL             ; Return.

Lvl_1:
	INC
	XBA
	STA  $010B
	RTL
Where did you get that the high byte of $010B is the level number? The level number stored in $010B is 16-bit, I commented what you're code is actually currently doing:

Code
main:

	REP  #$20       ; Make the accumulator 16-bit.
	LDA  $010B      ; Load a 16-Bit address. (for example: 0105)
	XBA             ; Here you switch high and low byte, A now contains 0501
        SEP  #$20       ; so get rid of the useless low byte. (This gets rid of the high byte)
	CMP  #$01       ; This therefore checks if the high byte of the level is 1 (if the level is in the 100-1FF range)
	BEQ  Lvl_1      ; If so, increment the level number.	
	DEC             ; A now contains 0
	XBA		; this swaps A which currently contains [05]00 back to [00]05
	STA  $010B      ; Put the address back. (since A is 8-bit here, this puts back the 05 into $010B which it already contained)
	RTL             ; Return.

Lvl_1:
	INC		; A was checked to be 0 here, now contains 1
	XBA		; same as above, this swaps A which now contains [05]01 back to [01]05
	STA  $010B	; since A is only 8 bit here, only the 05 is stored back, which was the value this address contained to begin with
	RTL


So in the end the code essentially does nothing. What you would want to do is check the entire thing in 16-bit or only modify the low byte, without doing XBA at all.



And finally, while that code would work logic wise with a few changes, $010B is a backup of the level number added by various tools so they can read it, it does not actually affect which level is loaded at all, doing that is unfortunately not as trivial as writing the level somewhere. If that is what you're trying to accomplish then that won't be as easy as changing the level number during load.
  • Pages:
  • 1
  • 2
  • 3
  • 4
  • 5
  • 407
  • 408
  • 409
  • 410
  • 411
  • 412
  • 413
  • 414
  • 415
  • 416
  • 417
  • 418
  • 419
  • 420