mirror of
https://github.com/zeldaret/tww.git
synced 2026-08-15 12:39:11 -04:00
some actor documentation and cleanup
This commit is contained in:
@@ -363,9 +363,9 @@ bool cCcD_CpsAttr::GetNVec(const cXyz& vec, cXyz* dst) const {
|
||||
|
||||
cXyz pt;
|
||||
if (dot < 0.0f) {
|
||||
pt.set(*GetStartP());
|
||||
pt.set(GetStart());
|
||||
} else if (dot > 1.0f) {
|
||||
pt.set(*GetEndP());
|
||||
pt.set(GetEnd());
|
||||
} else {
|
||||
VECScale(&lin, &lin, dot);
|
||||
VECAdd(&lin, GetStartP(), &pt);
|
||||
|
||||
@@ -187,9 +187,7 @@ void cCcS::ChkCo() {
|
||||
continue;
|
||||
f32 cross_len = 0.0f;
|
||||
if (co1ShapeAttr->CrossCo(*co2ShapeAttr, &cross_len)) {
|
||||
cXyz& obj2CoCP = co2ShapeAttr->GetCoCP();
|
||||
cXyz& obj1CoCP = co1ShapeAttr->GetCoCP();
|
||||
SetCoCommonHitInf(*objCo1, &obj1CoCP, *objCo2, &obj2CoCP, cross_len);
|
||||
SetCoCommonHitInf(*objCo1, co1ShapeAttr->GetCoCP(), *objCo2, co2ShapeAttr->GetCoCP(), cross_len);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -220,7 +220,7 @@ bool cM3d_Cross_LinPla(const cM3dGLin* lin, const cM3dGPla* pla, Vec* dst, bool
|
||||
f32 startVal = pla->getPlaneFunc(lin->GetStartP());
|
||||
f32 endVal = pla->getPlaneFunc(lin->GetEndP());
|
||||
if (startVal * endVal > 0.0f) {
|
||||
*dst = *lin->GetEndP();
|
||||
*dst = lin->GetEnd();
|
||||
return false;
|
||||
} else {
|
||||
if (startVal >= 0.0f && endVal <= 0.0f) {
|
||||
@@ -232,7 +232,7 @@ bool cM3d_Cross_LinPla(const cM3dGLin* lin, const cM3dGPla* pla, Vec* dst, bool
|
||||
return cM3d_CrossInfLineVsInfPlane_proc(startVal, endVal, lin->GetStartP(), lin->GetEndP(), dst);
|
||||
}
|
||||
}
|
||||
*dst = *lin->GetEndP();
|
||||
*dst = lin->GetEnd();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user