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

[L4D2] Map Weapon Manager


Post New Thread Reply   
 
Thread Tools Display Modes
Author
LinLinLin
Senior Member
Join Date: Sep 2021
Plugin ID:
8438
Plugin Version:
1.0.0
Plugin Category:
All
Plugin Game:
Left 4 Dead
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Old 04-12-2023 , 15:48   [L4D2] Map Weapon Manager
    Reply With Quote #1

    Introuduction:
    I know many people use Vscript in nut to modify the default weapon which is spawn by map. I just make it in plugin. Now you can use this plugin to modify which weapon should spawn on map, which will not.

    Feature:
    1. If you want to ban a weapon in map, just make the "enable" count to 0.
    2. This plugin only prevent the entity which spawn by map. You could use the ban weapon by "give" command or any other way you want.


    KV File:
    Code:
    "weapon"
    {
    	"weapon_pistol_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_pistol_magnum_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_smg_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_smg_silenced_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_smg_mp5_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_pumpshotgun_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_shotgun_chrome_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_autoshotgun_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_shotgun_spas_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_rifle_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_rifle_ak47_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_rifle_desert_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_rifle_sg552_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_hunting_rifle_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_sniper_military_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_sniper_awp_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_sniper_scout_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_rifle_m60_spawn"
    	{
    		"enable"		"1"
    	}
    	"weapon_grenade_launcher_spawn"
    	{
    		"enable"		"1"
    	}
    }
    Update:
    Code:
    [2023-4-16]
    1, delete the cvar, using kv file instead.
    Known Issue:
    • If the plugin start work, it makes the map spawn weapon in random, and you could see the tier2 weapon in the first chapter. I have no idea to solve that because it seems diffcult to get the KeyValue "weapon_selection" of the entity "weapon_spawn". So i simply use random.
    Attached Files
    File Type: sp Get Plugin or Get Source (map_weapon_manager.sp - 282 views - 6.6 KB)

    Last edited by LinLinLin; 04-15-2023 at 15:47.
    LinLinLin is offline
    LinLinLin
    Senior Member
    Join Date: Sep 2021
    Old 04-16-2023 , 03:49   Re: [L4D2] Map Weapon Manager
    Reply With Quote #2

    since OnConfigExcute is after than map start, it doesn't get the setting config when first time server start.
    so i use kv to setting config and get it when OnPluginStart fire.

    Last edited by LinLinLin; 04-16-2023 at 03:49.
    LinLinLin 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 22:52.


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