12/23/2024: Localization News - Team Innocent

PC-FX Localization for Team Innocent is released, a pre-Christmas gift!! In a twist, it feels like the NEC PC-FX got more attention in 2024 than any other time I can remember! Caveat: The localizers consider the "v0.9" patch a BETA as it still faces technical hurdles to eventually subtitle the FMV scenes, but they consider it very much playable.
github.com/TeamInnocent-EnglishPatchPCFX
x.com/DerekPascarella/PCFXNews
Main Menu

How'd they do that? Explaining PC Engine tricks.

Started by CrackTiger, 09/14/2007, 11:28 PM

Previous topic - Next topic

0 Members and 0 Guests are viewing this topic.

CrackTiger

If you're wondering how a particular crazy effect is achieved in a PC Engine game, post it here and hopefully the resident programming experts will unravel them for us. :)


One thing I'd like explained is vertical scrolling/overlapping of background sections. In that other thread, I pointed out the third stage of Magical Chase.

Jackie Chan and Bravo Man have some simple overlapping vertical 'scrolls', but one in particular that got me thinking about this the other day is the elevator bg 5 minutes into Toneman's Riot Zone video.
Justin the Not-So-Cheery Black/Hack/CrackTiger helped Joshua Jackass, Andrew/Arkhan Dildovich and the DildoPhiles destroy 2 PC Engine groups: one by Aaron Lambert on Facebook, then the other by Aaron Nanto!!! Him and PCE Aarons don't have a good track record together! Both times he blamed the Aarons and their staff in a "Look-what-you-made-us-do?!" manner, never himself nor his deranged/destructive/doxxing toxic turbo troll gang which he covers up for under the "community" euphemism!

TurboXray

 Riot zone: elevator part.

 The effect is a single hsync break in the screen to divide the elevator floor and the wall. The columns that fake the see through layer are dynamic tiles (animated in this case). The game even animates, or pauses the animation, of the column tiles to be in sync with the elevator floor when it shakes or rumbles.

 Some pics:

The normal screen:
/elevator.png

Minus Sprites:
/elevator1.png

Just sprites:
/elevator2.png

Here's a view of the PCEs memory when view in tile mode. See the single tile, halfway down the window/block and to the left (16x16 block)? That single tile is used for the whole column(s). When you animate that single tile, the whole column animates.

/elevator3.png

;)

Keranu

Excellent thread and excellent respond by Bonknuts! I'm sure I have a bunch of questions as well, but I'll have to go back and look for them.
Quote from: TurboXray on 01/02/2014, 09:21 PMAdding PCE console specific layer on top of that, makes for an interesting challenge (no, not a reference to Ys II).
IMG
Click the banner to learn more about Alex Chiu and his "immortality rings"

akamichi

I don't remember Batman being a hidden character in riot zone!  hehehehehe.  :-"

- akamichi

Keranu

Haha, that was some hack Bonknuts made awhile back :D . At least I'm pretty sure Bonknuts made it.

Mal you should replace the sprite with Cody from Final Fight (if possible) ;) .
Quote from: TurboXray on 01/02/2014, 09:21 PMAdding PCE console specific layer on top of that, makes for an interesting challenge (no, not a reference to Ys II).
IMG
Click the banner to learn more about Alex Chiu and his "immortality rings"

Turbo D

Quote from: MissaFX on 01/06/2008, 12:10 PMMy idea of gaming is a couple of friends over, a couple of drinks, a couple of medical-handrolled-game-enhancing-cigs and a glowing box you all worship.
IMG IMG
IMG

TurboXray

#6
The cody sprite is already in there (the 2 frames for punching), I just had the batman frame in as the stance frame. I lost the motivation to finish it since I got more exciting projects to work on ;)


Quote from: akamichiI don't remember Batman being a hidden character in riot zone!  hehehehehe.  Whistle

- akamichi
Akamichi! The man  :wink:

Keranu

