Raised This Month: $106 Target: $400
 26% 

[REQ] Strip Primary weapon, secondary weapon, grenades.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Evaldas.Grigas
Senior Member
Join Date: Sep 2011
Location: Lithuania
Old 10-25-2011 , 12:51   [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #1

I request someone to make a module that would include this commands:
Code:
stripuserweapons(id, "primary_weapon")
stripuserweapons(id, "secondary_weapon")
stripuserweapons(id, "grenades")
__________________
Please enter this website everyday: http://forums.alliedmods.net/showthread.php?t=169067

Last edited by Evaldas.Grigas; 10-25-2011 at 12:51.
Evaldas.Grigas is offline
Send a message via Skype™ to Evaldas.Grigas
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 10-25-2011 , 13:02   Re: [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #2

Can be done by a simple stock too, you don't need a module for that.

Edit: Working on this, gonna end up with a .inc file.
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.

Last edited by drekes; 10-25-2011 at 13:15.
drekes is offline
Send a message via MSN to drekes
Evaldas.Grigas
Senior Member
Join Date: Sep 2011
Location: Lithuania
Old 10-25-2011 , 13:34   Re: [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #3

Great!
__________________
Please enter this website everyday: http://forums.alliedmods.net/showthread.php?t=169067
Evaldas.Grigas is offline
Send a message via Skype™ to Evaldas.Grigas
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 10-25-2011 , 13:58   Re: [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #4

Inc:
http://forums.alliedmods.net/showpos...38&postcount=9

test plugin:
PHP Code:
#include <amxmodx>
#include <stripweapons>
#include <fakemeta>


public plugin_init()
{
    
register_clcmd("strip""CmdStrip");
}


public 
CmdStrip(id)
{
    new 
szArg[5];
    
read_argv(1szArgcharsmax(szArg));
    
strtolower(szArg);
    
    switch(
szArg[0])
    {
        case 
'p'StripWeapons(idPrimary);
        case 
's'StripWeapons(idSecondary);
        case 
'g'StripWeapons(idGrenades);
        case 
'c'StripWeapons(idC4);
        case 
'k'ham_strip_user_weapon(idCSW_KNIFE3true);
        default: 
console_print(id"Wrong argument.");
    }
    
    return 
PLUGIN_HANDLED;

__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.

Last edited by drekes; 01-30-2012 at 13:18. Reason: updated include
drekes is offline
Send a message via MSN to drekes
Evaldas.Grigas
Senior Member
Join Date: Sep 2011
Location: Lithuania
Old 10-25-2011 , 15:26   Re: [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #5

How do you name this inc?

EDIT: Found it. <stripweapons>

EDIT 2: Works perfect thanks! You saved me useless ~25 lines in my plugin!
__________________
Please enter this website everyday: http://forums.alliedmods.net/showthread.php?t=169067

Last edited by Evaldas.Grigas; 10-25-2011 at 15:35.
Evaldas.Grigas is offline
Send a message via Skype™ to Evaldas.Grigas
Evaldas.Grigas
Senior Member
Join Date: Sep 2011
Location: Lithuania
Old 10-28-2011 , 13:16   Re: [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #6

Yo, drekes. Can you add 1 feature? Please make that this include could strip all grenades and seperately. Example:
PHP Code:
StripWeapons(idCSW_HEGRENADE
__________________
Please enter this website everyday: http://forums.alliedmods.net/showthread.php?t=169067

Last edited by Evaldas.Grigas; 10-28-2011 at 13:18.
Evaldas.Grigas is offline
Send a message via Skype™ to Evaldas.Grigas
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 10-28-2011 , 13:38   Re: [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #7

Quote:
Originally Posted by Evaldas.Grigas View Post
Yo, drekes. Can you add 1 feature? Please make that this include could strip all grenades and seperately. Example:
PHP Code:
StripWeapons(idCSW_HEGRENADE
PHP Code:
ham_strip_user_weapon(idCSW_HEGRENADE); 
the ham* stock is also in that include.
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.

Last edited by drekes; 10-28-2011 at 13:39.
drekes is offline
Send a message via MSN to drekes
Evaldas.Grigas
Senior Member
Join Date: Sep 2011
Location: Lithuania
Old 10-28-2011 , 13:39   Re: [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #8

So I can use this sort of code? Or other CSW_ right?
__________________
Please enter this website everyday: http://forums.alliedmods.net/showthread.php?t=169067
Evaldas.Grigas is offline
Send a message via Skype™ to Evaldas.Grigas
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 10-28-2011 , 16:10   Re: [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #9

I've commented the .inc & made a small change.
That should help you understand it.
Attached Files
File Type: inc stripweapons.inc (4.0 KB, 1169 views)
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.

Last edited by drekes; 01-30-2012 at 13:19. Reason: Updated include
drekes is offline
Send a message via MSN to drekes
Evaldas.Grigas
Senior Member
Join Date: Sep 2011
Location: Lithuania
Old 10-28-2011 , 16:14   Re: [REQ] Strip Primary weapon, secondary weapon, grenades.
Reply With Quote #10

Thank you. But I still don't understand what do you mean by changeing weapon?
EDIT: Understood by reading it 10 times.
__________________
Please enter this website everyday: http://forums.alliedmods.net/showthread.php?t=169067

Last edited by Evaldas.Grigas; 10-28-2011 at 16:15.
Evaldas.Grigas is offline
Send a message via Skype™ to Evaldas.Grigas
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 10:29.


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