| 1605 | } |
| 1606 | |
| 1607 | void UpdateMikePos(const ItemInfo& item) |
| 1608 | { |
| 1609 | if (Camera.mikeAtLara) |
| 1610 | { |
| 1611 | Camera.mikePos = item.Pose.Position; |
| 1612 | Camera.actualAngle = item.Pose.Orientation.y; |
| 1613 | |
| 1614 | if (item.IsLara()) |
| 1615 | { |
| 1616 | const auto& player = GetLaraInfo(item); |
| 1617 | Camera.actualAngle += player.ExtraHeadRot.y + player.ExtraTorsoRot.y; |
| 1618 | } |
| 1619 | } |
| 1620 | else |
| 1621 | { |
| 1622 | int phdPerspective = g_Configuration.ScreenWidth / 2 * phd_cos(CurrentFOV / 2) / phd_sin(CurrentFOV / 2); |
| 1623 | |
| 1624 | Camera.actualAngle = phd_atan(Camera.target.z - Camera.pos.z, Camera.target.x - Camera.pos.x); |
| 1625 | Camera.mikePos.x = Camera.pos.x + phdPerspective * phd_sin(Camera.actualAngle); |
| 1626 | Camera.mikePos.z = Camera.pos.z + phdPerspective * phd_cos(Camera.actualAngle); |
| 1627 | Camera.mikePos.y = Camera.pos.y; |
| 1628 | } |
| 1629 | } |
| 1630 | |
| 1631 | void RumbleScreen() |
| 1632 | { |
no test coverage detected