Raised This Month: $32 Target: $400
 8% 

Donate Res (v1.3.4)


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   Natural Selection        Category:   General Purpose        Approver:   devicenull (200)
karlos
Veteran Member
Join Date: Apr 2004
Location: Germany/Poland
Old 07-24-2004 , 09:44   Donate Res (v1.3.4)
Reply With Quote #1

Code:
/*
* This Plugin allows aliens to donate res to other players and
* distribute his res when leaving
* Say giveres x or type in console giveres x while looking at player to donate
*
* amx_donateres_cvar gorgeonly 1/0	: player can only donate to gorge
* amx_donateres_cvar tax x		: how much to pay for transfer (percent)
* amx_donateres_cvar shareonexit 1/0	: player share res on disconnect on/off
* amx_donateres 1/0 or on/off		: turns Donate Res on/off
*
* by White Panther
*
* v1.0:
*	- first release
*
* v1.1.5:
*	- bug fixed where only skulks could donate to skulks, gorge to gorge, ...
*	- bug where gorgeonly could not be turned off after enabling
*	- res of players that leave can be distribute to all others (use "amx_donateres_cvar shareonexit 0" to disable )
*	- fixed bug where player could disconnect, distribute res, connect again and still has his res
*
* v1.2.2b:
*	- now working with NS 3 b5
*	- minor adjustments / fixes
*	- moved from ns2amx to engine + fakemeta + ns
*	- fixed bug for 32 players
*
* v1.2.3:
*	- minor code fixes
*
* v1.2.4:
*	- changed:
*		- moved from pev/set_pev to entity_get/entity_set (no fakemeta)
*
* v1.2.5:
*	- fixed:
*		- possible runtime errors (wrong check order)
*	- changed:
*		- if u have less res than u want to give, all res u have are given
*		- range increased (added define)
*		- minor code improvements
*
* v1.2.8:
*	- fixed:
*		- last alien available on team wont get res in "shareonexit" mode when alien leaves
*		- sharing res on exit tried to split the res to the leaving player too
*	- added:
*		- define to set how long players need to wait before they can start donating after round has started (default 0 seconds)
*		- now players can use "giveres" and "/giveres"
*		- in team chat players may now use the commands too
*	- changed:
*		- sharing res when player leaves server is now taxed
*		- calculation of res to donate/shareonexit
*
* v1.2.9:
*	- fixed:
*		- not running on combat anymore
*
* v1.3.0:
*	- changed:
*		- no more "alternative_linux" define ( unneeded )
*		- code improvements
*
* v1.3.0b:
*	- fix:
*		- small print fix not displaying correct value
*
* v1.3.1:
*	- added:
*		- Helper support
*
* v1.3.2:
*	- fixed:
*		- players trying to give more res than owned, lost res without donating ( King Arthur )
*	- changed:
*		- minor text adjustments
*
* v1.3.3:
*	- added:
*		- MvM check
*	- changed:
*		- moved to fakemeta
*
* v1.3.4:
*	- fixed:
*		- it was possible to give more res than player could receive ( res would be lost )
*/

#include <amxmodx>
#include <amxmisc>
#include <engine>
#include <ns>
#include <helper>
Donate Res (download here)

get helper.inc from this thread HERE
Attached Files
File Type: sma Get Plugin or Get Source (donateres.sma - 1555 views - 10.3 KB)
__________________
alias White Panther

Last edited by karlos; 02-26-2008 at 18:34.
karlos is offline
BOOM
Member
Join Date: Jun 2004
Old 07-24-2004 , 13:46  
Reply With Quote #2

this nice i'll eventually test this out
BOOM is offline
karlos
Veteran Member
Join Date: Apr 2004
Location: Germany/Poland
Old 08-18-2004 , 13:17  
Reply With Quote #3

new feature + bug fixes
__________________
alias White Panther
karlos is offline
SirChris
New Member
Join Date: Aug 2004
Old 08-20-2004 , 19:23  
Reply With Quote #4

works fine, nice one!
__________________
.:Change my Ava:.

Hi! I'm a signature virus! Copy me into your ~/.signature to help me spread!
SirChris is offline
karlos
Veteran Member
Join Date: Apr 2004
Location: Germany/Poland
Old 08-29-2004 , 10:57  
Reply With Quote #5

bug fixed where aliens could get extra by disconnecting and connecting again
__________________
alias White Panther
karlos is offline
Meatwad
Senior Member
Join Date: Jul 2004
Location: New york, LI
Old 08-29-2004 , 16:35  
Reply With Quote #6

It seems like a really good idea. But how would the marines use this?
__________________
http://googlefoundfunniest.ytmnd.com/

If you like Aqua Teen Hunger Force, then paste this onto your forehead. (Laugh out loud.)

Admin Weapons II
Meatwad is offline
Seraph
Junior Member
Join Date: Mar 2004
Old 08-29-2004 , 16:48  
Reply With Quote #7

Marines don't have individual res
__________________
VPhoenix.net CO / NS Server
n s 1 . v p h o e n i x . n e t
Seraph is offline
Meatwad
Senior Member
Join Date: Jul 2004
Location: New york, LI
Old 08-29-2004 , 17:42  
Reply With Quote #8

Does any of the servers have this on it? It sounds like a awsome plugin.
__________________
http://googlefoundfunniest.ytmnd.com/

If you like Aqua Teen Hunger Force, then paste this onto your forehead. (Laugh out loud.)

Admin Weapons II
Meatwad is offline
karlos
Veteran Member
Join Date: Apr 2004
Location: Germany/Poland
Old 09-10-2004 , 13:04  
Reply With Quote #9

new version, it works now with b5 and uses amxx 0.2 ns module
__________________
alias White Panther
karlos is offline
Meatwad
Senior Member
Join Date: Jul 2004
Location: New york, LI
Old 09-10-2004 , 18:35  
Reply With Quote #10

Every server I go to, thats NSb5, doesn't have donate any more. It takes FOREVER to get a hive now-a-days.
__________________
http://googlefoundfunniest.ytmnd.com/

If you like Aqua Teen Hunger Force, then paste this onto your forehead. (Laugh out loud.)

Admin Weapons II
Meatwad is offline
Reply



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 11:17.


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