Basic 3D Drone [DragonRuby]
A downloadable simulator
controls:
r, f, t, g - control the rotors
wasdqe - strafe the camera
[] - change field of view
spacebar - start / pause
enter - reset
is there a way to win? no. is this a game? no. it is just a tech demo.
using drgtk: https://dragonruby.itch.io/dragonruby-gtk
basic example of 3d rendering.
using just raw ruby, and the standard version of the engine.
obviously super unoptimized and inefficient, but we'll have to deal :/
this is using a basic pinhole projection model for the rendering.
the drone is modeled as four point masses at the positions of the rotors. each motor is 1kg, so the entire drone is 4kg. the rotors are also spinning by default, applying a force of ~8.8N, and when you engage a motor it instantly applies a force of ~10.8. i didn't simulate the rotors speeding up or anything.
things not simulated:
- collisions
- the torque in the yaw direction of the drone due to not all rotors spinning at same rate (this is why drones have an even number of rotors and why they rotate in different directions. it's also part of why helicopter stability is a difficult problem).
- wind
- a pretty environment
anyway. have fun. lmk if you have any qs. i can be found on the dragonruby discord as @kota : https://discord.com/channels/608064116111966245/608064116984250379
Status | Prototype |
Author | kotaonitch |
Genre | Simulation |
Tags | 3D, dragonruby, Physics |
Leave a comment
Log in with itch.io to leave a comment.