Skip to main content

Questions tagged [orbit]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer
37 views

2D orbit an orbiting body without ellipse

I have a monster (boss) that spawns a minion (m1) which orbits the boss. m1 can spawn its own minion (m2) which orbits m1. This creates a situation where m2 is orbiting m1 and m1 is orbiting the boss. ...
gabriel__'s user avatar
1 vote
1 answer
630 views

Orbit and control distance from object in 3D

I'm stumped on a key part of my game project, built in Godot 3.5.2. I'm trying to have my player character be able to rotate around an object using A and D, as well as get closer and farther from it ...
sungen's user avatar
  • 13
0 votes
0 answers
77 views

How to predict future position of body in solar system?

I have a solar system where each body interacts with each other by force F = Gm1m2/R^2 Is it possible to predict future position of some random body after t seconds since bodies velocity and position ...
Robotex's user avatar
  • 251
0 votes
1 answer
80 views

Unity3D: Firing a projectile from orbit

I am dropping bombs from a spaceship orbiting a planet. My camera is affixed to the ship. I fire bombs by instantiating a bomb at the position of the camera, which is at all times facing toward the ...
Truth's user avatar
  • 135
0 votes
0 answers
116 views

Simple Orbital transfer and intercept equation

I'm working on a game which has a game board made up of objects orbiting the center of the board. You can think of it as our solar system, but greatly simplified in terms of physics. All objects ...
bazcat's user avatar
  • 1
0 votes
0 answers
63 views

Logic behind a cubic reflection

I'm creating a cube in WebGL made of mirros that have to reflect the object inside of it. At the moment I'm stuck because I don't understand the correct logic to implement to achieve the result. I ...
keepyourweb's user avatar
0 votes
1 answer
2k views

360 Orbital Camera Controller

I have a stationary cube in my scene that I'm orbiting a camera around. I have my MainCamera nested under a GameObject that I'm calling 'OrbitalCamera'. I setup the script so that a click (or tap) ...
brandoncluff's user avatar
3 votes
1 answer
206 views

Smoothly moving an orbiting object back into orbit

I have an object that orbits the player's sprite with code that looks like this: ...
dinorider's user avatar
1 vote
1 answer
324 views

Direction between objects (shortest distance around sphere)

I have two objects rotating around a sphere. One is controlled by the user (object A), another is simulating a user but controlled by the computer (object B). At random intervals of time I'd like ...
DRiFTy's user avatar
  • 586
1 vote
1 answer
2k views

How to Find Collision Reflection Vector on a Sphere

I have a game I'm building in Unity with some objects orbiting a sphere via rotating around a pivot point (0,0,0) at a radius of 10 units on the z-axis. The orbiting objects all have the same velocity....
DRiFTy's user avatar
  • 586
0 votes
1 answer
301 views

How to achieve an orbit-adjustable rotation?

Here's a script: ...
Jacob's user avatar
  • 2,552
1 vote
2 answers
443 views

How do I make planet move slower the further away they are? [duplicate]

I got this code from somewhere else, I want to implement Kepler's third law to make the simulation look more realistic, the simulation is a 2D satellite orbiting around a planet, the satellite(Planet) ...
Lendrit Ibrahimi's user avatar
2 votes
2 answers
236 views

How can I make a spaceship auto level while in orbit?

I’m trying to make a ship auto level so that the belly of the ship stays facing the planet. I found the answer in 2.5D*, but I can’t get it to work in 3D. ...
Xorange's user avatar
  • 21
1 vote
2 answers
139 views

Detecting collisions between orbiting objects in 2D

I am currently in the process of creating a 2D space debris simulation. I have the orbital physics implemented, but I am currently struggling to find a suitable way of detecting collisions. There are ...
Dinsorsoos's user avatar
0 votes
1 answer
121 views

XNA - 2D camera orbit around sprite

OK, I have a 2d sprite in a scene and I would like to know the theory behind the camera orbiting around it with an analog stick. I know the basic code to get the input from the gamepad, but I'm having ...
user92008's user avatar
0 votes
1 answer
833 views

