‪Black Ops 3 Source Code Explorer  0.1
‪An script explorer for Black Ops 3 by ZeRoY
_ai_tank.gsc File Reference

Go to the source code of this file.

Macros

#define AI_TANK_BULLET_MITIGATION   .8
 
#define AI_TANK_EXPLOSIVE_MITIGATION   1
 
#define AI_TANK_FURTHEST_FROM_NAVMESH_ALLOWED   ( 40 * 12 )
 
#define AI_TANK_GUN_TURRET   1
 
#define AI_TANK_GUNNER_AIM_OFFSET   -24
 
#define AI_TANK_GUNNER_AIM_TAG   "tag_gunner_aim1"
 
#define AI_TANK_GUNNER_FLASH_TAG   "tag_flash_gunner1"
 
#define AI_TANK_HEALTH   1500
 
#define AI_TANK_IN_WATER_FUTZ_FRACTION   ( 12 / AI_TANK_IN_WATER_TRACE_START )
 
#define AI_TANK_IN_WATER_REF_DISTANCE   ( AI_TANK_IN_WATER_TRACE_REF - AI_TANK_IN_WATER_TRACE_END )
 
#define AI_TANK_IN_WATER_TRACE_DISTANCE   ( AI_TANK_IN_WATER_TRACE_START - AI_TANK_IN_WATER_TRACE_END )
 
#define AI_TANK_IN_WATER_TRACE_END   ( 12 )
 
#define AI_TANK_IN_WATER_TRACE_FRACTION   ( (AI_TANK_IN_WATER_TRACE_START - AI_TANK_IN_WATER_TRACE_REF) / ( AI_TANK_IN_WATER_TRACE_START - AI_TANK_IN_WATER_TRACE_END ) )
 
#define AI_TANK_IN_WATER_TRACE_MASK   ( PHYSICS_TRACE_MASK_WATER )
 
#define AI_TANK_IN_WATER_TRACE_MAXS   ( 2, 2, 2 )
 
#define AI_TANK_IN_WATER_TRACE_MINS   ( -2, -2, -2 )
 
#define AI_TANK_IN_WATER_TRACE_REF   ( 36 )
 
#define AI_TANK_IN_WATER_TRACE_START   ( 42 )
 
#define AI_TANK_IN_WATER_TRACE_WAIT   ( 0.3 )
 
#define AI_TANK_MISSILE_FLASH_TAG   "tag_flash"
 
#define AI_TANK_MISSILE_TURRET   0
 
#define AI_TANK_NAV_MESH_VALID_LOCATION_BOUNDARY   16
 
#define AI_TANK_NAV_MESH_VALID_LOCATION_TOLERANCE   4
 
#define AI_TANK_PATH_TIMEOUT   45
 
#define AI_TANK_STUN_DURATION   4
 
#define AI_TANK_STUN_DURATION_PROXIMITY   1.5
 
#define AI_TANK_THINK_DEBUG   GetDvarInt( "scr_ai_tank_think_debug" )
 
#define AI_TANK_TIME_TO_WAIT_FOR_LOST_TARGET   5
 
#define AI_TANK_WEAPON_NAME   "ai_tank_marker"
 

Functions

function ai_tank_killstreak_start (owner, origin, killstreak_id, category)
 
function ConfigureTeamPost (owner, isHacked)
 
function crateLand (crate, category, owner, team, context)
 
function deleteOnKillbrush (player)
 
function emp_crazy_death ()
 
function endTankRemoteControl (drone, exitRequestedByOwner)
 
function get_vehicle_name (vehicle_version)
 
function HackedCallbackPost (hacker)
 
function HackedCallbackPre (hacker)
 
function init ()
 
function is_location_good (location, context)
 
function kill_monitor ()
 
function killstreak_stop_and_assert (hardpoint_name, team, killstreak_id, assert_msg)
 
function perform_recoil (recoil_tag, force_scale_factor, force_z_offset)
 
function perform_recoil_missile_turret (player)
 
function register ()
 
function reload_rockets (player)
 
function setup_gameplay_think (category)
 
function startTankRemoteControl (drone)
 
function stop_remote ()
 
function tank_abort_think ()
 
function tank_compute_enemy_position ()
 
function tank_damage_think ()
 
function tank_death_think (hardpointName)
 
function tank_game_end_think (drone)
 
function tank_get_player_enemies (on_radar)
 
function tank_hacked_health_update (hacker)
 
function tank_has_radar ()
 
function tank_low_health_fx ()
 
function tank_rocket_watch (player)
 
function tank_rocket_watch_ai ()
 
function tank_stun (duration)
 
function tank_team_kill ()
 
function tank_timeout_callback ()
 
function tank_too_far_from_nav_mesh_abort_think ()
 
function tank_watch_owner_events ()
 
function update_client_ammo (ammo_count, driver_only_update=false)
 
function useKillstreakAITankDrop (hardpointType)
 
function valid_location (location)
 
function valid_target (target, team, owner)
 
function WatchWater ()
 

Macro Definition Documentation

◆ AI_TANK_BULLET_MITIGATION

#define AI_TANK_BULLET_MITIGATION   .8

Definition at line 44 of file _ai_tank.gsc.

◆ AI_TANK_EXPLOSIVE_MITIGATION

#define AI_TANK_EXPLOSIVE_MITIGATION   1

Definition at line 45 of file _ai_tank.gsc.

◆ AI_TANK_FURTHEST_FROM_NAVMESH_ALLOWED

#define AI_TANK_FURTHEST_FROM_NAVMESH_ALLOWED   ( 40 * 12 )

Definition at line 56 of file _ai_tank.gsc.

◆ AI_TANK_GUN_TURRET

#define AI_TANK_GUN_TURRET   1

Definition at line 49 of file _ai_tank.gsc.

◆ AI_TANK_GUNNER_AIM_OFFSET

#define AI_TANK_GUNNER_AIM_OFFSET   -24

Definition at line 53 of file _ai_tank.gsc.

◆ AI_TANK_GUNNER_AIM_TAG

#define AI_TANK_GUNNER_AIM_TAG   "tag_gunner_aim1"

Definition at line 52 of file _ai_tank.gsc.

◆ AI_TANK_GUNNER_FLASH_TAG

#define AI_TANK_GUNNER_FLASH_TAG   "tag_flash_gunner1"

Definition at line 51 of file _ai_tank.gsc.

◆ AI_TANK_HEALTH

#define AI_TANK_HEALTH   1500

Definition at line 42 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_FUTZ_FRACTION

#define AI_TANK_IN_WATER_FUTZ_FRACTION   ( 12 / AI_TANK_IN_WATER_TRACE_START )

Definition at line 1193 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_REF_DISTANCE

#define AI_TANK_IN_WATER_REF_DISTANCE   ( AI_TANK_IN_WATER_TRACE_REF - AI_TANK_IN_WATER_TRACE_END )

Definition at line 1192 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_TRACE_DISTANCE

#define AI_TANK_IN_WATER_TRACE_DISTANCE   ( AI_TANK_IN_WATER_TRACE_START - AI_TANK_IN_WATER_TRACE_END )

Definition at line 1191 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_TRACE_END

#define AI_TANK_IN_WATER_TRACE_END   ( 12 )

Definition at line 1189 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_TRACE_FRACTION

Definition at line 1190 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_TRACE_MASK

#define AI_TANK_IN_WATER_TRACE_MASK   ( PHYSICS_TRACE_MASK_WATER )

Definition at line 1185 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_TRACE_MAXS

#define AI_TANK_IN_WATER_TRACE_MAXS   ( 2, 2, 2 )

Definition at line 1184 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_TRACE_MINS

#define AI_TANK_IN_WATER_TRACE_MINS   ( -2, -2, -2 )

Definition at line 1183 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_TRACE_REF

#define AI_TANK_IN_WATER_TRACE_REF   ( 36 )

Definition at line 1188 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_TRACE_START

#define AI_TANK_IN_WATER_TRACE_START   ( 42 )

Definition at line 1187 of file _ai_tank.gsc.

◆ AI_TANK_IN_WATER_TRACE_WAIT

#define AI_TANK_IN_WATER_TRACE_WAIT   ( 0.3 )

Definition at line 1186 of file _ai_tank.gsc.

◆ AI_TANK_MISSILE_FLASH_TAG

#define AI_TANK_MISSILE_FLASH_TAG   "tag_flash"

Definition at line 50 of file _ai_tank.gsc.

◆ AI_TANK_MISSILE_TURRET

#define AI_TANK_MISSILE_TURRET   0

Definition at line 48 of file _ai_tank.gsc.

◆ AI_TANK_NAV_MESH_VALID_LOCATION_BOUNDARY

#define AI_TANK_NAV_MESH_VALID_LOCATION_BOUNDARY   16

Definition at line 58 of file _ai_tank.gsc.

◆ AI_TANK_NAV_MESH_VALID_LOCATION_TOLERANCE

#define AI_TANK_NAV_MESH_VALID_LOCATION_TOLERANCE   4

Definition at line 59 of file _ai_tank.gsc.

◆ AI_TANK_PATH_TIMEOUT

#define AI_TANK_PATH_TIMEOUT   45

Definition at line 43 of file _ai_tank.gsc.

◆ AI_TANK_STUN_DURATION

#define AI_TANK_STUN_DURATION   4

Definition at line 46 of file _ai_tank.gsc.

◆ AI_TANK_STUN_DURATION_PROXIMITY

#define AI_TANK_STUN_DURATION_PROXIMITY   1.5

Definition at line 47 of file _ai_tank.gsc.

◆ AI_TANK_THINK_DEBUG

#define AI_TANK_THINK_DEBUG   GetDvarInt( "scr_ai_tank_think_debug" )

Definition at line 54 of file _ai_tank.gsc.

◆ AI_TANK_TIME_TO_WAIT_FOR_LOST_TARGET

#define AI_TANK_TIME_TO_WAIT_FOR_LOST_TARGET   5

Definition at line 55 of file _ai_tank.gsc.

◆ AI_TANK_WEAPON_NAME

#define AI_TANK_WEAPON_NAME   "ai_tank_marker"

Definition at line 41 of file _ai_tank.gsc.

Function Documentation

◆ ai_tank_killstreak_start()

◆ ConfigureTeamPost()

function ConfigureTeamPost ( owner  ,
isHacked   
)

Definition at line 275 of file _ai_tank.gsc.

References tank_watch_owner_events().

Referenced by ai_tank_killstreak_start().

◆ crateLand()

function crateLand ( crate  ,
category  ,
owner  ,
team  ,
context   
)

Definition at line 188 of file _ai_tank.gsc.

References ai_tank_killstreak_start(), EnemyEMPActive(), is_location_good(), and killstreakStop().

Referenced by init().

◆ deleteOnKillbrush()

function deleteOnKillbrush ( player  )

Definition at line 621 of file _ai_tank.gsc.

Referenced by ai_tank_killstreak_start().

◆ emp_crazy_death()

function emp_crazy_death ( )

Definition at line 692 of file _ai_tank.gsc.

References AI_TANK_GUN_TURRET, AI_TANK_MISSILE_TURRET, set(), and WAIT_SERVER_FRAME.

◆ endTankRemoteControl()

function endTankRemoteControl ( drone  ,
exitRequestedByOwner   
)

◆ get_vehicle_name()

function get_vehicle_name ( vehicle_version  )

Definition at line 356 of file _ai_tank.gsc.

◆ HackedCallbackPost()

function HackedCallbackPost ( hacker  )

Definition at line 266 of file _ai_tank.gsc.

References set_vehicle_drivable_time_starting_now(), and UseRemoteWeapon().

Referenced by ai_tank_killstreak_start().

◆ HackedCallbackPre()

◆ init()

◆ is_location_good()

function is_location_good ( location  ,
context   
)

Definition at line 222 of file _ai_tank.gsc.

References IsLocationGood(), and valid_location().

Referenced by crateLand(), and useKillstreakAITankDrop().

◆ kill_monitor()

function kill_monitor ( )

Definition at line 390 of file _ai_tank.gsc.

References AI_TANK_AGR_NAME, and play_pilot_dialog_on_owner().

Referenced by ai_tank_killstreak_start().

◆ killstreak_stop_and_assert()

function killstreak_stop_and_assert ( hardpoint_name  ,
team  ,
killstreak_id  ,
assert_msg   
)

Definition at line 844 of file _ai_tank.gsc.

References killstreakStop().

Referenced by ai_tank_killstreak_start(), tank_death_think(), and useKillstreakAITankDrop().

◆ perform_recoil()

function perform_recoil ( recoil_tag  ,
force_scale_factor  ,
force_z_offset   
)

Definition at line 1096 of file _ai_tank.gsc.

Referenced by perform_recoil_missile_turret().

◆ perform_recoil_missile_turret()

function perform_recoil_missile_turret ( player  )

Definition at line 1084 of file _ai_tank.gsc.

References AI_TANK_AGR_NAME, IS_TRUE, and perform_recoil().

Referenced by tank_rocket_watch().

◆ register()

◆ reload_rockets()

function reload_rockets ( player  )

◆ setup_gameplay_think()

function setup_gameplay_think ( category  )

◆ startTankRemoteControl()

◆ stop_remote()

function stop_remote ( )

Definition at line 475 of file _ai_tank.gsc.

References clear_using_remote(), clientNotify(), and destroyRemoteHUD().

Referenced by HackedCallbackPre(), and tank_watch_owner_events().

◆ tank_abort_think()

function tank_abort_think ( )

◆ tank_compute_enemy_position()

function tank_compute_enemy_position ( )

Definition at line 922 of file _ai_tank.gsc.

References tank_get_player_enemies().

◆ tank_damage_think()

◆ tank_death_think()

◆ tank_game_end_think()

function tank_game_end_think ( drone  )

Definition at line 465 of file _ai_tank.gsc.

Referenced by ai_tank_killstreak_start().

◆ tank_get_player_enemies()

function tank_get_player_enemies ( on_radar  )

Definition at line 879 of file _ai_tank.gsc.

References tank_has_radar(), and valid_target().

Referenced by tank_compute_enemy_position().

◆ tank_hacked_health_update()

function tank_hacked_health_update ( hacker  )

Definition at line 486 of file _ai_tank.gsc.

Referenced by tank_damage_think().

◆ tank_has_radar()

function tank_has_radar ( )

Definition at line 869 of file _ai_tank.gsc.

References HasSatellite(), and HasUAV().

Referenced by tank_get_player_enemies().

◆ tank_low_health_fx()

function tank_low_health_fx ( )

Definition at line 604 of file _ai_tank.gsc.

References spawn().

Referenced by tank_damage_think().

◆ tank_rocket_watch()

function tank_rocket_watch ( player  )

◆ tank_rocket_watch_ai()

function tank_rocket_watch_ai ( )

Definition at line 1148 of file _ai_tank.gsc.

Referenced by ai_tank_killstreak_start().

◆ tank_stun()

function tank_stun ( duration  )

Definition at line 647 of file _ai_tank.gsc.

References set(), set_to_player(), and stunStaticFX().

Referenced by tank_damage_think().

◆ tank_team_kill()

function tank_team_kill ( )

Definition at line 383 of file _ai_tank.gsc.

Referenced by setup_gameplay_think().

◆ tank_timeout_callback()

function tank_timeout_callback ( )

Definition at line 426 of file _ai_tank.gsc.

References AI_TANK_AGR_NAME, and play_pilot_dialog_on_owner().

Referenced by tank_abort_think().

◆ tank_too_far_from_nav_mesh_abort_think()

function tank_too_far_from_nav_mesh_abort_think ( )

Definition at line 850 of file _ai_tank.gsc.

References AI_TANK_FURTHEST_FROM_NAVMESH_ALLOWED.

Referenced by setup_gameplay_think().

◆ tank_watch_owner_events()

function tank_watch_owner_events ( )

Definition at line 435 of file _ai_tank.gsc.

References AI_TANK_VISIONSET_ALIAS, deactivate(), set(), stop_remote(), and waittill_any().

Referenced by ConfigureTeamPost().

◆ update_client_ammo()

function update_client_ammo ( ammo_count  ,
driver_only_update  = false 
)

Definition at line 1103 of file _ai_tank.gsc.

References increment_to_player(), and set().

Referenced by reload_rockets(), startTankRemoteControl(), and tank_rocket_watch().

◆ useKillstreakAITankDrop()

◆ valid_location()

function valid_location ( location  )

Definition at line 227 of file _ai_tank.gsc.

References end(), IsTouchingAnyOOBTrigger(), PHYSICS_TRACE_MASK_VEHICLE_CLIP, and trace().

Referenced by is_location_good().

◆ valid_target()

function valid_target ( target  ,
team  ,
owner   
)

Definition at line 950 of file _ai_tank.gsc.

References IS_TRUE.

Referenced by tank_get_player_enemies().

◆ WatchWater()