Exopandora / ShoulderSurfing

Shoulder Surfing Reloaded is a highly configurable third person camera mod for minecraft.
MIT License
48 stars 9 forks source link

Additional feature request for [camera.offset.multiplier] #194

Closed Tapacywka closed 1 month ago

Tapacywka commented 1 month ago

There are currently 2 multipliers available:

I propose to add a new type of multiplier:

The camera is shifted to the specified XYZ coordinates during aiming with bow, crossbow, trident and other items that have RMB action (for example, staffs from RPG Series mods). Below I'll show screenshots of what it should look like (roughly).

2024-05-19_00 54 04 2024-05-19_00 55 25 2024-05-19_00 56 32 2024-05-19_00 57 13

Exopandora commented 1 month ago

Thank you for the suggestion. This will be part of the next release, since it was very easy to implement. Note that this multiplier will be applied whenever the player is holding or using an adaptive item (as configured in the config file). If 0.0 is configured as the default camera offset for a given axis, the multiplier of that axis will have no effect, as it is a multiplier. As a workaround, you could configure a very low value, for example 0.01, and a very large multiplier, for example 75, so that the resulting value (0.01 * 75 = 0.75 [blocks]) will have a suitable order of magnitude.

Tapacywka commented 1 month ago

Thank you for the suggestion. This will be part of the next release, since it was very easy to implement. Note that this multiplier will be applied whenever the player is holding or using an adaptive item (as configured in the config file). If 0.0 is configured as the default camera offset for a given axis, the multiplier of that axis will have no effect, as it is a multiplier. As a workaround, you could configure a very low value, for example 0.01, and a very large multiplier, for example 75, so that the resulting value (0.01 * 75 = 0.75 [blocks]) will have a suitable order of magnitude.

Ooh, yeah. That's very smart. Thanks so much for your suggestion and for accepting mine! Could you please tell me if this works if I don't want my character to be transparent at 0.0 X position, but I want this feature to remain, for example, when I run under trees or something else is above me? Because now I turned off this option, because my character becomes transparent forever.

Exopandora commented 1 month ago

Could you please tell me if this works if I don't want my character to be transparent at 0.0 X position, but I want this feature to remain, for example, when I run under trees or something else is above me? Because now I turned off this option, because my character becomes transparent forever.

Unfortunately, this is not possible, as the transparency is directly dependant on the distance between the crosshair and the center of the player.

Tapacywka commented 1 month ago

Unfortunately, this is not possible, as the transparency is directly dependant on the distance between the crosshair and the center of the player.

By the way, while the update with this isAiming feature is not out yet, will you be able to make a smooth transition between offsets? As far as I understand, you can't make a transition between first-person and third-person camera, but here only the third-person camera changes position. So, theoretically, it is possible?

Exopandora commented 1 month ago

By the way, while the update with this isAiming feature is not out yet, will you be able to make a smooth transition between offsets? As far as I understand, you can't make a transition between first-person and third-person camera, but here only the third-person camera changes position. So, theoretically, it is possible?

Offset changes within the shoulder surfing perspective use interpolation. See existing offset multipliers or ladder centering.