Basic Questions and Answers Thread

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

  1. TheStoneBanana

    TheStoneBanana banana Member

    Joined:
    Nov 27, 2013
    Messages:
    602
    Location:
    The Milky Way Galaxy
    Alright, I'll try that instead, although I'll make a backup copy of the code using that guide so it can be inspected by Shockwave later, I suppose.
     
  2. TheInvisibleSun

    TheInvisibleSun Visible Member

    Joined:
    Jul 2, 2013
    Messages:
    424
    Location:
    Western New York, USA
    The only annoying issue I had with water though, is the PLC issues that come with adding bubbles and water surface object art.
     
  3. Painto

    Painto Arthurus Paintus Erinaceus Member

    Joined:
    Mar 24, 2014
    Messages:
    321
    Location:
    Lublin, Poland
    I used that guide to add water to Main Zone in my hack, and worked perfectly.
     
  4. TheStoneBanana

    TheStoneBanana banana Member

    Joined:
    Nov 27, 2013
    Messages:
    602
    Location:
    The Milky Way Galaxy
  5. Viva La Luna

    Viva La Luna A.K.A. crypt0nymous Member

    Joined:
    Jun 7, 2012
    Messages:
    82
    Location:
    Istanbul
    Hey there folks, I have just encountered a serious problem. I don't know if here is the right place to post it.

    I just tried to make custom tiles and layouts in SonED2. I just inserted several tiles by pressing CTRL+I, and made custom layouts with it.

    This is how the tiles look like in SonED2:

    [​IMG]

    And they look like this in the game:

    [​IMG]

    So? As you can see the tiles between SonED2 and this game is completely different. The tiles are glitched in Sonic 1.

    I just can't solve this problem. What should I do for fixing this?

    EDIT: These layouts are exclusively for act 2.
     
    Last edited by a moderator: Jul 3, 2014
  6. rika_chou

    rika_chou Adopt Member

    Joined:
    Aug 11, 2007
    Messages:
    689
    It's because there's not space for the extra tiles in the VRAM. Take a look at how GHZ's VRAM looks when everything is loaded:

    [​IMG]

    Those tiles are overwriting your new tiles. If you want to use more tiles, you will have to make space by deleting others. Other people more familiar with Sonic 1 might know which tiles are unused, or other ways to clear space.
     
    Last edited by a moderator: Jul 3, 2014
  7. Viva La Luna

    Viva La Luna A.K.A. crypt0nymous Member

    Joined:
    Jun 7, 2012
    Messages:
    82
    Location:
    Istanbul
    Alright, thanks for answering. I will try to find and delete unused tiles.
     
    Last edited by a moderator: Jul 3, 2014
  8. SuperEgg

    SuperEgg I'm a guy that knows that you know that I know Member

    Joined:
    Oct 17, 2009
    Messages:
    Location:
    THE BEST GOD DAMN STATE OF TEXAS
    If the case in the matter is that you aren't even using the tiles that you used to create these new tiles, just replace the originals with your modified tiles.


    If that isn't that clear, see those tiles that look similar to yours, but don't have the background? Are they being used by you? No, replace them. Go off and use the rest of the existing tiles to fill in the blanks.


    Now If the case is that you are, well fuck. Good luck with messing with the VRAM.
     
  9. Viva La Luna

    Viva La Luna A.K.A. crypt0nymous Member

    Joined:
    Jun 7, 2012
    Messages:
    82
    Location:
    Istanbul
    Well, Since I don't have enough knowledge about increasing VRAM space, I have a "last" question. As I will be making these tiles only for act 2, Is there anything possible to make a tile graphics file for acts? If it is, I will be copying GHZ tile graphics for act 2 and delete unused tiles on it.
     
  10. N30member

    N30member non-pro user btw Member

    Joined:
    Feb 15, 2014
    Messages:
    216
    Location:
    Kazakhstan
    @DevrimRG: Enjoy, please. I also recommend you to use search services more often.
     
  11. Painto

    Painto Arthurus Paintus Erinaceus Member

    Joined:
    Mar 24, 2014
    Messages:
    321
    Location:
    Lublin, Poland
    I have two problems:

    • As you probably know, I'm making a Skill Shop (I posted a video in Screens thread). To make it workthere of course is neede a global ring counter. To do this in both Level and SS "gotthroughs" I'd put this line
      add.w ($FFFFFE20).w,($FFFF1234).w ; add rings to the main ring counter (of course the second RAM is random, I don't want to show my work)
      But when I'm trying to built it, the apperas the following error:
      Code:
      C:...SONIC1.ASM<5684> : Error : Illegal addressing mode (there's that line)
      C:...SONIC1.ASM<20779> : Error : Illegal addressing mode (there's that line)
      Is there any way to make this work?
    • During my playtrough of my hack I noticed this:[​IMG]

      (If someone don't noticed it yet, the OVER text is missing)

      How to fix this?
    Should be noted that I tried to fix both of these using all of my ASM knowledge, but I failed, so please, don't make replies in style "You should use search more", "Do it by yourself", etc.
     
    Last edited by a moderator: Jul 13, 2014
  12. Devon

    Devon I'm a loser, baby, so why don't you kill me? Member

    Joined:
    Aug 26, 2013
    Messages:
    1,376
    Location:
    your mom
    You can't add memory into memory directly. There's a way around this.
     
    Instead of:


           add.w    ($FFFFFE20).w,($FFFF1234).w
    Do this:

    Code:
           move.w ($FFFFFE20).w,d0
           add.w d0,($FFFF1234).w
     
    Last edited by a moderator: Jul 13, 2014
  13. MarkeyJester

    MarkeyJester ♡ ! Member

    Joined:
    Jun 27, 2009
    Messages:
    2,867
    The 68k is not able to add data from memory to memory, consider this alternative:

    move.w ($FFFFFE20).w,d0
    add.w d0,($FFFF1234).w
    There could be a number of reasons; the FG is in high-plane, and the OVER text sprites have been set as low-plane, or the OVER text art isn't in VRAM, and the space where it should be is completely blank. HOWEVER, those are very unlikely, I'd say chances are, the object that is responsible for displaying the OVER text, isn't functioning correctly. The reason for this could be that you've loaded/setup an object in the object slot that is used for the OVER text at some point, and obviously, when the OVER text loads its ID into the slot, there are different values set by that "other" object which have altered the outcome. The reason could also be, the routine responsible for loading the ID into the object slot has been altered in some way preventing it from doing so. It could also be the OVER object's routines have been altered. By altered of course, I do mean unknowingly or accidentally.

    Unfortunately, it isn't certain as to what the problem is, not enough information.

    EDIT: Ralakimus inb4 me!
     
    Last edited by a moderator: Jul 13, 2014
  14. Painto

    Painto Arthurus Paintus Erinaceus Member

    Joined:
    Mar 24, 2014
    Messages:
    321
    Location:
    Lublin, Poland
    Looks like I will need to keep that bug in game. Anyways, thanks for help.
     
  15. Devon

    Devon I'm a loser, baby, so why don't you kill me? Member

    Joined:
    Aug 26, 2013
    Messages:
    1,376
    Location:
    your mom
    Why is there an explosion at the top of the image. Was it generated when "Game" appeared? Or something else?
     
    Last edited by a moderator: Jul 13, 2014
  16. Painto

    Painto Arthurus Paintus Erinaceus Member

    Joined:
    Mar 24, 2014
    Messages:
    321
    Location:
    Lublin, Poland
    I just destroyed a Chopper when falling to the bottomless pit. But I checked and without destroying anything also don't appear.
     
  17. Stardust Gear

    Stardust Gear A Programmer Member

    Joined:
    Apr 27, 2014
    Messages:
    134
    Question for Sonic 1:

    How to enable putting objects with ID higher than $7F? (In "objpos" files, of course)

    Just move the bit of "Remember [sprite] State" to another byte?
     
    Last edited by a moderator: Jul 13, 2014
  18. MarkeyJester

    MarkeyJester ♡ ! Member

    Joined:
    Jun 27, 2009
    Messages:
    2,867
    The object position format is: XXXX MYYY OOSS

    XXXX is the X position of the object, if this value is FFFF, it indicates the end/beginning of the list in which the layout system cannot pass.

    M is the render mode, in binary this is VH00, where V is the vertical flip flag, and H is the horizontal mirror flag. The 0's are blank and unused.

    YYY is the Y position of the object.

    OO is the object ID and remember state flag, in binary this is ROOOOOOO, where R is the remember flag, and OOOOOOO is the object ID (00 to 7F).

    SS is the sub-type ID.

    I suggest relocating the remember flag from OO into M somewhere, there are two free 0's there to use, this'll help free up that binary R you have in OO.
     
  19. MainMemory

    MainMemory Well-Known Member Member

    Joined:
    Mar 29, 2011
    Messages:
    922
    Sonic 2 rearranged the "M" nybble to RVH0, if you want to look at its object manager.

    If you do the same, then you'll be able to set SonLVL to use objectfmt=S2 in the ini.
     
    Last edited by a moderator: Jul 13, 2014
  20. Stardust Gear

    Stardust Gear A Programmer Member

    Joined:
    Apr 27, 2014
    Messages:
    134
    How to implement the S2 object position format in S1 assembly project?

    I'll make a private tool that converts S1 objpos to S2 objpos.

    In other words: How to import S2 object manager?