English Amiga Board


Go Back   English Amiga Board > Other Projects > project.Amiga Game Factory

 
 
Thread Tools
Old 13 April 2020, 23:38   #1
mcgeezer
Registered User
 
Join Date: Oct 2017
Location: Sunderland, England
Posts: 2,702
Super Sprint AGA

After ripping out the Super Sprint car sprites on Friday (not that days matter now) I had a bit of time today and thought I might as well see if I can stitch some physics code to them.

See here for the thread and video...
http://eab.abime.net/showpost.php?p=1390754&postcount=1


Anyway... I've been racking my brains and I can't think of a way if I was making this game to ensure that the player followed the track completely.

What algorithm could I use to ensure that the player car went round the track in the correct order? I'm totally stumped by this one, it has really got me thinking and it the only barrier I can think of.

Any suggestion from the awesome EAB coders?

[ Show youtube player ]

Geezer
mcgeezer is offline  
Old 14 April 2020, 00:11   #2
fgh
Registered User
 
Join Date: Dec 2010
Location: Norway
Posts: 817
Put a numbered waypoint at each turn, and one at finish line, lap+1 if all were passed in correct sequence?
fgh is offline  
Old 14 April 2020, 00:24   #3
DanScott
Lemon. / Core Design
 
DanScott's Avatar
 
Join Date: Mar 2016
Location: Tier 5
Posts: 1,209
Yeah, fgh is correct.. we did this (or similar) for BC Racers

There were marker "strips" of floor blocks around the track... it you passed through them in sequence, and then cross the finish line (final marker), then a lap is completed.

We also used them for another reason, but can't remember exactly what it was... oh yes.. it's come back to me... can work out the position of each car, 1st,2nd,3rd to a reasonably reliable degree during the race
DanScott is online now  
Old 14 April 2020, 00:26   #4
Galahad/FLT
Going nowhere
 
Galahad/FLT's Avatar
 
Join Date: Oct 2001
Location: United Kingdom
Age: 50
Posts: 8,986
You need to do essentially 3 checks, but doing it one way takes care of all three.

1). First set of checks is numbered collision points. You can't just count collision blocks passed, it needs to be numbered, otherwise a player can go back and forth over one collision block and then goto finish.

So at certain points around the course, you would have collision barrier 1, then 2, then 3 etc, which have to be done in order, so lets assume you have 10 collision barriers, you would have a 10 word table, and first word refers to collision barrier 1, 2nd word etc, etc, and you would only allow a lap complete if the word table was filled from start to finish in order.

So what this also does means it solves the 3 check problem.

1). Forces driver to go in order you specify
2). Means driver can't go up to collision barrier 1 and simply cross over it again and again 10 times and then go back to finish
3). Means driver can't go around course backwards and confuse your detection.

And obviously once the lap is completed, you would then add 1 to that players lap counter and then clear the word table to start again.
Galahad/FLT is offline  
Old 14 April 2020, 00:32   #5
mcgeezer
Registered User
 
Join Date: Oct 2017
Location: Sunderland, England
Posts: 2,702
Cheers gents, i’ll see if i can implement it this week.
Its and interesting problem.
mcgeezer is offline  
Old 14 April 2020, 01:06   #6
DanScott
Lemon. / Core Design
 
DanScott's Avatar
 
Join Date: Mar 2016
Location: Tier 5
Posts: 1,209
it's quite a bit harder to work out the code that stops a player driving the wrong way, and creating "laps" in that way... if they have passed point X, then turn around and go the other way, and pass point (X+1), then you don't want that to count.... you need to store the last point they passed through... so to get to point (X+1) the wrong way, they would have to have passed through (X+2) peviously.. so it would not count... I hope you get what I mean
DanScott is online now  
Old 14 April 2020, 01:08   #7
DanScott
Lemon. / Core Design
 
DanScott's Avatar
 
Join Date: Mar 2016
Location: Tier 5
Posts: 1,209
basically store away the last point they passed through... the next point (X) is only valid if the previous point they passed through was X-1

