Topic awaiting preservation: FINALLY started controlling my movements with vectors (Page 2 of 2) |
|
---|---|
Lunatic (VI) Mad Scientist From: Massachusetts, USA |
posted 10-10-2002 19:56
> In reality the acceleration is based on one over the cube of the distance. code: lengthtosun = Math.sqrt((distancetosunX*distancetosunX) + (distancetosunY*distancetosunY));
code: lengthtosun_squared = (distancetosunX*distancetosunX) + (distancetosunY*distancetosunY);
|
Nervous Wreck (II) Inmate From: uk |
posted 10-10-2002 21:57
Wow this is fantastic stiuff. I love the demos.. |
Paranoid (IV) Mad Scientist From: Somewhere over the rainbow |
posted 10-10-2002 23:26
The poster has demanded we remove all his contributions, less he takes legal action. |
Bipolar (III) Inmate From: |
posted 10-10-2002 23:57
Slime. |
Paranoid (IV) Mad Scientist From: Somewhere over the rainbow |
posted 10-11-2002 00:03
The poster has demanded we remove all his contributions, less he takes legal action. |
Maniac (V) Lord Mad Scientist Sovereign of all the lands Ozone and just beyond that little green line over there... From: Stockholm, Sweden |
posted 10-11-2002 00:06
Wow, that worked perfectly! It's still kind of slow when you go crazy on the planets, especially when you add too many suns. Check it out with 99, http://www.bigbonfire.com/bugs/?howMany=99 - or add in a new number if it works for you. You can also add the control ?howFast=[x] where [x] is the refresh rate of the setInterval function. Thanks for the help, this is going to end up as a short sweet neat function, I love it! |
Bipolar (III) Inmate From: |
posted 10-11-2002 01:46
Hi Ini, |
Lunatic (VI) Mad Scientist From: Massachusetts, USA |
posted 10-11-2002 02:47
Yes, that part is right, you can cancel out the m's. (It's interesting to realize that this means that the mass of the object being pulled has no effect on how fast it accelerates.) |
Paranoid (IV) Mad Scientist From: Somewhere over the rainbow |
posted 10-11-2002 07:59
The poster has demanded we remove all his contributions, less he takes legal action. |
Bipolar (III) Inmate From: |
posted 10-11-2002 08:51
Hi Slime, quote:
|
Maniac (V) Lord Mad Scientist Sovereign of all the lands Ozone and just beyond that little green line over there... From: Stockholm, Sweden |
posted 10-11-2002 21:13
Yah, the problem with squaring the value there is that the movement, it scarcely happens at all! Whereas now, it at least appears to be somewhat proper to the eye. I'm already using this... |
Paranoid (IV) Mad Scientist From: Somewhere over the rainbow |
posted 10-11-2002 21:22
The poster has demanded we remove all his contributions, less he takes legal action. |
Paranoid (IV) Mad Scientist From: Omicron Persei 8 |
posted 10-13-2002 20:16
well doc, are you doing this game for fun or is this another strange job? |
Maniac (V) Lord Mad Scientist Sovereign of all the lands Ozone and just beyond that little green line over there... From: Stockholm, Sweden |
posted 10-14-2002 07:55
Nah, just goofing around, avoiding work, heh. I was thinking it could end up as some kind of cool space game maybe? I could set up a map of stars throught the "galaxy", I'd just have to make sure that I didn't bother calculating stars too far away otherwise the cpu-burn would be heavy. Then I guess, well, you could fly around and maybe.. shoot stuff? Or something. |
Maniac (V) Mad Scientist From: New California |
posted 10-14-2002 10:21
Space War was one of my favorite arcade games "back in the day". |
Maniac (V) Lord Mad Scientist Sovereign of all the lands Ozone and just beyond that little green line over there... From: Stockholm, Sweden |
posted 10-14-2002 19:20
Hah! Bugs, I was wondering when someone would bring up that game, I loved playing that! I was thinking maybe something that'd give me that same thrill, but with an endlessly generating universe. Even if you just "flew" around, picture the thrill as you have to slingshot past a black hole, virtually! Add in a whole mess of stuff you need to shoot along the way, well, that's game enough for me! Heck, maybe I'd even add in scoring as a perk. ;-) |
Paranoid (IV) Mad Scientist From: Somewhere over the rainbow |
posted 10-14-2002 22:14
The poster has demanded we remove all his contributions, less he takes legal action. |
Bipolar (III) Inmate From: |
posted 10-18-2002 06:13
Hey Doc, |
Paranoid (IV) Mad Scientist From: Somewhere over the rainbow |
posted 10-18-2002 09:15
The poster has demanded we remove all his contributions, less he takes legal action. |
Maniac (V) Lord Mad Scientist Sovereign of all the lands Ozone and just beyond that little green line over there... From: Stockholm, Sweden |
posted 10-18-2002 11:21
Actually, I'm building at a different address now, I've been having too many problems with the bigbonfire.com domain. Look now at http://ozoniclabs.com/gravlabs/ - I hope it'll remain here for now. (Last night I had a dream about building this into a spherical, or possibly toroidal world, something you could circumnavigate. You could fly around the screen, or if you got closer to the edge, the background would scroll and you'd see new stars. Hitting planets would be bad, crash! Hitting a star would be nearly impossible, unless it was a black hole. I could set up "fuel depots" around the landscape, each with it's own gravity. (Circle it, press a key, and then land, they'll fill you up.) Run out of fuel? Drift endlessly, eventually you'll end up sucked into the wormhole at the end, or crash into a planet or black hole. Somehow you'd have to fly around and pick up [something worth points] finishing up your foray by crashing into a wormhole, leading to the next level. Levels could be generated from a data file, so this opens the possiblilty of level designers. |
Paranoid (IV) Mad Scientist From: Somewhere over the rainbow |
posted 10-18-2002 15:02
The poster has demanded we remove all his contributions, less he takes legal action. |
Paranoid (IV) Mad Scientist From: Somewhere over the rainbow |
posted 10-20-2002 11:33
The poster has demanded we remove all his contributions, less he takes legal action. |
« Previous Page — 1 [2]