Unity Controller to Make Reticle Orbit based on the right stick input

d platformer arena like game. Right now I have it so a reticle moves around the player based on a controller's right stick's horizontal movement using the rotate around function and while it works ...
Green Bray Games LLC's user avatar
2 votes
2 answers
713 views

How to rotate actors around the actor like a satellite around the earth?

I'm not a pro in LibGDX and physics but I know basics, vectors, actor's actions and so. I'm trying to achieve a movement like on the gif below: For now, let's say that I have a stage and a central ...
Jacob's user avatar
  • 2,552
1 vote
0 answers
82 views

My orbit code produces the wrong results

I have a GameObject called "Sun" in the sky. A game object called "GameManager" keeps track of time in the game, it is responsible for updating the hours and days. For my sun I do something like this ...
Keeko's user avatar
  • 27
2 votes
1 answer
3k views

How to avoid gimbal lock in Unreal Engine (c++)?

I created an orbit camera (sometimes called turntable camera; similar to the one with the "use UE3 orbit controls" setting in a static mesh view). I attached the camera to a ...
arthur.sw's user avatar
  • 291
1 vote
2 answers
58 views

Manual orbit motion jerks at a certain point

So I've been trying to make a simple sphere-orbiting-another-sphere test. The smaller sphere is supposed to circle the bigger one based on the mouse location. Here is my code: ...
oldredbyte's user avatar
4 votes
3 answers
228 views

Computing a full revolution for an arbitrary orbit?

I'm making a game in which the goal is to get as many planets as possible to orbit around a star. The user launches planets at any distance away from the sun (as long as it's on-screen), and in any ...
JesseTG's user avatar
  • 1,077
1 vote
2 answers
1k views

Object orbiting a 3d sphere

I'm developing in libgdx java/android but not using any high-level environment like Unity. I have a sphere at [0,0,0], with a PerspectiveCamera looking at it. Through the main game loop I have ...
Jammo's user avatar
  • 113
7 votes
2 answers
2k views

Orbital mechanics: orbit as a function of time. Universal variable formulation?

I am trying to model a two dimensional orbit for a two body Kepler problem but have gotten stuck when introducing the time variable. For a satellite with known semi major axis (a), eccentricity (e), ...
imnegan's user avatar
  • 73
2 votes
0 answers
54 views

2D orbital mechanics [duplicate]

I'm working on a 2D game which involves firing projectiles around a solar system and having the path of the projectile change based on the gravitational pull of solar bodies. I've been trying to find ...
Nairou's user avatar
  • 604
3 votes
1 answer
729 views

GameMaker: Studio - Slow down calculations

I currently have an orbital simulator, with a brilliant answer in another Game Development question here, and would like to know how to slow down the calculations of Game Maker, to be able to do more ...
user avatar
0 votes
2 answers
3k views

How does orbital math work?

I'm writing a 2d space game, and I want the players to be able to 'orbit' objects and other players (if they're fast enough, of course), but I'm having trouble coming up with the right way to think ...
Silas Snider's user avatar
6 votes
1 answer
871 views

Orbits: Combine the Pros of RK4, Symplectic Euler, and Verlet Velocity Integrator

Recently, I've implemented and compared a number of basic integrators for my physics engine. The 3 that gave me the best results are RK4, Symplectic Euler, and Verlet Velocity, but I think I need ...
MindSeeker's user avatar
5 votes
1 answer
1k views

Non linear scaling to show a sol system

In a sol system 2d simulation I have some problems in showing the entire system (ie: eaven planets far away than saturn ) letting distinguibles the nearest planet orbits. Actualy a use a simple ...
dnk drone.vs.drones's user avatar
1 vote
0 answers
426 views

Calculating orbital elements from Cartesian Vectors

I'm having serious troubles with getting my calculations to work. I'm calculating the orbital elements from a position vector, and a velocity vector. (I also know the distance and mass of the bodies ...
Jacob Morris's user avatar
2 votes
0 answers
626 views

Calculate Orbit Path/Ellipse given mass, velocity, and distance (2body)

Calculate and draw the path of an orbit in a 2 body problem given the mass, current velocity, and distance of both bodies? We're working in Unity and will be using the default rigidbody.mass to start ...
Thundax's user avatar
  • 31
2 votes
1 answer
2k views

What is wrong with my 2D orbit calculation?

I am working on a 2D game, and I am working on adding some space physics, so I need to find a way to create a circular orbit. I want to make my game object move on a circular way around a planet. I'm ...
DeltaWeb's user avatar
  • 121
2 votes
2 answers
1k views

How do I keep my orbiting camera upright?

I am working on code that rotates the camera around a point on the in-game map when dragging the mouse. I understand how to lock it so it stays above the map surface. However, if I keep rotating the ...
themackyo's user avatar
3 votes
3 answers
6k views

How can I implement simple object orbits in Game Maker?

I've seen a lot of tutorials for things like "fixed circular orbit" and "elliptical orbits" which end up never been what I actually want. I have two objects: ...
user avatar
1 vote
1 answer
693 views

How can make an object orbit a sphere in a random direction?

How can I move an object on a random orbital path around a sphere? I've created some objects at an initial position that is essentially a random point on the sphere offset by some distance (say, 10.0)...
lacas's user avatar
  • 346
-1 votes
1 answer
343 views

Homeworld style orbital camera concept [closed]

So I spent some time thinking of how I'm going to make a camera similar to what's used in Homeworld (a 3D space RTS, in which your camera can be rotated around your units to look at them from any ...
Stuyvenstein's user avatar
1 vote
2 answers
532 views

How can I compute the orbit of one body around another?

I'm attempting to have a planet (with a known mass and radius) orbit it's sun (also with a known mass and radius). It doesn't have to be 100% realistic, but it should be possible that the sun have ...
terrorcell's user avatar
0 votes
1 answer
1k views

XNA Zoom in/out on model instead of scaling the model

I'm trying to implement zoom in/out functionality into my game. I can change the cameraDistance value with the Z and X keys. Instead of zooming, it looks like the model is scaled smaller or larger (...
Maarten Hartman's user avatar
6 votes
4 answers
36k views

Unity3D Orbit around orbiting object (transform.RotateAround)

The best way to explain this is I'm attempting to make a small model solar system (not to scale or anything complicated, just simple rotation as a learning exercise). There's a sun, a planet, and that ...
Niko's user avatar
  • 185
0 votes
1 answer
167 views

Computing orbit direction depending on angle of approach

I'm trying to develop a simple 2D space game with no friction using corona-sdk. In the game, I have several planets which all applies forces to the player according to Newton's law of universal ...
slavikos's user avatar
9 votes
3 answers
1k views

Avoiding orbiting in pursuit steering behavior

I have a missile that does pursuit behavior to track (and try and impact) its (stationary) target. It works fine as long as you are not strafing when you launch the missile. If you are strafing, the ...
bobobobo's user avatar
  • 17.1k
2 votes
2 answers
2k views

adapting a Unity gravitational script to allow moons

I'm using this script: http://wiki.unity3d.com/index.php/Simple_planetary_orbits to get a solar system going in Unity, but it doesn't seem to support creating bodies that orbit other moving bodies (...
PartyMix's user avatar
4 votes
2 answers
1k views

how to calculate intersection time and place of multiple moving arcs

I have rocks orbiting moons, moons orbiting planets, planets orbiting suns, and suns orbiting black holes, and the current system could have many many layers of orbitage. the position of any object ...
user20733's user avatar
  • 149
8 votes
2 answers
2k views

Elliptical orbit modeling

I'm playing with orbits in a simple 2-d game where a ship flies around in space and is attracted to massive things. The ship's velocity is stored in a vector and acceleration is applied to it every ...
Nathon's user avatar
  • 265
4 votes
1 answer
7k views

Orbiting a specific point - Orbiting Camera

How would I create a camera that with the mouse, it allows you to orbit around a specifc position, with the camera always facing that point? I would also like it to be able to always be at a constant ...
Darestium's user avatar
  • 1,154