Spellforce-Spell-framework
Loading...
Searching...
No Matches
sf_onhit_hook.c File Reference
#include "sf_onhit_hook.h"
Include dependency graph for sf_onhit_hook.c:

Go to the source code of this file.

Typedefs

typedef uint16_t(__thiscall * get_reduced_damage_ptr) (void *AutoClass34, uint16_t source_index, uint16_t target_index, uint16_t unkn)
typedef uint16_t(__thiscall * get_reduced_building_damage_ptr) (void *AutoClass32, uint16_t source_index, uint16_t target_index, uint16_t damage)
typedef uint16_t(__thiscall * get_hit_chance_ptr) (void *AutoClass34, uint16_t source_index, uint16_t target_index)
typedef void(__thiscall * FUN_006c3a60_ptr) (void *AutoClass30, uint16_t source_index, uint16_t target_index, uint8_t unkn, uint32_t unkn2)
typedef uint32_t(__thiscall * FUN_0071d7b0_ptr) (void *CGdObject, uint16_t object_index)
typedef uint32_t(__thiscall * FUN_00755180_ptr) (uint32_t param1)
typedef uint32_t(__thiscall * objectDealDamage_ptr) (void *CGdObjectToolBox, uint16_t source_index, uint16_t target_index, uint16_t damage, uint32_t unknown)
typedef uint32_t(__thiscall * getWeaponEffects_ptr) (void *CGdResource, uint32_t *param1, uint16_t weapon_id)

Functions

uint16_t __thiscall getCurrentDex (SF_CGdFigure *_this, uint16_t figure_index)
uint16_t __thiscall getCurrentInt (SF_CGdFigure *_this, uint16_t figure_index)
uint16_t get_effect_chance (uint16_t dex_val, uint16_t int_val, uint16_t spell_line)
void initialize_onhit_data_hooks ()
void __thiscall getTargetData (FigureJobData *_this, SF_CGdTargetData *target)
bool isJobDoNothing (uint16_t job_id)
bool __thiscall isFigureJobSpell (SF_CGdFigureJobs *_this, uint16_t figure_id)
bool __thiscall canJobBeInterrupted (FigureJobs job_id)
uint16_t __thiscall getAttackInterruptionChance (SF_CGdFigure *_this, uint16_t source_index, uint16_t target_index)
uint16_t __thiscall handle_riposte_set (SF_CGdFigureJobs *_this, uint16_t source_index, uint16_t target_index, uint16_t weapon_damage)
uint16_t __thiscall handle_berserk_set (SF_CGdFigureJobs *_this, uint16_t source_index, uint16_t target_index, uint16_t weapon_damage)
uint16_t __thiscall handle_trueshot_set (SF_CGdFigureJobs *_this, uint16_t source_index, uint16_t target_index, uint16_t weapon_damage)
void __thiscall sf_onhit_hook (SF_CGdFigureJobs *_this, uint16_t source_index, uint32_t param_2, uint8_t param_3)

Variables

get_reduced_damage_ptr g_get_reduced_damage
get_hit_chance_ptr g_get_hit_chance
FUN_006c3a60_ptr g_FUN_006c3a60
get_reduced_building_damage_ptr g_get_reduced_building_damage
FUN_0071d7b0_ptr g_FUN_0071d7b0
FUN_00755180_ptr g_FUN_00755180
objectDealDamage_ptr g_objectDealDamage
getWeaponEffects_ptr g_getWeaponEffects

Typedef Documentation

◆ FUN_006c3a60_ptr

typedef void(__thiscall * FUN_006c3a60_ptr) (void *AutoClass30, uint16_t source_index, uint16_t target_index, uint8_t unkn, uint32_t unkn2)

Definition at line 54 of file sf_onhit_hook.c.

◆ FUN_0071d7b0_ptr

typedef uint32_t(__thiscall * FUN_0071d7b0_ptr) (void *CGdObject, uint16_t object_index)

Definition at line 58 of file sf_onhit_hook.c.

◆ FUN_00755180_ptr

typedef uint32_t(__thiscall * FUN_00755180_ptr) (uint32_t param1)

Definition at line 60 of file sf_onhit_hook.c.

◆ get_hit_chance_ptr

typedef uint16_t(__thiscall * get_hit_chance_ptr) (void *AutoClass34, uint16_t source_index, uint16_t target_index)

Definition at line 51 of file sf_onhit_hook.c.

◆ get_reduced_building_damage_ptr

typedef uint16_t(__thiscall * get_reduced_building_damage_ptr) (void *AutoClass32, uint16_t source_index, uint16_t target_index, uint16_t damage)

Definition at line 48 of file sf_onhit_hook.c.

◆ get_reduced_damage_ptr

typedef uint16_t(__thiscall * get_reduced_damage_ptr) (void *AutoClass34, uint16_t source_index, uint16_t target_index, uint16_t unkn)

