View Single Post
Plugin Info:     Modification:          Category:          Approver:   Zenith77 (33)
M249-M4A1
I <3 Mac
Join Date: May 2005
Location: Not interested
Old 09-16-2007 , 22:33   CS/DoD/TFC Weapon Gravity
Reply With Quote #1

Quote:
/********************************************* *******
*
* Name: CS/DoD/TFC Weapon Gravity
* Author: M249-M4A1
* Idea: X-Script
* Version: 2.0
* Date: 10-06-2007
*
* Description:
* - Players will have a different personal gravity, depending on the weapon that
* they are currently using.
*
* Commands:
* - say /weapongrav
* - amx_reload_weapongrav [SERVER COMMAND]
* - amx_weapon_gravity <1=ON|0=OFF> [REQUIRES ADMIN_BAN FLAG]
*
* Command Details:
* - say /weapongrav toggles weapon gravity on or off (only for that person who typed it)
* - amx_reload_weapongrav reloads gravity configuration file
* - amx_weapon_gravity toggles the weapon gravity plugin on/off
*
* CVARs:
* - [CS] cs_weapon_gravity <1=ON|0=OFF> - enables/disables the plugin (default enabled)
* - [DoD] dod_weapon_gravity (same as above)
* - [TFC] tfc_weapon_gravity (same as above)
*
* Notes:
* - This plugin may interfere with other gravity plugins.
* - Refer to the gravity configuration file "m2_weapon_gravity.ini" file for instructions
* on editing weapon gravities.
*
* Special Thanks (and Credits):
* - X-Script, for their idea of making this plugin, and letting me take over.
* - Zenith77, for many great suggestions to make this plugin better, and providing me with alternative
* code for efficiency and ease of use.
* - EJL's Sound Download Management for the read-from-file example.
* - Bahrmanou, for their method of messaging all players except the caller.
*
* Changelog:
* - 1.0: Initial release
* - 1.5: Cleaned up code; Added lower gravity for all weapons; Added CVAR to enable/disable plugin
* - 1.6: Removed a useless variable; Removed as much white space as possible; Added comments
* - 1.6b: Added ability for clients to enable/disable weapon gravity; Say /weapongrav to toggle
* - 1.6c: Fixed bug where clients could not turn off weapon gravity; Added information message when player joins
* - 1.7: Plugin now reads from a configuration file; Default configuration file is:
* "addons/amxmodx/configs/tfc_weapon_gravity.ini" but can be changed (edit CONFIGFILE in the define section below)
* - 1.7b: Code revision; Added Credits
* - 1.7c: Cleaned up code; Changed CVAR name: "amx_tfcgravity" to "tfc_weapon_gravity"
* - 1.7d: Notify all players (except caller) of the caller's gravity change; Added command to toggle plugin on/off
* - 1.8: Updated "tfc_weapon_gravity.ini" and updated some code
* - 1.9: Supports Counter-Strike, Day of Defeat, and Team Fortress Classic
* - 2.0: One gravity configuration file: "m2_weapon_gravity.ini"
*
********************************************* *******/
Attached Files
File Type: ini m2_weapon_gravity.ini (3.3 KB, 793 views)
File Type: sma Get Plugin or Get Source (m2_weapon_gravity.sma - 2186 views - 10.4 KB)
__________________

Last edited by M249-M4A1; 01-27-2010 at 04:14. Reason: Demonstration video no longer available
M249-M4A1 is offline