File information

Last updated

Original upload

Created by

mutsisOnLihava

Uploaded by

mutsisOnLihava

Virus scan

Safe to use

Tags for this mod

About this mod

The cherry on top of the cake called "IronSight (1st person gun FOV fix)" that WickedHorseman cooked and also not forgetting the "Custom First Person FOV" made by vStar925. Now the RDR2 first person gameplay is decent with these adjustments!

Check the pictures to see how the changes look for some weapons, that treatment is done for all

Requirements
Permissions and credits
Changelogs
Features
1.) ADS-aim mode for all story mode weapons is alinged, including Navy revolver.

2.) Non-ADS-aim mode(You know when you point your gun forward in first person without looking done the sight) for all story mode weapons is alinged, including Navy revolver. Meaning, you can believe that where your gun is pointing is where your bullets will fly.

3.) Changed the Vertical FOV to 57 while ADS-aiming with rifles or repeaters. (You are probably more familier with horizontal FOV, because that is what most games use, but rdr2 uses Vertical FOV value. In Horizontal FOV terms the ADS-aim FOV is 88. over 90 Horizontal FOV causes fish eye lens effect, at least on 16:9 monitors, and PERSONALLY yyYY i dont like fish eye lens effect.)

4.) For everything else the VerticalFOV is approximatly 59(in Horizontal FOV terms its just under 90 FOV). everything else being walking, gambling, non-ads-aim, etc...

5.) The weapons are alinged in a way, such that there should be no clipping for any weapon.

6.) The aiming with bow in first person is alinged.

7.) restored non-ads-hip-aim for rifles and repeaters(yes, this is a trade-off with the current way the fps-camera works in this game. Either you don't have non-ads-hip-aim for rifles and repeaters in firstperson, while having ads-aim when having a scope on a rifle or a repeater, OR you have non-ads-hip-aim in firstperson for rifles and repeaters, but don't have ads-aim when having a scope on a rifle or repeater.)

8.) Alinged for Improved sights and basic sights.



Pre-requisites(Mods you need for this)
1.) IronSight (1st person gun FOV fix)
2.) Custom First Person FOV
3.) Pre-requisites, that are needed for the Ironsight and Custom First Person FOV mods.

Okey just a note here, these files that i uploaded are just modified files that are in the Ironsight mod and in the Custom First Person FOV mod. I just tweaked the values in those files so that the first person aiming is correct and finally good. So if you happen to have issues with those mods you have to direct those issues to the respective mod authors, i am not able to help with those problems and issues regarding those mods. If you wish to make your own changes to the codefiles i wrote my notes that i made for myself during the tweaking process at the bottom of this page, you can use those as a resource if you decide to do your own tweaking. I am not planning to make further changes to these files. And as final thing if you happen to use my notes as a resource, then dont ask me what everything means, i am not planning to spend more time with this and also i am not planning to teach those notes in detail, with all do respect. If you are not sure what something does, then make a backup of that thing you are not sure about, make a change to the thing you are not sure about, see what happens, document it, understand it and apply what you just learned when needed. What i am saying is test things out and see what happens :D, atleast when it comes to this(if you plan to do your own tweaks). This preaching is not supposed to be as harsh as it might seem ':D.   

Installation
0.) Install the pre-requisites
1.) Download the folder i have uploaded
2.) Extract the folder i have uploaded
3.) drop the lml folder from the extracted folder into your rdr2 game folder(where RDR2.exe is located).
4.) Ready to play



How it was done

Well...
1.) I used a photo i found in google image search for how it looks when sight is alinged in irl as a reference.

2.) For every weapon ADS i tweaked the values so long that it was good and correct.(meaning: change value, open game, aim gun, close game, change value, open game....).

3.) After that it was time to aling the non-ads-hip-aim. For that i used a hammer, to see how it looks if you are just pointing your handgun(yes it looked very weird) for reference, and for the reference to see how it approximatly looks when pointing a rifle/repeater/shotgun from hip i used a floor lamp(it looked more weird, but when engineering you have to use every available legal resource that you have at hand to produce the best practically attainable quality, and i dont happen to own pistols or rifles in my house).