Definition at line 44 of file sf_onhit_hook.c.

◆ getWeaponEffects_ptr

typedef uint32_t(__thiscall * getWeaponEffects_ptr) (void *CGdResource, uint32_t *param1, uint16_t weapon_id)

Definition at line 66 of file sf_onhit_hook.c.

◆ objectDealDamage_ptr

typedef uint32_t(__thiscall * objectDealDamage_ptr) (void *CGdObjectToolBox, uint16_t source_index, uint16_t target_index, uint16_t damage, uint32_t unknown)

Definition at line 61 of file sf_onhit_hook.c.

Function Documentation

◆ canJobBeInterrupted()

bool __thiscall canJobBeInterrupted ( FigureJobs job_id)

Definition at line 168 of file sf_onhit_hook.c.

Here is the caller graph for this function:

◆ get_effect_chance()

uint16_t get_effect_chance ( uint16_t dex_val,
uint16_t int_val,
uint16_t spell_line )

Definition at line 108 of file sf_onhit_hook.c.

◆ getAttackInterruptionChance()

uint16_t __thiscall getAttackInterruptionChance ( SF_CGdFigure * _this,
uint16_t source_index,
uint16_t target_index )

Definition at line 181 of file sf_onhit_hook.c.

Here is the caller graph for this function:

◆ getCurrentDex()

uint16_t __thiscall getCurrentDex ( SF_CGdFigure * _this,
uint16_t figure_index )

Definition at line 81 of file sf_onhit_hook.c.

◆ getCurrentInt()

uint16_t __thiscall getCurrentInt ( SF_CGdFigure * _this,
uint16_t figure_index )

Definition at line 94 of file sf_onhit_hook.c.

◆ getTargetData()

void __thiscall getTargetData ( FigureJobData * _this,
SF_CGdTargetData * target )

Definition at line 131 of file sf_onhit_hook.c.

Here is the caller graph for this function:

◆ handle_berserk_set()

uint16_t __thiscall handle_berserk_set ( SF_CGdFigureJobs * _this,
uint16_t source_index,
uint16_t target_index,
uint16_t weapon_damage )

Definition at line 228 of file sf_onhit_hook.c.

Here is the caller graph for this function:

◆ handle_riposte_set()

uint16_t __thiscall handle_riposte_set ( SF_CGdFigureJobs * _this,
uint16_t source_index,
uint16_t target_index,
uint16_t weapon_damage )

Definition at line 207 of file sf_onhit_hook.c.

Here is the caller graph for this function:

◆ handle_trueshot_set()

uint16_t __thiscall handle_trueshot_set ( SF_CGdFigureJobs * _this,
uint16_t source_index,
uint16_t target_index,
uint16_t weapon_damage )

Definition at line 248 of file sf_onhit_hook.c.

Here is the caller graph for this function:

◆ initialize_onhit_data_hooks()

void initialize_onhit_data_hooks ( )

Definition at line 118 of file sf_onhit_hook.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ isFigureJobSpell()

bool __thiscall isFigureJobSpell ( SF_CGdFigureJobs * _this,
uint16_t figure_id )

Definition at line 148 of file sf_onhit_hook.c.

Here is the caller graph for this function:

◆ isJobDoNothing()

bool isJobDoNothing ( uint16_t job_id)

Definition at line 138 of file sf_onhit_hook.c.

Here is the caller graph for this function:

◆ sf_onhit_hook()

void __thiscall sf_onhit_hook ( SF_CGdFigureJobs * _this,
uint16_t source_index,
uint32_t param_2,
uint8_t param_3 )

Definition at line 268 of file sf_onhit_hook.c.

Here is the call graph for this function:

Variable Documentation

◆ g_FUN_006c3a60

FUN_006c3a60_ptr g_FUN_006c3a60

Definition at line 72 of file sf_onhit_hook.c.

◆ g_FUN_0071d7b0

FUN_0071d7b0_ptr g_FUN_0071d7b0

Definition at line 74 of file sf_onhit_hook.c.

◆ g_FUN_00755180

FUN_00755180_ptr g_FUN_00755180

Definition at line 75 of file sf_onhit_hook.c.

◆ g_get_hit_chance

get_hit_chance_ptr g_get_hit_chance

Definition at line 71 of file sf_onhit_hook.c.

◆ g_get_reduced_building_damage

get_reduced_building_damage_ptr g_get_reduced_building_damage

Definition at line 73 of file sf_onhit_hook.c.

◆ g_get_reduced_damage

get_reduced_damage_ptr g_get_reduced_damage

Definition at line 70 of file sf_onhit_hook.c.

◆ g_getWeaponEffects

getWeaponEffects_ptr g_getWeaponEffects

Definition at line 77 of file sf_onhit_hook.c.

◆ g_objectDealDamage

objectDealDamage_ptr g_objectDealDamage

Definition at line 76 of file sf_onhit_hook.c.