Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Update IDs. (#7) #16

Merged
merged 3 commits into from
May 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 36 additions & 26 deletions CommonLibF4/include/RE/Bethesda/Actor.h
Original file line number Diff line number Diff line change
Expand Up @@ -491,28 +491,28 @@ namespace RE
[[nodiscard]] TESAmmo* GetCurrentAmmo(BGSEquipIndex a_equipIndex) const
{
using func_t = decltype(&AIProcess::GetCurrentAmmo);
REL::Relocation<func_t> func{ REL::ID(1154936) };
REL::Relocation<func_t> func{ REL::ID(2232300) };
return func(this, a_equipIndex);
}

COMMAND_TYPE GetCommandType()
{
using func_t = decltype(&AIProcess::GetCommandType);
REL::Relocation<func_t> func{ REL::ID(678523) };
REL::Relocation<func_t> func{ REL::ID(2231825) };
return func(this);
}

[[nodiscard]] ObjectRefHandle GetOccupiedFurniture()
{
using func_t = decltype(&AIProcess::GetOccupiedFurniture);
REL::Relocation<func_t> func{ REL::ID(1162965) };
REL::Relocation<func_t> func{ REL::ID(2232401) };
return func(this);
}

bool IsWeaponSubgraphFinishedLoading(const Actor& a_actor)
{
using func_t = decltype(&AIProcess::IsWeaponSubgraphFinishedLoading);
REL::Relocation<func_t> func{ REL::ID(320183) };
REL::Relocation<func_t> func{ REL::ID(2231757) };
return func(this, a_actor);
}

Expand All @@ -531,7 +531,7 @@ namespace RE
bool ProcessGreet(Actor* a_actor, DIALOGUE_TYPE a_type, DIALOGUE_SUBTYPE a_subType, TESObjectREFR* a_target, BGSDialogueBranch* a_branch, bool a_forceSub, bool a_stop, bool a_que, bool a_sayCallback)
{
using func_t = decltype(&AIProcess::ProcessGreet);
REL::Relocation<func_t> func{ REL::ID(1174935) };
REL::Relocation<func_t> func{ REL::ID(2231808) };
return func(this, a_actor, a_type, a_subType, a_target, a_branch, a_forceSub, a_stop, a_que, a_sayCallback);
}

Expand All @@ -545,14 +545,14 @@ namespace RE
void SetActorsDetectionEvent(Actor* a_actor, const NiPoint3& a_location, std::int32_t a_soundLevel, TESObjectREFR* a_refr)
{
using func_t = decltype(&AIProcess::SetActorsDetectionEvent);
REL::Relocation<func_t> func{ REL::ID(1376336) };
REL::Relocation<func_t> func{ REL::ID(2231738) };
return func(this, a_actor, a_location, a_soundLevel, a_refr);
}

void SetCurrentAmmo(BGSEquipIndex a_equipIndex, TESAmmo* a_ammo)
{
using func_t = decltype(&AIProcess::SetCurrentAmmo);
REL::Relocation<func_t> func{ REL::ID(795983) };
REL::Relocation<func_t> func{ REL::ID(2232302) };
return func(this, a_equipIndex, a_ammo);
}

Expand Down Expand Up @@ -580,14 +580,14 @@ namespace RE
bool SetWeaponBonesCulled(const Actor& a_actor, bool a_stateToSet, WEAPON_CULL_TYPE a_weaponCullType)
{
using func_t = decltype(&AIProcess::SetWeaponBonesCulled);
REL::Relocation<func_t> func{ REL::ID(397172) };
REL::Relocation<func_t> func{ REL::ID(2232535) };
return func(this, a_actor, a_stateToSet, a_weaponCullType);
}

void StopCurrentIdle(Actor* a_actor, bool a_instant, bool a_killFlavor)
{
using func_t = decltype(&AIProcess::StopCurrentIdle);
REL::Relocation<func_t> func{ REL::ID(434460) };
REL::Relocation<func_t> func{ REL::ID(2231705) };
return func(this, a_actor, a_instant, a_killFlavor);
}

Expand Down Expand Up @@ -853,6 +853,16 @@ namespace RE
kUnderwater = 1 << 31,
};

enum class DETECTION_PRIORITY
{
kNone = 0,
kVeryLow = 1,
kLow = 2,
kNormal = 3,
kHigh = 4,
kCritical = 5,
};

// add
virtual void PlayPickUpSound(TESBoundObject* a_boundObj, bool a_pickUp, bool a_use); // 0C6
virtual float GetHeading() const { return data.angle.z; } // 0C7
Expand Down Expand Up @@ -974,21 +984,21 @@ namespace RE
bool CanUseIdle(TESIdleForm* a_idle) const
{
using func_t = decltype(&Actor::CanUseIdle);
REL::Relocation<func_t> func{ REL::ID(1223707) };
REL::Relocation<func_t> func{ REL::ID(2229592) };
return func(this, a_idle);
}