4.) Then i used some perspective geometry, analytical geometry and desmos to derive line equations from points on xy-plane for the alingment process.(trying to reason 3D-space on a 2D-plane is very fun, trust me ;)). Jokes aside i really actually enjoy pondering and doing math & also applying math, but exhaustion from mental labor sucks).

5.) Then i adjusted all the values for non-ads-hip-aim till those were good and correct.(open game, non-ads-hip-aim gun,take screenshot, put screenshot in desmos, place line-points to correct position relative to the gun in the screenshot, make adjustments, open game, non-ads-hip-aim gun....)

6.) When those were done, i did final testing and inspection.

7.) After 8 days it was good & complete, and then i rested(i slept between project days, trust me).

8.) Then i played the game, and had to figure something else to do.



Credits

- Credit for WickedHorseman, for building the "IronSight (1st person gun FOV fix)" mod.
- Credit for vStar925, for building the "Custom First Person FOV" mod.
- Credit for the7nightmare in the "No aiming zoom" mods comment sections page 2 for the values of bow aiming.
- Credit for Rockstar for the game -_-(but please next time GET YOU FIRST PERSON ADS RIGHT GODDAMMET!)

What i did was just configure and tweak the values for the aiming and change the fov, but it was made on top of the work of the above people. Somebody makes something, somebody improves it and somebody improves that improved and....  The continuum of engineering.

I would like to have credit for the tweaks i made. I don't want credit for the mods the above people have made, just for the tweaks and alingments i made.



Points of further improvement for the next person on the line

1.) When aiming a bow on horseback in first person, the bow aim is not fixed(it aims a bit wonky, i did nothing for this).

2.) If you have scope on rifle or repeater and you do non-ads-hip-aim, the scope is kind of on the way(I noticed this after a while of playing, its nothing serious. You see in this game the non-ads-hip-aim orientation of the weapon is the same if you have scope or don't have scope. And on top of that Arthur seems to be right-handed, meaning he holds the gun like right handed, and if you orient the gun to non-ads-hip-aim from the left, hes hands get bit twisted, so i just let it be).

Somebody with actual software engineering experience and all that could try to make a mod, such that there would be different non-ads-hip-aim configuration for when you have a scope on the weapon, and when you don't have a scope on the weapon. This could potentially allow for the co-existence of non-ads-hip-aim without scope and ads aim with scope, for the rifles and repeaters. But for now no such thing exists.



My notes(as they are given, edited version for this page)


Lets assume that we have values for weapon xyz-position,  weapon xyz-rotation and for camera FOV for some given state with the given weapon.
In the firstperson.meta file at line 1528 a concrete example is this. Found in the folders of IronSight mod

                <Item key="WEAPON_SHOTGUN_PUMP" type="CWeaponAnimations">
                    <FPSCameraOffsets>
                        <Item>
                            <FOV value="57.0"/>
                            <Translation x="-0.085" y="0.080" z="0.00"/>
                            <Rotation x="-2.165" y="4.000" z="-2.105"/>
                            <WeaponActionIndex>FPCO_WEAPON_AIM</WeaponActionIndex>
                        </Item>


1.) Item key tells us that what weapon is in question, in this specific case its the "Pump_shotgun".

2.) WeaponActionIndex tells us that what state is in question, in this case "FPCO_WEAPON_AIM" is the state, and this specific state is "non-ads-hip-aim mode"

3.) Values of interest are between <Item> and </Item>

4.) FOV value is VERTICAL FOV(i talked about vertical and horizontal fov earlier on in this post). In this case "FOV value = "57.0" means "the vertical FOV value when non-ads-hip-aiming is 57".

CALCULATOR for converting between vertical FOV and horizontal FOV -> https://themetalmuncher.github.io/fov-calc/ . That link is from the "Custom first person FOV" mod's readme file.

5.) Translation values MOVE the weapon up-down(z value), sideways left-right(x value) and closer-farther(y value). MOVE meaning the WHOLE weapon moves on the screen.

6.) Rotation values ROTATE the weapon upwards-downwards(x rotate value), sideways left to right(z rotate value) and around its self leftwards and rightwards(y-value). for x-rotate and z-rotate the weapon does not rotate around its middle point, but around the end of the weapons stock. Yes it is what it sounds, go test out. 

