Jump to content

  •  

Photo

Basic Questions and Answers Thread


  • Please log in to reply
2020 replies to this topic

#1 Malevolence

Malevolence

    2 Chaos Emeralds

  • Pro User
  • 94 posts
  • Gender:Male

Posted 07 July 2009 - 09:48 PM

Lately there have been many new threads for very simple and basic questions that tend to be answered with a small amount of posts and then fall into oblivion. This thread is for those sort of questions that are believed to be very simple and not thread worthy, and also a way to keep those kinds of questions available with the answers in one thread in case someone is experiencing the same problem, and could easily look it up. Remember to check this thread or the forum for an answer before posting.
  • 0

#2 fantasticfish

fantasticfish

    The Fantastic Fish

  • Member
  • 72 posts
  • Gender:Male

Posted 10 July 2009 - 12:15 AM

I tried to put this code, (from a Sonic 1 ROM, below,) into my Sonic 2 hack, and it spat out an error about StartOfROM being $C.

SRAMSupport:	dc.l $5241E020		; change to $5241E020 to create	SRAM
dc.l $200000 ; SRAM start
dc.l $20FFFF ; SRAM end

How should I get this to work?

I know I'm going about this the wrong way.

:D

Edited by fantasticfish, 10 July 2009 - 12:18 AM.

  • 0

#3 fantasticfish

fantasticfish

    The Fantastic Fish

  • Member
  • 72 posts
  • Gender:Male

Posted 10 July 2009 - 12:33 AM

; ---------------------------------------------------------------------------
; Subroutine to perform a NEW move!!!!!!!!
; ---------------------------------------------------------------------------

Sonic_WEIRD:
btst #6,(Ctrl_1_Press).w
beq.w Sonic_WEIRD_End ; If not, branch

move.w #$3C,d0 ; set sound
jsr (PlaySound).l ; play sound
cmpi.w #1,(Ring_count).w ; does Sonic have at least 1 rings?
bcs.s Sonic_WEIRD_End ; if not, branch
subq.w #1,(Ring_count).w ; Subtract 1 rings.
ori.b #1,(Update_HUD_rings).w ; Update the HUD.

move.w #$1500,d0 ; set the speed to d0

Sonic_WEIRD_ChkDirection:
btst #0,$22(a0) ; is sonic facing left?
beq.s Sonic_WEIRD_MovePlayer ; if yes, branch
neg.w d0 ; if not, negate d0 (for jumping to the right)

Sonic_WEIRD_MovePlayer:
move.w d0,$10(a0) ; Move Sonic...


Sonic_WEIRD_End:
rts ; return
; End of function Sonic_WEIRD


This code does everything--except for moving Sonic!

Does anyone have any idea exactly why this code, inserted into Sonic 2, with the proper
Obj01_MdNormal
call does not work and how to fix it?

I think the code was meant for in-air movement, but don't know how to fix it.

Edited by fantasticfish, 10 July 2009 - 12:37 AM.

  • 0

#4 hitaxas

hitaxas

    I can has super speed?

  • Member
  • 131 posts
  • Gender:Male

Posted 10 July 2009 - 01:47 AM

Don't call to this from Obj01_MdNormal, try md_jump or md_air.

If that doesn't work, there might be something else wrong with the code.
  • 0

#5 liamsonichacker

liamsonichacker

    Mad Level Skillz ;)

  • Member
  • 49 posts
  • Gender:Male
  • Location:Leicester, UK
  • Interests:Girls
    Sonic
    & hardcore
    SEX

Posted 10 July 2009 - 01:55 AM

I was just wondering if anyone could help me code the eggman monitor so it hurts sonic, I did try using the spike code but all it does is play the dieing sound

Can any one help me please??
  • 0

#6 MikeTH

MikeTH

    1 Chaos Emerald

  • Member
  • 34 posts
  • Gender:Male
  • Location:Ohio

Posted 10 July 2009 - 03:02 AM

You need to show us the code before we can make any logical assumptions to what you did wrong. We don't know everything Liam, a lot of us here do know quite a bit though.
  • 0

#7 MikeTH

MikeTH

    1 Chaos Emerald

  • Member
  • 34 posts
  • Gender:Male
  • Location:Ohio

Posted 10 July 2009 - 03:06 AM

I tried to put this code, (from a Sonic 1 ROM, below,) into my Sonic 2 hack, and it spat out an error about StartOfROM being $C.

SRAMSupport: dc.l $5241E020 ; change to $5241E020 to create SRAM
dc.l $200000 ; SRAM start
dc.l $20FFFF ; SRAM end


How should I get this to work?

I know I'm going about this the wrong way.

blink.gif


You most likely chose hex values that aren't empty. you should open up you hex editor and check, as using hex values that are already used cause games to go haywire. At least that's what I've learned form my in's and out's with ASM.
  • 0

#8 fantasticfish

fantasticfish

    The Fantastic Fish

  • Member
  • 72 posts
  • Gender:Male

Posted 10 July 2009 - 12:42 PM

Don't call to this from Obj01_MdNormal, try md_jump or md_air.

If that doesn't work, there might be something else wrong with the code.


No, you don't understand; I mean I want it to happen when you're on the ground.

Sorry, about any unclearness.
  • 0

#9 fantasticfish

fantasticfish

    The Fantastic Fish

  • Member
  • 72 posts
  • Gender:Male

Posted 10 July 2009 - 12:43 PM

I tried to put this code, (from a Sonic 1 ROM, below,) into my Sonic 2 hack, and it spat out an error about StartOfROM being $C.

SRAMSupport: dc.l $5241E020 ; change to $5241E020 to create SRAM
dc.l $200000 ; SRAM start
dc.l $20FFFF ; SRAM end


How should I get this to work?

I know I'm going about this the wrong way.

blink.gif


You most likely chose hex values that aren't empty. you should open up you hex editor and check, as using hex values that are already used cause games to go haywire. At least that's what I've learned form my in's and out's with ASM.


Sorry, I don't understand you. Could you clarify?
  • 0

#10 Selbi

Selbi

    Obligatory new year's avatar remake.

  • Pro User
  • 1770 posts
  • Gender:Male
  • Location:L√ľneburg, Germany

Posted 10 July 2009 - 02:27 PM

I was just wondering if anyone could help me code the eggman monitor so it hurts sonic, I did try using the spike code but all it does is play the dieing sound

Can any one help me please??

Check this out. Here is a simple guide on how to add this function.
  • 0

#11 Irixion

Irixion

    6 Chaos Emeralds

  • Pro User
  • 539 posts
  • Gender:Male
  • Location:Ontario, Canada

Posted 10 July 2009 - 04:14 PM

I was just wondering if anyone could help me code the eggman monitor so it hurts sonic, I did try using the spike code but all it does is play the dieing sound

Can any one help me please??




Just tell it to jump to Obj01_Hurt. That's it.
  • 0

#12 fantasticfish

fantasticfish

    The Fantastic Fish

  • Member
  • 72 posts
  • Gender:Male

Posted 10 July 2009 - 06:03 PM

{NEW QUESTION}

I was thinking about music editing, noticed Qjimbo's porter tool, and it was extremely helpful--until I noticed all the ill effects on my hack, which used a disassembly. Does anyone know of an equivalent tool that works on the disassembly files?

Edited by fantasticfish, 10 July 2009 - 06:04 PM.

  • 0

#13 Amphobius

Amphobius

    eat shit~

  • Pro User
  • 800 posts
  • Gender:Male
  • Location:Belfast
  • Interests:being beyta, the colour purple and thrash metal

Posted 10 July 2009 - 08:39 PM

What porter tool.

Also, questions don't need a {NEW QUESTION}, it's stupid. You don't see that on Ret- oh wait.

It's bro- oh wait, it's slowly coming back.
  • 0

#14 Animemaster

Animemaster

    Lets get to work!

  • Pro User
  • 1035 posts
  • Gender:Male
  • Location:UK

Posted 10 July 2009 - 08:49 PM

; ---------------------------------------------------------------------------
; Subroutine to perform a NEW move!!!!!!!!
; ---------------------------------------------------------------------------

Sonic_WEIRD:
btst #6,(Ctrl_1_Press).w
beq.w Sonic_WEIRD_End ; If not, branch

move.w #$3C,d0 ; set sound
jsr (PlaySound).l ; play sound
cmpi.w #1,(Ring_count).w ; does Sonic have at least 1 rings?
bcs.s Sonic_WEIRD_End ; if not, branch
subq.w #1,(Ring_count).w ; Subtract 1 rings.
ori.b #1,(Update_HUD_rings).w ; Update the HUD.

move.w #$1500,d0 ; set the speed to d0

Sonic_WEIRD_ChkDirection:
btst #0,$22(a0) ; is sonic facing left?
beq.s Sonic_WEIRD_MovePlayer ; if yes, branch
neg.w d0 ; if not, negate d0 (for jumping to the right)

Sonic_WEIRD_MovePlayer:
move.w d0,$10(a0) ; Move Sonic...


Sonic_WEIRD_End:
rts ; return
; End of function Sonic_WEIRD


This code does everything--except for moving Sonic!

Does anyone have any idea exactly why this code, inserted into Sonic 2, with the proper
Obj01_MdNormal
call does not work and how to fix it?

I think the code was meant for in-air movement, but don't know how to fix it.

