Xonotic
hook.qh
Go to the documentation of this file.
1 #pragma once
2 
17 
18 // Wazat's grappling hook
19 .entity hook;
20 void GrapplingHookThink(entity this);
22 void RemoveHook(entity this);
23 // (note: you can change the hook impulse #'s to whatever you please)
24 .float hook_time;
25 
26 .float hook_length;
27 
28 const float HOOK_FIRING = BIT(0);
29 const float HOOK_REMOVING = BIT(1);
30 const float HOOK_PULLING = BIT(2);
31 const float HOOK_RELEASING = BIT(3);
32 const float HOOK_WAITING_FOR_RELEASE = BIT(4);
33 .float hook_state;
34 .int state;
35 
37 
void RemoveHook(entity this)
Definition: hook.qc:96
float hook_time
Definition: hook.qh:24
float autocvar_g_balance_grapplehook_airfriction
Definition: hook.qh:3
entity hook
Definition: hook.qh:19
float autocvar_g_balance_grapplehook_damagedbycontents
Definition: hook.qh:11
float autocvar_g_balance_grapplehook_speed_pull
Definition: hook.qh:9
float autocvar_g_balance_grapplehook_health
Definition: hook.qh:6
entity() spawn
const float HOOK_RELEASING
Definition: hook.qh:31
float hook_length
Definition: hook.qh:26
float autocvar_g_balance_grapplehook_stretch
Definition: hook.qh:10
float autocvar_g_balance_grapplehook_force_rubber_overstretch
Definition: hook.qh:5
#define BIT(n)
Only ever assign into the first 24 bits in QC (so max is BIT(23)).
Definition: bits.qh:8
int state
Definition: hook.qh:34
void RemoveGrapplingHooks(entity pl)
Definition: hook.qc:78
float autocvar_g_balance_grapplehook_length_min
Definition: hook.qh:7
const float HOOK_PULLING
Definition: hook.qh:30
vector hook_shotorigin[4]
Definition: hook.qh:36
float autocvar_g_balance_grapplehook_refire
Definition: hook.qh:12
vector(float skel, float bonenum) _skel_get_boneabs_hidden
float autocvar_g_balance_grapplehook_force_rubber
Definition: hook.qh:4
const float HOOK_FIRING
Definition: hook.qh:28
const float HOOK_REMOVING
Definition: hook.qh:29
float autocvar_g_balance_grapplehook_speed_fly
Definition: hook.qh:8
const float HOOK_WAITING_FOR_RELEASE
Definition: hook.qh:32
bool autocvar_g_balance_grapplehook_crouchslide
Definition: hook.qh:16
bool autocvar_g_balance_grapplehook_gravity
Definition: hook.qh:15
int autocvar_g_balance_grapplehook_pull_frozen
Definition: hook.qh:13
void GrapplingHookThink(entity this)
Definition: hook.qc:154
float hook_state
Definition: hook.qh:33
float autocvar_g_balance_grapplehook_nade_time
Definition: hook.qh:14