tutorials/urban_terror/gear_cvar.1340034024.txt.gz · Last modified: 2012/06/18 17:40 by JRandomNoob

gear cvar

This is an old revision of the document!


gear cvar

Your current gear setup is stored in your q3config.cfg file in format of seta gear "ABCDEFG". Every weapon and item has its own code and the combination must be in specific order (slightly different from the order of the in-game gear selection menu). To denote empty slots in the cvar, use A. The minimum legal gear requires at least primary, sidearm and one item in the first item slot: GLAAWAA for Deagle, LR300 and helmet. The letters are case-sensitive.

The following table shows what gear can be placed in which slots (the slots are in correct order). You can’t have duplicate items (two shotguns or helmets).

Sidearm Primary Secondary Grenades Item #1 Item #2 Item #3
Beretta F
Desert Eagle G
SPAS H H
MP5K I I
UMP45 J J
HK69 K
LR300 L
G36 M
PSG-1 N
SR8 Z
AK-103 a
Negev c
M4 e
HE grenade O
Smoke grenade Q1)
Kevlar vest R R R
Goggles S S S
Medkit T T T
Silencer U U U
Laser Sight V V V
Helmet W W W
Extra ammo X X X

Simple gear bind

To avoid clicking in the menu for every weapon change, different gear combinations can be bound to a key in your own config file:

bind 8 "gear GMAARUT"
bind 9 "gear GLAAVUT"
bind 0 "gear GZIAWTA"

Now the gear combination with G36 can be chosen with through key 8, another combination with LR300 can be chosen through 9 and the last combination with SR8 by the key 0.

Advanced gear bind

This can be enhanced to a switchable gear setup, so that one key can rotate through different gear setups:

set gear_g36_1 "set gear_g36 vstr gear_g36_2; gear GMAARUT; ut_echo ^7G36 ^1+ ^7Kevlar ^1+ ^7Silencer ^1+ ^7MedKit"
set gear_g36_2 "set gear_g36 vstr gear_g36_3; gear GMAARWT; ut_echo ^7G36 ^1+ ^7Kevlar ^1+ ^7Helmet ^1+ ^7MedKit"
set gear_g36_3 "set gear_g36 vstr gear_g36_1; gear GMAARWU; ut_echo ^7G36 ^1+ ^7Kevlar ^1+ ^7Helmet ^1+ ^7Silencer"
set gear_g36 "vstr gear_g36_1" // the default, necessary for the script to work
bind 8 "vstr gear_g36"

This script will rotate through different weapon combinations with G36 by the key 8 and output a short descriptive text to the console display. http://q3ut3.free.fr/gear/ provides an online tool to choose different gear setups and creates config script out of it.

Delayed-execution gear bind

This script allows you to rotate through numerous gears without actually setting the cvar until you’ve decided (to avoid triggering the floodprotection of the server).

set gear_g36_1 "set gear_g36 vstr gear_g36_2; set set-gear gear GMAARUT; ut_echo ^7G36 ^1+ ^7Kevlar ^1+ ^7Silencer ^1+ ^7MedKit"
set gear_g36_2 "set gear_g36 vstr gear_g36_3; set set-gear gear GMAARWT; ut_echo ^7G36 ^1+ ^7Kevlar ^1+ ^7Helmet ^1+ ^7MedKit"
set gear_g36_3 "set gear_g36 vstr gear_g36_1; set set-gear gear GMAARWU; ut_echo ^7G36 ^1+ ^7Kevlar ^1+ ^7Helmet ^1+ ^7Silencer"
set gear_g36 "vstr gear_g36_1"
set set-gear "gear GMAARUT"
bind 8 "vstr gear_g36" // rotate through gears
bind 9 "vstr set-gear" // set the selected gear

Links

1) The letter P was used for flash grenades in previous versions