X-Git-Url: https://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fworld%2FBody.hpp;h=1e32e6d020a41d71392d4f7ce68865aba6d96aaf;hb=HEAD;hp=d90806584b0e43d37f1202d0dcddce7e8afe3d23;hpb=3989da924c4e33c52f500aead5ae62bb40294781;p=blobs.git diff --git a/src/world/Body.hpp b/src/world/Body.hpp index d908065..1e32e6d 100644 --- a/src/world/Body.hpp +++ b/src/world/Body.hpp @@ -61,9 +61,6 @@ public: Orbit &GetOrbit() noexcept { return orbit; } const Orbit &GetOrbit() const noexcept { return orbit; } - const glm::dvec2 &SurfaceTilt() const noexcept { return surface_tilt; } - void SurfaceTilt(const glm::dvec2 &t) noexcept { surface_tilt = t; } - const glm::dvec2 &AxialTilt() const noexcept { return axis_tilt; } void AxialTilt(const glm::dvec2 &t) noexcept { axis_tilt = t; } @@ -78,6 +75,10 @@ public: double GravitationalParameter() const noexcept; double OrbitalPeriod() const noexcept; double RotationalPeriod() const noexcept; + /// day length relative to parent, not neccessarily a sun + /// gives absolute value in seconds + /// returns sidereal day for parent-less bodies + double DayLength() const noexcept; double SphereOfInfluence() const noexcept; math::Sphere CollisionBounds() const noexcept { return math::Sphere{ glm::dvec3(0.0), Radius() }; } @@ -119,7 +120,6 @@ private: double mass; double radius; Orbit orbit; - glm::dvec2 surface_tilt; glm::dvec2 axis_tilt; double rotation; double angular;