//HeadShot Script by atif-sattar.blogspot.com
//Thanks to luckyboyaitf@yahoo.com
//Calling the head status for regular mouse or inverted mouse

alias hspitch1 "alias hspitch hp1"
alias hspitch2 "alias hspitch hp2"
alias hp1 "m_pitch 0.022"
alias hp2 "m_pitch -0.022"
alias hspitchoff "m_pitch 0"
alias hslook "+lookup;wait;-lookup"
alias devon "developer 1"
alias devoff "developer 0"
alias n1 "echo Regular Mouse Mode"
alias n2 "echo Inverted Mouse Mode"
alias n3 "echo Hit F8 for Regular Mouse or hit F9 for Inverted Mouse Mode hit F10 for toggle of HeadShot"
alias n4 "echo Once a Mouse Mode is changed it is set to that, if you need to change it hit ~ and type rbf89"
alias hson2 "bind mouse1 +hson;bind f10 hson3;devon;echo HeadShot = On;devoff;hsdto1"
alias hson3 "bind mouse1 +hsoff;bind f10 hson2;decon;echo HeadShot = Off;devoff;hsdto2"
bind f10 hson2
alias ubf89 "unbind f8;wait;unbind f9"
alias imm "hspitch2;devon;n2;devoff;ubf89"
alias rmm "hspitch1;devon;n1;devoff;ubf89"
alias dn "devon;n3;n4;devoff"
alias rbf89 "bind f8 rmm;bind f9 imm;n3"
bind f8 rmm
bind f9 imm
dn

//Bind head status to mouse

alias +hson "-mlook;centerview;cl_pitchspeed 10;wait;hspitchoff;+attack;hslook"
alias -hson "-attack;cl_pitchspeed 150;+mlook"

alias +hsoff "+attack"
alias -hsoff "-attack"

alias +hsgren "+attack"
alias -hsgren "-attack;bind mouse1 +hson"

alias +hsbomb "+attack"
alias -hsbomb "-attack;bind mouse1 +hson"

//Exceptional Keys
alias hsducktogoff "hsducktogoff2"
alias hsducktogoff2 "bind mouse1 -hson"
alias hsducktogoff3 "bind mouse1 -hsoff"
alias hsdto1 "alias hsducktogoff hsducktogoff2"
alias hsdto2 "alias hsducktogoff hsducktogoff3"
alias +hsducktog "bind mouse1 +hsoff"
alias -hsducktog "hsducktogoff"
alias +hsduck "+duck;+hsducktog"
alias -hsduck "-duck;-hsducktog"
bind ctrl +hsduck
bind 4 "slot4;bind mouse1 +hsgren"
bind 5 "slot5;bind mouse1 +hsbomb"
bind 1 "slot1;bind mouse1 +hson"
bind 2 "slot1;bind mouse1 +hson"
bind 3 "slot3;bind mouse1 +hsoff"