Ahh, yeah I wasn't sure if he made a hack of that or not. I'd still like to see a stage of the arcade Final Fight ported to the PCE ;) . There was some programmer who was working on a cool Strider demo for PCE (or SGX?), but I don't know what happened to it. He was working on some other way cool things too!
Quote from: TurboXray on 01/02/2014, 09:21 PMAdding PCE console specific layer on top of that, makes for an interesting challenge (no, not a reference to Ys II).
IMG
Click the banner to learn more about Alex Chiu and his "immortality rings"

Arjak

In the intro of Lords of Thunder, there's this moment in the intro as Landis takes off and the background has this neat rotating like effect, it looks weird, like a backdrop falling down at a play. Looks cool though. How did they do that one?
He who dings the Gunhed must PAAAAY!!! -Ninja Spirit

TurboXray

That's an Hsync effect. Spriggan Mark 2 also does this in the intro.

 You can stretch or sine warp an image vertically by using hsync interrupts to change the BG position on every scanline. You know that cool effect in Axelay that looks sort of mode-7? It's not. It's an hsync effect just like intro to LOT. Check out Chris Covell's page as he has a demo showing this effect on the SGX (and it has some PCE versions bundled in with it). He also has some vertical warping demos on the same page.

 The effect work like this:

frame one:

 scanline 120: set BG to position 60
 scanline 121: set BG to position 60
 scanline 122: set BG to position 60
 scanline 123: set BG to position 61
 scanline 124: set BG to position 61
 scanline 125: set BG to position 61

frame two:

 scanline 120: set BG to position 60
 scanline 121: set BG to position 60
 scanline 122: set BG to position 61
 scanline 123: set BG to position 61
 scanline 124: set BG to position 62
 scanline 125: set BG to position 62

frame two:

 scanline 120: set BG to position 61
 scanline 121: set BG to position 62
 scanline 122: set BG to position 63
 scanline 123: set BG to position 64
 scanline 124: set BG to position 65
 scanline 125: set BG to position 66

That's simplifying it though, as LOT didn't stretch ever pixel to the same width but instead gave it a skewed look.

CrackTiger

#10
Final Fantasy IV on Wonderswan color used that Axelay effect for the world map when flying the airship.

It worked pretty good and is one way that a 'warping' world map could be done in a Turbo RPG or Final Fantasy port.


Now that I know that sections of background can push over the rest, the HP bar in SFIICE and the Neo Geo ports makes sense. :)
Justin the Not-So-Cheery Black/Hack/CrackTiger helped Joshua Jackass, Andrew/Arkhan Dildovich and the DildoPhiles destroy 2 PC Engine groups: one by Aaron Lambert on Facebook, then the other by Aaron Nanto!!! Him and PCE Aarons don't have a good track record together! Both times he blamed the Aarons and their staff in a "Look-what-you-made-us-do?!" manner, never himself nor his deranged/destructive/doxxing toxic turbo troll gang which he covers up for under the "community" euphemism!

Keranu

Quote from: guest on 09/16/2007, 02:52 PMFinal Fantasy IV on Wonderswan color used that Axelay effect for the world map when flying the airship.

It worked pretty good and is one way that a 'warping' world map could be done in a Turbo RPG or Final Fantasy port.
That's cool, I didn't know about that! Might be something to look into for any PCE coders out there making an RPG or something.
Quote from: TurboXray on 01/02/2014, 09:21 PMAdding PCE console specific layer on top of that, makes for an interesting challenge (no, not a reference to Ys II).
IMG
Click the banner to learn more about Alex Chiu and his "immortality rings"

ParanoiaDragon

Yeah, we just gotta find some PCE coders that are working on any RPG's.....now where to find them :-"
IMG

Joe Redifer

In games like Gate of Thunder or many others where the Turbo actually shows graphic scaling, is there a scaling subroutine written in to the programming, it is it just animated tiles?

ccovell

The scaling of the enemy ships and the moving blocks in Stage 2, etc, are just animations.

The PCE hardware can't scale any sprites or backgrounds, but by changing the scrolling at each scanline, vertical scaling of backgrounds can be achieved -- a common trick on many game systems.

nat

So does Star Parodia just use animations like that, too? There is some scaling in that game so smooth you'd swear the hardware was doing it.

