Forum
Zoom script?
Created 8th June 2009 @ 21:06
Add A Reply Pages: 1 2 Next »
Hey all, I’m a big newb at scripting and I’m trying to make a bind for switching fov between 75 and 90 each time I click it. I’ve read the Steam forum tutorial and all, but can’t get it to work. the “fov” console command doesn’t seem to be working either which might be a cause of it. This is how the script looks currently:
alias +zoom “fov 75”
alias -zoom “fov 90”
bind “key” “+zoom”
Yes, I’m aware you will unzoom when you let go of the button, just wanted to get the thing working first :P
Ah, darn *slaps forehead* I knew it was the fov command! :P Thanks!
if you really want a toggle button:
bind KEY “toggle fov_desired 75 90”
should work iirc.
I see, but I think, now after testing, hold-to-zoom is better.
The zooming worked well, but the viewmodels jag up a bit when the fov changes, and look confusing. So, I decided to make the zoom remove viewmodels as well. I changed the script to this:
alias +zoom “fov 75; r_drawviewmodel 0”
alias -zoom “fov 90; r_drawviewmodel 1”
bind “mouse3” “+zoom”
The viewmodels now disappear, but there is no change to the fov anymore. :S
EDIT: GOD I’M STUPID
alias +zoom “+attack2; fov 75″
alias -zoom “-attack2; fov 90″
bind “mouse3″ “+zoom”
If its for sniper?
@Beef eater
I just tried this:
alias +zoom “fov_desired 75; r_drawviewmodel 0″
alias -zoom “fov_desired 90; r_drawviewmodel 1″
bind “mouse3″ “+zoom”
I’m wondering what class and what for?
it doesn’t really zoom that much..
i usually wear binoculars when i play tf2 so i have no problem…
old skool
//Field of view changes, for reg classes not snipers.
//toggle zoom in
alias zs80 “fov 80;bind F1 zs70;developer 1;echo zoom in 80;developer 0”
alias zs70 “fov 70;bind F1 zs90;developer 1;echo zoom in 70;developer 0”
alias zs90 “fov 90;bind F1 zs80;developer 1;echo normal 90;developer 0”
//toggle zoom out-wider field of view
alias zeiss100 “fov 100;bind F2 zeiss90;developer 1;echo zoom out 100;developer 0”
alias zeiss90 “fov 90;bind F2 zeiss100;developer 1;echo normal 90;developer 0”
bind F2 zeiss100
@Beef eater
I just tried this:
alias +zoom “fov_desired 75; r_drawviewmodel 0″
alias -zoom “fov_desired 90; r_drawviewmodel 1″
bind “mouse3″ “+zoom”I’m wondering what class and what for?
it doesn’t really zoom that much..
Like Gibz siad, being able to see enemies really far away, and making heads “bigger”, for Ambassador ownage :P
Double post: I moved the script to an autoexec cfg and reset my config file, and now the script is really messed up. For some reason only the “+zoom” part of the command is working, so when I let go of the button the fov is still 75, and the viewmodel is still gone.
alias +zoom “fov_desired 75; r_drawviewmodel 0″
alias -zoom “fov_desired 90; r_drawviewmodel 1”
bind “mouse3” “+zoom”
I can see nothing wrong :|
Add A Reply Pages: 1 2 Next »