Raised This Month: $7 Target: $400
 1% 

[Any] Strip Weapons from Player


Post New Thread Reply   
 
Thread Tools Display Modes
Author
RedSword
SourceMod Plugin Approver
Join Date: Mar 2006
Location: Quebec, Canada
Plugin ID:
4575
Plugin Version:
1.2.0
Plugin Category:
General Purpose
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
    28 
    Plugin Description:
    Remove weapons from a player.
    Old 03-29-2015 , 07:31   [Any] Strip Weapons from Player
    Reply With Quote #1

    Strip Weapons from Player

    With sm_admin menu integration
    v. 1.2.0

    Foreword :
    I was a bit saddened and baffled to find that I couldn't find any plugin to strip a player from his weapons in different mods, when searching 'strip' or 'remove' or 'weapon' in the plugin search. So I decided to make my own and release it.

    Features (Admin Commands) :
    • <sm_strip | say !strip> <#userid|name|targets> <[slots]> : Remove weapons specified in 2nd arg, or in 'swfp_slot_default' if not present.
    • <sm_stripall | say !stripall> <#userid|name|targets> ; Remove all weapons with slot lower or equals swfp_slot_max.
    • <sm_stripbut | say !stripbut> <#userid|name|targets> <slots> ; slot is 1-based ; Remove all weapons with slot lower or equals swfp_slot_max from target except those in 2nd-argument slot.
    • --------------------
    • Note that the slot specified by the ConVar swfp_slot_default will be used instead of sm_strip 2nd arg if it is missing.
    • Tested and works in CSS/TF2. Should work with other mods.
    • Note that player being stripped from all their weapons will have a 'T' pose, which is normal.
    • Ban flag is needed.

    ConVars :
    • swfp_slot_max : Until which item slot (included) should the plugin end to remove weapons. 1-based. Def. 10.
    • swfp_slot_default : Which slots should be stripped from their weapons by default ? (stick the slot digits together; sm_strip only; 0=slot 10; digits must all be below or equal swfp_slot_max). Default "1234".
    • ----------
    • swfp_log : Should the plugin log admin activity ? 1=Yes (Def.), 0=No.

    Changelog :
    • 1.0.0 Initial release. (29-03-2015)
    • 1.1.0 (01-04-2015)
      • Changed the way commands work.
      • Removed swfp_slot_min and swfp_slot_skip convars.
      • Added swfp_slot_default convar.
      • You can now specify slots when stripping someone (if not present, those specified by swfp_slot_default are used).
      • Reversed the arguments in sm_stripbut (to have the same order as sm_strip).
      • Removed aim-target as optional argument; since anyway an admin can use @aim.
      • Changed verbose so the stripped slots are shown (unless if stripping all). Translation file must be redownloaded.
    • 1.2.0 (08-09-2015)
      • Added admin menu integration (under player commands).
      • Added a possibility to avoid handling immunity (see convar swfp_ignore_immunity).
      • Fixed swfp_log being incorrectly used in the code .
      • Translations must be redownloaded.

    Thanks :
    • Perm strip ?

    Thanks :
    • House : Slot-flags idea, instead of range & skips (1.1.0). Also where would I live without it ^^.
    Attached Files
    File Type: sp Get Plugin or Get Source (stripweaponsfromplayer.sp - 2538 views - 14.8 KB)
    File Type: txt stripweaponsfromplayer.phrases.txt (903 Bytes, 747 views)
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 09-11-2015 at 05:42. Reason: 185sp/86txt
    RedSword is offline
    Bjorngomes
    Member
    Join Date: Jun 2013
    Old 03-31-2015 , 13:23   Re: [Any] Strip Weapons from Player
    Reply With Quote #2

    Plugin failed to compile! Please try contacting the author.

    Is it possible to Provide the plugin. thanks.
    Bjorngomes is offline
    RedSword
    SourceMod Plugin Approver
    Join Date: Mar 2006
    Location: Quebec, Canada
    Old 03-31-2015 , 14:43   Re: [Any] Strip Weapons from Player
    Reply With Quote #3

    Quote:
    Originally Posted by Bjorngomes View Post
    Plugin failed to compile! Please try contacting the author.

    Is it possible to Provide the plugin. thanks.
    That 1.7 <.<

    Compiles fine in 1.8

    Uploaded. Thanks for reporting :/.
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 03-31-2015 at 17:21.
    RedSword is offline
    micazoid
    Veteran Member
    Join Date: Oct 2010
    Location: Munich - Germany
    Old 03-31-2015 , 15:04   Re: [Any] Strip Weapons from Player
    Reply With Quote #4

    Quote:
    Originally Posted by RedSword View Post
    That 1.7 <.<

    Compiles fine in 1.8
    He tried to use Webcompiler ^^
    __________________
    micazoid is offline
    RedSword
    SourceMod Plugin Approver
    Join Date: Mar 2006
    Location: Quebec, Canada
    Old 03-31-2015 , 17:20   Re: [Any] Strip Weapons from Player
    Reply With Quote #5

    https://forums.alliedmods.net/custom...tar94702_2.gif

    Bahahahahahahahaha your owl is awesome, reversed <3

    Quote:
    Originally Posted by micazoid View Post
    He tried to use Webcompiler ^^
    No it really doesn't compile on the forum. I believe it is due to 1.7 syntax bugs zzz. It is understandable that they do not use 1.8 compilers when 1.8 isn't released <.<.

    EDIT : Wtf, it compiles fine in 1.7 default snapshot, as well as SM online compiler; but not forum compiler (and 1.7 is selected)

    RE-EDIT : https://bugs.alliedmods.net/show_bug.cgi?id=6340
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 03-31-2015 at 17:39.
    RedSword is offline
    RedSword
    SourceMod Plugin Approver
    Join Date: Mar 2006
    Location: Quebec, Canada
    Old 04-01-2015 , 07:28   Re: [Any] Strip Weapons from Player
    Reply With Quote #6

    Released 1.1.0 :
    • Changed the way commands work.
    • Removed swfp_slot_min and swfp_slot_skip convars.
    • Added swfp_slot_default convar.
    • You can now specify slots when stripping someone (if not present, those specified by swfp_slot_default are used).
    • Reversed the arguments in sm_stripbut (to have the same order as sm_strip).
    • Removed aim-target as optional argument; since anyway an admin can use @aim.
    • Changed verbose so the stripped slots are shown (unless if stripping all). Translation file must be redownloaded.

    Thanks to House for the slot-flag idea.

    Also even though I reuploaded the plugin, bug 6340 is still in effect.

    EDIT : Removed .smx as 6340 is fixed
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 04-06-2015 at 16:31.
    RedSword is offline
    Robin955
    Veteran Member
    Join Date: Jun 2013
    Old 04-25-2015 , 22:22   Re: [Any] Strip Weapons from Player
    Reply With Quote #7

    slot 1 primary, slot 2 pistol. slot 3 knife, slot 4 grenade?

    im not sure im understanding how to set it right based on -1 and 10 what is all that.

    how do i simply make it strip everyone at round beginning, hopefully this would take effect before the sm_hosties starts giving out knifes to T's since i got the problem where t's doesn't get a knife when spawning somethimes
    it does give the knife animations but it does not provide the knife, its like it gave the knife but then removed it quickly again wich is bugging me
    oh so strip 1234 would be all slots? well 12345 would?

    Last edited by Robin955; 04-25-2015 at 22:26.
    Robin955 is offline
    RedSword
    SourceMod Plugin Approver
    Join Date: Mar 2006
    Location: Quebec, Canada
    Old 04-25-2015 , 22:51   Re: [Any] Strip Weapons from Player
    Reply With Quote #8

    Quote:
    Originally Posted by Robin955 View Post
    slot 1 primary, slot 2 pistol. slot 3 knife, slot 4 grenade?
    Yes.

    Quote:
    Originally Posted by Robin955 View Post
    im not sure im understanding how to set it right based on -1 and 10 what is all that.
    Did you try it as is ? And I'm not sure where you take your "-1". And 10 is so all mods are taken into consideration.

    Quote:
    Originally Posted by Robin955 View Post
    how do i simply make it strip everyone at round beginning, hopefully this would take effect before the sm_hosties starts giving out knifes to T's since i got the problem where t's doesn't get a knife when spawning somethimes
    it does give the knife animations but it does not provide the knife, its like it gave the knife but then removed it quickly again wich is bugging me
    I never said anything about round beginning...

    Quote:
    Originally Posted by Robin955 View Post
    oh so strip 1234 would be all slots? well 12345 would?
    sm_stripall

    If you feel something is unclear in the first post feel free to pinpoint it; I feel it should be clear enough as is (I did add the default for swfp_slot_default though).
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 06-11-2015 at 21:52.
    RedSword is offline
    Robin955
    Veteran Member
    Join Date: Jun 2013
    Old 04-25-2015 , 23:33   Re: [Any] Strip Weapons from Player
    Reply With Quote #9

    oh so when doing strip robin it would strip the defaults? and if i type the numbers myself it would strip that?
    well i was looking for a meele plugin annyway and this works nicely. thanks.

    yeah sorry about the confusion that was caused by someone else.

    Last edited by Robin955; 04-25-2015 at 23:35.
    Robin955 is offline
    RedSword
    SourceMod Plugin Approver
    Join Date: Mar 2006
    Location: Quebec, Canada
    Old 04-26-2015 , 00:25   Re: [Any] Strip Weapons from Player
    Reply With Quote #10

    Well the square brackets ([]) represent the fact that the argument is optional (as I've seen somewhere else I can't remember), so yes.

    For a melee plugin I suggest you change the default to 124 or 1245 & use sm_strip.
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 06-11-2015 at 21:51.
    RedSword 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 03:20.


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