shit I had too much Gin tonight
DanScott is online now  
Old 14 April 2020, 01:18   #8
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,161
don't do like I did with my Supercars III remake. Geometric zones that you could "tunnel" though because they were triangles (and the lap isn't validated)... Apart from that I did exactly how everyone is telling you do do, and it works.

Use an unshown picture with color codes for walls, bridges, etc... and for each lap note the zones that you have to pass on with another color too. The test is instant, too.

Guiding computer cars isn't trivial either. One way I successfully implemented in SCIII is to make them aim a point on the road, then another, then another. Problem with that approach is that the cars never deviate too much from the same trajectory. Target the next point as soon as you're close enough to the current point (so if cars collide, they're not going backwards to validate the point)

It was my first big project (in Java, on windows) and I didn't think I could manage with the pseudo-AI and track laps and all, but I ended up completing it

Implementing real AI for computer cars is another story! (can be done of course, there's an open source 3D racer which does that, I didn't even dare looking at the code)
jotd is offline  
Old 14 April 2020, 01:35   #9
phx
Natteravn
 
phx's Avatar
 
Join Date: Nov 2009
Location: Herford / Germany
Posts: 2,496
Oh yes, Super Sprint! That brings back memories! I loved to play it with three players at a friend's AtariST 30 years ago.

I even started to recreate the game on my Amiga in 1990. There is a screen shot of it in our Games Museum: http://night.owl.de/index.php?id=54

I remember that I didn't even touch the lap-counting problem but had serious trouble with the collision detection. The cars were constantly stuck in the track borders.

I wish you good success with it! A real Amiga version would be just great!
phx is offline  
Old 14 April 2020, 01:49   #10
DanScott
Lemon. / Core Design
 
DanScott's Avatar
 
Join Date: Mar 2016
Location: Tier 5
Posts: 1,209
For computer controller car guidance in BC Racers, each "block" on the floor had a set of direction bits (3 bit for 8 directions), showing which way to aim for. It worked quite well, as from any point on the map, the "arrows" would guide the car in the right direction... ie. off the side of the track the arrows would guide the car towards the middle racing line.

with the added inertia, this worked a treat
DanScott is online now  
Old 14 April 2020, 08:38   #11
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,161
If you check Supercars II, you'll see that sometimes the computer cars are stuck. After several repeated collisions against walls, you can make cars explode (if the game allows cars destructions, not in super sprint!) or/and increase the bounce force.

I think CPU behaviour heavily depends on the circuits themselves. That's the problem when you're remaking a game without the actual code: original coders made sure that computer cars behaved properly on all circuits. It means that they hacked the AI only for those circuits.
jotd is offline  
Old 14 April 2020, 10:42   #12
mcgeezer
Registered User
 
Join Date: Oct 2017
Location: Sunderland, England
Posts: 2,702
Thanks for the input here...very informative.

In my head I have a fairly good idea how I would go about achieving this, I've attached an image to help describe it though.

Each track would contain a 64x48 byte array containing the numbered checkpoints (4 bits), drone car direction (3 bits), and 1 bit for a DRS enable zone (if you like F1 you'll know what that is).

I've attached an image of how this would work, I'd just draw the grid out with different colours and use a Python script to build the byte array for each track.

For the track collisions I was simply going to use a 2 bit bitmap, 1st plane would be for the track collision using the blitter zero flag to check against with the car mask, 2nd plane I would use as an additional mask for when the car goes through an underpass. It might not be very efficient but I reckon the A500 would breeze it anyway.

I think that's a decent quick approach.

Geezer

Edit:- I just checked and I would need something that modifies the car angle, for example when it drives up a ramp.
Attached Thumbnails
Click image for larger version

Name:	ss_grid.png
Views:	562
Size:	37.0 KB
ID:	66855  

Last edited by mcgeezer; 14 April 2020 at 11:00.
mcgeezer is offline  
Old 14 April 2020, 13:09   #13
kamelito
Zone Friend
 
kamelito's Avatar
 
Join Date: May 2006
Location: France
Posts: 1,801
Loved the ST version 3 players too. You could crash the computer car easily in the last track because of the collision with the track. It will then never be able to continue. As for the algorithm I was asking the same question to myself and thought about the same solution. I’ll play it for sure but it should IMO need beta testing to calibrate the gameplay.
I still have the ST source code I did disassemble if you want.

Last edited by kamelito; 14 April 2020 at 13:15.
kamelito is offline  
Old 14 April 2020, 13:46   #14
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,161
1) make a special color for slopes
2) make checkpoint color codes wider just in case the framerate update tunnels through the checkpoint.

