-
Notifications
You must be signed in to change notification settings - Fork 4
/
BetterScopes.h
49 lines (40 loc) · 1.11 KB
/
BetterScopes.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#pragma once
#include "f4se_common/Relocation.h"
#include "f4se/GameForms.h"
#include "f4se/GameReferences.h"
#include "f4se/GameObjects.h"
#include "f4se/NiNodes.h"
#include "f4se/PluginAPI.h" // SKSEInterface, PluginInfo
extern PluginHandle g_pluginHandle;
extern F4SEMessagingInterface* g_messaging;
namespace BetterScopes {
class Reticle {
public:
Reticle() : reticleNode(nullptr) {
rightEye = true;
};
Reticle(NiNode* a_node, NiNode* a_body) : reticleNode(a_node), body(a_body) {
rightEye = true;
};
void collimateSight();
void moveReticle();
private:
NiNode* reticleNode;
NiPoint3 eye2ret;
NiPoint3 ret2Barrel;
NiPoint3 offset;
bool rightEye;
NiNode* body;
NiTransform eye;
};
void startUp();
void update();
void setEquippedScopeZoom(const bool toggleZoom=false);
float getZoomMultiplier();
void keepScopeVisible();
void setZoomToggle(const bool value = true);
void repositionReticle(const float x, const float z, const float interval);
void saveReticlePreview();
void handleStaticGripping(NiNode* weaponNode);
void restoreWeaponNode(NiNode* weaponNode, NiTransform weapSave);
}