mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-12-09 13:07:42 +00:00
Fix CScriptSound favoring the right speaker, cleanup CBallCamera, update amuse
This commit is contained in:
@@ -13,11 +13,12 @@ void CCameraSpline::CalculateKnots(TUniqueId cameraId, const std::vector<SConnec
|
||||
const SConnection* lastConn = nullptr;
|
||||
|
||||
for (const SConnection& conn : connections) {
|
||||
if (conn.x0_state == EScriptObjectState::CameraPath && conn.x4_msg == EScriptObjectMessage::Follow)
|
||||
if (conn.x0_state == EScriptObjectState::CameraPath && conn.x4_msg == EScriptObjectMessage::Follow) {
|
||||
lastConn = &conn;
|
||||
}
|
||||
}
|
||||
|
||||
if (lastConn) {
|
||||
if (lastConn != nullptr) {
|
||||
TCastToConstPtr<CScriptCameraWaypoint> waypoint = mgr.ObjectById(mgr.GetIdForScript(lastConn->x8_objId));
|
||||
x14_wpTracker.clear();
|
||||
x14_wpTracker.reserve(4);
|
||||
@@ -93,7 +94,7 @@ float CCameraSpline::GetKnotT(size_t idx) const {
|
||||
float CCameraSpline::CalculateSplineLength() {
|
||||
float ret = 0.f;
|
||||
x24_t.clear();
|
||||
if (x4_positions.size() > 0) {
|
||||
if (!x4_positions.empty()) {
|
||||
zeus::CVector3f prevPoint = x4_positions[0];
|
||||
float tDiv = 1.f / float(x4_positions.size() - 1);
|
||||
for (size_t i = 0; i < x4_positions.size(); ++i) {
|
||||
|
||||
Reference in New Issue
Block a user