Fallout 4
0 of 0

File information

Last updated

Original upload

Created by

BLUESHADOW2020

Uploaded by

BLUESHADOW2020

Virus scan

Safe to use

About this mod

Enables all scopes to have a variable zoom level! Controlled with the mouse wheel even! Or a controller! Should work for any weapon, even Modded.

Requirements
Permissions and credits
Changelogs
NOT DEAD - NEW VERSION 0.3

Fine Zoom adds the ability to dynamically zoom in and out with scopes.

When aiming with a gun in first person you can change the zoom level with either the scroll wheel, keyboard/mouse buttons or the DPad on a controller.

Details

  • REQUIRES F4SE
  • May break after updates, I will try to create a fix as soon as possible
  • Currently works for every gun, with scope choice options
  • If set, min and max zoom levels are relative to the equipped scope
  • Should work with just about any modded gun or scope, even See Through Scopes
  • MCM integration to allow changing of settings in the game, if NOT using MCM please see special instructions

Changing FOV
If you wish to change the FOV using commands as you can normally, you need to make sure to first switch to a different weapon and don't aim, else it probably won't work properly.

With Mod Manager

Installing with your favourite mod manager should be as simple as normal

Without Mod Manager


  • Download the mod files, and paste the folders into your Data folder inside your Fallout4 folder
  • Add FineZoom.esp to your load order, it changes nothing existing so the order shouldn't really matter

Change Settings Without MCM


If you wish to change the settings without using MCM, then you need to copy the file, from inside your Fallout4 folder Data\MCM\Config\FineZoom\settings.ini into Data\MCM\Settings and rename it to FineZoom.ini

TODO
  • Add custom scopes, so that the zoom function is only available on them, and thus bring some balance to this, with 'cheaty' version still available of course


Memory Address Finding Guide:

Spoiler:  
Show

This is a guide to finding the memory addresses needed for this mod to work, should I be unable or unwilling to update them myself.

You will need:
- Text editor
- A tool to find relative memory addresses, e.g. Cheat Engine (I will assume Cheat Engine for this guide)
- Time

First, find the version of the Fallout 4 runtime you want to use, can be found in the properties of the .exe, e.g. 1.10.138.0
Then create the file, located at: "Data\F4SE\Plugins\FineZoomMem\FineZoomMem_v[VERSION].ini" obviously substituting the version in place of the [VERSION],
so for version 1.10.138.0 you would get "Data\F4SE\Plugins\FineZoomMem\FineZoomMem_v1.10.138.0.ini"

If this file already exists, then there should already be memory addresses and so either you got the wrong version or I assume that you believe it to be invalid and so wish to replace it.


Second, launch the Fallout 4 version you wish to find the Memory addresses for, F4SE not required, nor any mods.
I recommend that you launch in windowed mode so that you can see both Cheat Engine and the game.
Then attach CheatEngine to the Fallout4 process, and in the game, load into a save where you have access to:


Thirdly, all the memory address we are looking for will be stack memory, meaning that in Cheat Engine they will show up as green, so you can ignore all the other grey ones.
Each time you find the correct memory address, add it to the list at the bottom, I recommend naming it the name of the memory address you are trying to find, and save this cheat table to a cumulative file so you don't loose anything if it crashes


Now you are ready to start hunting for memory addresses, each of which will get a section below.


Once you find all the memory address, what you now need to do is to open your saved cheat table in a text editor,
you will see a series of <CheatEntry></CheatEntry> entries, where the <Description> is the name and <Address> the address.
For each entry here, add the corresponding entry into the [...]Mem.ini file you created earlier under the [GENERAL] header, see provided versions for reference,
WHERE the name of the option is the name of the memory address you are trying to find (e.g. iBaseTPFOV) and the value is the address, taken from the <Address> field,
!!!
IMPORTANT: Take only the part after the + (e.g. 384E990 in <Address>Fallout4.exe+384E990</Address>) and this is in Hexadecimal (aka Base 16) and you need to convert it to decimal (aka Base 10), so 384E990 -> 59042192
I use windows calculator in Programmer mode, but use whatever tool you want
!!
Then once this is done for all memory addresses, it should be complete and you can test it, if it doesn't work then try make sure everything is correct.

