lunoka
Gun-headed
Diving into retrodev
Posts: 55
Homebrew skills: art, music
Fave PCE Shooter: Burning angels
Fave PCE Platformer: Ninja Spirit
Fave PCE Game Overall: Valis 3
Fave PCE RPG: Neutopia
|
Post by lunoka on May 8, 2022 13:44:01 GMT
Hello/ I've played a little bit with Bravoman and I am actually wondering how did they do to create this scrolling set up : There are 4 speeds but 5 distinct zones. If I'm right, you can set up up to 4 scroll windows in HuC. But they can't overlap, otherwise it will display a blank zone. So it's impossible to set a Window1 for speed 1 and 2 other thinner windows overlaping and centered for speed 2 & 3. How do the devs managed to do this? Setting 1 window with some asm code for the scrolling part to create the 4 zones and the fixed HUD is another window?
|
|
|
Post by dshadoff on May 8, 2022 14:34:09 GMT
The way you have described this, this game has set up RCR interrupts to reset the scroll position at each of these areas. Each of these can point to an (x,y) offset within the overall background area. All of the scrolling here is horizontal, so BAT management is made easier.
There is no particular limit to the number of such RCR interrupts; you can see on many games there is an effect where there is background undulation (regular shift) or "heathaze" (irregular shift) nearly every scanline, and sprites are unaffected. But you need to keep in mind that those interrupts require immediate processing, so there is a processing burden.
However, I'm not sure about the limitations of HuC - any such limitations would be specific to HuC.
|
|
|
Post by elmer on May 8, 2022 22:01:09 GMT
There are 4 speeds but 5 distinct zones. If I'm right, you can set up up to 4 scroll windows in HuC. But they can't overlap, otherwise it will display a blank zone. So it's impossible to set a Window1 for speed 1 and 2 other thinner windows overlaping and centered for speed 2 & 3. How do the devs managed to do this? Setting 1 window with some asm code for the scrolling part to create the 4 zones and the fixed HUD is another window? "How do the devs managed to do this?"Well, first of all, they don't use HuC! Having said which, there's nothing on that particular game's screen that you can't do in HuC with its 4 splits. The PC Engine does not support overlapping windows. Whenever you *think* that you're seeing overlapping backgrounds, you really aren't. What you're seeing is separate windows with either tile-animation to create the graphical overlaps, or sprites to create the graphical overlaps. So using that technique will get you the top 4 splits in HuC. Then you just do the bottom status layer as 8 32x64 sprites, and you've got all 5 splits dealt with in the default HuC configuration. IIRC, turboxray has been giving out improved split-screen code for HuC that allows for more than 4 splits, so you can probably ask him for that if you wish.
|
|
|
Post by DarkKobold on May 8, 2022 23:11:21 GMT
I'd like to note, Jessie also uses 7 or 8 splits for the final battle. It's pretty easy to just increase the number of scrolling sections in HuC with very few code changes.
|
|
|
Post by turboxray on May 9, 2022 5:55:22 GMT
Hello/ I've played a little bit with Bravoman and I am actually wondering how did they do to create this scrolling set up : There are 4 speeds but 5 distinct zones. If I'm right, you can set up up to 4 scroll windows in HuC. But they can't overlap, otherwise it will display a blank zone. They can't overlap because you only have one layer - something will always show and that something will be whatever line in the map you tell it to draw. For every line of the display, you can tell the VDC to start drawing from here at position Y of the map. If you had an interrupt on every line, you could draw the BG up side down, or you could scale it be either repeating every line (blow up) or skipping whatever line (shrinking), or in your example have a few interrupts where you tell the VDC to start drawing the map at position Y for that line. And if you think about it, you ~could~ treat a section of the map as a different overlapping section - scroll that up and down independent of the layer scrolling "sections". The only caveat, is that this block or separate section can't have "see through" parts into the sections behind it... simple because you don't have two independent layers to do that with - but you could make the section look a little more natural by giving it a few sprite around the edges.
|
|
lunoka
Gun-headed
Diving into retrodev
Posts: 55
Homebrew skills: art, music
Fave PCE Shooter: Burning angels
Fave PCE Platformer: Ninja Spirit
Fave PCE Game Overall: Valis 3
Fave PCE RPG: Neutopia
|
Post by lunoka on May 9, 2022 8:01:28 GMT
Alright, thank you guys. I will try to find some code to play with the VDC interrupts in HuC. I assume the vreg() function is the entry point for those tricks.
|
|
|
Post by elmer on May 11, 2022 17:44:36 GMT
Alright, thank you guys. I will try to find some code to play with the VDC interrupts in HuC. I assume the vreg() function is the entry point for those tricks. If you're going to stick with HuC, then I'd recommend using HuC's existing library functions, or you're going to open up a world-of-pain for yourself. If you're ready to come over to the dark-side and join us assembly-language folk, then I'd recommend avoiding MagicKit's scroll() library like the plague! But, if you're staying with HuC, then turboxray did actually provide a simple and clean method to increase the number of scroll regions that the scroll() library supports, up to a maximum of 8. Just understand that the more regions that you use, the more time that the scroll() library uses during vblank. You just have to put a text file in your source code directory, and it will be read when you build, and you can use it to configure some of HuC's library setttings. I use the same method (but a different file) to allow for user-configuration of the CORE library code in my new assembly-language example projects. Anyway here's the file that you need to edit ... lib_exclude.asm (374 B)
|
|
lunoka
Gun-headed
Diving into retrodev
Posts: 55
Homebrew skills: art, music
Fave PCE Shooter: Burning angels
Fave PCE Platformer: Ninja Spirit
Fave PCE Game Overall: Valis 3
Fave PCE RPG: Neutopia
|
Post by lunoka on May 11, 2022 19:29:40 GMT
Sweet, thank you, tested, approved !
|
|
|
Post by Galahad on Jul 16, 2022 16:00:17 GMT
I've been looking at frogger for gameboy and it scrolls the entities,cars,logs,ect...on frogger for pc engine I'd have to use splits for some of the objects and then use sprites on the left and right columns,quite easy but huC is slow with arrays.I stayed below the sprite limit on Lucky Penguin and the snow flakes slowed the game down to a crawl with to many sprites,it's a good idea to test huc and decide if game design will work into it's limitations first.
|
|