Joe Redifer

So the Super CD Screen flying away is just animated tiles?  I'm sure the TG could scale small things if the software had a scaling routine written in.

Keranu

Here's one for 'ya!

/cdf032b9d4001nb4.png

This screenshot is taken from Hyaku Monogatari with Magic Engine with only the sprite layer showing. There are over 100 sprites on that screen, since there are one hundred candles. From what I know, the PCE can only display 64 sprites on screen at max, so how are so many sprites on the screen in this image? My guess is that each candle isn't it's own sprite, but multiple candles grouped in one sprite box of whatever size. I should menton though that after viewing the story for each candle, the candle is blown out, which makes me wonder how they grouped the blown out candles with the lit ones.

Also this game uses a lot of wavy effects and there is one in particular I'd like to know more about where it shows the flame of a candle up close shifting left and right with invisible horizontal lines through it. I'll have to capture a video of that or something later, it looks really good on a TV.
Quote from: TurboXray on 01/02/2014, 09:21 PMAdding PCE console specific layer on top of that, makes for an interesting challenge (no, not a reference to Ys II).
IMG
Click the banner to learn more about Alex Chiu and his "immortality rings"

ccovell

Quote from: nat on 09/30/2007, 03:06 PMSo does Star Parodia just use animations like that, too? There is some scaling in that game so smooth you'd swear the hardware was doing it.
Can you specify or post a pic of the parts you're referring to?

Yes, the Super CD screen is a large animation.  The PCE can do scaling in software (well, any system can), but it's very slow -- take a look at Metamor Jupiter.

Keranu most likely answered his own questions about Hyaku Monogatari.  A 160x160 area of sprites on-screen isn't impossible by any means.

TurboXray

Quote from: Joe Redifer on 09/30/2007, 05:55 PMSo the Super CD Screen flying away is just animated tiles?  I'm sure the TG could scale small things if the software had a scaling routine written in. 
The system card has quite a few math routines, but a developer is better off using their own (faster code or with LUT aids). Either way, it's not realistic to try to scale image data in real time. One of the biggest reasons is that console systems don't use linear bitmap style displays, so you have even more overhead of converting the scaled or rotated image into a planer tile format. I know two really fast scaling and rotation methods (no cos/sin or multiplication or add/subs used), too bad the format conversion to planar tile negates the process.

 One method is to pre-scale all the frames in realtime (during a break or low cpu resource part) and then store them in memory for later use. This saves  memory, if you think of it as a form of compression (just more CPU intensive than most compression methods), and can cut down on loading times.  The other method of course is just to have them already prep'd as frames, stored on the CD.

 Funny thing about the PCE; it would have benefited more from the scaling/rotation chip like in the SegaCD, than the SegaCD did, since the PCE is free to write to VRAM during active display unlike the Genesis (or SNES). They could very easily added such a chip to the system card.

Joe Redifer

About the converting to a planer tile format, does the Genesis work like this as well?  I ask because of the MASAYA logo at the beginning of Target Earth.  The game allows the user to stretch and rotate the logo in real time.  I can't imagine them creating tiles for all of that in advance, it would be unreasonable for such a thing with memory what it was back in those days.  When the logo gets bigger, the adjustments get slower.  It must have a scaling/rotation routine in the software which then converts it to tiles.

I agree about the possibility of a scaling chip for the PCE system card.  That would have rocked!

TurboXray

#21
Quote from: Joe Redifer on 09/30/2007, 11:51 PMAbout the converting to a planer tile format, does the Genesis work like this as well?  I ask because of the MASAYA logo at the beginning of Target Earth.
No, the Genesis uses 4bit linear (packed) format for both tile and sprites - which is easier (and faster!) for doing "pixel plotting" on a tile based system. Yeah, that's real time in Target Earth, you can tell when it slows to a crawl as it gets bigger than normal (in the test) and other rotated angles.

 There was talk of doing another system card (4.0?). It'd be possible to add a coprocessor to it. Maybe an NEC 32bit RISC chip (to keep in the spirit of things) :D  ..one can dream