Note About Version Check:
If the wrong version warning is getting annoying and you know that it works, you can rename the plugin file inside:
Data\F4SE\Plugins
FineZoom.dll -> _FineZoom.dll

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

[iBaseTPFOV] + [iBaseFPFOV] + [iCurrentFPTPFOV] + [iCurrentModelFOV] + [iIsProperFirstPerson]
These are not currently needed, as such I will not yet explain how to find them, I will if I ever need them

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

[iIsFirstPerson]
This is a 1 byte boolean which if 1, you are in first person, if 0, other such as third person

To Find:
Set the Value Type to Byte
Set the Scan Type to Exact
Set the Value to 1
Go into the game, enter first person
Go back to Cheat Engine and click first scan
 
Go back to game, enter third person        ] Repeat these steps
Go back to Cheat Engine and Set the Value to 0 and click next scan   ] until when you scroll to the bottom on memory addresses,
Go back to game, enter first person                 ] you see only 3 green (stack) addresses
Go back to cheat engine and Set the Value to 1 and click next scan    ] then:

Make sure in first person, then enter VATS, and exclude the option that goes to 0, now you should have only 2 green
then
Go into third person, then enter VATS, and exclude the option that goes to 1, now you should have only 1 green

This 1 remaining green (stack) variable is the iIsFirstPerson, so save it to the list

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

[iActiveBaseFOV] + [iBaseModelFOV] + [iCurrentFOVDelta] + [iTargetFOVDelta] + [iFOVAdjustSpeed]
iActiveBaseFOV: The currently active base FOV, so if in first person then the first person FOV, if in third person, then the Third person FOV
iBaseModelFOV: The model FOV when no zoom is applied, e.g. the FOV used for the pipboy and guns
iCurrentFOVDelta: The current delta added to iActiveBaseFOV to get the current FOV (iCurrentFPTPFOV) and added to iBaseModelFOV to get the current model FOV (iCurrentModelFOV)
iTargetFOVDelta: The value for iCurrentFOVDelta that the game is approaching, so it changes when you scope as it now targets a lower FOV
iFOVAdjustSpeed: The rate at which the game is making iCurrentFOVDelta approach iTargetFOVDelta

That is a lot of memory address to find, but luckily they are all contiguous in memory, probably from being stored adjacent in a struct or something, which means we only need to find 1
memory address and we get the rest. The easier to find is iActiveBaseFOV.


For iActiveBaseFOV:
Set Value Type to Float
Set Scan Type to Exact (leaving rounding at extreme)

Go into the game, using console commands set the fov as such:        ] Repeat these steps
fov A Bwhere A and B are your choosing in range (0,180)             ] Choosing different values for A and B
Then go into third person          ] Until when you scroll to the bottom on memory addresses,
Then in Cheat Engine set Value to that of A, then click next scan (first scan, if first time through)  ] you have 2 green (stack) addresses
Then go into first person   ] Then:
Then in Cheat Engine set Value to that of B, then click next scan ]

Scope with a gun and exclude the option which changes.

This leaves you with only one green (stack) memory address, which is that of iActiveBaseFOV


Then when you are saving these addresses to the file, after converting each offset to decimal (aka base 10),
the other memory addresses are found by adding to the iActiveBaseFOV value, so evaluate and use these:

iBaseModelFOV = iActiveBaseFOV + 4
iCurrentFOVDelta = iActiveBaseFOV + 8
iTargetFOVDelta = iActiveBaseFOV + 12
iFOVAdjustSpeed = iActiveBaseFOV + 16

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------


Credit for image: bl3azy