Files
game-physics/Simulations/Spring.h
2023-10-31 00:37:29 +01:00

12 lines
181 B
C++

#pragma once
struct Spring
{
std::weak_ptr<MassPoint> mp1;
std::weak_ptr<MassPoint> mp2;
float initialLength;
bool isValid() { return !mp1.expired() && !mp2.expired(); }
};