mirror of
https://github.com/ZDoom/Raze.git
synced 2025-06-02 10:11:04 +00:00
- Floatify chase cam code, providing an inline interface for legacy setup.
This commit is contained in:
parent
977d8f8109
commit
056bb9b0cd
2 changed files with 45 additions and 48 deletions
|
@ -252,11 +252,21 @@ inline constexpr int getincangle(unsigned a, unsigned na)
|
|||
}
|
||||
|
||||
|
||||
extern int cameradist, cameraclock;
|
||||
extern double cameradist, cameraclock;
|
||||
|
||||
void loaddefinitionsfile(const char* fn, bool cumulative = false, bool maingrp = false);
|
||||
|
||||
bool calcChaseCamPos(int* px, int* py, int* pz, DCoreActor* pspr, sectortype** psectnum, DAngle ang, fixedhoriz horiz, double const smoothratio);
|
||||
bool calcChaseCamPos(DVector3& ppos, DCoreActor* pspr, sectortype** psectnum, DAngle ang, fixedhoriz horiz, double const smoothratio);
|
||||
|
||||
inline bool calcChaseCamPos(int* px, int* py, int* pz, DCoreActor* pspr, sectortype** psectnum, DAngle ang, fixedhoriz horiz, double const smoothratio)
|
||||
{
|
||||
auto pos = DVector3((*px) * inttoworld, (*py) * inttoworld, (*pz) * zinttoworld);
|
||||
auto res = calcChaseCamPos(pos, pspr, psectnum, ang, horiz, smoothratio);
|
||||
(*px) = pos.X * worldtoint;
|
||||
(*py) = pos.Y * worldtoint;
|
||||
(*pz) = pos.Z * zworldtoint;
|
||||
return res;
|
||||
}
|
||||
|
||||
void PlanesAtPoint(const sectortype* sec, float dax, float day, float* ceilz, float* florz);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue