poll:outrun for msx2

Page 6/11
1 | 2 | 3 | 4 | 5 | | 7 | 8 | 9 | 10 | 11

By edoz

Prophet (2168)

edoz's picture

29-06-2019, 15:42

Fun! It looks nice!

By Ivan

Ascended (9095)

Ivan's picture

29-06-2019, 22:23

LeandroCorreia wrote:

IMHO, the best 3D racing engine for the MSX1...

https://www.youtube.com/watch?v=KQHiiY3H6es

Impressive! Never heard of that game (Live in the fast lane).

And It was made in 1987! oO

By Maggoo

Paragon (1195)

Maggoo's picture

29-06-2019, 22:34

zPasi wrote:

I made a demo thing with Fusion C:
https://youtu.be/jaLeSjrIRIk

It works in Screen 5, alternating two pages. Basically it just YMMMs the background, then adds the lane markings with HMMM. Then the rest of it (including the car) is done with LMMM with transparency, and pre-calculated (pseudo) 3D coordinates.

This is still buggy and crappy and the framerate is not impressive, but maybe something could be done this way.

If replaced the bulk YMMM with HMMMs only on the parts where required, might improve the framerate.

It actually looks pretty good. You may be able to improve the framerate by using hardware sprites for a few elements or doing vpoke for updating some elements while copys are being executed.

By santiontanon

Paladin (808)

santiontanon's picture

30-06-2019, 04:00

Indeed it looks very good for a first experiment! Nice work!!! And being in C, there should be plenty of room for improvement adding assembler routines here and there, so, I'm not too worried about framerate Smile Do you think this technique would support having curving roads?

By ARTRAG

Enlighted (6229)

ARTRAG's picture

01-07-2019, 08:02

zPasi wrote:

I made a demo thing with Fusion C:
https://youtu.be/jaLeSjrIRIk

It works in Screen 5, alternating two pages. Basically it just YMMMs the background, then adds the lane markings with HMMM. Then the rest of it (including the car) is done with LMMM with transparency, and pre-calculated (pseudo) 3D coordinates.

This is still buggy and crappy and the framerate is not impressive, but maybe something could be done this way.

If replaced the bulk YMMM with HMMMs only on the parts where required, might improve the framerate.

It looks very good
I would make cars smaller (or the road larger)

By zPasi

Champion (410)

zPasi's picture

01-07-2019, 08:37

Thanks for your kind words, everyone! Smile

Maggoo wrote:

You may be able to improve the framerate by using hardware sprites for a few elements or doing vpoke for updating some elements while copys are being executed.

I actually disabled the hw sprites to make VDP commands run faster. But maybe using them would make more sense, haven't done proper testing yet.

That "vpoke" sounds a good idea, when I'll figure out where to use that without messing things when commands are running.

santiontanon wrote:

Do you think this technique would support having curving roads?

Sure it would. Not very easy, but that could be a good place to try the "vpoke" approach! But then I'd also have to horizontally scroll the upper part. Not impossible I think.

ARTRAG wrote:

I would make cars smaller (or the road larger)

Yeah. Might do proper 3D calculations as well, it doesn't "cost" much because they are pre-calculated.

By Grauw

Ascended (8316)

Grauw's picture

15-07-2019, 22:59

Posted in another thread but also on-topic here for the gameplay:

alexito wrote:

Recently I discovered this upcoming game for Amstrad CPC called VESPERTINO they show fluid cars animations very impressive.

By Grauw

Ascended (8316)

Grauw's picture

15-07-2019, 23:09

So I was thinking about the issue of the vertical scrolling affecting the sprites. The solutions to me seems to be: don’t use vertical scrolling.

So that quickly brings us to the other fast alternative: pattern modes. Ue screen 4 for the road graphics, create up to 128 or name tables in VRAM, one for each road width, and change register 2 in line splits to select the appropriate one. Now you can safely use sprites for the cars and objects along the road. For turns use the V9958 horizontal scroll.

Building on this concept perhaps one could find some more clever use of the name or pattern tables to avoid needing horizontal scroll for turns, so it can be done on MSX2 and without split artifacts near the edges of the screen… but no idea currently comes to mind.

By Grauw

Ascended (8316)

Grauw's picture

16-07-2019, 00:10

Oh. Another idea just sprang to mind.

In screen 4, have 8 name tables. Then on the bottom third of the screen (race track), set up a series of splits which for each line selects the name table corresponding to the line number modulo 8. Now you can address the screen as if it had a 64x32 name table with 8x1 patterns. Updating the bottom third of the screen takes 2048 writes, or 36864 cycles with OUTI (61.7% CPU @ 60 fps).

Alternatively to cut that CPU usage in half you can have just 4 name tables and select the name table corresponding to the line * 2 modulo 4, which gives you a 32x32 name table with 8x2 patterns. Updating the bottom third will take 1024 writes, or 18432 cycles (30.8% CPU @ 60 fps).

Put tiles for the track edges with different shift values in the pattern table, and some lookup tables in ROM with the name table lines (32 bytes each) for different vertical and horizontal offsets, I bet you can get a good looking result on MSX2 with pixel-perfect perspective, turns and hills, with sprites still at your full disposal.

(And this may fit in 16K VRAM so even MSX1 could be an option, though splits will be a challenge.)

p.s. Better to give the player a motorcycle rather than a car; since it’s tall (16×32) rather than wide (32×16), you won’t hit the 8 sprites per line limit so easily. If the car already uses 4 sprites on a line (two OR layers), the remaining four can be used for objects along the road (2 OR sprites each). But if you overtake another car (again 4 sprites), the objects’ll disappear. Maybe things move fast enough that it’s not really an issue, however with a tall motorcycle sprite you avoid the problem altogether.

By wimpie3

Master (254)

wimpie3's picture

16-07-2019, 06:48

Some nice ideas here for the next msxdev :-)

Page 6/11
1 | 2 | 3 | 4 | 5 | | 7 | 8 | 9 | 10 | 11