Basic Questions and Answers Thread

Discussion in 'Discussion & Q&A' started by Malevolence, Jul 7, 2009.

  1. DeoxysKyogre

    DeoxysKyogre No idea what to put here .-. Member

    Joined:
    Jan 31, 2009
    Messages:
    298
    I'm doing an intro sequence for my hack, and I'm trying to make a new code instead of using EndingSequence's. But when I try to make it load the Ending PLC's, there seems to be overflow and the game goes slow. Below I'm providing the code so you can see:



    Code:
    ; ===========================================================================
    
    ; ---------------------------------------------------------------------------
    
    ; Ending sequence dynamic screen resizing (empty)
    
    ; ---------------------------------------------------------------------------
    
    
    
    Resize_Ending:			&#59; XREF: Resize_Index
    
    				
    
    		moveq	#0,d0
    
    		move.b	($FFFFF742).w,d0
    
    		move.w	Intro(pc,d0.w),d0
    
    		jmp	Intro(pc,d0.w)
    
    ; ===========================================================================
    
    Intro:	dc.w Resize_Intro-Intro
    
    ; ===========================================================================
    
    Resize_Intro:
    
    			  &#59;cmpi.w	#$1C,d0
    
    	&#59;beq.w	locret_7322
    
    			   moveq	#$1C,d0
    
    		jsr	RunPLC_ROM&#59; load ending sequence patterns
    
    				move.b	#$84,d0
    
    		jmp	PlaySound_Special&#59; play music
     
  2. Gardeguey

    Gardeguey Well-Known Member Member

    Joined:
    Aug 6, 2010
    Messages:
    82
    Location:
    México
    Do this:



    ; ===========================================================================
    ; ---------------------------------------------------------------------------


    ; Ending sequence dynamic screen resizing (empty)


    ; ---------------------------------------------------------------------------


    Resize_Ending:


    moveq #0,d0


    move.b ($FFFFF742).w,d0


    move.w Intro(pc,d0.w),d0


    jmp Intro(pc,d0.w)


    ; ===========================================================================


    Intro: dc.w Resize_Intro-Intro


    dc.w Resize_Rts-Intro


    ; ===========================================================================


    Resize_Intro:


    addq.b #2,($FFFFF742).w


    moveq #$1C,d0


    jsr RunPLC_ROM; load ending sequence patterns


    move.b #$84,d0


    jmp PlaySound_Special; play music


    Resize_Rts:


    rts
     
  3. SpirituInsanum

    SpirituInsanum Well-Known Member Member

    Joined:
    Feb 11, 2010
    Messages:
    642
    Is the "Stick to convex surfaces flag" ($3C) of S3 ever set?


    If I didn't misinterpret S3's code for walking on ceiling and walls, the game should switch to classic behavior when it's set, and while playing a bit monitoring the relevant memory, I've never seen it set. Therefore the question: why is there a flag at all?


    I guess it isn't a useless waste of resources, but I can't find it in the disassembly either. ;)
     
  4. MarkeyJester

    MarkeyJester ♡ ! Member

    Joined:
    Jun 27, 2009
    Messages:
    2,867
    I won't pretend I know anything about Sonic 3, but if the program you're using to monitor that flag shows up only once every frame, then it could be that it's set sometime within the frame and then deset before the end of the frame (again, this is just a guess and I won't pretend to know the details).
     
  5. SpirituInsanum

    SpirituInsanum Well-Known Member Member

    Joined:
    Feb 11, 2010
    Messages:
    642
    Indeed, that's partially why I still assume there's a reason for it. I thought if it was something clear like hanging on some special walls or objects, it would be easy to find, therefore that test (fortunately I'm still able to play s3k without looking directly at the screen xD).


    I searched that "$3C(a" and its real address for player 1 in the disassembly, and from what I've seen, it's only being used for some other objects, not even as a flag actually. I'm probably missing something.
     
  6. FireRat

    FireRat Do Not Interact With This User, Anywhere!!! Exiled

    Joined:
    Oct 31, 2009
    Messages:
    535
    Its a very stupid question, and im facepalmed of this...


    Where is the levelselect font art? my god, I can't found it
     
  7. SpirituInsanum

    SpirituInsanum Well-Known Member Member

    Joined:
    Feb 11, 2010
    Messages:
    642
    It's uncompressed art, menutext.bin iirc. (in s1, don't know for the others)
     
    Last edited by a moderator: Jan 11, 2011
  8. FireRat

    FireRat Do Not Interact With This User, Anywhere!!! Exiled

    Joined:
    Oct 31, 2009
    Messages:
    535
    Thanks)) *facepalm*
     
  9. EMK-20218

    EMK-20218 The Fuss Maker Exiled

    Joined:
    Aug 8, 2008
    Messages:
    1,067
    Location:
    Jardim Capelinha, São Paulo
    Dude, I know this question is already solved, but this makes clear that you need to be a bit more specific when you request something or need any kind of help. I mean, you could give us more details of the help you want. Otherwise we will haven't how to help you.
     
  10. MarkeyJester

    MarkeyJester ♡ ! Member

    Joined:
    Jun 27, 2009
    Messages:
    2,867
    While it's not the brightest of questions; "Being more specific"? Hmm, the only way I can see him being more specific is if he said it was for Sonic 1, that's about it. you can't get more specific than "levelselect font art" I don't think.
     
  11. Selbi

    Selbi The Euphonic Mess Member

    Joined:
    Jul 20, 2008
    Messages:
    2,429
    Location:
    Northern Germany
    The only way to make the question more specific would be by saying why you want to do that, even though that really wouldn't be necessary for a question like this. He could try to improve his writing style though, as this already helps to encourage people to answer, regardless of the english knowledge itself.
     
    Last edited by a moderator: Jan 11, 2011
  12. FireRat

    FireRat Do Not Interact With This User, Anywhere!!! Exiled

    Joined:
    Oct 31, 2009
    Messages:
    535
    Well, sorry but I asked that because I did not have time to look at the code. And I And in that time I had not enough time to use my computer. Sorry
     
  13. MarkeyJester

    MarkeyJester ♡ ! Member

    Joined:
    Jun 27, 2009
    Messages:
    2,867
    While I understand the english could be improved, some people like to keep their plan private, and hence would like to provide as little info as possible, so perhaps by being more specific, you risk ruining any suprises instore for the release of your project. There's a line after all, and I don't believe it's passed here enough for us to not be able to answer the question.
     
  14. EMK-20218

    EMK-20218 The Fuss Maker Exiled

    Joined:
    Aug 8, 2008
    Messages:
    1,067
    Location:
    Jardim Capelinha, São Paulo
    But I just told him to be specific about the content he requested, not about what he is making on his hack, Markey. Let's supose that he want help with compressed art. How would we guess wich kind of compression is used in the art he want? This is just what I was pointing on, dude.
     
  15. SpirituInsanum

    SpirituInsanum Well-Known Member Member

    Joined:
    Feb 11, 2010
    Messages:
    642
    Is there a way to place objects beyond $80 in levels with soned2? Object 90 saves as object 10 ^^'
     
  16. FireRat

    FireRat Do Not Interact With This User, Anywhere!!! Exiled

    Joined:
    Oct 31, 2009
    Messages:
    535
    I'm now creating a object, for a cutscene. For some movements of the obkect, I added a timer. Here's the code




    Obj10_First:


    subq.w #1,($FFFFFF90).w


    beq.s Next_Func


    move.b #0,$1C(a0)


    jsr Obj10_Display


    rts


    Next_Func:


    addq.b #2,$24(a0)


    rts



    This code works fine in Kega, but not in Gens. How to fix it?


    EDIT:


    Bug fixed by using SSTs.


    Anyway, why is this bug caused, just if I use the RAM?
     
    Last edited by a moderator: Jan 22, 2011
  17. DeoxysKyogre

    DeoxysKyogre No idea what to put here .-. Member

    Joined:
    Jan 31, 2009
    Messages:
    298
    So I'm trying that my boss checks his Y pos, and if it's affirmative, he changes his Y position, but it doesn't work... I tried a lot of ways, but it seems it doesn't just want to work.



    Code:
    loc_177E6:
    
    				cmpi.w  #$360,$C(a0) &#59; IS THE Y POS EQUAL TO $360?
    
    				beq.s   ypos; IF YES, BRANCH
    
    				bra	 y_pos2; branch to the rest of the code
    
    ypos:
    
    				move.w  #$300,$C(a0); move to another vertical position
    
    ypos_2:			   
    
    		move.b	$3F(a0),d0
    
    		jsr	(CalcSine).l
    
    		asr.w	#6,d0
    
    		add.w	$38(a0),d0
    
    		move.w	d0,$C(a0)
    
    		move.w	$30(a0),8(a0)
    
    		addq.b	#2,$3F(a0)
    
    		cmpi.b	#8,$25(a0)
    
    		bcc.s	locret_1784A
    
    		tst.b	$22(a0)
    
    		bmi.s	loc_1784C
    
    		tst.b	$20(a0)
    
    		bne.s	locret_1784A
    
    		tst.b	$3E(a0)
    
    		bne.s	Obj3D_ShipFlash
    
    		move.b	#$20,$3E(a0); set number of	times for ship to flash
    
    		move.w	#$AC,d0
    
    		jsr	(PlaySound_Special).l;	play boss damage sound
    This uses the Obj3D object code.


    Do you know a solution for this?
     
    Last edited by a moderator: Jan 22, 2011
  18. EMK-20218

    EMK-20218 The Fuss Maker Exiled

    Joined:
    Aug 8, 2008
    Messages:
    1,067
    Location:
    Jardim Capelinha, São Paulo
    Are you editing Sonic 1 or Sonic 2?
     
  19. SpirituInsanum

    SpirituInsanum Well-Known Member Member

    Joined:
    Feb 11, 2010
    Messages:
    642
    S1
     
  20. Animemaster

    Animemaster Lets get to work! Member

    Joined:
    Mar 20, 2009
    Messages:
    1,229
    Location:
    UK
    Try changing $C to $38.