FeuerSturm
06-30-2007, 01:21 PM
//
// DESCRIPTION:
// ============
//
// - players drop exactly the grenades they have left on
// death and alive players can pickup those
// (example: Axis player dies and drops a stickgrenade
// -> Allied player picked it up while still having a handgrenade
// -> Allies player dies and drops 1x Stick- and 1x Handgrenade
// -> A player that has no grenades picks up both and will drop
// both on death as well)
// - grenades will be removed once a round is finished
// - additionally each player's previously dropped grenade(s) can be removed
// before dropping new ones.
//
//
// USAGE:
// ======
//
// CVARS:
//
// dod_dropgrenades_enabled <1/0> = enable/disable DoD DropGrenades
// 1 = enabled
// 0 = disabled
//
// dod_dropgrenades_removeold <1/0> = enable/disable removing player's
// previously dropped grenade(s) before
// dropping new ones
// 1 = enabled
// 0 = all grenades stay until roundend
//
// dod_dropgrenades_ignorebots <1/0> = enable/disable ignoring bots
// 1 = ignore bots (bots don't drop or pickup grenades)
// 0 = don't ignore bots (bots drop and pickup grenades)
//
//
// ADMIN COMMAND:
//
// amx_dropgrenades <1/0> = enable/disable DoD DropGrenades
// 1 = enable
// 0 = disable and remove all dropped grenades
//
//
// CHANGELOG:
// ==========
//
// - 26.07.2005 Version 0.5beta
// Initial Public Release
//
// - 21.08.2005 Version 0.5beta2
// workaround:
// - added a fix for strange behavior on AMXX 1.50beta
//
// - 27.08.2005 Version 0.6beta
// changes:
// - removed workaround for AMXX 1.50beta as the bug is
// fixed in AMXX 1.55 which everyone should rather use
// than 1.50beta!
//
// - 12.01.2007 Version 0.6
// changes:
// - made it so that whatever side you are it will pickup your type of nades
// this is to make it compatiable with zors smoke nades plugin
// - added cvar to change amount of grenades allowed to have
//
// - 30.06.2007 Version 0.7
// - discarded changes from v0.6
// - changed Engine- to Fakemeta-Module for better performance
// - removed need for DoDFun module
// - changed to using pcvars
// - added full Linux compatibility with removing dod_get_user_ammo
// and counting players' grendades depending on their class after spawning
// - using grenade_throw forward to decrease amount of dropable grenades
// when a player throws a grenade.
// - players now drop exactly the grenades they have left on
// death and alive players can pickup those
// (example: Axis player dies and drops a stickgrenade
// -> Allied player picked it up while still having a handgrenade
// -> Allies player dies and drops 1x Stick- and 1x Handgrenade
// -> A player that has no grenades picks up both and will drop
// both on death as well)
// - removed all effects and ability to use an AmmoBox-Model instead of the
// grenade models for dropped grenades for more realism
// - added cvar dod_dropgrenades_ignorebots with that bots can be prevented
// from dropping and picking up grenades
//
// - 30.06.2007 Version 0.75
// - added ability to adjust the amount of grenades a player has by default
// NOTE: if you are not using any plugins that mess with the
// amount of grenades per player, keep the default value!
// - added ability to adjust the amount of grenades a player can pickup
// from the ground
// NOTE: if you are not using any plugins that mess with the
// amount of grenades per player, keep the default value!
// - added ability to adjust the amount of grenades that will be dropped
// when a player dies
// NOTE: if you are not using any plugins that mess with the
// amount of grenades per player, keep the default value!
//
// - 02.07.2007 Version 0.8
// - added roundstate "Draw" to clean up of dropped grenades
// - added global tracking cvar
//
PLEASE NOTE:
From now on this Plugin is considered a realism Plugin, if you
wish to have funny effects or different models for the dropped
grenades, please use "DoD DropGrenades 2 (http://dodplugins.net/forums/showthread.php?t=739)" modded by "Wilson [29th ID]".
It contains a lot more features other than the basic realism features.
If you like realism though, DropGrenades v0.7 is the right one for you!
PLEASE NOTE #2:
If you are running a Plugin that messes with or just changes the DoD default
amount of grenades that a specific player class has, you can adjust
DoD DropGrenades to fit to the changed amounts with editing the source code
(dod_dropgrenades.sma) with your text editor before compiling!
Look for the following lines:
// PLEASE ONLY CHANGE THE FOLLOWING NUMBERS THAT DECLARE THE
// NUMBER OF GRENADES EACH GROUP OF CLASSES HAVE IF YOU ARE
// USING A PLUGIN THAT CHANGES THE STANDARD AMOUNT OF GRENADES!
#define DOD_RIFLE_CLASSES 2 // GARAND, CARBINE, ENFIELD, K98, K43
#define DOD_MP_CLASSES 1 // THOMPSON, BAR, GREASEGUN, BREN, STEN, MP40, STG44, FG42, SCOPED FG42
#define DOD_SNIPER_CLASSES 0 // SPRINGFIELD, SCOPED ENFIELD, SCOPED K98
#define DOD_MG_CLASSES 0 // 30CAL, MG34, MG42
#define DOD_ROCKET_CLASSES 0 // BAZOOKA, PIAT, PANZERSCHRECK
// THE FOLLOWING IS THE MAX AMOUNT OF GRENADES A PLAYER CAN
// PICKUP! ADJUST THIS VALUE CAREFULLY!
#define DOD_GRENADES_PICKUP 2
// THE FOLLOWING IS THE MAX AMOUNT OF GRENADES THAT WILL BE DROPPED
// WHEN A PLAYER DIES THAT HAD MORE THAN THE DOD STANDARD LIMIT!
// TO PREVENT GRENADE-SPAMMING DEFAULT VALUE IS HIGHLY RECOMMENDED!
#define DOD_DROPGRENADES_MAX 2
IF NO OTHER PLUGIN MESSES WITH PLAYER'S GRENADES YOU
CAN LEAVE THE SOURCE CODE UNTOUCHED!
Now enjoy playing with a bit more realism! :D
// DESCRIPTION:
// ============
//
// - players drop exactly the grenades they have left on
// death and alive players can pickup those
// (example: Axis player dies and drops a stickgrenade
// -> Allied player picked it up while still having a handgrenade
// -> Allies player dies and drops 1x Stick- and 1x Handgrenade
// -> A player that has no grenades picks up both and will drop
// both on death as well)
// - grenades will be removed once a round is finished
// - additionally each player's previously dropped grenade(s) can be removed
// before dropping new ones.
//
//
// USAGE:
// ======
//
// CVARS:
//
// dod_dropgrenades_enabled <1/0> = enable/disable DoD DropGrenades
// 1 = enabled
// 0 = disabled
//
// dod_dropgrenades_removeold <1/0> = enable/disable removing player's
// previously dropped grenade(s) before
// dropping new ones
// 1 = enabled
// 0 = all grenades stay until roundend
//
// dod_dropgrenades_ignorebots <1/0> = enable/disable ignoring bots
// 1 = ignore bots (bots don't drop or pickup grenades)
// 0 = don't ignore bots (bots drop and pickup grenades)
//
//
// ADMIN COMMAND:
//
// amx_dropgrenades <1/0> = enable/disable DoD DropGrenades
// 1 = enable
// 0 = disable and remove all dropped grenades
//
//
// CHANGELOG:
// ==========
//
// - 26.07.2005 Version 0.5beta
// Initial Public Release
//
// - 21.08.2005 Version 0.5beta2
// workaround:
// - added a fix for strange behavior on AMXX 1.50beta
//
// - 27.08.2005 Version 0.6beta
// changes:
// - removed workaround for AMXX 1.50beta as the bug is
// fixed in AMXX 1.55 which everyone should rather use
// than 1.50beta!
//
// - 12.01.2007 Version 0.6
// changes:
// - made it so that whatever side you are it will pickup your type of nades
// this is to make it compatiable with zors smoke nades plugin
// - added cvar to change amount of grenades allowed to have
//
// - 30.06.2007 Version 0.7
// - discarded changes from v0.6
// - changed Engine- to Fakemeta-Module for better performance
// - removed need for DoDFun module
// - changed to using pcvars
// - added full Linux compatibility with removing dod_get_user_ammo
// and counting players' grendades depending on their class after spawning
// - using grenade_throw forward to decrease amount of dropable grenades
// when a player throws a grenade.
// - players now drop exactly the grenades they have left on
// death and alive players can pickup those
// (example: Axis player dies and drops a stickgrenade
// -> Allied player picked it up while still having a handgrenade
// -> Allies player dies and drops 1x Stick- and 1x Handgrenade
// -> A player that has no grenades picks up both and will drop
// both on death as well)
// - removed all effects and ability to use an AmmoBox-Model instead of the
// grenade models for dropped grenades for more realism
// - added cvar dod_dropgrenades_ignorebots with that bots can be prevented
// from dropping and picking up grenades
//
// - 30.06.2007 Version 0.75
// - added ability to adjust the amount of grenades a player has by default
// NOTE: if you are not using any plugins that mess with the
// amount of grenades per player, keep the default value!
// - added ability to adjust the amount of grenades a player can pickup
// from the ground
// NOTE: if you are not using any plugins that mess with the
// amount of grenades per player, keep the default value!
// - added ability to adjust the amount of grenades that will be dropped
// when a player dies
// NOTE: if you are not using any plugins that mess with the
// amount of grenades per player, keep the default value!
//
// - 02.07.2007 Version 0.8
// - added roundstate "Draw" to clean up of dropped grenades
// - added global tracking cvar
//
PLEASE NOTE:
From now on this Plugin is considered a realism Plugin, if you
wish to have funny effects or different models for the dropped
grenades, please use "DoD DropGrenades 2 (http://dodplugins.net/forums/showthread.php?t=739)" modded by "Wilson [29th ID]".
It contains a lot more features other than the basic realism features.
If you like realism though, DropGrenades v0.7 is the right one for you!
PLEASE NOTE #2:
If you are running a Plugin that messes with or just changes the DoD default
amount of grenades that a specific player class has, you can adjust
DoD DropGrenades to fit to the changed amounts with editing the source code
(dod_dropgrenades.sma) with your text editor before compiling!
Look for the following lines:
// PLEASE ONLY CHANGE THE FOLLOWING NUMBERS THAT DECLARE THE
// NUMBER OF GRENADES EACH GROUP OF CLASSES HAVE IF YOU ARE
// USING A PLUGIN THAT CHANGES THE STANDARD AMOUNT OF GRENADES!
#define DOD_RIFLE_CLASSES 2 // GARAND, CARBINE, ENFIELD, K98, K43
#define DOD_MP_CLASSES 1 // THOMPSON, BAR, GREASEGUN, BREN, STEN, MP40, STG44, FG42, SCOPED FG42
#define DOD_SNIPER_CLASSES 0 // SPRINGFIELD, SCOPED ENFIELD, SCOPED K98
#define DOD_MG_CLASSES 0 // 30CAL, MG34, MG42
#define DOD_ROCKET_CLASSES 0 // BAZOOKA, PIAT, PANZERSCHRECK
// THE FOLLOWING IS THE MAX AMOUNT OF GRENADES A PLAYER CAN
// PICKUP! ADJUST THIS VALUE CAREFULLY!
#define DOD_GRENADES_PICKUP 2
// THE FOLLOWING IS THE MAX AMOUNT OF GRENADES THAT WILL BE DROPPED
// WHEN A PLAYER DIES THAT HAD MORE THAN THE DOD STANDARD LIMIT!
// TO PREVENT GRENADE-SPAMMING DEFAULT VALUE IS HIGHLY RECOMMENDED!
#define DOD_DROPGRENADES_MAX 2
IF NO OTHER PLUGIN MESSES WITH PLAYER'S GRENADES YOU
CAN LEAVE THE SOURCE CODE UNTOUCHED!
Now enjoy playing with a bit more realism! :D