|
Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
|
|
#include "selection.qh"#include <common/constants.qh>#include <common/items/item.qh>#include <common/mapobjects/triggers.qh>#include <common/mutators/mutator/waypoints/waypointsprites.qh>#include <common/net_linked.qh>#include <common/replicate.qh>#include <common/state.qh>#include <common/util.qh>#include <common/weapons/_all.qh>#include <common/wepent.qh>#include <server/items/items.qh>#include <server/items/spawning.qh>#include <server/weapons/weaponsystem.qh>Go to the source code of this file.
| bool client_hasweapon | ( | entity | this, |
| Weapon | wpn, | ||
| .entity | weaponentity, | ||
| float | andammo, | ||
| bool | complain ) |
Definition at line 48 of file selection.qc.
References autocvar_g_showweaponspawns, autocvar_g_weaponswitch_debug, CS(), dual_weapons, entity(), FOREACH, g_mines, hasweapon_complain_spam, IL_EACH, Weapon::impulse, IS_REAL_CLIENT, IT_UNLIMITED_AMMO, items, Weapon::m_id, offhand, OFFHAND_HOOK, play2(), PS, Send_WeaponComplain(), SND, Weapon::spawnflags, sprint(), STAT, time, Weapon_whereis(), Weapons, weaponsInMap, weaponslot(), WEP_FLAG_DUALWIELD, WepSet_FromWeapon, Weapon::wr_checkammo1(), and Weapon::wr_checkammo2().
Referenced by bot_cmd_select_weapon(), GiveItems(), havocbot_chooseweapon(), havocbot_movetogoal(), Item_GiveTo(), NIX_GiveCurrentWeapon(), REGISTER_MUTATOR(), W_LastWeapon(), and W_SwitchWeapon().
| REPLICATE_APPLYCHANGE | ( | "cl_weaponpriority" | , |
| for(int slot=0;slot< MAX_WEAPONSLOTS;++slot) { .entity weaponentity=weaponentities[slot];if(this.(weaponentity) &&(this.(weaponentity).m_weapon !=WEP_Null||slot==0)) this.(weaponentity).m_switchweapon=w_getbestweapon(this, weaponentity);} | ) |
References m_switchweapon, m_weapon, MAX_WEAPONSLOTS, w_getbestweapon, and weaponentities.
Definition at line 18 of file selection.qc.
References entity(), msg_entity, MSG_ONE, WriteByte(), and WriteHeader.
Referenced by client_hasweapon().
Definition at line 305 of file selection.qc.
References dir, entity(), REGISTRY_GET, W_GetCycleWeapon(), W_SwitchWeapon(), weaponorder, and Weapons.
Referenced by for(), W_NextWeapon(), and W_PreviousWeapon().
| float W_GetCycleWeapon | ( | entity | this, |
| string | weaponorder, | ||
| float | dir, | ||
| float | imp, | ||
| bool | complain, | ||
| bool | skipmissing, | ||
| .entity | weaponentity ) |
Definition at line 132 of file selection.qc.
References car(), cdr(), dir, entity(), FOREACH, imp, m_switchweapon, NULL, REGISTRY_GET, selectweapon, stof(), weaponorder, and Weapons.
Referenced by W_CycleWeapon(), and W_NextWeaponOnImpulse().
Definition at line 344 of file selection.qc.
References client_hasweapon(), cnt, entity(), REGISTRY_GET, W_SwitchToOtherWeapon(), W_SwitchWeapon(), and Weapons.
Referenced by IMPULSE().
Definition at line 322 of file selection.qc.
References CS_CVAR, entity(), W_CycleWeapon(), weaponorder_byid, and weaponorder_byimpulse.
Referenced by IMPULSE(), IMPULSE(), ObserverOrSpectatorThink(), reset_map(), and X().
Definition at line 313 of file selection.qc.
References CS_CVAR, entity(), imp, REGISTRY_GET, W_GetCycleWeapon(), W_SwitchWeapon(), and Weapons.
Referenced by W_SwitchWeapon_TryOthers(), and weapon_group_handle().
Definition at line 333 of file selection.qc.
References CS_CVAR, entity(), W_CycleWeapon(), weaponorder_byid, and weaponorder_byimpulse.
Definition at line 256 of file selection.qc.
References entity(), m_weapon, STAT, w_getbestweapon, W_SwitchWeapon_Force(), and WepSet_FromWeapon.
Referenced by W_Arc_Beam_Think(), W_Hagar_Attack2_Load(), W_LastWeapon(), W_Reload(), and weapon_prepareattack_checkammo().
Definition at line 275 of file selection.qc.
References client_hasweapon(), CS_CVAR, entity(), Weapon::m_id, m_switchweapon, selectweapon, W_SwitchWeapon_Force(), weaponLocked(), and Weapon::wr_reload().
Referenced by GiveBall(), IMPULSE(), MUTATOR_HOOKFUNCTION(), NIX_GiveCurrentWeapon(), W_CycleWeapon(), W_LastWeapon(), W_NextWeaponOnImpulse(), W_SwitchWeapon_TryOthers(), and W_WeaponFrame().
Definition at line 246 of file selection.qc.
References entity(), Weapon::m_id, and TC.
Referenced by GiveItems(), Item_GiveTo(), MUTATOR_HOOKFUNCTION(), TEST(), W_Hagar_Attack_Auto(), W_HLAC_Attack_Frame(), W_MachineGun_Attack_Auto(), W_MachineGun_Attack_Frame(), W_OverkillHeavyMachineGun_Attack_Auto(), W_OverkillMachineGun_Attack_Auto(), W_Shotgun_Attack3_Frame1(), W_Shotgun_Attack3_Frame2(), W_SwitchToOtherWeapon(), W_SwitchWeapon(), W_ThrowWeapon(), and W_WeaponFrame().
Definition at line 299 of file selection.qc.
References CS_CVAR, entity(), Weapon::impulse, W_NextWeaponOnImpulse(), and W_SwitchWeapon().
Referenced by weapon_byid_handle().
Definition at line 26 of file selection.qc.
References autocvar_g_showweaponspawns, enemy, entity(), g_items, IL_EACH, ITS_AVAILABLE, NULL, and WaypointSprite_Spawn().
Referenced by client_hasweapon(), and NET_HANDLE().