AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [L4D & L4D2] Mission and Weapons - Info Editor (1.25) [25-Oct-2023] (https://forums.alliedmods.net/showthread.php?t=310586)

Silvers 09-10-2018 22:22

[L4D & L4D2] Mission and Weapons - Info Editor (1.25) [25-Oct-2023]
 
34 Attachment(s)
About:
  • This plugin provides 2 configs to modify mission info and weapon info data.
  • There are lots of possibilities, search the internet for guides.
  • Yee15467982314 posted on Gamebanana various weapon configs.
  • Here is a guide on SteamCommunity with details on modifying weapons, you only need to copy the key values to this plugins config.
  • Valve wiki has information on L4D2 Mission Files.
  • Info .txt scripts can be found in your games \left4dead2\pak01_dir.vpk, navigate to /missions/, /scripts/ and /scripts/melee/ folders.
  • Weapon Info examples can be found in the "weapon_*" .txt files in the /scripts/ folder.
  • The provided configs do not show all possible key values to edit, you'll have to search the internet.
  • Some key values will have no affect since they are client side.
  • Plugin version convar l4d_info_editor_version.
  • Please share your changes or configs with others.



Mission Info: Features: (saved to \sourcemod\data\l4d_info_editor_mission.cfg)
  • Add female Boomers
  • Change tank model
  • Boss spawning chance per chapter
  • Specify melee weapons allowed (replaces Melee Spawn Control extension)
  • Automatically adds 3rd party melee weapons on maps that provide.
  • + more

Weapon Info: Features: (saved to \sourcemod\data\l4d_info_editor_weapons.cfg)
  • Change shooting sounds and first person view models
  • Change damage,damage type, reload time and various values for each weapon
  • Possibly replace infected team claws with guns and vice versa?
  • Possibly allow bots to pickup and use chainsaws (currently untested)
    (requires extra vscripts not provided here, search for the Chainsaw Bots VPK addon)
  • + more



Game Mode overrides:
  • The plugin will attempt to load "l4d_info_editor_weapons.versus.cfg" or other game mode named config. If that file does not exist it will load the default "l4d_info_editor_weapons.cfg" data config file.
  • When loading the default "l4d_info_editor_weapons.cfg" file, if it contains it's own "versus" or other game mode sections they will overwrite any duplicate data already read from the "all" or map specific sections, unless the map specific section is placed after the game mode specific section.
  • This also applies to the "l4d_info_editor_mission.cfg" data config.
  • Works for all game modes, any value the "mp_gamemode" cvar accepts.



Natives and Forwards for developers:
Spoiler




Admin Commands: (requires "z" flag)

PHP Code:

sm_info_weapons_list        // Show weapons config tree of modified data for this map.
sm_info_mission_list        // Show mission config tree of modified data for this map.
sm_info_mission             // Get or set the value of a mission keyname. Usage: sm_info_mission <keyname> [value].
sm_info_reload              // Reloads the mission and weapons configs. Weapons info data is re-parsed allowing changes to be made live without changing level.
sm_info_melee               // (L4D2 only) Lists the maps current melee weapons allowed and report any issues. 



Thanks:
  • Lux
  • Dragokas
  • Crasher_3637
  • JKing
  • Iizuka07
  • Yabi
  • ProjectSky
  • Mi.Cura



Changes:
Code:

1.25 (07-Nov-2023)
    - Fixed missing "data/l4d_info_editor_mission.cfg" config in the archive. Thanks to "HarryPotter" for reporting.

1.25 (25-Oct-2023)
    - Test plugins will now throw an error if running, to notify server owners they should only be using for testing and as an example.

1.24 (19-Sep-2023)
    - Update for L4D2:
    - Fixed not precaching the Knife model. Thanks to "S.A.S" for reporting.
    - Fixed not loading melee weapons on some 3rd party maps that are missing the "meleeweapons" key value. Thanks to "Iizuka07" for reporting.

1.23 (10-Sep-2023)
    - Fixed mistake with the last update not reading the weapons config. Thanks to "ProjectSky" for reporting.

1.22 (10-Sep-2023)
    - Fixed not loading the map specific sections. Thanks to "KadabraZz" for reporting.
    - The config data load order slightly changed:
    - 1. Attempt to load "all" section.
    - 2. Attempt to load custom maps section.
    - 3. Attempt to load game mode specific configs.
    - 4. Attempt to load game mode specific sections within a config.
    - 5. Game mode specific sections can be overwritten by map specific sections when the map specific section is below the game mode specific section.

    - The default config files have been cleaned up, and example config files provided instead.

1.21 (09-Sep-2023)
    - Update for L4D2 to precache melee weapon models to prevent crashes. Wrongly was OnMapEnd instead of OnMapStart.

1.20 (05-Sep-2023)
    - Update for L4D2 to precache melee weapon models to prevent crashes. Thanks to "S.A.S" for reporting.

1.19 (16-Dec-2022)
    - Fixed not loading melee weapons on certain maps under certain conditions. Thanks to "Mi.Cura" for reporting.
    - Feature added: plugin can load mode specific sections that overwrite previous data loaded from the "l4d_info_editor_mission.cfg" config. Requested by "ProjectSky".
    - Feature added: plugin can load mode specific configs, e.g. "l4d_info_editor_mission.versus.cfg" or "l4d_info_editor_mission.mutation3.cfg" for "Versus" or "Bleedout" modes etc.
    - These features also apply to the "l4d_info_editor_weapons.cfg" data config.

1.18 (15-Dec-2022)
    - Fixed duplicating custom melee weapons in the mission keyvalue string. Thanks to "ProjectSky" for reporting.
    - Fixed not loading melee weapons if the "Info Editor" config is missing a "meleeweapons" key to use.

1.17 (12-Dec-2022)
    - Forgot to turn off debug printing values.

1.16 (11-Dec-2022)
    - Fixed error in command "sm_info_melee" causing it to not display everything correctly.

1.15 (11-Dec-2022)
    - L4D2: Now supports 3rd party melee weapons where the mission.txt file does not contain a "meleeweapons" key. Thanks to "Yabi" for reporting and testing.
    - L4D2: Added command "sm_info_melee" to list the maps currently allowed melee weapons and report any issues.
    - L4D2: GameData file has updated to support these changes.

1.14 (21-Oct-2022)
    - Fixed plugins not loading with the updated include file.
    - Include file updated.

1.13 (20-Oct-2022)
    - L4D2: Plugin now prevents setting over 16 melee weapons. Thanks to "gabuch2" for reporting.
    - Compiled .smx plugin is now compiled with SourceMod version 1.11.

1.12 (01-Oct-2020)
    - Fixed not properly adding both melee weapons causing potential issues.

1.11 (24-Sep-2020)
    - Compatibility update for L4D2's "The Last Stand" update.
    - Added support for the 2 new melee weapons.
    - GameData .txt file updated.

1.10 (02-Jul-2020)
    - Fixed not always loading the correct map section data in the config for the current map.
    - Fixed not adding 3rd party melee weapons on all 3rd party maps. Thanks to "Shao" for reporting.

1.9 (10-May-2020)
    - Added better error log message when gamedata file is missing.
    - Now supports setting strings to "" when using the "InfoEditor_SetString" native.
    - Various changes to tidy up code.
    - Various optimizations and fixes.

1.8 (29-Apr-2020)
    - Changed "InfoEditor_GetString" and "InfoEditor_SetString" natives to not require the mission pointer.
    - Specifying 0 when calling will make Info Editor use the last known mission pointer value.
    - A valid pointer will still be required to read weapons data.

1.7 (12-Apr-2020)
    - Fixed breaking some melee entries when adding 3rd party melee names containing similar classnames.
    - Thanks to "Marttt" for reporting.

1.6 (10-Apr-2020)
    - Added support to match multiple map names using comma separation in the data configs, as requested by "Lux".
    - Added "clip_size", "ReloadDuration", "CycleTime", "Damage", "Range" and "RangeModifier" to "l4d_info_editor_weapons.cfg" config.
    - Values shown are default from L4D2 weapon scripts.
    - Fixed not creating keys for weapons and accidentally creating them on the mission file instead.

1.5 (01-Apr-2020)
    - Changed command block to allow listen servers to operate the reload command.
    - Changed .inc file to remove args from copy paste error of "InfoEditor_ReloadData" native.

1.4 (18-Mar-2020)
    - Added native "InfoEditor_ReloadData" for external plugins to reload the mission and weapon configs.
    - Fixed crashing with "CTerrorWeaponInfo::Reload" error. Finally!

1.3 (25-Feb-2020)
    - Now dynamically generates "meleeweapons" string for any map using custom melee weapons.
    - Set the string to the default game weapons you want to include, and the custom ones will be added.
    - Mission config "l4d_info_editor_mission.cfg" updated with changes for "Helms Deep" map.

1.2 (17-Sep-2019)
    - No longer removing cheat flags from "sb_all_bot_game" command, was never deleted from testing.

1.1.1a (25-Aug-2019) re-upload
    - Added "helms_deep" section in the mission config to enable all melee weapons on that map.

1.1.1 (09-Jun-2019)
    - Added FORCE_VALUES define to force create missing keys.
    - Slightly optimized fixing single line mistake.
    - Slight code cleaning.

1.1 (01-Jun-2019)
    - Fixed reading incorrect data for map specific sections.
    - Added support to load map specific weapon and melee data.
    - Added commands to display mission and weapon changes applied to the current map.
    - Added a command to get and set keyname values from the mission info.
    - Added a command to reload the mission and weapons configs. Live changes can be made!
    - Added natives to read and write mission and weapon data from third party plugins.
    - Added test plugin to demonstrate natives and forwards for developers.
    - Gamedata .txt changed.

1.0 (10-Sep-2018)
    - Initial release.



Conflicts:
  • [EXTENSION] Melee Spawn Control is replaced by this plugin.
  • Custom melee weapons are automatically added on top of your "meleeweapons" string from the "all" or map section.
  • Maximum 16 melee weapons so create a section for that map and omit some default melee weapons if the maps custom + default melee weapons exceed the limit.

Requirements:
Installation:
  • Download the .zip and extract the files to their respective folders in your servers \addons\sourcemod\ folder.
  • (Included are two example scripts l4d_info_test and l4d_info_editor_weapons for developers, not required to operate the plugin.)

Xanaguy 09-11-2018 01:23

Re: [L4D & L4D2] Mission and Weapons - Info Editor (1.0) [10-Sep-2018]
 
I hope this blocks the special instant fail of c7m3_port. Because I need to get rid of that special trigger.

Psyk0tik 09-11-2018 02:13

Re: [L4D & L4D2] Mission and Weapons - Info Editor (1.0) [10-Sep-2018]
 
This will make adding support for custom melee weapons a lot easier! Nice one man! :D

Spirit_12 09-11-2018 07:40

Re: [L4D & L4D2] Mission and Weapons - Info Editor (1.0) [10-Sep-2018]
 
As I stated earlier I needed something to alter weapon attributes without using Downtown2. This one should do nicely.

Great value! I wonder if this can make campaign only maps run versus on them.

disawar1 09-11-2018 10:21

Re: [L4D & L4D2] Mission and Weapons - Info Editor (1.0) [10-Sep-2018]
 
And as always, good job!

Spirit_12 09-11-2018 21:41

Re: [L4D & L4D2] Mission and Weapons - Info Editor (1.0) [10-Sep-2018]
 
Just found a little bug. I'm unable to shove with the pistol.

Silvers 09-12-2018 02:36

Re: [L4D & L4D2] Mission and Weapons - Info Editor (1.0) [10-Sep-2018]
 
Quote:

Originally Posted by Spirit_12 (Post 2614803)
Just found a little bug. I'm unable to shove with the pistol.

Many things can break by setting bad values. By default this is not an issue.

mikaelangelis 09-12-2018 09:39

Re: [L4D & L4D2] Mission and Weapons - Info Editor (1.0) [10-Sep-2018]
 
So i need to get rid of melee weapon spawn extension? or do i just leave it alone in folder and paste this zip?

Spirit_12 09-12-2018 11:02

Re: [L4D & L4D2] Mission and Weapons - Info Editor (1.0) [10-Sep-2018]
 
Quote:

Originally Posted by mikaelangelis (Post 2614877)
So i need to get rid of melee weapon spawn extension? or do i just leave it alone in folder and paste this zip?

Both plugin and the extension do the same job. There is no reason to keep them both.

sirphr 01-30-2019 21:46

Re: [L4D & L4D2] Mission and Weapons - Info Editor (1.0) [10-Sep-2018]
 
Code:

L 01/30/2019 - 21:44:04: [SM] Exception reported: Failed to find "CTerrorGameRules::GetMissionInfo" signature.
L 01/30/2019 - 21:44:04: [SM] Blaming: l4d_info_editor.smx
L 01/30/2019 - 21:44:04: [SM] Call stack trace:
L 01/30/2019 - 21:44:04: [SM]  [0] SetFailState
L 01/30/2019 - 21:44:04: [SM]  [1] Line 109, C:\Servers\L4D2\left4dead2\addons\sourcemod\scripting\l4d_info_editor.sp::OnPluginStart
L 01/30/2019 - 21:44:04: [SM] Unable to load plugin "l4d_info_editor.smx": Error detected in plugin startup (see error logs)



All times are GMT -4. The time now is 07:19.

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