Problem of remaking super sprint is that you can't use the superb endless steering wheels they had in the arcades. Even with a microsoft steering wheel it's not the same since it's not endless.

Atari was famous at the time for those arcade games with special controls (with paperboy, marble madness)
jotd is offline  
Old 14 April 2020, 15:25   #15
WayneK
Registered User
 
Join Date: May 2004
Location: Somewhere secret
Age: 50
Posts: 364
We (my flatmates and I) actually had a Championship Sprint arcade machine in our flat for a while - until the girls downstairs complained to the landlord about the noise we made stamping on the accelerators and shouting at each other during late night alcohol-fueled races...
WayneK is offline  
Old 15 April 2020, 21:06   #16
fgh
Registered User
 
Join Date: Dec 2010
Location: Norway
Posts: 817
I have this one. Would love to make some 360 degree wheels for it!

One feature that would make the amiga version stand out is four player multiplayer. Four player adapters are available and super easy to build.

(Some admin should turn off ‘force landscape orientation’ when uploading pics!)
Attached Thumbnails
Click image for larger version

Name:	446A57C4-F148-45D3-A50C-E3E95B4B1E7B.jpg
Views:	535
Size:	766.2 KB
ID:	66871  
fgh is offline  
Old 16 April 2020, 00:33   #17
malko
Ex nihilo nihil
 
malko's Avatar
 
Join Date: Oct 2017
Location: CH
Posts: 4,856
If you go for this conversion Graeme, in addition to the 4 players facility (adapter), would you mind to try to add a "net-play" feature if it's not too time consuming doing it ? Over serial/parallel port (like lotus link play) or tcpip (like Battle duel) [ Show youtube player ] ?
I subscribe in advance for being a beta tester (even without the net-play facility)
malko is offline  
Old 16 April 2020, 10:56   #18
mcgeezer
Registered User
 
Join Date: Oct 2017
Location: Sunderland, England
Posts: 2,702
I doubt I will do the full conversion, besides Badlands on the Amiga looks like it was a direct rip-off of Super Sprint.

If i was to do it I'd probably go with the a A1200 and use Hi-Res interlaced mode (640x400) for the native Super Sprint resolution (512x384).

That way I could use the 4 hardware sprites for the cars but also pop it into Dual Playfield mode and solve most of the bridge/underpass problems quickly.

I've not done much in hires interlaced mode before, but the question would be would it be worth the effort to port the game - however if I did I would definetely put in as much multiplayer capability as possible.

Super Sprint - Covid19 Edition.

Graeme
mcgeezer is offline  
Old 16 April 2020, 12:15   #19
str0m
Registered User
 
Join Date: Oct 2016
Location: Newcastle, UK
Posts: 264
Is this one an ST port and you are looking to do a direct arcade one? https://www.lemonamiga.com/games/details.php?id=4298
str0m is offline  
Old 16 April 2020, 13:05   #20
mcgeezer
Registered User
 
Join Date: Oct 2017
Location: Sunderland, England
Posts: 2,702
Quote:
Originally Posted by str0m View Post
Is this one an ST port and you are looking to do a direct arcade one? https://www.lemonamiga.com/games/details.php?id=4298
Yes, that's an ST port (or more an ST emulation).
mcgeezer is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Super Sprint and Oids for Amiga / ST Emulator Photon support.Games 4 31 July 2018 01:48
super sprint motor sound turrican3 support.Games 3 03 November 2014 08:21
[REQ] Super Sprint angel_killah project.Sprites 6 21 April 2012 07:26
Super Sprint - Atari ST Conversion Galahad/FLT Retrogaming General Discussion 83 12 March 2012 21:34
Super Sprint & Oids ??? BeelzebubUK request.Old Rare Games 10 30 January 2002 21:43

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 16:32.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.12944 seconds with 14 queries