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

Content Replacer


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Plugin Info:     Modification:   ALL        Category:   Gameplay        Approver:   Hawk552 (427)
ts2do
Senior Member
Join Date: Mar 2004
Old 08-08-2007 , 13:28   Content Replacer
Reply With Quote #1

About
With this plugin you can replace content in the game with custom content. You can swap any two resources with each other without risking any complications. The plugin precaches any new resources being used.
Usage
Code:
"ContentReplace"
{
	"Models"
	{
		<Entries here would apply to all maps>
		"de_dust;cs_office"
		{
			<Entries here would only apply to de_dust and cs_office>
		}
		"!de_dust;cs_office"
		{
			<Entries here would only apply to maps other than de_dust and cs_office>
		}
	}
	"Sounds"
	{
		<The following replaces in this fashion: hos1->vehicle1, hos2->vehicle2, etc...>
		"hostage/hos(.*).wav" "plats/vehicle(1).wav"
		<The following switches affirmative and negative>
		"!MRAD_AFFIRM" "!MRAD_NEGATIVE"
		"!MRAD_NEGATIVE" "!MRAD_AFFIRM"
	}
}
  • Include models/ in Models entries.
  • Don't include sound/ in Sounds entries.
  • When replacing a sound, check whether or not it's played as a sentence in sound/senteces.txt.
  • Wherever you want a true wildcard in a left-side file, use (.*).
  • To match all models in a specific folder (e.g. no subdirectories), use ([^/]*).
  • When you need to copy over a matched substring [e.g. what matched inside (.*)], use (#). To have the literal text (1) in the replacement, simply use (\1\)
Can Replace
  • All models
  • All sprites
  • Some sounds
Can't Replace
  • Footstep sounds
  • Some weapon sounds
Notes
  • You must have the Vdf module installed on the server.
  • Texture models should not explicitly be replaced (e.g. *t.mdl).
  • Sprites should be added to the Models branch.
  • Always remember that introducing new content requires users to download that content and may cause a long download time.
Version 1.0
  • Initial release
Version 1.1
  • Added sentence support
Version 1.2
  • Map-specific configuration
  • Sprite support
Version 1.3
  • Regex
  • Vdf utilization
Version 1.4
  • Precache *t models
  • Cellarray utilization (in the latest build of AMX Mod X)
    Note that the online compiler does not support 1.80, so the plugin has been compiled and compressed into the attached contentreplace.zip.
Attached Files
File Type: sma Get Plugin or Get Source (contentreplace.sma - 4312 views - 13.9 KB)
File Type: zip contentreplace.zip (14.4 KB, 2816 views)

Last edited by ts2do; 08-30-2007 at 22:45.
ts2do is offline
Send a message via AIM to ts2do
 



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 21:59.


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