Skip to content
This repository has been archived by the owner on Apr 20, 2024. It is now read-only.

Commit

Permalink
Fix Bug
Browse files Browse the repository at this point in the history
Fix the issue where the FPSCamera does not automatically exit when the vehicle disappears (Asu4ni#54)
  • Loading branch information
will258012 committed Apr 4, 2024
1 parent 701f746 commit 4c0658e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion CSkyL
Submodule CSkyL updated 1 files
+3 −0 Game/Object/Vehicle.cs
9 changes: 9 additions & 0 deletions FPSCamera/Cam/VehicleCam.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,15 @@ public override bool Validate()
if (Config.G.StickToFrontVehicle &&
!_SwitchTarget(_target.GetFrontVehicleID())) return false;
}


if (!_target.IsSpawned) {
if (_target.IsExporting || _target.IsImporting) {
return _target.IsGoingBack;
}
return false;
}

return true;
}

Expand Down

0 comments on commit 4c0658e

Please sign in to comment.