Clarification on "around its self" -> If you stand up and spin around yourself, you are rotating around yourself. You can spin to leftwards or rightwards around yourself. Now replace "yourself" with the weapon in this thought experiment, and instead of standing up, the weapon is laying in Arthur's hands. Now you should get what "around its self rotating" means.  If not, then test it out(i will stop repeating this, but take this "test it out" advice as default for the rest of notes)

When talking about x value, y value and z value it means xyz cartesian coordinate values. in practice, try to imagine that the weapon moves alongside these xyz axises, when changing translation. AND the gun rotates around these axises, if rotate values are changed, SUCH THAT for leftright rotation and updown rotation, the point that we are rotating around is at the end of the guns stock, and in this three dimensional space the stock is at origo. ORIGO being the point (0,0,0). If you want to delve deeper into this math use keywords "Analytical Geometry", "Calculus" and "Linear algebra". Learning "Set theory" and "Mathematical proofs" are very usefull to understand and know when it comes to learning math in general, but this is starting to diverge from the main point of these notes for rdr2 modding, so i'll just say that if you wish to delve deeper into this math, you gotta continue that journey on your own from here. Now back to modding.
Link here -> Cartesian coordinate system
And link here -> Three dimensional space




EXACT BEHAVIOURS OF THE TRANSLATION VALUES

Positive change in x translation value => Gun moves Right
Negative change in x-translation value => Gun moves Left

Positive change in z translation value => Gun moves up
Negative change in z translation value => Gun moves down

Positive change in y translation value => Gun moves Closer
Negative change in y translation value => Gun moves away

Now an important word on the amount of value change, when it comes to Translation values. Change of 0.1 for translations is noticable. and for finegrain tuning for translations i used  0.00015.




EXACT BEHAVIOURS OF THE ROTATION VALUES

Positive change in x rotate value => Gun rotates upwards
Negative change in x rotate value => Gun rotates downwards

Positive change in z rotate value => Gun rotates leftwards
Negative change in z rotate value => Gun rotates rightwards

Positive change in y rotate value => Gun rotates around itself rightwards
Negative change in y rotate value => Gun rotates around itself leftwards

FOR rotation values, a value change of 0.5 is very noticable. I used 0.150 for bigger change and for finegraintuning i used 0.025 or 0.050




EXACT BEHAVIOUR OF FOV

Positive change in FOV value => More staff in the view
Negative change in z rotate value => Less staff in the view

Too low fov value causes the feeling of being crammed and zoomed in, too high fov value causes fishEyeLens effect and quake style movement.




EXACT BEHAVIOUR OF WEIGHT CONSTRAINT

Positive change in WeightConstraint value => The gun sways less in hands
Negative change in z rotate value => The gun sways more in hands.

Okey another important note, first of all weapon constraint max value is 1, that means there is no "weapon sway" at all, basically Arthur the iron hand. Lowest value is 0, meaning the gun goes all around the screen. But there is a devil in the details, because "weapon sway" is actually == "How much the weapon is constraint to the defined coordinates of translation and rotate", so the less weapon constraint you put, the more the weapon actually can be offset from the defined coordinates. In short, this can cause great amount of pain, because the offset is not static, its sort of dynamic depending on "is arthur looking upward", "is arthur looking downward", "is arthur courching", "is arthur standing on a slope", "has arthur forgot to file hes taxes". How i thought of it when i did adjustments = "If weapon constraintWeight is for example 0.95, it mean that the weapon can be off from the defined coordinates in a random direction and rotation by 5% at all times". Interesting is that when the constraintWeight is lowered too much, the weapon points rightwards when aiming up and leftwards when aiming down. The value i set is a non-painfull solution. But you are free to change it of course, just remember to adjust all your rotate values and translation values for that weapon, if you change weaponConstraint value.  




EXACT BEHAVIOUR OF ANIMATION BLEND TIMES

Okey here me out, i am not totally sure that the logic is the following for BlendTimes, because i did not do much testing on these. I just set good values and checked that everything works and then moved on. If you want to change animation blend time values, you should verify this blend time value change logic by testing.

