Jump to content
IGNORED

Ultimate Indy 500 (0.8 released - Real Indy cars)


Fort Apocalypse

Recommended Posts

A bar might be a good way to show how much fuel you have left. When you run out of gas, is the game just over because the car stalls or you get sent back to the starting line with half a tank or a full tank? Since the seem early in the development, I guess you have the time figure out the gameplay.

Link to comment
Share on other sites

I can't remember exactly where I found this, but I believe batari wrote it. I did a quick search on the forums and I couldn't find the original post. It's an indy 500 demo game that has the all the car physics for the car configured just like the original indy 500 game. It works really well - It might be a good example to look at if you want to tweak your game.

 

Great job by the way! Your game is very cool and has great potential.

 

Steve

 

Steve,

 

Thanks for the code from batari. I looked at it and unfortunately it uses 16 variables per player (since I can't reuse player1 and 2 x and y coords since I share player0 and 1 with players 2 and 3), which would mean 64 variables for all 4 cars. If there is some part of it that you think I could reuse or if you think that it is going to suck too bad without bank switching let me know and I'll do what I can. I'll definitely look at it to see what I can use though. I was really hoping to keep it under 4k to try to make it more accessible (isn't 4k the lowest common denominator?).

Link to comment
Share on other sites

0.4 released. Steering less sensitive (went from diving paddle difference from center by 5 to dividing by 8 for the 255-based direction delta- don't ask me what percentage difference that is- it is too late today for me to do math), accel/decel more sensitive (2x sensitivity). Changed code to not use temp1-3 (so had to use up 3 more regular vars). It now sets sound and checks for playfield collision 2x as quickly and maybe more accurately (I didn't test to see if it fixed the pf bug yet- let me know if it does).

 

Let me know what you think. You may have to turn up the default paddle delta in Stella to get it to turn quickly enough via keyboard.

 

ultindy500_0.4.bas.binultindy500_0.4.bas

Link to comment
Share on other sites

A bar might be a good way to show how much fuel you have left. When you run out of gas, is the game just over because the car stalls or you get sent back to the starting line with half a tank or a full tank? Since the seem early in the development, I guess you have the time figure out the gameplay.

 

