Raised This Month: $12 Target: $400
 3% 

Grenades Drop + Ammo Control


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   Counter-Strike        Category:   Gameplay       
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 04-30-2016 , 07:59   Grenades Drop + Ammo Control
Reply With Quote #1


Grenades Drop + Ammo Control 0.1
Release: 30.04.2016 | Last Update: 30.04.2016

Table of Contents

Description top

I'll keep it short this time. With this plugin you can drop grenades(with "drop" command, like for any other weapon) and you can also control the max ammount of grenades that a player can use.

1.Grenades Drop features:
  • Drop grenades.
  • Make sure grenades are properly dropped.
  • For example, with other drop plugins you would get 2 grenades when picking just one.
  • Using game method & game functions, no useless entities are created.

2.Grenade Ammo features:
  • As you know, in CS you have have 1 HE/ 2 FL/ 1 SK
  • Now, you can choose how many grenades a player can buy/pickup via cvars.
  • All grenades are fully usable and no useless entities are created.

Requirements top

This doesn't require much special things, only:
  • Orpheu module.
  • A server without dproto.
    This is not generally needed, but I won't help you if you are running an outdated server with dproto. If you are experiencing problems, update your server/ fix the erros by yourself.
Installation top

To install the plugin:
  1. Download the resources from this post.
  2. Put grenade_dac.amxx in addons/amxmodx/plugins
  3. Open addons/amxmodx/configs/plugins.ini and add at the end of this file grenade_dac.amxx
  4. You can put the sma file into addons/amxmodx/sources but this is not mandatory.
  5. Download the Grenade Drop + Ammo Control archive and copy everything from orpheu folder to server's orpheu folder.
  6. Restart the server/change map.

To install orpheu:
  1. Download orpheu_files-2.5.1.zip and extrat the arhive.
  2. Copy orpheu_amxx.dll/orpheu_amxx_i386.so depending on your operation system into addons/amxmodx/modules
  3. The module will be auto-loaded, you don't need to add it into modules.ini

To compile locally:
  • First way:
    1. Download AMX Mod X for windows/linux from main site
    2. Extract somewhere the arhive and remember the folder!
    3. Copy the content from include folder from the orpheu arhive into addons/amxmodx/scripting/include( in the folder created in the step 2 ).
    4. Download the source of the plugin( grenade_dac.sma) from this post and drag it over the compile.exe(scripting folder from the archive created at step 2)
    5. It will create a new folder called compiled. Open it and you will find your compiled plugin( grenade_dac.amxx )
  • Second way:
    1. Go to http://spider.limetech.org/
    2. Copy/paste the code from the .sma file into the website.
    3. Under the big blue Compile button you see a box which Drop .inc files here
    4. Then press Compile and Download

Cvars top
  • max_flashbangs: max ammount of flashbangs that a player can have in his inventory. Default 2
  • max_hegrenades: max ammount of hegrenades that a player can have in his inventory. Default 1
  • max_smokegrenades: max ammount of smokegrenades that a player can have in his inventory. Default 1
  • drop_grenades: 1 - allow grenade drop | 0 - block grenade drop
ChangeLog top
  • V 0.1:
    • Initial release
Downloads top
  • 0.1 version: will see
End Note:

This is pretty experimental, though I tested it and everything seems to work as intended. It does a lot of things that game is not made to do. I did my best to handle every case, but if you find any kind of bugs please report so I can fix them.
Code has some comments for explaining why some methods were choosed and not the others.
I have not tested in linux, but signatures look ok. If someone can check I would be glad.

Attached Files
File Type: zip Grenade Drop + Ammo Control.zip (11.0 KB, 551 views)
__________________

Last edited by HamletEagle; 06-14-2016 at 09:59.
HamletEagle is offline
chaves
Senior Member
Join Date: Oct 2011
Old 04-30-2016 , 08:28   Re: Grenades Drop + Ammo Control
Reply With Quote #2

great idea, it seems complete, I will try now works in amxx 1.8.3?
chaves is offline
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 04-30-2016 , 08:30   Re: Grenades Drop + Ammo Control
Reply With Quote #3

Quote:
Originally Posted by chaves View Post
great idea, it seems complete, I will try now works in amxx 1.8.3?
Yes, it should work.
__________________
HamletEagle is offline
chaves
Senior Member
Join Date: Oct 2011
Old 04-30-2016 , 08:44   Re: Grenades Drop + Ammo Control
Reply With Quote #4

does not work in amxx 1.8.2, q will do something wrong?
chaves is offline
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 04-30-2016 , 08:48   Re: Grenades Drop + Ammo Control
Reply With Quote #5

I'm testing in 1.8.2 and it works. You have to give some information.
1. Do you get something in logs/console?
2. Did you install the signature files? Type orpheu config and upload the log(addons/amxmodx/logs/orpheu-date.txt) here.
3. Does the plugin appear as running?
4. What is your server version?
__________________
HamletEagle is offline
chaves
Senior Member
Join Date: Oct 2011
Old 04-30-2016 , 08:57   Re: Grenades Drop + Ammo Control
Reply With Quote #6

the plug-in menu appears active, only generated these errors

L 04/30/2016 - 09:45:40: Start of error session.
L 04/30/2016 - 09:45:40: Info (map "de_dust2") (file "addons/amxmodx/logs/error_20160430.log")
L 04/30/2016 - 09:45:40: [ORPHEU] Function "InstallGameRules" not found
L 04/30/2016 - 09:45:40: [AMXX] Run time error 10 (plugin "grenade_dac.amxx") (native "OrpheuGetFunction") - debug not enabled!
L 04/30/2016 - 09:45:40: [AMXX] To enable debug mode, add "debug" after the plugin name in plugins.ini (without quotes).
L 04/30/2016 - 09:45:42: [ORPHEU] Function "CBasePlayer::AmmoInventory" not found
L 04/30/2016 - 09:45:42: [AMXX] Run time error 10 (plugin "grenade_dac.amxx") (native "OrpheuGetFunction") - debug not enabled!
L 04/30/2016 - 09:45:42: [AMXX] To enable debug mode, add "debug" after the plugin name in plugins.ini (without quotes).
chaves is offline
chaves
Senior Member
Join Date: Oct 2011
Old 04-30-2016 , 09:01   Re: Grenades Drop + Ammo Control
Reply With Quote #7

Istalei Orpheu 2.6.3, posted .iso file in / modules, and Orpheu folder in / configs, then installed .amxx file in / plugins and / Orpheu folder in the / configs folder, posted the plugin name in the file. ini, an error?
chaves is offline
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 04-30-2016 , 09:07   Re: Grenades Drop + Ammo Control
Reply With Quote #8

It looks like you did not installed the signatures. Download https://forums.alliedmods.net/attach...6&d=1462017518 and copy what it inside configs/orpheu to addons/amxmodx/configs/orpheu.

Please type orpheu config in your server console, then open addons/amxmodx/logs and upload here orpheu-04-30-2016.log.
__________________

Last edited by HamletEagle; 04-30-2016 at 09:33.
HamletEagle is offline
tousif
AlliedModders Donor
Join Date: Nov 2014
Location: India
Old 04-30-2016 , 09:54   Re: Grenades Drop + Ammo Control
Reply With Quote #9

Will test it
tousif is offline
chaves
Senior Member
Join Date: Oct 2011
Old 04-30-2016 , 09:58   Re: Grenades Drop + Ammo Control
Reply With Quote #10

anything :/
chaves is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 19:33.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode