Raised This Month: $ Target: $400
 0% 

[REQ] Custom Rebuy


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
sekac
Senior Member
Join Date: Nov 2016
Old 05-27-2018 , 07:28   [REQ] Custom Rebuy
Reply With Quote #1

I want a plugin that saves your last bought weapons and allows you to buy them the next round with 'repurchase'. I need this so I can customize the original 'rebuy'.
sekac is offline
karimoo97
Member
Join Date: Apr 2018
Location: Tamazgha
Old 05-27-2018 , 17:16   Re: [REQ] Custom Rebuy
Reply With Quote #2

What's wrong with the original rebuy ?
I'm not sure what do you exactly need but try THIS
__________________
Why do you need a plugin that changes your admin pw?
Quote:
Originally Posted by marcopollo View Post
Becouse if someone comes to my house and watch config.cfg see my password for admin.
karimoo97 is offline
sekac
Senior Member
Join Date: Nov 2016
Old 05-28-2018 , 06:48   Re: [REQ] Custom Rebuy
Reply With Quote #3

Quote:
Originally Posted by karimoo97 View Post
What's wrong with the original rebuy ?
I'm not sure what do you exactly need but try THIS
Sometimes it does absolutely nothing, other times it just buys your pistol without your primary. I will try storing players weapon on buy?

Last edited by sekac; 05-28-2018 at 06:52.
sekac is offline
sekac
Senior Member
Join Date: Nov 2016
Old 05-28-2018 , 07:19   Re: [REQ] Custom Rebuy
Reply With Quote #4

Can someone help me hook rebuy?

I tried this
PHP Code:
register_clcmd("rebuy""ClRebuy"
but it didn't work.

I want to block it and call custom_rebuy(id)
sekac is offline
CrAzY MaN
Senior Member
Join Date: Mar 2017
Location: India
Old 05-28-2018 , 07:48   Re: [REQ] Custom Rebuy
Reply With Quote #5

What do u want?

1.U wanna make server custom rebuy?
Like press F2 to get server rebuy weapons.

2.Or rebuy that weapons which were bought by person last round?
__________________
CrAzY MaN is offline
sekac
Senior Member
Join Date: Nov 2016
Old 05-28-2018 , 07:54   Re: [REQ] Custom Rebuy
Reply With Quote #6

Quote:
Originally Posted by CrAzY MaN View Post
What do u want?

1.U wanna make server custom rebuy?
Like press F2 to get server rebuy weapons.

2.Or rebuy that weapons which were bought by person last round?
2. Rebuy the weapons which were bought by that person last round.

Here is what I have for getting the weapons.

PHP Code:
public client_buy(iditemID) {
    if(
itemID 30)
        return 
PLUGIN_CONTINUE;
    
    if(
itemID == 17 || itemID == 16 || itemID == || itemID == 26 || itemID == 11)
        
secWeapon[id] = itemID
    
else 
        
primWeapon[id] = itemID 
sekac is offline
CrAzY MaN
Senior Member
Join Date: Mar 2017
Location: India
Old 05-28-2018 , 11:44   Re: [REQ] Custom Rebuy
Reply With Quote #7

I think u have default file named rebuy.txt and autobuy.txt in base folder
__________________
CrAzY MaN is offline
^SmileY
Veteran Member
Join Date: Jan 2010
Location: Brazil [<o>]
Old 05-28-2018 , 13:12   Re: [REQ] Custom Rebuy
Reply With Quote #8

You can't block rebuy command since it execute internal file on client (Rebuy.txt) and to server commands that stored in this file.

Specify what you want to do here
__________________
Projects:

- See my Git Hub: https://github.com/SmileYzn
PHP Code:
set_pcvar_num(pCvar, !get_pcvar_num(pCvar)); 
^SmileY is offline
Send a message via MSN to ^SmileY Send a message via Skype™ to ^SmileY
sekac
Senior Member
Join Date: Nov 2016
Old 05-28-2018 , 14:35   Re: [REQ] Custom Rebuy
Reply With Quote #9

Quote:
Originally Posted by ^SmileY View Post
You can't block rebuy command since it execute internal file on client (Rebuy.txt) and to server commands that stored in this file.

Specify what you want to do here
I want to block the original rebuy command and execute a custom one. What about CS_InternalCommand?
sekac is offline
^SmileY
Veteran Member
Join Date: Jan 2010
Location: Brazil [<o>]
Old 05-28-2018 , 14:44   Re: [REQ] Custom Rebuy
Reply With Quote #10

Quote:
Originally Posted by sekac View Post
I want to block the original rebuy command and execute a custom one. What about CS_InternalCommand?
This is not a valid repply, what you want to do exactly?

Again, you can't simple block rebuy or replace it, you can hook it and do actions based on parameters of that command or code that you want.
__________________
Projects:

- See my Git Hub: https://github.com/SmileYzn
PHP Code:
set_pcvar_num(pCvar, !get_pcvar_num(pCvar)); 
^SmileY is offline
Send a message via MSN to ^SmileY Send a message via Skype™ to ^SmileY
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 10:35.


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