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 / best way of doing this

Author
Message
JoelJ
21
Years of Service
User Offline
Joined: 8th Sep 2003
Location: UTAH
Posted: 3rd Dec 2003 02:38
im starting to make it so if a matrix tile is under an explosion, it will go down a little.
i thought of putting it all in a for loop and check if each tile is within the area of the circle, then lower that tile a bit. i then i thought it would take WAY to much time. any suggestions?

=<=Pudgie Wars=>=
Game engine: 20% = Models: 25% = Textures: 1% = Sounds/Music: 0% = www.geocities.com/bigapple_entertainment
John H
Retired Moderator
22
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 3rd Dec 2003 03:03
Use maths to find the area covered by the circle, then use maths to find the area of each matrix tile and position of each matrix point then use maths once again to check if the points are in that circle then lower them

Weee maths

RPGamer


Dont forget to Join the Forums!
Jess T
Retired Moderator
21
Years of Service
User Offline
Joined: 20th Sep 2003
Location: Over There... Kablam!
Posted: 3rd Dec 2003 03:03
Yep, i know how

Get the x position of the explostion, then divide that by how many tiles you have accross the matrix, and that will give you the x tile number of the explosion.

Then do the same for the y position and you'll have the exact tile.

Then do whatever to it that you want to do..

Hope I Helped...


Team EOD :: Programmer/Logical Engineer/All-Round Nice Guy
John H
Retired Moderator
22
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 3rd Dec 2003 03:33
Lol me and JessTicular basically said the same thing


Dont forget to Join the Forums!
Jess T
Retired Moderator
21
Years of Service
User Offline
Joined: 20th Sep 2003
Location: Over There... Kablam!
Posted: 3rd Dec 2003 04:45
And at exactly the same time... lol




Team EOD :: Programmer/Logical Engineer/All-Round Nice Guy
JoelJ
21
Years of Service
User Offline
Joined: 8th Sep 2003
Location: UTAH
Posted: 4th Dec 2003 03:02
okay, thats weird, what are the chances...

anyways. thats what i figured, i just didnt know how to get the tilenumber. thanx RPG and Jess

=<=Pudgie Wars=>=
Game engine: 20% = Models: 25% = Textures: 1% = Sounds/Music: 0% = www.geocities.com/bigapple_entertainment

Login to post a reply

Server time is: 2025-05-22 07:02:49
Your offset time is: 2025-05-22 07:02:49