This article's documentation is for anything that uses the Source engine. Click here for more information.

Prop detail sprite: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
Line 11: Line 11:
{{KV|[[Origin]] (X Y Z)|intn=origin|coordinates|The position of this entity's center in the world. Rotating entities typically rotate around their origin.}}
{{KV|[[Origin]] (X Y Z)|intn=origin|coordinates|The position of this entity's center in the world. Rotating entities typically rotate around their origin.}}
{{KV|[[Pitch Yaw Roll]] (X Y Z)|intn=angles|angle|This entity's orientation in the world. Pitch is rotation around the Y axis, yaw is the rotation around the Z axis, roll is the rotation around the X axis.}}
{{KV|[[Pitch Yaw Roll]] (X Y Z)|intn=angles|angle|This entity's orientation in the world. Pitch is rotation around the Y axis, yaw is the rotation around the Z axis, roll is the rotation around the X axis.}}
; <code>detailOrientation <[[int]]></code>
{{kv|detailOrientation|intn=detailOrientation|int|See [[Detail props#Sprites|Detail props]].}}
: See [[Detail props#Sprites|Detail props]].
{{kv|position_ul|intn=position_ul|Vector2D|The location of the sprite's upper left corner, relative to its origin.}}
; <code>position_ul <[[Vector2D]]></code>
{{kv|position_lr|intn=position_lr|Vector2D|The location of the sprite's lower right corner, relative to its origin.}}
: The location of the sprite's upper left corner, relative to its origin.
{{kv|tex_ul|intn=tex_ul|Vector2D|The X Y position of the sprite's upper left corner on the detail texture.}}
; <code>position_lr <Vector2D></code>
{{kv|tex_size|intn=tex_size|Vector2D|The area of the detail texture that should constitute this sprite (dimensions of the sprite in [[texel]]s). See [[Detail props#Sprites]].}}
: The location of the sprite's lower right corner, relative to its origin.
{{kv|tex_total_size|intn=tex_total_size|int|The width (X-axis resolution) of the detail texture.}}
; <code>tex_ul <Vector2D></code>
: The X Y position of the sprite's upper left corner on the detail texture.
; <code>tex_size <Vector2D></code>
: The area of the detail texture that should constitute this sprite (dimensions of the sprite in [[texel]]s). See [[Detail props#Sprites]].
; <code>tex_total_size <int> </code>
: The width (X-axis resolution) of the detail texture.


==Example==
==Example==
Line 48: Line 42:
; <code>tex_size <83 128></code>
; <code>tex_size <83 128></code>
; <code>tex_total_size <512> </code>
; <code>tex_total_size <512> </code>
== FGD Code ==
{{empty}}


[[Category:Prop entities|detail sprite]]
[[Category:Prop entities|detail sprite]]

Revision as of 20:23, 4 March 2025

Icon-NotInFGD.png
This entity is not in the FGD by default.
See below for instructions on making it available.

prop_detail_sprite is an internal point entity available in all Source Source games. It allows manual insertion of detail sprites into a level.

See Detail props#Sprites for detailed information about setting up detail props through .VBSP files.

Tip.pngTip:Only use this entity if you are desperate. It is much better to assign a material a %detailtype and let VBSP generate detail sprites itself.

Template:Intent

Keyvalues

!FGDThis entity is not in Valve's FGDs. Its properties must be set with SmartEdit disabled.

Origin (X Y Z) (origin) <coordinates>
The position of this entity's center in the world. Rotating entities typically rotate around their origin.
Pitch Yaw Roll (X Y Z) (angles) <angle>
This entity's orientation in the world. Pitch is rotation around the Y axis, yaw is the rotation around the Z axis, roll is the rotation around the X axis.
detailOrientation (detailOrientation) <integer>
See Detail props.
position_ul (position_ul) <Vector2D>
The location of the sprite's upper left corner, relative to its origin.
position_lr (position_lr) <Vector2D>
The location of the sprite's lower right corner, relative to its origin.
tex_ul (tex_ul) <Vector2D>
The X Y position of the sprite's upper left corner on the detail texture.
tex_size (tex_size) <Vector2D>
The area of the detail texture that should constitute this sprite (dimensions of the sprite in texels). See Detail props#Sprites.
tex_total_size (tex_total_size) <integer>
The width (X-axis resolution) of the detail texture.

Example

Here is an example of a sprite from a custom .VBSP file.

			RoseFlower
			{
				sprite "0 0 83 128 512"
				spritesize "0.5 0.05 7 13"
				spriterandomscale .3
				amount 0.02
				detailorientation 2
				sway 0.2
				upright 1
				maxangle 70
			}

To place this sprite manually, the entity would be set up in this way:

detailOrientation <2>
position_ul <0 13>
position_lr <7 0>
tex_ul <0 0>
tex_size <83 128>
tex_total_size <512>

FGD Code

Empty

This article or section is empty. You can help by adding it.