void ClearAttackStates()
{
using func_t = decltype(&Actor::ClearAttackStates);
REL::Relocation<func_t> func{ REL::ID(1525555) };
REL::Relocation<func_t> func{ REL::ID(2229773) };
return func(this);
}

void EndInterruptPackage(bool a_notRunOnceDialogue)
{
using func_t = decltype(&Actor::EndInterruptPackage);
REL::Relocation<func_t> func{ REL::ID(575188) };
REL::Relocation<func_t> func{ REL::ID(2229892) };
return func(this, a_notRunOnceDialogue);
}

Expand Down Expand Up @@ -1023,7 +1033,7 @@ namespace RE
TESCombatStyle* GetCombatStyle()
{
using func_t = decltype(&Actor::GetCombatStyle);
REL::Relocation<func_t> func{ REL::ID(1270929) };
REL::Relocation<func_t> func{ REL::ID(2231053) };
return func(this);
}

Expand All @@ -1049,7 +1059,7 @@ namespace RE
float GetDesiredSpeed()
{
using func_t = decltype(&Actor::GetDesiredSpeed);
REL::Relocation<func_t> func{ REL::ID(106892) };
REL::Relocation<func_t> func{ REL::ID(2230410) };
return func(this);
}

Expand All @@ -1063,14 +1073,14 @@ namespace RE
[[nodiscard]] ActorHandle GetMountHandle()
{
using func_t = decltype(&Actor::GetMountHandle);
REL::Relocation<func_t> func{ REL::ID(313362) };
REL::Relocation<func_t> func{ REL::ID(2231230) };
return func(this);
}

[[nodiscard]] std::int16_t GetLevel()
{
using func_t = decltype(&Actor::GetLevel);
REL::Relocation<func_t> func{ REL::ID(661617) };
REL::Relocation<func_t> func{ REL::ID(2229734) };
return func(this);
}

Expand All @@ -1079,28 +1089,28 @@ namespace RE
[[nodiscard]] std::uint8_t GetPerkRank(BGSPerk* a_perk)
{
using func_t = decltype(&Actor::GetPerkRank);
REL::Relocation<func_t> func{ REL::ID(1368313) };
REL::Relocation<func_t> func{ REL::ID(2230125) };
return func(this, a_perk);
}

void HandleDefaultAnimationSwitch()
{
using func_t = decltype(&Actor::HandleDefaultAnimationSwitch);
REL::Relocation<func_t> func{ REL::ID(1163130) };
REL::Relocation<func_t> func{ REL::ID(2229780) };
return func(this);
}

void HandleItemEquip(bool bCullBone)
{
using func_t = decltype(&Actor::HandleItemEquip);
REL::Relocation<func_t> func{ REL::ID(164912) };
REL::Relocation<func_t> func{ REL::ID(2229781) };
return func(this, bCullBone);
}

void InitiateDoNothingPackage()
{
using func_t = decltype(&Actor::InitiateDoNothingPackage);
REL::Relocation<func_t> func{ REL::ID(89993) };
REL::Relocation<func_t> func{ REL::ID(2229807) };
return func(this);
}

Expand Down Expand Up @@ -1198,21 +1208,21 @@ namespace RE
void SetGunState(GUN_STATE a_gunState, bool a_val = true)
{
using func_t = decltype(&Actor::SetGunState);
REL::Relocation<func_t> func{ REL::ID(977675) };
REL::Relocation<func_t> func{ REL::ID(2231175) };
return func(this, a_gunState, a_val);
}

void SetHeading(float a_angle)
{
using func_t = decltype(&Actor::SetHeading);
REL::Relocation<func_t> func{ REL::ID(353571) };
REL::Relocation<func_t> func{ REL::ID(2229625) };
return func(this, a_angle);
}

void TrespassAlarm(TESObjectREFR* a_refr, TESForm* a_owner, std::int32_t a_crime)
{
using func_t = decltype(&Actor::TrespassAlarm);
REL::Relocation<func_t> func{ REL::ID(1109888) };
REL::Relocation<func_t> func{ REL::ID(2229834) };
return func(this, a_refr, a_owner, a_crime);
}

Expand Down Expand Up @@ -1280,7 +1290,7 @@ namespace RE
public:
[[nodiscard]] static ActorEquipManager* GetSingleton()
{
REL::Relocation<ActorEquipManager**> singleton{ REL::ID(1174340) };
REL::Relocation<ActorEquipManager**> singleton{ REL::ID(2690994) };
return *singleton;
}

Expand All @@ -1297,7 +1307,7 @@ namespace RE
bool a_locked)
{
using func_t = decltype(&ActorEquipManager::EquipObject);
REL::Relocation<func_t> func{ REL::ID(988029) };
REL::Relocation<func_t> func{ REL::ID(2231392) };
return func(this, a_actor, a_object, a_stackID, a_number, a_slot, a_queueEquip, a_forceEquip, a_playSounds, a_applyNow, a_locked);
}

Expand All @@ -1314,7 +1324,7 @@ namespace RE
const BGSEquipSlot* a_slotBeingReplaced)
{
using func_t = decltype(&ActorEquipManager::UnequipObject);
REL::Relocation<func_t> func{ REL::ID(1292493) };
REL::Relocation<func_t> func{ REL::ID(2231395) };
return func(this, a_actor, a_object, a_number, a_slot, a_stackID, a_queueEquip, a_forceEquip, a_playSounds, a_applyNow, a_slotBeingReplaced);
}
};
Expand Down
2 changes: 1 addition & 1 deletion CommonLibF4/include/RE/Bethesda/BGSEntryPoint.h
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ namespace RE
inline void HandleEntryPoint(ENTRY_POINT a_entryPoint, Actor* a_perkOwner, Args... a_args)
{
using func_t = decltype(&BGSEntryPoint::HandleEntryPoint<Args...>);
REL::Relocation<func_t> func{ REL::ID(714336) };
REL::Relocation<func_t> func{ REL::ID(2206243) };
return func(a_entryPoint, a_perkOwner, a_args...);
}
}
Expand Down
4 changes: 2 additions & 2 deletions CommonLibF4/include/RE/Bethesda/BGSInventoryInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,14 @@ namespace RE

[[nodiscard]] static BGSInventoryInterface* GetSingleton()
{
REL::Relocation<BGSInventoryInterface**> singleton{ REL::ID(501899) };
REL::Relocation<BGSInventoryInterface**> singleton{ REL::ID(2689299) };
return *singleton;
}

[[nodiscard]] const BGSInventoryItem* RequestInventoryItem(const std::uint32_t& a_handleID) const
{
using func_t = decltype(&BGSInventoryInterface::RequestInventoryItem);
REL::Relocation<func_t> func{ REL::ID(1200959) };
REL::Relocation<func_t> func{ REL::ID(2194009) };
return func(this, a_handleID);
}

Expand Down
8 changes: 4 additions & 4 deletions CommonLibF4/include/RE/Bethesda/BGSInventoryItem.h
Original file line number Diff line number Diff line change
Expand Up @@ -148,21 +148,21 @@ namespace RE
[[nodiscard]] const char* GetDisplayFullName(std::uint32_t a_stackID)
{
using func_t = decltype(&BGSInventoryItem::GetDisplayFullName);
REL::Relocation<func_t> func{ REL::ID(277641) };
REL::Relocation<func_t> func{ REL::ID(2194079) };
return func(this, a_stackID);
}

[[nodiscard]] TBO_InstanceData* GetInstanceData(std::uint32_t a_stackID)
{
using func_t = decltype(&BGSInventoryItem::GetInstanceData);
REL::Relocation<func_t> func{ REL::ID(491493) };
REL::Relocation<func_t> func{ REL::ID(2194072) };
return func(this, a_stackID);
}

[[nodiscard]] std::int32_t GetInventoryValue(std::uint32_t a_stackID, bool a_scale) const
{
using func_t = decltype(&BGSInventoryItem::GetInventoryValue);
REL::Relocation<func_t> func{ REL::ID(430292) };
REL::Relocation<func_t> func{ REL::ID(2194099) };
return func(this, a_stackID, a_scale);
}

Expand All @@ -183,7 +183,7 @@ namespace RE
virtual void WriteDataImpl(TESBoundObject& a_baseObj, BGSInventoryItem::Stack& a_stack) override // 01
{
using func_t = decltype(&ApplyChangesFunctor::WriteDataImpl);
REL::Relocation<func_t> func{ REL::ID(1291190) };
REL::Relocation<func_t> func{ REL::ID(2223194) };
return func(this, a_baseObj, a_stack);
}

Expand Down
4 changes: 2 additions & 2 deletions CommonLibF4/include/RE/Bethesda/BGSStoryManagerTreeForm.h
Original file line number Diff line number Diff line change
Expand Up @@ -129,11 +129,11 @@ namespace RE
struct ListObjectivesAccess;
struct ListStagesAccess;

bool SetStage(std::uint16_t stage)
bool SetStage(std::uint16_t a_stage)
{
using func_t = decltype(&TESQuest::SetStage);
REL::Relocation<func_t> func{ REL::ID(2207743) };
return func(this, stage);
return func(this, a_stage);
}

BSPointerHandle<TESObjectREFR>* GetAliasedRef(BSPointerHandle<TESObjectREFR>* a_result, std::uint32_t a_aiAliasID)
Expand Down
2 changes: 1 addition & 1 deletion CommonLibF4/include/RE/Bethesda/BSHavok.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ namespace RE
static bool RemoveObjects(NiAVObject* a_object, bool a_recurse, bool a_force)
{
using func_t = decltype(&RemoveObjects);
REL::Relocation<func_t> func{ REL::ID(1514984) };
REL::Relocation<func_t> func{ REL::ID(2277721) };
return func(a_object, a_recurse, a_force);
}

Expand Down
2 changes: 1 addition & 1 deletion CommonLibF4/include/RE/Bethesda/BSTempEffect.h
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ namespace RE
bool isFirstPerson)
{
using func_t = BSTempEffectDebris* (*)(BSTempEffectDebris*, TESObjectCELL*, float, const char*, TESObjectREFR*, const NiPoint3&, const NiMatrix3&, const NiPoint3&, const NiPoint3&, float, bool, bool, bool);
REL::Relocation<func_t> func{ REL::ID(1075623) };
REL::Relocation<func_t> func{ REL::ID(2212059) };
func(this, a_parentCell, a_lifetime, a_fileName, a_sourceRef, a_position, a_rotation, a_startLinearVelocity, a_startAngularVelocity, a_scale, a_useCache, a_addDebrisCount, isFirstPerson);
}

Expand Down
2 changes: 1 addition & 1 deletion CommonLibF4/include/RE/Bethesda/BSTextureSet.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ namespace RE
static BSShaderTextureSet* CreateObject()
{
using func_t = decltype(&BSShaderTextureSet::CreateObject);
REL::Relocation<func_t> func{ REL::ID(993063) };
REL::Relocation<func_t> func{ REL::ID(2316324) };
return func();
}

Expand Down
4 changes: 2 additions & 2 deletions CommonLibF4/include/RE/Bethesda/BSTimer.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ namespace RE
public:
[[nodiscard]] static BSTimer GetSingleton()
{
REL::Relocation<BSTimer*> singleton{ REL::ID(1256126) };
REL::Relocation<BSTimer*> singleton{ REL::ID(2703179) };
return *singleton;
}

Expand All @@ -26,7 +26,7 @@ namespace RE
void SetGlobalTimeMultiplier(float a_mult, bool a_now)
{
using func_t = decltype(&BSTimer::SetGlobalTimeMultiplier);
REL::Relocation<func_t> func{ REL::ID(1419977) };
REL::Relocation<func_t> func{ REL::ID(2267970) };
return func(this, a_mult, a_now);
}

Expand Down
2 changes: 1 addition & 1 deletion CommonLibF4/include/RE/Bethesda/Calendar.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ namespace RE

[[nodiscard]] static Calendar* GetSingleton()
{
REL::Relocation<Calendar**> singleton{ REL::ID(1444952) };
REL::Relocation<Calendar**> singleton{ REL::ID(2689092) };
return *singleton;
}

Expand Down
6 changes: 3 additions & 3 deletions CommonLibF4/include/RE/Bethesda/GameScript.h
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ namespace RE
BSScript::ErrorLogger::Severity a_severity = BSScript::ErrorLogger::Severity::kError)
{
using func_t = decltype(&LogFormError);
REL::Relocation<func_t> func{ REL::ID(1081933) };
REL::Relocation<func_t> func{ REL::ID(2251028) };
return func(a_obj, a_error, a_vm, a_stackID, a_severity);
}

Expand Down Expand Up @@ -266,7 +266,7 @@ namespace RE
void GetInventoryObjFromHandle(std::uint64_t a_cobj, TESObjectREFR*& a_container, std::uint16_t& a_uniqueID, TESObjectREFR*& a_inWorldREFR)
{
using func_t = decltype(&HandlePolicy::GetInventoryObjFromHandle);
REL::Relocation<func_t> func{ REL::ID(66597) };
REL::Relocation<func_t> func{ REL::ID(2249989) };
return func(this, a_cobj, a_container, a_uniqueID, a_inWorldREFR);
}

Expand Down Expand Up @@ -503,7 +503,7 @@ namespace RE
bool QueuePostRenderCall(const BSTSmartPointer<GameScript::DelayFunctor>& a_functor)
{
using func_t = decltype(&GameVM::QueuePostRenderCall);
REL::Relocation<func_t> func{ REL::ID(34412) };
REL::Relocation<func_t> func{ REL::ID(2251314) };
return func(this, a_functor);
}

Expand Down
Loading
Loading