View Single Post
Plugin Info:     Modification:          Category:          Approver:   Exolent[jNr] (178)
DynamicBits
Senior Member
Join Date: Sep 2007
Location: US
Old 11-20-2008 , 05:04   Molotov Cocktail v3.30 - Released April 13, 2014
Reply With Quote #1

Description

This plugin adds a new type of grenade, the Molotov cocktail. It can be used in addition to the standard grenade (high explosive in CS/CS:CZ, hand grenade/stick grenade/Mills bomb in DOD, hand grenade in TFC), or as a replacement.


YouTube Video Demonstration
Geeky video capture details


This version is based on the last version released by SAMURAI & [ --<-@ ] Black Rose. Some CVARs, default values, command arguments, and file paths have been changed. Please read everything here if you are upgrading. I recommend you delete all of the old files related to this plugin as the zip file below has everything required in the proper path.

This plugin supports Counter-Strike 1.6, Counter-Strike: Condition Zero, Day of Defeat 1.2, and Team Fortress Classic 1.5.

I have put countless hours of my time into this plugin and wish for it to work as flawlessly as possible. In return, I only ask that you report any bugs you may find. Either post a reply to this thread, or add a new task to my bug tracker (quick registration required).


Installation

Just unzip the archive into your <modname> directory, (e.g. cstrike, czero, dod, tfc). The location of this directory depends on where your server was installed, but some examples are:
  • Linux: /usr/local/hlds/cstrike/, /opt/hlds/cstrike/
  • Windows: C:\Program Files\Steam\SteamApps\<username>\dedicated server\cstrike\
Unimportant details about every files used and which mods require which files


Once the files are in place, add the following line to plugins.ini:
Code:
molotov_cocktail.amxx
Optionally, add any CVARs you wish to customize to server.cfg (or another config file of your choosing).


Usage

Say Commands
  • molotov Buy a Molotov
  • /molotov Buy a Molotov

Console Commands
  • molotov_give <player|@all|@t|@ct|@al|@ax|@br|@b|@r|@y|@g > Give Molotovs to a player, everyone, or specified team
  • molotov_cocktail [0|1] Enable(1)/Disable(0) the plugin (If no arguments, show the status)
  • molotov_override [0|1] Enable(1)/Disable(0) the standard grenade override (If no arguments, show the status)


Configuration

CVARs
  • molotov_enabled <0|1> (Default: 1) Enable(1)/Disable(0) the plugin
  • molotov_price <N> (Default: 1200) Set the Molotov price (Counter-Strike only)
  • molotov_damage <N> (Default: 50) Set the damage done by initial Molotov explosion
  • molotov_radius <N> (Default: 150) Set the radius of Molotov damage
  • molotov_firetime <N> (Default: 6) Duration (in seconds) of fire effects, sounds, etc.
  • molotov_firedamage <N> (Default: 3) Amount of damage done by fire effects (every 0.2 secs)
  • molotov_ff <0|1|-1|-2> (Default: 1) Set Molotov friendly fire status (Was molotov_tk)
    • 0 - Disable friendly fire for Molotov (regardless of mp_friendlyfire)
    • 1 - Enable friendly fire for Molotov (regardless of mp_friendlyfire)
    • -1 - Use mp_friendlyfire value (v3.21+)
    • -2 - Check bit 5 (decimal: 16) of mp_teamplay (DOD and TFC only) (v3.21+)
  • molotov_override_he <0|1> (Default: 0) Override the mod's standard grenade automatically with Molotov (Was molotov_tempoverride)
  • molotov_max <N> (Default: 1) Limit carried Molotovs to this amount (Does not work with override)
    (Recommended: CSTRIKE: ≤ 10; DOD: ≤ 9; TFC: ≤ 4;)
  • molotov_buyzone <0|1> (Default: 1) Limit Molotov buying to buyzone (Counter-Strike only)
  • molotov_menu <0|1> (Default: 0) Enable menu at beginning of each round (Was amx_molotovmenu) (Counter-Strike only)
  • mp_friendlyfire <0|1> Only checked if molotov_ff = -1
  • mp_teamplay <N> Only checked if molotov_ff = -2 (DOD/TFC only)


Known Issues and (Possible) Future Changes
  • When you "drop weapon" with a molotov equipped ("G" by default), the model shown is of the HE (Counter-Strike)
  • Multilingual support is missing
  • CSTRIKE: Killing hostages doesn't penalize killer
  • DOD: Player grenade count not updated immediately
  • DOD: Wrong throwing animation played
  • DOD/TFC: Molotov doesn't explode after hitting breakable glass
  • TFC: Molotov kills allied team players (e.g. hunted) This is due to a bug in tfc_is_team_ally() in AMX Mod X


Changelog/Credit
Code:
- DynamicBits
  * Version 3.30 (2014-04-13)
    - (Beta) Day of Defeat support was added
    - (Beta) Team Fortress Classic support was added
    - (Untested) Stats logging support was added
    - New values for molotov_ff were added
    - Friction/velocity after explosion was adjusted for realism
    - Bottle breaking sound was added
    - Molotov suicides no longer reward extra score points
    - Frag count calculations were fixed
    - Money calculations were fixed
    - Override no longer sets a negative number of Molotovs
    - Default price was changed to match standard grenades
    - Console text now goes to correct console
    - Text (non-VGUI) buy menu support was removed
    - Converted fun functions to fakemeta_util functions (removed fun include)
    - Various optimizations
    - A few typos were fixed
  * Version 3.20 (2008-11-20)
    - My first public release
    - Finally tracked down and fixed the intermittent crashing problem (I hope!)
    - Modified default damage values
    - molotov_cocktail/molotov_override commands now change settings *or* display status
    - Broken Molotov model stays closer to the explosion (looks more realistic)
    - Task IDs are now guaranteed to be unique
    - Modified anti-lag calculations to be more accurate (less likely to lag)
    - Changed amx_molotovmenu CVAR to molotov_menu
    - Changed molotov_tk CVAR to molotov_ff
    - Changed molotov_tempoverride CVAR to molotov_override_he
    - Preparation for support of mods other than Counter-Strike
    - Fixed lots of coding mistakes
    - Optimized several sections of code
    - Corrected grammar/typos
    - Clean up code (Removed unused code/unhelpful comments, fixed formatting, and semicolons!)
- Raffe (CantShoot)
  * (Unversioned release)
    - Originally fixed plugin to run on Linux servers
    - Added optional menu to purchase Molotov cocktails each round
    - Moved models and sounds into proper molotov/ subdirectories
    - Fixed Molotovs not being reset upon player disconnect
    - (Almost) fixed Molotovs not being removed for new round
    - Added @all/@ct/@t arguments to molotov_give command
    - Changed some models/sound
- [ --<-@ ] Black Rose
  * Version 3.0-3.1c ?
    - Unknown changes
- SAMURAI
  * Original plugin author

Other Versions

Every version of the files for this plugin will be available via my SVN repository. Please note that there are files for other plugins in there as well.


--
Andy


Each of the zip files differs by only one line in the source code (#define CSTRIKE vs. #define DOD vs #define TFC).
Attached Files
File Type: sma Get Plugin or Get Source (molotov_cocktail.sma - 6735 views - 59.9 KB)
File Type: zip molotov_cocktail-3.30_cstrike.zip (547.5 KB, 7426 views)
File Type: zip molotov_cocktail-3.30_dod.zip (547.5 KB, 1708 views)
File Type: zip molotov_cocktail-3.30_tfc.zip (547.5 KB, 1574 views)

Last edited by DynamicBits; 04-13-2014 at 19:07. Reason: v3.30 Release
DynamicBits is offline