Xonotic
|
#include "havocbot.qh"
#include <common/constants.qh>
#include <common/impulses/all.qh>
#include <common/items/_mod.qh>
#include <common/mapobjects/func/ladder.qh>
#include <common/mapobjects/teleporters.qh>
#include <common/mapobjects/trigger/hurt.qh>
#include <common/mapobjects/trigger/jumppads.qh>
#include <common/mutators/mutator/powerups/_mod.qh>
#include <common/mutators/mutator/status_effects/_mod.qh>
#include <common/net_linked.qh>
#include <common/physics/player.qh>
#include <common/state.qh>
#include <common/stats.qh>
#include <common/weapons/_all.qh>
#include <common/wepent.qh>
#include <lib/warpzone/common.qh>
#include <server/bot/api.qh>
#include <server/bot/default/aim.qh>
#include <server/bot/default/bot.qh>
#include <server/bot/default/cvars.qh>
#include <server/bot/default/havocbot/roles.qh>
#include <server/bot/default/navigation.qh>
#include <server/bot/default/scripting.qh>
#include <server/bot/default/waypoints.qh>
#include <server/client.qh>
#include <server/damage.qh>
#include <server/items/items.qh>
#include <server/mutators/_mod.qh>
#include <server/weapons/selection.qh>
#include <server/weapons/weaponsystem.qh>
#include <server/world.qh>
Go to the source code of this file.
Macros | |
#define | ROCKETJUMP_DAMAGE() |
Functions | |
void | havocbot_ai (entity this) |
void | havocbot_aim (entity this) |
void | havocbot_bunnyhop (entity this, vector dir) |
bool | havocbot_checkgoaldistance (entity this, vector gco) |
void | havocbot_chooseenemy (entity this) |
void | havocbot_chooseweapon (entity this,.entity weaponentity) |
float | havocbot_chooseweapon_checkreload (entity this,.entity weaponentity, int new_weapon) |
vector | havocbot_dodge (entity this) |
entity | havocbot_gettarget (entity this, bool secondary) |
void | havocbot_keyboard_movement (entity this, vector destorg) |
float | havocbot_moveto (entity this, vector pos) |
bool | havocbot_moveto_refresh_route (entity this) |
void | havocbot_movetogoal (entity this) |
float | havocbot_resetgoal (entity this) |
entity | havocbot_select_an_item_of_group (entity this, int gr) |
void | havocbot_setupbot (entity this) |
#define ROCKETJUMP_DAMAGE | ( | ) |
Referenced by havocbot_movetogoal().
Definition at line 35 of file havocbot.qc.
References AI_STATUS_ATTACKING, AI_STATUS_OUT_WATER, AI_STATUS_ROAMING, aistatus, autocvar_bot_ai_chooseweaponinterval, autocvar_bot_nofire, bot_aimdir(), bot_aimdir_executed, bot_aimtarg, bot_chooseweapontime, bot_execute_commands(), bot_ispaused(), bot_strategytoken, bot_strategytoken_taken, clip_load, clip_size, CS(), dir, draggedby, enemy, entity(), FOREACH, g_waypoints, get_closer_dest(), goalcurrent, goalcurrent_prev, havocbot_aim(), havocbot_blockhead, havocbot_chooseenemy(), havocbot_chooseweapon(), havocbot_movetogoal(), IL_EACH, IS_DEAD, IS_INDEPENDENT_PLAYER, IS_ONGROUND, IS_PLAYER, jumppadcount, lag_update(), lastfiredweapon, lastteleporttime, MAX_WEAPONSLOTS, navigation_clearroute(), navigation_goalrating_timeout_force(), navigation_pushroute(), NULL, origin, PHYS_INPUT_BUTTON_ATCK, PHYS_INPUT_BUTTON_ATCK2, skill, time, vdist, vector(), view_ofs, waterlevel, WATERLEVEL_SWIMMING, WAYPOINTFLAG_JUMP, weaponentities, and WEP_FLAG_RELOADABLE.
Referenced by havocbot_setupbot().
Definition at line 1529 of file havocbot.qc.
References CS(), enemy, goalcurrent, lag_additem(), MUTATOR_CALLHOOK, nextaim, NULL, origin, ping, time, vector(), velocity, and waterlevel.
Referenced by havocbot_ai().
Definition at line 217 of file havocbot.qc.
References AI_STATUS_ATTACKING, AI_STATUS_DANGER_AHEAD, AI_STATUS_RUNNING, aistatus, autocvar_bot_ai_bunnyhop_dir_deviation_max, autocvar_bot_ai_bunnyhop_downward_pitch_max, autocvar_bot_ai_bunnyhop_turn_angle_max, autocvar_bot_ai_bunnyhop_turn_angle_min, autocvar_bot_ai_bunnyhop_turn_angle_reduction, bot_jump_time, fabs(), get_closer_dest(), goalcurrent, goalcurrent_prev, goalstack01, IS_DUCKED, IS_ONGROUND, IS_PLAYER, max(), origin, PHYS_INPUT_BUTTON_JUMP, time, vdist, vec2, vectoangles(), vector(), velocity, vlen(), waterlevel, WATERLEVEL_WETFEET, WAYPOINTFLAG_JUMP, and WAYPOINTFLAG_TELEPORT.
Referenced by havocbot_movetogoal().
Definition at line 345 of file havocbot.qc.
References bot_stop_moving_timeout, fabs(), goalcurrent_distance_2d, goalcurrent_distance_time, goalcurrent_distance_z, max(), origin, time, vec2, and vlen().
Referenced by havocbot_movetogoal().
Definition at line 1298 of file havocbot.qc.
References autocvar_bot_ai_enemydetectioninterval, autocvar_bot_ai_enemydetectioninterval_stickingtoenemy, autocvar_bot_ai_enemydetectionradius, autocvar_bot_nofire, best, bot_shouldattack(), DPCONTENTS_BODY, DPCONTENTS_CORPSE, DPCONTENTS_OPAQUE, DPCONTENTS_SOLID, dphitcontentsmask, enemy, entity(), g_bot_targets, havocbot_chooseenemy_finished, havocbot_stickenemy_time, IL_EACH, IS_INDEPENDENT_PLAYER, LABEL, NULL, origin, time, trace_ent, trace_fraction, v, vdist, vector(), view_ofs, and vlen2.
Referenced by havocbot_ai().
Definition at line 1428 of file havocbot.qc.
References ATTACK_FINISHED, autocvar_bot_ai_weapon_combo, autocvar_bot_ai_weapon_combo_threshold, bot_custom_weapon, bot_distance_close, bot_distance_far, bot_rangepreference, bot_weapons_close, bot_weapons_far, bot_weapons_mid, bot_weaponskill, bound(), client_hasweapon(), enemy, FOREACH, g_weaponarena_weapons, havocbot_chooseweapon_checkreload(), lastcombotime, NULL, origin, REGISTRY_COUNT, REGISTRY_GET, skill, time, vlen(), and WEPSET.
Referenced by havocbot_ai().
Definition at line 1408 of file havocbot.qc.
References FOREACH, skill, and weapon_load.
Referenced by havocbot_chooseweapon().
Definition at line 1693 of file havocbot.qc.
References bot_dodge, entity(), findchainfloat(), normalize(), origin, v, vector(), and vlen().
Referenced by havocbot_movetogoal().
Definition at line 1278 of file havocbot.qc.
References best, CENTER_OR_VIEWOFS, entity(), g_bot_targets, IL_EACH, NULL, and vector().
Definition at line 274 of file havocbot.qc.
References autocvar_bot_ai_keyboard_distance, autocvar_bot_ai_keyboard_threshold, bot_moveskill, bound(), CS(), havocbot_ducktime, havocbot_keyboard, havocbot_keyboardskill, havocbot_keyboardtime, max(), min(), origin, PHYS_INPUT_BUTTON_CROUCH, random(), skill, time, vector(), and vlen().
Referenced by havocbot_movetogoal().
Definition at line 1560 of file havocbot.qc.
References AI_STATUS_WAYPOINT_PERSONAL_GOING, AI_STATUS_WAYPOINT_PERSONAL_LINKING, AI_STATUS_WAYPOINT_PERSONAL_REACHED, aistatus, autocvar_bot_debug_goalstack, bot_aimdir(), bot_aimdir_executed, bot_strategytoken_taken, CMD_STATUS_ERROR, CMD_STATUS_EXECUTING, CMD_STATUS_FINISHED, debuggoalstack(), dir, entity(), ftos(), g_teleporters, get_closer_dest(), goalcurrent, havocbot_moveto_refresh_route(), havocbot_movetogoal(), havocbot_personal_waypoint, havocbot_personal_waypoint_failcounter, havocbot_personal_waypoint_searchtime, IL_EACH, lastteleporttime, LOG_TRACE, netname, NULL, origin, time, vector(), view_ofs, vtos(), WarpZoneLib_BoxTouchesBrush(), waypoint_remove(), waypoint_spawnpersonal(), and WAYPOINTFLAG_TELEPORT.
Referenced by havocbot_setupbot().
Definition at line 1549 of file havocbot.qc.
References entity(), goalentity, havocbot_personal_waypoint, navigation_goalrating_end(), navigation_goalrating_start(), navigation_routerating(), and NULL.
Referenced by havocbot_moveto().
Definition at line 399 of file havocbot.qc.
References AI_STATUS_DANGER_AHEAD, AI_STATUS_JETPACK_FLYING, AI_STATUS_JETPACK_LANDING, AI_STATUS_OUT_JUMPPAD, AI_STATUS_OUT_WATER, AI_STATUS_ROAMING, AI_STATUS_RUNNING, aistatus, autocvar_bot_ai_bunnyhop_skilloffset, autocvar_bot_ai_ignoregoal_timeout, autocvar_bot_debug_goalstack, boolean, bot_aimdir(), bot_aimdir_executed, bot_dodgeskill, bot_jump_time, bot_moveskill, bot_navigation_movemode, bot_stop_moving_timeout, bot_tracewalk_time, bound(), boxesoverlap(), checkpvs(), client_hasweapon(), CONTENT_LAVA, CONTENT_SLIME, CONTENT_SOLID, CONTENT_WATER, cos(), CS(), debuggoalstack(), DEG2RAD, dir, enemy, entity(), eZ, fabs(), FLOAT_MAX, frametime, g_items, g_waypoints, get_closer_dest(), GetResource(), goalcurrent, goalcurrent_distance_2d, goalcurrent_distance_time, goalcurrent_distance_z, goalcurrent_prev, goalentity, goalentity_lock_timeout, goalentity_shouldbefrozen, goalstack01, havocbot_blockhead, havocbot_bunnyhop(), havocbot_checkgoaldistance(), havocbot_dodge(), havocbot_ducktime, havocbot_keyboard_movement(), havocbot_select_an_item_of_group(), ignoregoal, ignoregoaltime, IL_EACH, IS_DEAD, IS_DUCKED, IS_MONSTER, IS_ONGROUND, IS_PLAYER, item_group, Item_IsLoot(), items, jumpheight_vec, jumppadcount, jumpstepheightvec, LABEL, ladder_entity, LOG_TRACE, M_SQRT2, makevectors, max(), MAX_WEAPONSLOTS, maxs, min(), mins, MOVE_NOMONSTERS, navigation_clearroute(), navigation_goalrating_timeout_can_be_anticipated(), navigation_goalrating_timeout_expire(), navigation_goalrating_timeout_force(), navigation_jetpack_goal, navigation_jetpack_point, navigation_poptouchedgoals(), navigation_pushroute(), navigation_routetogoal(), navigation_shortenpath(), netname, normalize(), NULL, origin, PHYS_INPUT_BUTTON_ATCK, PHYS_INPUT_BUTTON_ATCK2, PHYS_INPUT_BUTTON_CROUCH, PHYS_INPUT_BUTTON_JETPACK, PHYS_INPUT_BUTTON_JUMP, point_line_vec(), Q3SURFACEFLAG_SKY, random(), RES_HEALTH, ROCKETJUMP_DAMAGE, rocketjumptime, set_tracewalk_dest(), skill, stepheightvec, time, trace_dphitq3surfaceflags, trace_endpos, trace_ent, trace_fraction, trace_plane_normal, trace_startsolid, tracewalk(), tracewalk_dest, tracewalk_dest_height, v, v_angle, v_forward, v_right, v_up, vdist, vec2, vectoangles(), vector(), velocity, view_ofs, vlen(), vlen2, vtos(), waterlevel, WATERLEVEL_SWIMMING, WATERLEVEL_WETFEET, waypoint_is_hardwiredlink(), WAYPOINTFLAG_CROUCH, WAYPOINTFLAG_JUMP, WAYPOINTFLAG_LADDER, WAYPOINTFLAG_TELEPORT, weaponentities, and WEP_CVAR.
Referenced by havocbot_ai(), and havocbot_moveto().
Definition at line 1677 of file havocbot.qc.
References CMD_STATUS_FINISHED, and navigation_clearroute().
Referenced by havocbot_setupbot().
Definition at line 371 of file havocbot.qc.
References entity(), g_items, IL_EACH, and NULL.
Referenced by havocbot_movetogoal().
Definition at line 1683 of file havocbot.qc.
References havocbot_ai(), havocbot_chooserole(), havocbot_moveto(), and havocbot_resetgoal().
Referenced by bot_clientconnect().