Sprinkle

From Valve Developer Community
Revision as of 20:28, 7 December 2018 by Polygonerror (talk | contribs) (Saved the page, stormy today.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Entitysprinkledialog.png

The Sprinkle Tool allows for quick placement of pre-defined entities onto your map. The Sprinkle Tool requires a custom script in order for it to place entities.

To open the Sprinkle Tool:

  1. Choose Sprinkle... from the Tools Menu or use the shortcut CTRL+ALT+S to open the Entity Sprinkle dialog.

Adding Types

To add types to the tool, you'll need to make a Sprinkle script. All Sprinkle scripts are located at game abbreviation/scripts/hammer/sprinkle, which usually doesn't exist by default.

A script file can be named anything, along as it ends with the .txt file extension.

"Agave Plants" //This is what shows up in Type
{
	base //The base values of what you want to sprinkle. Every entity will have these values, but you do not need to put anything here
	{
		"classname" "prop_static"
		grid "64 64" // The default grid size of this script, this can be overridden in Hammer
	}
	
	10 //This is the chance of this set of values being used, this can be any number
	{
		"model" "models/props/de_dust/hr_dust/foliage/agave_plant_01.mdl" //The values of this case
	}
	10
	{
		"model" "models/props/de_dust/hr_dust/foliage/agave_plant_02.mdl"
		"rendercolor" "13 204 75"
	}
	10
	{
		"model" "models/props/de_dust/hr_dust/foliage/agave_plant_03.mdl"
		"rendercolor" "13 204 75"
	}
	10 //Since there's 4 cases with the same chance, each case has a 1/4 chance of being placed
	{
		"model" "models/props/de_dust/hr_dust/foliage/agave_plant_04.mdl"
		"uniformscale" "1.3"
	}
}