3 questions

Discussion in 'Discussion and Q&A Archive' started by FireRat, Jun 5, 2010.

Thread Status:
Not open for further replies.
  1. FireRat

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

    Joined:
    Oct 31, 2009
    Messages:
    535
    I have more asks. Sorry


    1-How to change the boss start position? I tried looking the RESIZEs subroutines, but nothing. I tried looking the code of boss' object, but nothing


    2-How to do not fadeout screen when a act is complete? I tried deleting some coden in LEVEL screenmode, but the game will to crash. This efect is used in sonic 3 and some hacks.


    (and here is the MOST stupid ask)


    3-How to port the Kick DAC sample of sonic 3? (facepalm) I use the file, with $2CF size, and is very bad. I tried decreasing this, without results. I tried changing the pitch, without results. why?? (my latest DAC problem is solved, by creating more of one PCM table)


    NOTE: Sorry the bad grammar D:
     
    Last edited by a moderator: Jun 5, 2010
  2. MAXXX309

    MAXXX309 Newcomer Exiled

    Joined:
    Mar 4, 2010
    Messages:
    19
    Location:
    Ukraine, Kiev
    Example: look at the Resize_GHZ3boss: code



    Code:
    Resize_GHZ3boss:
    
    		cmpi.w	#$960,&#40;$FFFFF700&#41;.w; <-------- here is coordinate
    
    		bcc.s	loc_6EB0
    
    		subq.b	#2,&#40;$FFFFF742&#41;.w
    
    
    
    loc_6EB0&#58;
    
    		cmpi.w	#$2960,&#40;$FFFFF700&#41;.w; <--------here is coordinate
    
    		bcs.s	locret_6EE8
    
    		bsr.w	SingleObjLoad
    
    		bne.s	loc_6ED0
    
    		move.b	#$3D,0&#40;a1&#41; &#59; load GHZ boss	object
    
    		move.w	#$2A60,8&#40;a1&#41;
    
    		move.w	#$280,$C&#40;a1&#41;
    
    
    
    loc_6ED0&#58;
    
    		move.w	#$8C,d0
    
    		bsr.w	PlaySound &#59; play boss music
    
    		move.b	#1,&#40;$FFFFF7AA&#41;.w; lock	screen
    
    		addq.b	#2,&#40;$FFFFF742&#41;.w
    
    		moveq	#$11,d0
    
    		bra.w	LoadPLC	 &#59; load boss patterns

    Just change them to make boss appear in other place of level.
     
    Last edited by a moderator: Jun 5, 2010
  3. FireRat

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

    Joined:
    Oct 31, 2009
    Messages:
    535
    Thanks.


    The latest 2 asks...
     
  4. MAXXX309

    MAXXX309 Newcomer Exiled

    Joined:
    Mar 4, 2010
    Messages:
    19
    Location:
    Ukraine, Kiev
    You should modify Obj3A_NextLevel: code. Have a look through it.
     
  5. FireRat

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

    Joined:
    Oct 31, 2009
    Messages:
    535
    Nothing...
     
  6. Selbi

    Selbi The Euphonic Mess Member

    Joined:
    Jul 20, 2008
    Messages:
    2,429
    Location:
    Northern Germany
    This is called "act transition" and is not easy to do. If you really want to do it, look at the post of Alriightyman, he has it in his hack. (Fun fact, you were the one who asked there.)
     
  7. FireRat

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

    Joined:
    Oct 31, 2009
    Messages:
    535
    hahaha ty =P


    The latest ask...
     
    Last edited by a moderator: Jun 5, 2010
  8. Qjimbo

    Qjimbo Well-Known Member Member

    Joined:
    Feb 27, 2008
    Messages:
    850
    Location:
    Vancouver, BC
    This is the second time you've used profanity for no reason in a topic title. I have nothing against profanity per se, but when it's used pointlessly it's juvenile and grating. Also the word you're looking for is "Questions" not "Asks".

    Topic title was originally "3 fuckin asks" if you're wondering.
     
    Last edited by a moderator: Jun 5, 2010
  9. FireRat

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

    Joined:
    Oct 31, 2009
    Messages:
    535
    ok...
     
  10. hfdshdgfhgn

    hfdshdgfhgn fdsgfdgfhgfds Member

    Joined:
    Dec 28, 2009
    Messages:
    89
  11. Reverie

    Reverie Good sir, I do read that as "Derp" Member

    Joined:
    Mar 10, 2009
    Messages:
    54
    Location:
    your local coffee shop ^^
    For question 3 try using the Z80new sound driver, as for the samples there is a thing called asking. Anyways here's my copy of the s3 Kick sample (DEC is the used [incbin] same as BIN, use a hex calculator to figure out the sizes) I hope this helped a bit, if not: oh well.
     
    Last edited by a moderator: Jun 6, 2010
  12. FireRat

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

    Joined:
    Oct 31, 2009
    Messages:
    535
    Oh no, nothing of this!


    I only need the size, and the pitch of this sample. I'm using the Sonic2's clone driver. Calculating this, the sample size is $2CF and the pitch (for me) is unknown. For the pitch I use $4. Testing this, this sample listen distorted. why?
     
    Last edited by a moderator: Jun 7, 2010
  13. MarkeyJester

    MarkeyJester ♡ ! Member

    Joined:
    Jun 27, 2009
    Messages:
    2,867

    loc_6EB0:
    cmpi.w #$2960,($FFFFF700).w ; has the screen passed 2960 pixels on the X axiz?


    bcs.s locret_6EE8 ; if not, branch


    bsr.w SingleObjLoad ; find a free object slot space


    bne.s loc_6ED0 ; if no space is available, branch


    move.b #$3D,0(a1) ; load the GHZ boss object


    move.w #$2A60,8(a1) ; set it's X position


    move.w #$280,$C(a1) ; set it's Y position



    When you're a little more wiser maybe and you can prove to me that you have a good sense of style, then I'd be glad to explain one of many ways.


    For more information about act transitions, try here.

    +

    1. You must keep the samples within a bank size of 7FFF, over mount that limit, and some samples will not play.


    2. The Z80 DAC drivers I've known of so far, none of them support bank swicthing via the 8000 offset mark, meaning you can only have samples between the offsets of 0000 and 7FFF, never 8000 and FFFF, no matter where the bank is located.


    3. The position of the sample is based on where it starts within the bank (Plus 8000 because the Z80's bank reading area is 8000 - FFFF in the Z80 map).


    4. The size of the sample is well, the size, number of bytes, etc. You can easily find this out with a hexadecimal editor, and see the end offset, now depending on what rate the sample is set at, depends on whether the size needs dividing by 2, 4 or even 8. though a simple ($SIZE/$02) should do it (The 2 being the division).


    5. The pitch can be done by listening with your ears, though others have already collected precalculated picthes before:


    24,000Hz ($03 Pitch)


    22,050Hz ($05 Pitch)


    16,000Hz ($09 Pitch)


    11,025Hz ($13 Pitch)


    For more information on DAC, try these places:


    http://sonicresearch.org/forums/index.php?...t=0&start=0


    http://sonicresearch.org/forums/index.php?showtopic=2041


    http://sonicresearch.org/forums/index.php?...t=0&start=0
     
    Last edited by a moderator: Jun 7, 2010
Thread Status:
Not open for further replies.