Positive change in BlendTime value => Slower change from one animation state to another animation state
Negative change in BlendTime value => Faster change from one animation state to another animation state

I think it was 0.2 value change for BlendTimes that was noticable. But as i said for BlendTimes, this BlendTime thing should be tested for more accurate data and conclusions.




ALL THE ABOVE VALUES CAN BE FOUND IN THE FOLLOWING FILES.

lml/WickedHorseMan/Gameplay/IronSight/firstperson.meta
lml/WickedHorseMan/Gameplay/IronSight/DLCs/(any folder in the DLCs folder, check em out)

firstperson.meta constains configuration code lines for the story weapons.
Subfolders of "DLCs" folder contain files that also contain configuration code lines, evans repeater was in there i believe, and the online guns also.

For opening and editing these files i used Visual Studio 2022. It's in essence a code editor and Software development tool. For "how to install it" search for tutorial in internet(Youtube or Google). Teaching how to install visual studio is out of my scope.

OKEY so the configuration codelines for story weapons are between line 1295 and 1595 in firstperson.meta file.
The configuration code for starting bow starts at line 544 in that same file.
Improved bow is after starting bow in the file.
Then there is "generic 2h" and "generic 1h". Those Generic values are in action, if nothing else is specifically configured for that state. 2h for two-handed weapons and 1h for one handed weapons.
After checking firstperson.meta file and fiddling around you will now know what to look for in the files in the DLCs folder's sub-folders.

FPCO_WEAPON_AIM = "Hip-non-ads-aim"
FPCO_GUN_IRON_SIGHT = "Iron-sight-aim"

I have not looked that closer into the other states.




AND NOW THE OTHER FOV VALUES IN THE "Custom First Person FOV " mod.(non-aiming FOV values)

I am getting bit tired so ill keep this short and concise.

If you change FOV values in the "Ironsight" mod's files, then you want to adjust other fovs in the "Custom First Person FOV" mod, if you don't, you will get missmatched fov for aiming and other activities. 

So the correct file is in the folder lml\Custom First Person FOV\data
and in there the file is called cameras.ymt

1.) When open that cameras.ymt file you want to use search feature of visual studio.
2.) Shortcut key combo for using search feature is Control + f
3.) In the search box put this following variable name without the parentheses (0x1F1D79FF)

4.) Now you find something like this

      <UNK_MEMBER_0x1F1D79FF value="71.00000000"/>

The "71.00000000"
is what we want to change. And there are many instances of 0x1F1D79FF , you can navigate over them by clicking the search box with left mouse click and pressing enter. That is how i do it. Now back to editing, you want to change every value of all instances of 0x1F1D79FF.

Change to what? well, if you increased the fov in the ironsight mod then you have to increase it also here in Custom First Person FOV mod. How i did it was to first change in ironsight mod the aiming fov, then go to Custom First Person FOV mod's cameras.ymt and increase, or decrease it by 1 or 2 till ingame just standing fov matched my aiming fov, then i decreased the aiming fov in ironsight mod for rifles and repeaters by 2 or 3 to mimic "leaning in"  when aiming. The value "71.00000000" can be thought of as magic number. It configures FOV in someway, but it is not one to one with actual fov value. So the following was a basic rule for me -> if gun "zooms in" when aiming, then decrease the magic number in cameras.ymt by 1 or 2, and if camera "zooms out", then increase magic number in cameras.ymt by 1 or 2. WHEN no "zoom in" and "zoom out" happens when aiming in game, then the magic number is correct. 

In short, treat the "Fov value" in the Ironsight mod as actual Vertical FOV value, and the value of 0x1F1D79FF in the Custom First Person FOV mod's camera.ymt as magic value. Values in Custom First Person FOV mod define other fovs BUT NOT AIMING, and "Fov values" in Ironsight mod's files define AIMING FOV, FOR BOTH ADS AIM AND NOT-ADS-AIM-FROM-HIP.

That is pretty much it. I'll now pack the changes i made and upload them here. Have fun and i hope the game is abit better again. Sry for typos if there are any, i wrote this on one sitting.