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

[L4D] Silencer Weapon.


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Aya Supay
Member
Join Date: Nov 2015
Plugin ID:
5911
Plugin Version:
1.0
Plugin Category:
Gameplay
Plugin Game:
Left 4 Dead
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Only a simple plugin that deactivates the sound of the primary weapons in the game.
    Old 11-12-2017 , 17:05   [L4D] Silencer Weapon.
    Reply With Quote #1

    I've had this plugin for a few months now. I figured I'd just share it with you guys


    Fixed all the errors and converted the original source code into the new syntax ..
    Attached Files
    File Type: sp Get Plugin or Get Source (silencer.sp - 1522 views - 1,013 Bytes)

    Last edited by Aya Supay; 11-12-2017 at 18:28.
    Aya Supay is offline
    headline
    SourceMod Moderator
    Join Date: Mar 2015
    Old 11-12-2017 , 17:36   Re: [L4D] Silencer Weapon.
    Reply With Quote #2

    Use the MaxClients variable instead of GetMaxClients()

    It'll be depreciated in the future
    headline is offline
    Aya Supay
    Member
    Join Date: Nov 2015
    Old 11-12-2017 , 18:29   Re: [L4D] Silencer Weapon.
    Reply With Quote #3

    I'm sorry it's already solved thanks for watching friend
    Aya Supay is offline
    Striker black
    Member
    Join Date: Apr 2013
    Old 11-12-2017 , 19:28   Re: [L4D] Silencer Weapon.
    Reply With Quote #4

    Oh, fence a plugin provided by third parties

    Question: it is necessary to use the "#pragma newdecls required"?

    It is better to use the code clean and without so many manipulations


    PHP Code:
    #include <sourcemod>

    public Plugin myinfo 
    {
        
    name "[L4D] Silencer Weapon.",
        
    author "Figa",
        
    description "",
        
    version "",
        
    url ""
    }

    public 
    OnPluginStart()
    {
        
    RegAdminCmd("sm_silenceron"EnableAllSilencerOnADMFLAG_CHANGEMAP"sm_silenceron - enable silencer");
        
    RegAdminCmd("sm_silenceroff"EnableAllSilencerOffADMFLAG_CHANGEMAP"sm_silenceroff - disable silencer");
    }
    public 
    Action:EnableAllSilencerOn(clientargs)
    {
        new 
    max MaxClients();
        for(new 
    i=1i<=maxi++)
        {
            if (
    IsClientConnected(i) && IsClientInGame(i) && !IsFakeClient(i) && GetClientTeam(i) == 2)
        
    SetEntProp(iProp_Send"m_upgradeBitVec"2621444);
        }
    }
    public 
    Action:EnableAllSilencerOff(clientargs)
    {
        new 
    max MaxClients();
        for(new 
    i=1i<=maxi++)
        {
            if (
    IsClientConnected(i) && IsClientInGame(i) && !IsFakeClient(i) && GetClientTeam(i) == 2)
        
    SetEntProp(iProp_Send"m_upgradeBitVec"04);
        }

    Striker black is offline
    Aya Supay
    Member
    Join Date: Nov 2015
    Old 11-12-2017 , 19:39   Re: [L4D] Silencer Weapon.
    Reply With Quote #5

    how is it in the code I just edit it with the new syntax just for sharing with all I do not specify that it was mine the name of the author is in the sp
    Aya Supay is offline
    edu.1962
    Member
    Join Date: Mar 2010
    Old 11-16-2017 , 06:16   Re: [L4D] Silencer Weapon.
    Reply With Quote #6

    Quote:
    Originally Posted by Aya Supay View Post
    I've had this plugin for a few months now. I figured I'd just share it with you guys


    Fixed all the errors and converted the original source code into the new syntax ..
    This plugin work's on both l4d and l4d2? Ty
    edu.1962 is offline
    edu.1962
    Member
    Join Date: Mar 2010
    Old 11-17-2017 , 02:27   Re: [L4D] Silencer Weapon.
    Reply With Quote #7

    Quote:
    Originally Posted by Aya Supay View Post
    I suppose this should work for l4d2
    L 11/17/2017 - 05:23:08: SourceMod error session started
    L 11/17/2017 - 05:23:08: Info (map "c8m1_apartment") (file "errors_20171117.log")
    L 11/17/2017 - 05:23:08: [SM] Native "SetEntProp" reported: Property "m_upgradeBitVec" not found (entity 1/player)
    L 11/17/2017 - 05:23:08: [SM] Displaying call stack trace for plugin "silencer.smx":
    L 11/17/2017 - 05:23:08: [SM] [0] Line 53, /home/groups/sourcemod/upload_tmp/phpI8P2hn.sp:isableAllUpgrades()
    L 11/17/2017 - 05:23:08: [SM] [1] Line 49, /home/groups/sourcemod/upload_tmp/phpI8P2hn.sp::OnClientPutInServer()
    L 11/17/2017 - 05:23:14: [SM] Native "SetEntProp" reported: Property "m_upgradeBitVec" not found (entity 1/player)
    L 11/17/2017 - 05:23:14: [SM] Displaying call stack trace for plugin "silencer.smx":
    L 11/17/2017 - 05:23:14: [SM] [0] Line 53, /home/groups/sourcemod/upload_tmp/phpI8P2hn.sp:isableAllUpgrades()
    L 11/17/2017 - 05:23:14: [SM] [1] Line 44, /home/groups/sourcemod/upload_tmp/phpI8P2hn.sp::player_death()
    edu.1962 is offline
    Striker black
    Member
    Join Date: Apr 2013
    Old 01-13-2018 , 15:42   Re: [L4D] Silencer Weapon.
    Reply With Quote #8

    Quote:
    Originally Posted by Aya Supay View Post
    how is it in the code I just edit it with the new syntax just for sharing with all I do not specify that it was mine the name of the author is in the sp

    You are not the author to proclaim yourself as such. If you added the latest syntax or added a few lines does not mean that you are the almighty.

    PHP Code:
    public Plugin myinfo 
    {
        
    name "[L4D] Silencer Weapon.",
        
    author "Figa edited by [†×Ą]AYA SUPAY[Ļ×Ø]",
        
    description "",
        
    version "1.0",
        
    url "http://steamcommunity.com/id/AyaSupay/"
    }; 
    This is a lack of respect toward the real author.

    You should learn how these real developers are not advertised as authors
    https://forums.alliedmods.net/showpo...4&postcount=11

    Last edited by Striker black; 01-13-2018 at 15:53.
    Striker black is offline
    MasterMind420
    BANNED
    Join Date: Nov 2010
    Old 01-19-2018 , 09:08   Re: [L4D] Silencer Weapon.
    Reply With Quote #9

    Quote:
    Originally Posted by Striker black View Post
    You are not the author to proclaim yourself as such. If you added the latest syntax or added a few lines does not mean that you are the almighty.

    PHP Code:
    public Plugin myinfo 
    {
        
    name "[L4D] Silencer Weapon.",
        
    author "Figa edited by [†×Ą]AYA SUPAY[Ļ×Ø]",
        
    description "",
        
    version "1.0",
        
    url "http://steamcommunity.com/id/AyaSupay/"
    }; 
    This is a lack of respect toward the real author.

    You should learn how these real developers are not advertised as authors
    https://forums.alliedmods.net/showpo...4&postcount=11
    Firstly, if the original code is on allied modders, and the original author isn't active or working on this specific plugin anymore. As long as his names in the .sp, which gives him credit. Then what he did wasn't disrespectful. I highly doubt figa would see this as disrespectful to him. This is an open source community afterall. Don't want your shit used in this way well, don't post it here then, this is a very common practice by coders to redo others plugins. But of coarse always give credit.
    MasterMind420 is offline
    TiTz
    Member
    Join Date: Jan 2020
    Old 03-03-2020 , 08:02   Re: [L4D] Silencer Weapon.
    Reply With Quote #10

    Hi,

    Would it be possible to add an optional cvar to switch on sounds for a weapon that are very quiet?

    The sounds in mind would be:

    \left4dead\left4dead\sound\weapons\fx\rics

    ric6.wav
    ric7.wav
    ric8.wav
    ric9.wav

    Would be perfect noises for every time you fire a weapon.

    It would randomly play one of these four wav's every time you hit the fire button.
    (if random not easy or possible - just one wav would be good)

    It would give the firing of the gun a more defined feeling.

    Regards

    TiTz

    Last edited by TiTz; 03-03-2020 at 08:05.
    TiTz 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 03:06.


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