I’d appreciate it if someone could help me debug this script.
This first bit binds a different crosshair to ‘F1’, ‘F2’ and ‘F3’. For instance, I prefer the latter on dark maps like Radar. The various keys and names differ from the script I use, but I changed it to make it more comprehensible to others.
bind F1 “seta CROSSHAIR cg_drawcrosshair 3; cg_crosshairsize 42; cg_crosshaircolor cyan; cg_crosshaircoloralt red; cg_crosshairalpha .9; cg_crosshairalphaalt 1; vstr CROSSHAIR”
bind F2 “seta CROSSHAIR cg_drawcrosshair 3; cg_crosshairsize 42; cg_crosshaircolor cyan; cg_crosshaircoloralt red; cg_crosshairalpha .6; cg_crosshairalphaalt 1; vstr CROSSHAIR”
bind F3 seta “CROSSHAIR cg_drawcrosshair 4; cg_crosshairsize 46; cg_crosshaircolor cyan; cg_crosshaircoloralt cyan; cg_crosshairalpha .4; cg_crosshairalphaalt .9; vstr CROSSHAIR”
The second part makes the crosshair smaller when crouching, and when I “uncrouch” it loads the predefined crosshair settings and resets the size of the crosshair.
seta crouchon “+movedown; cg_crosshairsize 36”
seta crouchoff “-movedown; vstr CROSSHAIR”
bind mouse2 “+vstr crouchon crouchoff”
All of this used to work when I only had one command to each of the crosshair setting; which was cg_crosshairalpha, but when I added more it just won’t work anymore. This means that there is a syntaxt error; or at least I assume it is.
The old and more simple setting (which worked ) looked like this:
bind F1 “seta CROSSHAIR cg_crosshairalpha .9; vstr CROSSHAIR”
bind F1 “seta CROSSHAIR cg_crosshairalpha .6; vstr CROSSHAIR”
bind F1 “seta CROSSHAIR cg_crosshairalpha .3; vstr CROSSHAIR”
That much for so little may seem unnecessary, but there are other scripts which refers to these things, so it’s kind of intertwined.