Kitsunexus

Quote from: Joe Redifer on 09/30/2007, 11:51 PMAbout the converting to a planer tile format, does the Genesis work like this as well?  I ask because of the MASAYA logo at the beginning of Target Earth.  The game allows the user to stretch and rotate the logo in real time.
So does the Rocko's Modern Life game for SNES. :P
Forgive me, my brain is on par with the Bubble System.
THE CHEMICAL BROTHERS RULE!

CrackTiger

I assumed that the 4-in-1 intro was animation, but just for the hell of it, I ran it using the PC Engine System 3 card as soon as I got one.
Justin the Not-So-Cheery Black/Hack/CrackTiger helped Joshua Jackass, Andrew/Arkhan Dildovich and the DildoPhiles destroy 2 PC Engine groups: one by Aaron Lambert on Facebook, then the other by Aaron Nanto!!! Him and PCE Aarons don't have a good track record together! Both times he blamed the Aarons and their staff in a "Look-what-you-made-us-do?!" manner, never himself nor his deranged/destructive/doxxing toxic turbo troll gang which he covers up for under the "community" euphemism!

Joe Redifer

Yeah, it has to be animation for the 4-in1 since the words "PC Engine" go away when I use the mighty arcade card.

Keranu

Quote from: ccovell on 09/30/2007, 12:31 PMThe PCE hardware can't scale any sprites or backgrounds, but by changing the scrolling at each scanline, vertical scaling of backgrounds can be achieved -- a common trick on many game systems.
So is this how they did the scailing in the Arcade Card port of Art of Fighting? I was examining the game recently and I noticed when it scales in, the width seems to remain the same and just the height increases.
Quote from: TurboXray on 01/02/2014, 09:21 PMAdding PCE console specific layer on top of that, makes for an interesting challenge (no, not a reference to Ys II).
IMG
Click the banner to learn more about Alex Chiu and his "immortality rings"

CrackTiger

Quote from: Keranu on 10/02/2007, 06:40 PM
Quote from: ccovell on 09/30/2007, 12:31 PMThe PCE hardware can't scale any sprites or backgrounds, but by changing the scrolling at each scanline, vertical scaling of backgrounds can be achieved -- a common trick on many game systems.
So is this how they did the scailing in the Arcade Card port of Art of Fighting? I was examining the game recently and I noticed when it scales in, the width seems to remain the same and just the height increases.
From what I understand, AoF actually switches resolutions, I'm guessing from 256 x 240 to 336 x 240.

The vertical scaling trick would be more like the Lords of Thunder intro when the hero takes off.
Justin the Not-So-Cheery Black/Hack/CrackTiger helped Joshua Jackass, Andrew/Arkhan Dildovich and the DildoPhiles destroy 2 PC Engine groups: one by Aaron Lambert on Facebook, then the other by Aaron Nanto!!! Him and PCE Aarons don't have a good track record together! Both times he blamed the Aarons and their staff in a "Look-what-you-made-us-do?!" manner, never himself nor his deranged/destructive/doxxing toxic turbo troll gang which he covers up for under the "community" euphemism!

Keranu

Quote from: guest on 10/02/2007, 07:05 PM
Quote from: Keranu on 10/02/2007, 06:40 PM
Quote from: ccovell on 09/30/2007, 12:31 PMThe PCE hardware can't scale any sprites or backgrounds, but by changing the scrolling at each scanline, vertical scaling of backgrounds can be achieved -- a common trick on many game systems.
So is this how they did the scailing in the Arcade Card port of Art of Fighting? I was examining the game recently and I noticed when it scales in, the width seems to remain the same and just the height increases.
From what I understand, AoF actually switches resolutions, I'm guessing from 256 x 240 to 336 x 240.
Actually when I checked, the resolution remained at 256x224. Maybe it changes in the actual playing area, but I'm not sure.

Quote from: CrackTigerThe vertical scaling trick would be more like the Lords of Thunder intro when the hero takes off.
Or my favorite, the opening of Spriggan Mark 2 :) .
Quote from: TurboXray on 01/02/2014, 09:21 PMAdding PCE console specific layer on top of that, makes for an interesting challenge (no, not a reference to Ys II).
IMG
Click the banner to learn more about Alex Chiu and his "immortality rings"

