I have replaced the FPS cam with a modified TPS camera.
Also has crosshair so you can actually hit enemies.
You can use the below sample to get started:
Sample mission:
OmerInverseTPS.zip (18.8 KB)
Same mission on the sandbox portal:
https://sandbox.enlisted.net/post/K2NmNNkYUE1fn9PB/
Video with TPS in action:
If you wish to edit the camera position (relative to the soldier’s head afaik) you need to edit tpscam.blk inside the cameras folder. Editing base_shooter_cam yields no changes, the camera specified in shooter_cam__blk:t="CAMERAPATH"
needs to be edited instead.
If you want to edit the default camera (when you are not zooming in, looking down sights) edit zoomedOut offset:
zoomedOut{
atPos:r=0.0
pivotPos:p3=0.35, 0.2, 0.07
offset:p3=0.37, 0.0, -0.66
fov:r=90.0
velTau:r=0.12
velFactor:r=0.1
tau:r=0.2
tmToAnimRatio:r=0.7
animTau:r=0.8
}
If you want to zoom into first person mode while aiming down sights, change this:
zoomedIn{
atPos:r=1.0
offset:p3=0.37, 0.0, -0.66
fov:r=90.0
velTau:r=0.0
velFactor:r=0.0
tau:r=0.0
}
to this:
zoomedIn{
atPos:r=1.0
offset:p3=0.0, 0.0, 0.0
fov:r=90.0
velTau:r=0.0
velFactor:r=0.0
tau:r=0.0
}
(offset is 0,0,0)
Note that changes to zoomedIn are only visible online, for some reason, in the editor, changing the zoomedIn in any way doesn’t show up. This is not true for zoomedOut.
It’s not perfect. Issues are:
- TPS also is applied when driving wheeled/regular vehicles like APCs, Trucks etc. Most of the time it works fine, but it has no constraints, so it can clip into the vehicle.
- You cannot use sniper rifles’s scopes.
- Crosshair is broken when running/sprinting.
- While can be enabled for tanks, the inner modules become visible, and TPS would need to be modded for every single tank seperately. (I have not looked into this much)
More
I also tried to enable the trajectory when throwing grenades, but they don’t seem to be working, even when enabled. But the entites for them still exist. I mean this: