Plugin Info:
|
Modification: Day of Defeat
Category: Gameplay
Approver: Emp` (115)
|
Veteran Member
Join Date: Jul 2006
Location: I|O wa
|

12-25-2007
, 17:35
DoD Variable-Zoom Scopes
|
#1
|
DOD Zoomscopes for Day of Defeat 1.3
(updated 6-30-09)
This plugin will turn DOD rifle scopes into scopes with a variable zoom.
(yes, I'm well aware that they didn't have zoom scopes in WWII)
To use the zoom scope, you must bind one key to +zoomin, and another key to +zoomout. To make it easier, I built in a routine so that players can simply enter a command in-console and the plugin will bind keys for the player. There is also a display while scoped to inform the player of the approximate zoom magnification and the available zoom commands. A 'default' zoom value can be set by entering the command setzoom while zoomed. After setting a default value, weapons will zoom to this value by default when a new weapon is obtaimed or you zoom after respawning (must be set on each map change). A default zoom value can also be set from your own user config file. Using this method will set a zoom value upon entering the server.
The scope will remain at the last used setting unless you change to a non-scoped primary weapon (or die of course). There is a very slight flicker when changing zoom settings. But it doesn't affect functionallity. Hopefully someone smarter than me can tell me how to get rid of this.
Commands:
+zoomin - Causes the scope to zoom in
+zoomout - Causes the scope to zoom out
setzoom - Sets the default zoom value to the current zoom value
zoombindpg - Binds the keys PageUp to +zoomin and PageDown key to +zoomout
zoombindmw - Binds the mousewheel to zoom in and out
CVars:
zoomscopes_enable <0|1> Disables|Enables the plugin (default 1)
zoomscopes_info_enable <0|1> Disables|Enables the zoom display (default 1)
User Vars:
set_zoomscope <##> Sets the default zoom from a user config. This will set your default zoom upon entering the server. It is preferrable to set this value in a user config file (such as autoexec.cfg or userconfig.cfg). Howeverm it can be set or changed in the console.
The syntax is: setinfo set_zoomscope ##
The ## value must be from 10 - 36. Normal zoom is 20. The lower the value, the closer (more magnified) the view. So a value of 10 is fully zoomed in. (Not that it matters, but I use a value of 17).
Revisions:
NOTE: Recommend placing this plugin ahead of others plugins that create
HUD meaasges upon death (ie: stats)
1.6 Added user CVar to set player's default zoom from a player's config file
- Fixed 'setzoom' command to only set if actually zoomed
1.5 Fixed that you couldn't set default zoom for the Scoped_Enfield
1.4 Added ability to set a default zoom value
1.3 Replaced scoped distance with zoom commands
- Fixed zooming if killed while zoomed
- Uses a dedicated channel for HUD message
1.21 - Fixed display appearing when dead
1.2 Original release
(updated 6-30-09)
.
__________________
=====================================
- My Plugins -
=====================================
Last edited by Vet; 06-30-2009 at 22:49.
|
|
|
|