Change $10 to $14, 10 is used in air, $14 is used on the floor.
  • 0

#15 fantasticfish

fantasticfish

    The Fantastic Fish

  • Member
  • 72 posts
  • Gender:Male

Posted 11 July 2009 - 11:40 AM

; ---------------------------------------------------------------------------
; Subroutine to perform a NEW move!!!!!!!!
; ---------------------------------------------------------------------------

Sonic_WEIRD:
btst #6,(Ctrl_1_Press).w
beq.w Sonic_WEIRD_End ; If not, branch

move.w #$3C,d0 ; set sound
jsr (PlaySound).l ; play sound
cmpi.w #1,(Ring_count).w ; does Sonic have at least 1 rings?
bcs.s Sonic_WEIRD_End ; if not, branch
subq.w #1,(Ring_count).w ; Subtract 1 rings.
ori.b #1,(Update_HUD_rings).w ; Update the HUD.

move.w #$1500,d0 ; set the speed to d0

Sonic_WEIRD_ChkDirection:
btst #0,$22(a0) ; is sonic facing left?
beq.s Sonic_WEIRD_MovePlayer ; if yes, branch
neg.w d0 ; if not, negate d0 (for jumping to the right)

Sonic_WEIRD_MovePlayer:
move.w d0,$10(a0) ; Move Sonic...


Sonic_WEIRD_End:
rts ; return
; End of function Sonic_WEIRD


This code does everything--except for moving Sonic!

Does anyone have any idea exactly why this code, inserted into Sonic 2, with the proper
Obj01_MdNormal
call does not work and how to fix it?

I think the code was meant for in-air movement, but don't know how to fix it.

Change $10 to $14, 10 is used in air, $14 is used on the floor.


Thanks a lot! It worked perfectly!
  • 0

#16 Animemaster

Animemaster

    Lets get to work!

  • Pro User
  • 1035 posts
  • Gender:Male
  • Location:UK

Posted 12 July 2009 - 12:10 PM

; ---------------------------------------------------------------------------
; Subroutine to perform a NEW move!!!!!!!!
; ---------------------------------------------------------------------------

Sonic_WEIRD:
btst #6,(Ctrl_1_Press).w
beq.w Sonic_WEIRD_End ; If not, branch

move.w #$3C,d0 ; set sound
jsr (PlaySound).l ; play sound
cmpi.w #1,(Ring_count).w ; does Sonic have at least 1 rings?
bcs.s Sonic_WEIRD_End ; if not, branch
subq.w #1,(Ring_count).w ; Subtract 1 rings.
ori.b #1,(Update_HUD_rings).w ; Update the HUD.

move.w #$1500,d0 ; set the speed to d0

Sonic_WEIRD_ChkDirection:
btst #0,$22(a0) ; is sonic facing left?
beq.s Sonic_WEIRD_MovePlayer ; if yes, branch
neg.w d0 ; if not, negate d0 (for jumping to the right)

Sonic_WEIRD_MovePlayer:
move.w d0,$10(a0) ; Move Sonic...


Sonic_WEIRD_End:
rts ; return
; End of function Sonic_WEIRD


This code does everything--except for moving Sonic!

Does anyone have any idea exactly why this code, inserted into Sonic 2, with the proper
Obj01_MdNormal
call does not work and how to fix it?

I think the code was meant for in-air movement, but don't know how to fix it.

Change $10 to $14, 10 is used in air, $14 is used on the floor.


Thanks a lot! It worked perfectly!

No problem. :)
  • 0

#17 *_Rydia3667_*

*_Rydia3667_*
  • Lurker

Posted 13 July 2009 - 08:12 PM

Ok, I fixed the level select, but for Labyrinth Zone (The missing act from scrap brain act 3 and add final zone to scrap brain). Maybe I read the guide wrong, but I want to add sbz act 3 to labyrinth zone and add final zone to scrap brain zone so you can play through the last act of sbz. I think I made it confusing enough. Idk if this would help
Green Hill Zone 1
2
3
Marble Zone 1
2
3
Spring Yard Zone 1
2
3
Labyrinth Zone 1
2
3
4 (SBZ act 3)
Star Light Zone 1
2
3
Scrap Brain Zone 1
2
3 (true 3rd act, Final Zone)
Special Stage
Sound Test.
Do I just use ese or do asm (Thats what I did first trying to fix the level select)

#18 Selbi

Selbi

    Obligatory new year's avatar remake.

  • Pro User
  • 1770 posts
  • Gender:Male
  • Location:L√ľneburg, Germany

Posted 13 July 2009 - 08:17 PM

You will need to edit the level select text, the level select pointers and the level order. I guess these 3 functions are all included in ESE, or at least 2 of them.

Edited by Selbi, 13 July 2009 - 08:17 PM.

  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users