Skip to content

vbsp_config fizzler

TeamSpen210 edited this page May 15, 2023 · 2 revisions

Fizzlers or Laserfields require a large amount of configuration information, which is used to generate the brushes with the appropriate textures and keyvalues. No Conditions are needed to apply the changes. For each fizzler, a Fizzler block inside a Fizzlers block should be added to vbsp_config. These contain a number of Brush blocks, specifying each brush which should be generated:

"Fizzlers"
	{
	"Fizzler"
		{
		"ID"        "VALVE_MATERIAL_EMANCIPATION_GRID"
		"Item_ID"   "ITEM_BARRIER_HAZARD:fizzler"
		
		"Model"      "..."
		"Model_Left"  "..."
		"Model_Left"  "..."
		"Model_Left_static"  "..."
		"Model_Right" "..."
		"Base_Inst"  "..."
		"Model_Left_Weight" "1, 3, 1"
		
		"OutActivate"  "instance:on_rl;OnTrigger"
		"OutDectivate" "instance:off_rl;OnTrigger"
		
		"TemplateBrush"
			{
			"Left"   "LEFT_TEMPLATE_ID"
			"Right"  "RIGHT_TEMPLATE_ID"
			"Short"  "SHORT_TEMPLATE_ID"
			
			"Keys"
				{
				...
				}
			"LocalKeys"
				{
				...
				}
			}
		
		"Brush"
			{
			"Name"          "cleanser"
			"Side_tint"     "55 100 110"
			"Side_alpha"    "0.5"
			
			"tex_center"    "effects/fizzler_center"
			"tex_left"      "effects/fizzler_l"
			"tex_right"     "effects/fizzler_r"
			"tex_short"     "effects/fizzler"
			"tex_trigger"   "tools/toolstrigger"
			"tex_fitted"    "effects/laserplane"
			
			
			"Keys"
				{
				"classname"     "trigger_portal_cleanser"
				...
				}
			"LocalKeys"
				{
				"target" "blah"
				}
				
			"Singular" "1"
				
			"Mat_mod_name" "mat_mod"
			"Mat_Mod_Var"  "$outputintensity"
			}
		}
	}
  • ID: A unique ID used to identify this fizzler type. This does not have to match the item's ID.
  • Item_ID: The ID of the associated ItemBarrierHazard item that produces this fizzler. Optionally the ID can be suffixed with :fizzler or :laserfield to apply this only to that Hazard Type option. This allows implementing different fizzlers for each subtype.
  • Model: Specifies the instance used for the emitter models. There are several different categories, which generate differently. Multiple names can be specified to choose a random variant for each instance.
    • Model: Basic option, all emitters receive the same filename.
    • Model_Left, Model_Right: when specified Model is not used. For each pair of emitters, one of each instance will be used. This allows setting up env_beams, for example.
    • Model_Single: If set, 128-wide fizzlers will instead use one of these instances centered on the field.
    • Model_Mid: If set, one of these instances will be generated every 128 units spanning the field.
    • Model_static, Model_left_static, etc: If specified, this is used instead of the regular instance when the fizzler has no input connections, allowing use of prop_static etc.
  • Model_Weight, Model_Mid_Weight, etc: An option corresponding to the list of models. This applies weights to the randomisation process.
  • ModelName: A name local to the base instance used to name all the model instance. This allows inputs to be sent directly to it.
  • NameType: Specifies the method used to give names to the models:
    • SAME: Use the same name as the base instance.
    • UNIQUE: Each instance has a unique number added at the end. This allows each instance to do its own effects and behaviour.
    • PAIRED: Each pair of emitters gets the same random number suffix, but distinct to all other models.
    • LOCAL: Use just the suffix.
  • Base_Inst: If set, alters the fizzler base/logic instance. This allows different instances for fizzlers and laserfields.
  • OutActivate, OutDectivate: Set to values like in editoritems. If set, a Fizzler Output Relay is useable to fire these outputs to other items.
  • Brush: For each of these, a brush is generated.
    • Name: The instance-local name to use.
    • Singular: If true, one brush entity is shared among all the emitter pairs. If false, each row gets a different brush entity. This should be true for non-trigger_portal_cleansers, to save on entity costs.
    • Side_tint: If set, a beam material with this colour will be generated and applied to the side. This makes it possible to see the field when facing it fully side-on.
    • Side_alpha: If set, a number from 0-1 making the material more or less transparent.
    • tex_: Specifies the textures to use for the brush, and how they are applied:
      • left, right, center, short: These must all be specified. The brush is generated in the 3 parts required for fizzler fields, using the different textures as appropriate. Other sides are textured as nodraw. The short texture is used for fields ≤ 128 wide.
      • fitted: Generates a single brush, with this texture on the front and back stretched to length. This is used for laserfields. The other sides are also textured with nodraw.
      • trigger: A single brush is used, with all sides textured with this material. This is intended for triggers and clips, producing a nicer Hammer appearance. The side tint is not permitted or useful with this type.
    • Keys: The keyvalues applied to the brush entity. classname is essential to specify the entity class. origin and targetname are automatically set.
    • LocalKeys: Additional keyvalues, which should have their names fixed up to be local to the base instance.
    • Mat_Mod_Name: Local name for a material_modify_control entity generated to alter vars on the textures. Singular must be active for this to work.
    • Mat_Mod_Var: Material modify variable to modify via material_modify_control.
  • TemplateBrush: Only one can be present - this generates a single brush ent from several templates.
    • Left, Right: Paired templates for each emitter side.
    • Short: If specified, used once for 128x128 items.
    • Keys, LocalKeys: Sets the keyvalues used by the entity.
Clone this wiki locally