1980gamer Posted December 28, 2013 Share Posted December 28, 2013 Here is my second attempt at a racing game. This is early, as in, I started a hour ago. No collision detection or sound yet. Thus it runs way to fast for overdrive. Nothing to slow execution. Run in straight XB. Should I continue.... Ultimately, I'd like to do a full scrolling course. But I would need some major help! Be well, Gene RACING.zip 3 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/ Share on other sites More sharing options...
1980gamer Posted December 28, 2013 Author Share Posted December 28, 2013 Forgot.. Any key to begin Joystick left and right to turn the car. Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2894559 Share on other sites More sharing options...
1980gamer Posted December 30, 2013 Author Share Posted December 30, 2013 Here is a newer version. It now has a linear acceleration / Brakes If you change direction, you will skid until you normalize in the new direction. If you spin the car 180 degrees, it will take a few clicks to reverse direction. Braking will help this. The Q key or joystick button should be the brakes. No joystick to test this. You can play with the top speed and acceleration. I use 2 and 1 but you can increase these values. Speed should be greater than/equal to Acceleration. You can play with the settings. Gene RACING.txt 1 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2895722 Share on other sites More sharing options...
unhuman Posted December 31, 2013 Share Posted December 31, 2013 This is really nice. The power slide is really good. Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2895887 Share on other sites More sharing options...
1980gamer Posted December 31, 2013 Author Share Posted December 31, 2013 Thanks unhuman, That is the effect I was looking for. I like to let you play with the settings to see what happens. I would really like to add the pixel perfect sprite to background collision detection. Add a few check points, lap counter and timer. Of course... Sounds.. Engine, breaks and skidding.\ 2 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2895890 Share on other sites More sharing options...
RobertLM78 Posted December 31, 2013 Share Posted December 31, 2013 Off to Windows 7 for a few to make use of Paste XB in Classic99 for this - unfortunately, TEXTLOADER is giving me errors when I tried to use it earlier for the new version (It would be great to know what's going on with TEXTLOADER, seeing as I've used it many times now without much hassle.) Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2895923 Share on other sites More sharing options...
1980gamer Posted December 31, 2013 Author Share Posted December 31, 2013 The attached text file was generated with list "clip" then pasted into notepad. Save As xxx Attached. Nothing special... Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896027 Share on other sites More sharing options...
+Vorticon Posted December 31, 2013 Share Posted December 31, 2013 Looks very promising The car handling is great. I hope you will turn it into a full game! Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896283 Share on other sites More sharing options...
RobertLM78 Posted December 31, 2013 Share Posted December 31, 2013 (edited) Looks very promising The car handling is great. I hope you will turn it into a full game! It is pretty good with 2/2, but 2/1 is like driving on ice Edit: BTW - tried it out on the real iron last night (F18A enhanced) - looks great. I even tried to compile it using Harry's XB compiler, got no errors, but it still didn't run right . Edited December 31, 2013 by RobertLM78 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896290 Share on other sites More sharing options...
1980gamer Posted December 31, 2013 Author Share Posted December 31, 2013 It is pretty good with 2/2, but 2/1 is like driving on ice Edit: BTW - tried it out on the real iron last night (F18A enhanced) - looks great. I even tried to compile it using Harry's XB compiler, got no errors, but it still didn't run right . I was thinking of compiling at some point, but without sound etc. to slow things down... When you say it doesn't run right.. I am guessing the car turns way to fast to handle? I was planning to slow it down...By a factor of 10. ( for the compiled version ) but multiples are easy. I'll add variables that can be tested, to figure out a good turning speed setting. Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896297 Share on other sites More sharing options...
unhuman Posted December 31, 2013 Share Posted December 31, 2013 I remember asking Senior Falcon for timing functionality in the compiler, to make regulating game speed easier to plan and build. Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896300 Share on other sites More sharing options...
RobertLM78 Posted December 31, 2013 Share Posted December 31, 2013 I was thinking of compiling at some point, but without sound etc. to slow things down... When you say it doesn't run right.. I am guessing the car turns way to fast to handle? I was planning to slow it down...By a factor of 10. ( for the compiled version ) but multiples are easy. I'll add variables that can be tested, to figure out a good turning speed setting. Actually, the compiled version just gives me a green screen . I have probably done something wrong though, considering that nothing I've compiled so far seems to work - they all either give a green screen or just lock up the computer. Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896405 Share on other sites More sharing options...
senior_falcon Posted January 1, 2014 Share Posted January 1, 2014 Actually, the compiled version just gives me a green screen . I have probably done something wrong though, considering that nothing I've compiled so far seems to work - they all either give a green screen or just lock up the computer. Hi Robert: Why don't you post something you've compiled that doesn't run. I will take a look and find out why it is not working right. Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896910 Share on other sites More sharing options...
RobertLM78 Posted January 1, 2014 Share Posted January 1, 2014 Hi Robert: Why don't you post something you've compiled that doesn't run. I will take a look and find out why it is not working right. Heya Harry - Thanks for the aid - I've been pretty excited to see something compiled. In addition to RACING, I've tried these two XB programs without success: https://dl.dropboxusercontent.com/u/95921622/DECTOHEX-XBS https://dl.dropboxusercontent.com/u/95921622/HEXTODEC-XBS Like I said, I'm probably doing something wrong, or have over-looked some detail... Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896927 Share on other sites More sharing options...
senior_falcon Posted January 1, 2014 Share Posted January 1, 2014 I looked at the first program and found a couple of unsupported things: 390 ACCEPT AT(5,10)VALIDATE(DIGIT)BEEP SIZE(5):DEC From the manual: ACCEPT works almost exactly like it does in XB. AT, BEEP, ERASE ALL, SIZE and VALIDATE are all supported with one difference: VALIDATE requires that you provide the string expression. UALPHA, DIGIT, NUMERIC are not supported. So this line should be: 390 ACCEPT AT(5,10)VALIDATE("0123456789")BEEP SIZE(5):DEC and it should work. ------------------------------------------------------------------------------------ From the manual: IF-THEN-ELSE will only work with line numbers, like in TI BASIC. The more advanced XB style of IF-THEN-ELSE is not supported. Being able to use multiple statements in a line provides ways to partially work around this limitation:10 IF X>3 THEN Y=7::Z=19 can be changed to:10 IF X<=3 THEN 20::Y=7::Z=19 There are a lot of lines that use the XB style of IF-THEN-ELSE. For example: 510 IF DEC>=T(15)THEN BN15$="1" :: DEC=DEC-T(15)520 IF DEC>=T(14)THEN BN14$="1" :: DEC=DEC-T(14)530 IF DEC>=T(13)THEN BN13$="1" :: DEC=DEC-T(13) If you change all these to something like this then the program should work: 510 IF DEC<T(15)THEN 520::BN15$="1" :: DEC=DEC-T(15)520 IF DEC<T(14)THEN 530::BN14$="1" :: DEC=DEC-T(14)530 IF DEC<T(13)THEN 540::BN13$="1" :: DEC=DEC-T(13) The difference may seem subtle, but it is important! When using IF-THEN-ELSE think in TI BASIC and you'll be OK. ------------------------------- I'm not sure what happens with ON WARNING NEXT. I think it would be ignored, but that might have to go as well. --------------------------------------------------------------------- Right now that's all I can see. Doctor up the program and try again. If it doesn't work re post and I will take another look. FWIW, that program could be written four times smaller if you felt like taking that on as a challenge. Harry 1 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896945 Share on other sites More sharing options...
RobertLM78 Posted January 1, 2014 Share Posted January 1, 2014 I looked at the first program and found a couple of unsupported things: 390 ACCEPT AT(5,10)VALIDATE(DIGIT)BEEP SIZE(5):DEC From the manual: ACCEPT works almost exactly like it does in XB. AT, BEEP, ERASE ALL, SIZE and VALIDATE are all supported with one difference: VALIDATE requires that you provide the string expression. UALPHA, DIGIT, NUMERIC are not supported. So this line should be: 390 ACCEPT AT(5,10)VALIDATE("0123456789")BEEP SIZE(5):DEC and it should work. ------------------------------------------------------------------------------------ From the manual: IF-THEN-ELSE will only work with line numbers, like in TI BASIC. The more advanced XB style of IF-THEN-ELSE is not supported. Being able to use multiple statements in a line provides ways to partially work around this limitation: 10 IF X>3 THEN Y=7::Z=19 can be changed to: 10 IF X<=3 THEN 20::Y=7::Z=19 There are a lot of lines that use the XB style of IF-THEN-ELSE. For example: 510 IF DEC>=T(15)THEN BN15$="1" :: DEC=DEC-T(15) 520 IF DEC>=T(14)THEN BN14$="1" :: DEC=DEC-T(14) 530 IF DEC>=T(13)THEN BN13$="1" :: DEC=DEC-T(13) If you change all these to something like this then the program should work: 510 IF DEC<T(15)THEN 520::BN15$="1" :: DEC=DEC-T(15) 520 IF DEC<T(14)THEN 530::BN14$="1" :: DEC=DEC-T(14) 530 IF DEC<T(13)THEN 540::BN13$="1" :: DEC=DEC-T(13) The difference may seem subtle, but it is important! When using IF-THEN-ELSE think in TI BASIC and you'll be OK. ------------------------------- I'm not sure what happens with ON WARNING NEXT. I think it would be ignored, but that might have to go as well. --------------------------------------------------------------------- Right now that's all I can see. Doctor up the program and try again. If it doesn't work re post and I will take another look. FWIW, that program could be written four times smaller if you felt like taking that on as a challenge. Harry Awesome! I will make these changes and then try again - thank you Harry . I should have looked more closely at the program - of course it didn't help that I had forgotten about how the compiler handles IF-THEN-ELSE. Good advice to just think TI BASIC . It seems there's a certain style with which to approach a program that will be compiled - just takes some getting used to . Compiling these converters should speed them up significantly. Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2896973 Share on other sites More sharing options...
unhuman Posted January 2, 2014 Share Posted January 2, 2014 Harry - The IF THEN flow is a little bit confusing, but certainly seems to be an opportunity for a learning moment: 510 IF DEC<T(15)THEN 520::BN15$="1" :: DEC=DEC-T(15) Does the above line do DN15="1" and then DEC=DEC-T(15) and then fall through to line 520? If the line was changed to: 510 IF DEC<T(15)THEN 540::BN15$="1" :: DEC=DEC-T(15) Would this skip lines 520 and 530 but still process the DN15="1" and DEC=DEC-T(15) ? Thanks - Howie 1 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2897071 Share on other sites More sharing options...
senior_falcon Posted January 2, 2014 Share Posted January 2, 2014 Harry - The IF THEN flow is a little bit confusing, but certainly seems to be an opportunity for a learning moment: 510 IF DEC<T(15)THEN 520::BN15$="1" :: DEC=DEC-T(15) Does the above line do DN15="1" and then DEC=DEC-T(15) and then fall through to line 520? If the line was changed to: 510 IF DEC<T(15)THEN 540::BN15$="1" :: DEC=DEC-T(15) Would this skip lines 520 and 530 but still process the DN15="1" and DEC=DEC-T(15) ? Thanks - Howie The mods to the program should make it work just like it did originally. Consider the original line: 510 IF DEC>=T(15)THEN BN15$="1" :: DEC=DEC-T(15) If DEC is <T then it falls through to line 520. If DEC is > or = to T then BN15$ will = 1 and DEC will = DEC-T(15) and then it falls through to line 520. Now the modified line: 510 IF DEC<T(15)THEN 520::BN15$="1" :: DEC=DEC-T(15) If DEC is <T then the program is sent to line 520. If DEC is > or = to T then BN15$ will = 1 and DEC will = DEC-T(15) and then it falls through to line 520 as before. So the end result is the same. You can think of the double colons as additional line numbers something like this: 510 IF DEC<T(15)THEN 520 511 BN15$="1" 512 DEC=DEC-T(15) 520 more code... Of course, you cannot GOTO a double colon like you could GOTO 511 The original XB program could be tightened up (what program can't be improved) but that's a different subject. 1 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2897086 Share on other sites More sharing options...
unhuman Posted January 2, 2014 Share Posted January 2, 2014 Thanks for the explanation. I did miss the flipping of the >= to < Good to have that clarity now because it does indeed sound like it's a little bit different than the way XB handles IF THEN. Cool. Me likes. Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2897312 Share on other sites More sharing options...
1980gamer Posted January 4, 2014 Author Share Posted January 4, 2014 New updates. Added collision with walls. Still tweaking this a little. Added course selection. Many possibilities here. Course 1 and 3 are the first 2 courses. 2 and 4 are a little different but are holders for now. This work well with overdrive. 4 input values. I like 2,2,3, 1 or 3 no overdrive.. 2,2,10, 1 or 3. I have compiled, it works fine. I need to change the power slide / acceleration parameters. Compiled, it recovers toooo quickly. I can live with it. I have a bunch of ideas for this. Course designs are welcome!!! Do you like the thin line, or wider walls? The wider walls are truer representation of collision.... RC.txt 2 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2898682 Share on other sites More sharing options...
Bones-69 Posted January 5, 2014 Share Posted January 5, 2014 (edited) Hey - loving this. Good wholesome XB fun! I am fooling around with some stuff at the moment and the player action in mine is kind of similar to yours. I didn't use any CALL MOTION though and instead used CALL LOCATE which has its own execution speed challenges (running too fast!). I am using X / Y coordinates and trying to take advantage of the way the compiler forces integers. In other words - I update screen positions using CALL LOCATE (#1,Y/10,Y/10). The sprite position will not change unless there is a minimum increase/decrease of +/-10. This means I can add smaller amounts to the coordinates and slow things down by up to 10 times if needed. I guess I am just re-creating a decimal point which has one position....... I have attached my compiled version so you can see the effects. You might enjoy playing with the Custom Menu numbers by entering different values and seeing the speed change - there is some flexibility there to go very fast or very slow using this method and CALL LOCATE. If the XB listing is of interest I can post. There are no brakes in my controls. Left and right arrows change the direction you are facing and the up arrow pushes you in that direction, a little like Asteroids I guess.... I like that you can rotate while power sliding then hit the thrust to get going again! SLIDES-C.zip Edited January 5, 2014 by Bones-69 1 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2899090 Share on other sites More sharing options...
RobertLM78 Posted January 5, 2014 Share Posted January 5, 2014 New updates. Compiled this tonight - great fun! For the compiled version, a turning speed of 1 is almost too fast though . Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2899144 Share on other sites More sharing options...
1980gamer Posted January 10, 2014 Author Share Posted January 10, 2014 Here is a pretty good update. It's been a little while, I had some emulation issues... Anyway, This version let's you visually select tracks. Joy stick left/right to look at them, fire/Q to select. The tracks have check points now. If you miss a check point, the course will turn blue until you pass a valid check point again. I also count laps.. 5 laps complete the race. I also store best times per course. ( session only of course ) I have also added very fine tuning of he car's turning rate. I use 720 slices of a circle.. This lets you pick 1-90 for .5 to 45 degree turn rate. On the lap clock, for every tick, a turn tick occurs. so, selecting 1 would take 90 cycles to turn the car one position of the 8 possible directions. I would like to add car sounds... but I am not very good a sounds It would let me fine tune the power slide of the car. I don't want to put useless delays in...Sounds are better. Any engine sounds and skidding sounds are welcome! Good night. Gene zip contains XB and Compiled versions RCGL-C.zip 2 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2902850 Share on other sites More sharing options...
sometimes99er Posted January 10, 2014 Share Posted January 10, 2014 I tried the compiled version and used standard values. Nice interface. Used most of my time "stuck" outside the track. Yes, I can get "unstuck". Collision detection was not too good. Shows great potential. Keep at it. If you want I guess I could produce a small video with my comments. 1 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2903009 Share on other sites More sharing options...
+Vorticon Posted January 10, 2014 Share Posted January 10, 2014 (edited) Looking great so far! I love the ability to choose a track, and the layout of these tracks is very nicely thought out. I used to play Sprint 2 http://youtu.be/RuPEoLkVwtI at the arcades back in the early 80's for hours, and this project brought back a lot of good memories (and some frustration as well ). A few observations: Under plain XB without overdrive, the car does not respond well at all to the joystick. It worked fine with the first version of the game, so you must have changed your joystick polling timing since then. No issues with the compiled version. The car moves much slower when going up-down or right-left, and much faster diagonally. You might want to introduce a correction factor to the sprite speed for the orthogonal directions in order to even things out. A speed of 2, acceleration of 1 and turn rate of 15 seem to give the best results in the compiled version. Collision detection seems to work fine for me with the above settings, however I suggest reducing the "stuck" time at the track borders in order to enhance play. Also, I would add code to limit the sprite travel to the screen so as to avoid a fatal error and crash the program. Excellent work! I can't wait to see how this game develops If interested, I would be happy to design an algorithm for opponent cars AI since racing against oneself is not ideal Edited January 10, 2014 by Vorticon 1 Quote Link to comment https://forums.atariage.com/topic/220178-xb-racing/#findComment-2903056 Share on other sites More sharing options...
Recommended Posts
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.