mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-18 11:19:10 +00:00
Some fixes from mingw.
This commit is contained in:
@ -132,7 +132,8 @@ fOffsetPct(1.0f)
|
||||
fPOAGoal.Set(0,0,0);
|
||||
fGoal.Set(1,1,1);
|
||||
fPOAOffset.Set(0,0,0);
|
||||
fTargetMatrix.Make(&fGoal, &fPOAGoal, &hsVector3(0,0,1));
|
||||
hsVector3 up(0, 0, 1);
|
||||
fTargetMatrix.Make(&fGoal, &fPOAGoal, &up);
|
||||
fFlags.Clear();
|
||||
}
|
||||
|
||||
@ -758,8 +759,8 @@ void plCameraBrain1_Drive::Pop()
|
||||
//
|
||||
void plCameraBrain1_Drive::Update(hsBool forced)
|
||||
{
|
||||
|
||||
fTargetMatrix.Make(&fGoal, &fPOAGoal, &(-1*fUp));
|
||||
hsVector3 neg_up = -1 * fUp;
|
||||
fTargetMatrix.Make(&fGoal, &fPOAGoal, &neg_up);
|
||||
|
||||
// update our desired position:
|
||||
double time = hsTimer::GetSeconds();
|
||||
@ -1628,14 +1629,15 @@ void plCameraBrain1_Circle::Update(hsBool forced)
|
||||
|
||||
fPOAGoal += fPOAOffset;
|
||||
|
||||
hsPoint3 goalpos = fCamera->GetTargetPos();
|
||||
if (HasFlag(kCutPosOnce))
|
||||
{
|
||||
fGoal = MoveTowardsFromGoal(&fCamera->GetTargetPos(), secs, true);
|
||||
fGoal = MoveTowardsFromGoal(&goalpos, secs, true);
|
||||
fFlags.ClearBit(kCutPos);
|
||||
}
|
||||
else
|
||||
{
|
||||
fGoal = MoveTowardsFromGoal(&fCamera->GetTargetPos(), secs);
|
||||
fGoal = MoveTowardsFromGoal(&goalpos, secs);
|
||||
fFlags.SetBit(kCutPos);
|
||||
}
|
||||
AdjustForInput(secs);
|
||||
|
@ -274,7 +274,8 @@ void plCameraModifier1::Update()
|
||||
// have to ask the avatar controller for the subworld key.
|
||||
if (!worldKey)
|
||||
{
|
||||
plArmatureMod* armMod = plAvatarMgr::FindAvatar(plKey(GetBrain()->GetSubject()->GetKey()));
|
||||
plKey subject = plKey(GetBrain()->GetSubject()->GetKey());
|
||||
plArmatureMod* armMod = plAvatarMgr::FindAvatar(subject);
|
||||
if (armMod && armMod->GetController() )
|
||||
worldKey = armMod->GetController()->GetSubworld();
|
||||
}
|
||||
@ -491,4 +492,4 @@ void plCameraModifier1::SetTransform(hsPoint3 at)
|
||||
l2w.Make(&fFrom, &at, &up);
|
||||
l2w.GetInverse(&w2l);
|
||||
IGetTargetCoordinateInterface(0)->SetTransform( l2w, w2l );
|
||||
}
|
||||
}
|
||||
|
@ -1980,9 +1980,15 @@ void plVirtualCam1::StartTransition(CamTrans* transition)
|
||||
hsVector3 dist;
|
||||
// figure out transition time
|
||||
if (transition->fCutPos)
|
||||
dist.Set(&(fTransitionCamera->GetTargetPOA() - pCam->GetTargetPOA()));
|
||||
{
|
||||
hsPoint3 poadist = fTransitionCamera->GetTargetPOA() - pCam->GetTargetPOA();
|
||||
dist.Set(&poadist);
|
||||
}
|
||||
else
|
||||
dist.Set(&(fTransitionCamera->GetTargetPos() - pCam->GetTargetPos()));
|
||||
{
|
||||
hsPoint3 posdist = fTransitionCamera->GetTargetPos() - pCam->GetTargetPos();
|
||||
dist.Set(&posdist);
|
||||
}
|
||||
|
||||
time = (double)(dist.Magnitude() / pBrain->GetVelocity());
|
||||
|
||||
|
Reference in New Issue
Block a user