Joe Redifer

Check again.  Art of Fighting changes resolutions.  Count the pixels one by one on your TV screen.   Don't make me post screenshots (in order to do so I think I'd need an Arcade Card image for Magic Engine).

Keranu

I took screenshots in Magic Engine and the resolution appeared the same, and the screen didn't change while I was playing it either. Probably just a problem with ME then. By the way Joe, you can just use the Super System Card 3.0 ROM to play Arcade Card games in ME.
Quote from: TurboXray on 01/02/2014, 09:21 PMAdding PCE console specific layer on top of that, makes for an interesting challenge (no, not a reference to Ys II).
IMG
Click the banner to learn more about Alex Chiu and his "immortality rings"

TurboXray

Quote from: guest on 10/02/2007, 07:05 PM
Quote from: Keranu on 10/02/2007, 06:40 PM
Quote from: ccovell on 09/30/2007, 12:31 PMThe PCE hardware can't scale any sprites or backgrounds, but by changing the scrolling at each scanline, vertical scaling of backgrounds can be achieved -- a common trick on many game systems.
So is this how they did the scailing in the Arcade Card port of Art of Fighting? I was examining the game recently and I noticed when it scales in, the width seems to remain the same and just the height increases.
From what I understand, AoF actually switches resolutions, I'm guessing from 256 x 240 to 336 x 240.

The vertical scaling trick would be more like the Lords of Thunder intro when the hero takes off.
You called it! That's exactly what it is. The game switches between mid to low res and it uses scanline BG repositioning to scale it vertically. The sprites are changed out in the middle of the process.

ccovell

Mednafen's emulation isn't perfect, but it does emulate the resolution change mid-screen in Art of Fighting. Here's a little animation I made to show the change:

IMG

The playfield resolution changes from 256 to 304 horizontal pixels.  Of course, on a TV, the pixel aspect is wider in the 256 resolution, so the screen is filled up.

CrackTiger

I've got another question about horizontal scrolling.

Can a background horizontally scroll into itself, kinda like the vertical scrolling discussed earlier?

Today I played through Lords of Thunder and in a few places some of the horizontal scrolls hit a vertical wall where the bg transitioned to fully flat.
Justin the Not-So-Cheery Black/Hack/CrackTiger helped Joshua Jackass, Andrew/Arkhan Dildovich and the DildoPhiles destroy 2 PC Engine groups: one by Aaron Lambert on Facebook, then the other by Aaron Nanto!!! Him and PCE Aarons don't have a good track record together! Both times he blamed the Aarons and their staff in a "Look-what-you-made-us-do?!" manner, never himself nor his deranged/destructive/doxxing toxic turbo troll gang which he covers up for under the "community" euphemism!

TurboXray

Quote from: guest on 10/03/2007, 01:47 PMI've got another question about horizontal scrolling.

Can a background horizontally scroll into itself, kinda like the vertical scrolling discussed earlier?

Today I played through Lords of Thunder and in a few places some of the horizontal scrolls hit a vertical wall where the bg transitioned to fully flat.
No. But that would be cool if it could. Lords of Thunder uses dynamic tiles to simulate hsync scrolls, but they're not. Dynamic tiles are either rendered on the fly or pre-rendered, and then sent to the display. This allows you more freedom when mixing tiles, lifting some of the restrictions of just hsync scrolls on a single plane system. You know that large enemy at the beginning of the desert level? That's mostly made of BG tiles. It looks like another layer because the tiles surrounding it, and the whole of the parallaxing tiles, are dynamic tiles.

 I'll post some pics if you need.

CrackTiger

What I don't get is, if animated tiles are used for bg scroll effects so much, why did developers only use them to simulate such simple effects?

