Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / Angle adjusting to land

Author
Message
Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 24th Jul 2005 07:17
I just don't understand that Tank example.

How does it adjust the angle of the tank to the angle of the matrix?!

I like DB!
Metrion
19
Years of Service
User Offline
Joined: 8th Jul 2005
Location: In the darkest cave
Posted: 29th Jul 2005 17:52
Check out the Limit Rush tutorial on this website... one of them tells you how.

If practice makes perfect and nobody is perfect, then why practice?
Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 30th Jul 2005 09:28
Thanx!

Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 30th Jul 2005 10:16
Uh, where is the Limit Rush tutorial?

Robot
20
Years of Service
User Offline
Joined: 27th May 2004
Location:
Posted: 30th Jul 2005 12:24 Edited at: 30th Jul 2005 12:25
Try here
http://developer.thegamecreators.com/?f=t02/bm_tutorial_25

[Edit] Or here for the tilting bit
http://developer.thegamecreators.com/?f=t02/bm_tutorial_33

The happenings of tommorow are behind us now
Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 30th Jul 2005 19:29
Thank you sooooo much!

I'll finally be able to master this!

Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 30th Jul 2005 23:03
Okay, I got it to work in my game, but there is a problem:

When you go up a hill, the tank tilts down, and I think vice versa when you go downhill!

Heeeeeeeeeeeeeeeeeeelp!

blanky
20
Years of Service
User Offline
Joined: 3rd Aug 2004
Location: ./
Posted: 30th Jul 2005 23:22
Just reverse it, that's all. Swap the '+' and '-' signs around when you've got something like 'xrotate object 1, object angle x(1)-bleh'. Or something.

[Insert extremely witty comment here]
Metrion
19
Years of Service
User Offline
Joined: 8th Jul 2005
Location: In the darkest cave
Posted: 30th Jul 2005 23:22 Edited at: 30th Jul 2005 23:27
@Uncle Sam:

Um, sorry to be a bit rude, but I'm not sure if u even read the tutorial. You need to put in a bit more effort into solving problems. Please take the time to read over the tutorial carefully. It should be all you need.

Cheers,

Metrion

If practice makes perfect and nobody is perfect, then why practice?
Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 30th Jul 2005 23:30
Thank you all, I will try again.

Metrion
19
Years of Service
User Offline
Joined: 8th Jul 2005
Location: In the darkest cave
Posted: 30th Jul 2005 23:49
That's good. If you need any more help, just ask

If practice makes perfect and nobody is perfect, then why practice?
Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 30th Jul 2005 23:57
Will do.

Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 1st Aug 2005 04:22
I need help, I can't figure it out!

BearCDPOLD
21
Years of Service
User Offline
Joined: 16th Oct 2003
Location: AZ,USA
Posted: 2nd Aug 2005 02:51
Use a text file to hold the level info. Here's an example->

Format:
Keyword "new" designates new object to keep track of. Once "new " (with space) is parsed, the next word after a space is parsed as one of the following:
object
matrix
enemy
spawn

There will be a sequence of values following each new declaration, defining the various attributes for each object. These are typically the ID number, x position, y position, z position, x angle, y angle, and z angle in that order. Though there are special cases, such as matrices where normal object transformation procedures do not apply.




I'm going to eat you!
master programmer
19
Years of Service
User Offline
Joined: 30th May 2005
Location: 3D Space
Posted: 2nd Aug 2005 04:42
It does the angle by getting the y axis of the matrix using the get ground height


----------------------
Vote for Excelsis on the Puzzle Game Compo

__________________________________________
<<<<<Check out my sites>>>>>
www.rhettgames.tk | www.slayerbattletanks.tk
Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 2nd Aug 2005 04:44
Ok, I didn't really understand either of your posts, at all!

--------------
Uncle Sam
master programmer
19
Years of Service
User Offline
Joined: 30th May 2005
Location: 3D Space
Posted: 2nd Aug 2005 04:54
The y axis, in simple terms, up and down. It gets the height of the ground by using the get height command. This gets the height of the floor matrix. Using that, you can determine the height of the objects on the screen. Thus, moving around easily and fluently. If you can' understand that, go to CodeBase, or just start over.

I don't know what to tell you, I don't know the get height command off the top of my head, so you'll have to do some fishing through the books.

__________________________________________
<<<<<Check out my sites>>>>>
www.rhettgames.tk | www.slayerbattletanks.tk
Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 2nd Aug 2005 05:26 Edited at: 2nd Aug 2005 08:44
I understand that, it just for some reason doesn't adjust the angle of the tank (actually, now a motorcycle ) properly.

I'm not talking about height.

--------------
Uncle Sam
master programmer
19
Years of Service
User Offline
Joined: 30th May 2005
Location: 3D Space
Posted: 2nd Aug 2005 05:50
So, the angle of the mountains and hills? Oh I see. Use something like this:

A collision detection that detects if their is collision between the motorcycle and the matrix. Then, increase the x or z axis angle by a specified amount, until there is no longer a collision, once you figure that out, it should work.

If you need more help on making that code, just post again, I'll be here to help.

-----------------
Vote for Excelsis on the Puzzle Game Compo

__________________________________________
<<<<<Check out my sites>>>>>
www.rhettgames.tk | www.slayerbattletanks.tk
Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 2nd Aug 2005 05:55 Edited at: 2nd Aug 2005 08:44
Oh, I already did that with the help of the Limit Rush tutorial, but for some reason, it kind lifts up the back tire when going up hills, and vice versa going down.

I don't know what to do about it!

--------------
Uncle Sam
BearCDPOLD
21
Years of Service
User Offline
Joined: 16th Oct 2003
Location: AZ,USA
Posted: 2nd Aug 2005 07:23

My post went to the wrong thread, ignore it.


I'm going to eat you!
bibz1st
22
Years of Service
User Offline
Joined: 2nd Jan 2003
Location:
Posted: 2nd Aug 2005 12:29
try this link...
http://developer.thegamecreators.com/?m=codebase_view&i=b69c37441b1493b2329ec78280e16e05
master programmer
19
Years of Service
User Offline
Joined: 30th May 2005
Location: 3D Space
Posted: 2nd Aug 2005 22:23
If the back tire lifts, that probably means that the surface area of the angle of the matrix isn't large enough to fit the entire area of the tank/motorcycle. In which case, increase the surface area, and or, when you change the rotatation on the x or y axis, move the object forward a little bit so it doesn't hang over. Other than that, I think you'll just have to play with it for a while to get the desired effect.

----------------------
Vote for [b]Excelsis]/b] on the Puzzle Game Compo

__________________________________________
<<<<<Check out my sites>>>>>
www.rhettgames.tk | www.slayerbattletanks.tk
Uncle Sam
19
Years of Service
User Offline
Joined: 23rd Jul 2005
Location: West Coast, USA
Posted: 2nd Aug 2005 22:42
Thanx.

--------------
Uncle Sam

Login to post a reply

Server time is: 2025-05-22 13:16:50
Your offset time is: 2025-05-22 13:16:50