Unfortunately, since there are four players, there is no way to show 4 bars without writing a minikernel (and I'm not quite up to that level yet ;) ). I had originally thought that maybe you would still be able to move but just really, really slow at this point. That way, even though you will probably lose the game, at least you still have a chance and can play.

 

I almost have to code done for the fuel (to use car color) but am having to take chance using temp vars 2 and 3 and lose title sequence. Hopefully playfield collision detection won't screw up again.

Link to comment
Share on other sites

Ok, tried it again on a real atari.... the steering is more sluggish, which would seem to be good, but still very difficult to control... It feels like the car and the paddle controller are not "connected" so to speak... the car doesn't seem to "sync" with the paddle control at all....

 

I think that a new concept of steering should be investigated... In the original Indy 500, the steering controller would give a momentary right or left joystick "pulse" for every click the wheel encountered as it turned... This functionality can be easily replicated with the paddle controller (just store the current paddle value and in each frame see if the next value is higher or lower and store again)... but, you run into the problem of the paddle controllers having stops at each end...

 

But, there has to be a way where the two philosophies can be merged... the tight control and response of the original Indy 500 driving controllers, but with the realistic steering the paddle controllers can give you...

 

I don't know the best way to go about this.... but, I do know that the current steering algorithm needs an overhaul. I'll look at the code and see what I might be able to come up with...

 

Thanks,

 

Mike

Link to comment
Share on other sites

but, you run into the problem of the paddle controllers having stops at each end...

 

Right.

 

But, there has to be a way where the two philosophies can be merged... the tight control and response of the original Indy 500 driving controllers, but with the realistic steering the paddle controllers can give you...

 

I don't know the best way to go about this.... but, I do know that the current steering algorithm needs an overhaul. I'll look at the code and see what I might be able to come up with...

 

That would be awesome. It is really hard getting the right feel for it without having actually paddles. :(

 

I think the problem may be this:

if paddle > 40 then tempdir255maxdelta = (paddle - 38) / 8 : gosub incrdir : return

if paddle < 36 then tempdir255maxdelta = (38 - paddle) / 8 : gosub decrdir

 

I was trying to have a way to keep it "steady" in the middle, but maybe I should make it like this (lowering from 8 to might it turn faster and changed the middle value to not have a "center" range:

 

if paddle > 38 then tempdir255maxdelta = (paddle - 38) / 6 : gosub incrdir : return

if paddle < 38 then tempdir255maxdelta = (38 - paddle) / 6 : gosub decrdir

Edited by Fort Apocalypse
Link to comment
Share on other sites

Actually, I think I know what may be wrong with it if it is about car movement and not the actual direction of the car. (If it is about direction of the car though I think the previous fix is the first thing to do probably.)

 

Here is the part of the code that does 0-15 direction to x,y coordinate delta:

setdeltas
if tempvel >= 0 then temp100percentdelta = 0 : temp92percentdelta = 0 : temp71percentdelta = 0 : temp38percentdelta = 0
if tempvel > 1 then temp100percentdelta = 1 : temp92percentdelta = 1 : temp71percentdelta = 1 : temp38percentdelta = 1
if tempvel > 20 then temp100percentdelta = 2 : temp92percentdelta = 2 : temp71percentdelta = 1 : temp38percentdelta = 1
if tempvel > 40 then temp100percentdelta = 3 : temp92percentdelta = 3 : temp71percentdelta = 2 : temp38percentdelta = 1
rem if tempvel > 50 then temp100percentdelta = 5 : temp92percentdelta = 5 : temp71percentdelta = 4 : temp38percentdelta = 2
rem if tempvel > 60 then temp100percentdelta = 6 : temp92percentdelta = 6 : temp71percentdelta = 4 : temp38percentdelta = 2
return

changepos
if tempdir16max = 1 then tempy = tempy - temp100percentdelta
if tempdir16max = 2 then tempx = tempx + temp38percentdelta : tempy = tempy - temp92percentdelta
if tempdir16max = 3 then tempx = tempx + temp71percentdelta : tempy = tempy - temp71percentdelta
if tempdir16max = 4 then tempx = tempx + temp92percentdelta : tempy = tempy - temp38percentdelta
if tempdir16max = 5 then tempx = tempx + temp100percentdelta
if tempdir16max = 6 then tempx = tempx + temp92percentdelta : tempy = tempy + temp38percentdelta
if tempdir16max = 7 then tempx = tempx + temp71percentdelta : tempy = tempy + temp71percentdelta
if tempdir16max = 8 then tempx = tempx + temp38percentdelta : tempy = tempy + temp92percentdelta
if tempdir16max = 9 then tempy = tempy + temp100percentdelta
if tempdir16max = 10 then tempx = tempx - temp38percentdelta : tempy = tempy + temp92percentdelta
if tempdir16max = 11 then tempx = tempx - temp71percentdelta : tempy = tempy + temp71percentdelta
if tempdir16max = 12 then tempx = tempx - temp92percentdelta : tempy = tempy + temp38percentdelta
if tempdir16max = 13 then tempx = tempx - temp100percentdelta
if tempdir16max = 14 then tempx = tempx - temp92percentdelta : tempy = tempy - temp38percentdelta
if tempdir16max = 15 then tempx = tempx - temp71percentdelta : tempy = tempy - temp71percentdelta
if tempdir16max = 16 then tempx = tempx - temp38percentdelta : tempy = tempy - temp92percentdelta
return

 

If you look at that you can see that at slow speed, the x,y deltas are REALLY rough. That is the best I could come up with at the time, because I just didn't have enough variables (and/or space) available to have 2 byte floats. When you're only using 2 cars you can do stuff like store the first byte in the player x coord and only need one variable, but you can't do that with 4 cars without using multisprite kernel, but you can't use paddles with multisprite, so...

 

If I had more variables, the x,y coord changes would definitely be smoother. For now, you have to drive fast as heck to get more realistic movement.

Link to comment
Share on other sites

0.7 contains radical changes and is a major step backwards in smoothness and gameplay, but radically different for steering (and saved some space). Direction is tied 1:1 to paddle (so you have to rotate it all the way back around after turning right too far) - this is just temporary to make it easier to drive and figure out the x, y deltas. Changed the way I was doing deltas. Unfortunately, it is pretty jumpy.

 

ultindy500_0.7.bas.binultindy500_0.7.bas

 

One kind of neat trick I used (not sure yet whether it is a good trick or not) is that since I didn't need the persistance of player0x, player0y, player1x, player1y (since I was storing those in car0x, car0y, etc.) I could use them as temp variables. :) I don't know whether it is affecting collision detection, but that is not a concern for now (until I get driving dynamics figured out).

Link to comment
Share on other sites

That would be awesome. It is really hard getting the right feel for it without having actually paddles. :(

 

Actually, if you use the mouse, Stella's paddle emulation is pretty accurate... you pretty much get the same "feel" as with the paddle controllers.. there really isn't that dramatic of a difference going from Stella mouse to a real Atari paddle controller...

 

Just letting you know my personal experience in testing your game... the mouse with Stella gives you a pretty good feel as to what the game will be like in real life. :)

 

I'll give your new version a go on the supercharger and let you know what I find! :)

 

Thanks,

 

Mike

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...