Why not give the bgs a more 3D animation like the SFII floors or have more overlapping pieces of parallax or something?
Justin the Not-So-Cheery Black/Hack/CrackTiger helped Joshua Jackass, Andrew/Arkhan Dildovich and the DildoPhiles destroy 2 PC Engine groups: one by Aaron Lambert on Facebook, then the other by Aaron Nanto!!! Him and PCE Aarons don't have a good track record together! Both times he blamed the Aarons and their staff in a "Look-what-you-made-us-do?!" manner, never himself nor his deranged/destructive/doxxing toxic turbo troll gang which he covers up for under the "community" euphemism!

CrackTiger

Can anyone tell me if the in-game menu windows of Popful Mail use real wire frame/"vector" graphics or are simply animation?

The shadow 'transparency' effect in this game also looks cool since the screen frame doesn't change.
Justin the Not-So-Cheery Black/Hack/CrackTiger helped Joshua Jackass, Andrew/Arkhan Dildovich and the DildoPhiles destroy 2 PC Engine groups: one by Aaron Lambert on Facebook, then the other by Aaron Nanto!!! Him and PCE Aarons don't have a good track record together! Both times he blamed the Aarons and their staff in a "Look-what-you-made-us-do?!" manner, never himself nor his deranged/destructive/doxxing toxic turbo troll gang which he covers up for under the "community" euphemism!

Ceti Alpha

This thread is the bees knees.

QuoteThere was talk of doing another system card (4.0?). It'd be possible to add a coprocessor to it. Maybe an NEC 32bit RISC chip (to keep in the spirit of things) Very Happy  ..one can dream
...and dream I will...  [-o<
IMG
"Let the CAW and Mystery of a Journey Unlike Any Other Begin"

Nazi NecroPhile

Here's a question for the programming geniuses: towards the end of the second level in Sapphire, how is the castle wall warped to look like the perspective is shifting as you fly over?  Is it just animated sprites, or what?
Ultimate Forum Bully/Thief/Saboteur/Clone Warrior! BURN IN HELL NECROPHUCK!!!

CrackTiger

Quote from: NecroPhile on 01/15/2008, 12:32 AMHere's a question for the programming geniuses: towards the end of the second level in Sapphire, how is the castle wall warped to look like the perspective is shifting as you fly over?  Is it just animated sprites, or what?
I believe thats an Hsync effect, which Bonknuts explains on the first page of this thread.
Justin the Not-So-Cheery Black/Hack/CrackTiger helped Joshua Jackass, Andrew/Arkhan Dildovich and the DildoPhiles destroy 2 PC Engine groups: one by Aaron Lambert on Facebook, then the other by Aaron Nanto!!! Him and PCE Aarons don't have a good track record together! Both times he blamed the Aarons and their staff in a "Look-what-you-made-us-do?!" manner, never himself nor his deranged/destructive/doxxing toxic turbo troll gang which he covers up for under the "community" euphemism!

Nazi NecroPhile

Quote from: CrackTiger on 01/15/2008, 08:06 AMI believe thats an Hsync effect, which Bonknuts explains on the first page of this thread.
Thanks.
Ultimate Forum Bully/Thief/Saboteur/Clone Warrior! BURN IN HELL NECROPHUCK!!!

nat

Quote from: guest on 01/15/2008, 12:32 AMHere's a question for the programming geniuses: towards the end of the second level in Sapphire, how is the castle wall warped to look like the perspective is shifting as you fly over? 
That also happens during stage 1 as you fly over the skyscraper. It might happen elsewhere in the game too, I can't remember.

TurboXray

Quote from: guest on 01/15/2008, 12:32 AMHere's a question for the programming geniuses: towards the end of the second level in Sapphire, how is the castle wall warped to look like the perspective is shifting as you fly over?  Is it just animated sprites, or what?
Yeah, it's the same type of effect that Chris did in his Axelay demo. You can scale or distort the background on the Y axis, pretty easily actually.

QuoteCan anyone tell me if the in-game menu windows of Popful Mail use real wire frame/"vector" graphics or are simply animation?

The shadow 'transparency' effect in this game also looks cool since the screen frame doesn't change.
Where in the game is the transparency part?

ParanoiaDragon

I think he's talking about one of the first area's in the game.
IMG