$collisiontext: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
mNo edit summary
Line 1: Line 1:
<div style="float:right;padding:0 1em;background:#FFF;">__TOC__</div>
<div style="float:right;padding:0 1em;background:#FFF;">__TOC__</div>
{{stub}}[[Category: QC Commands]]
{{stub}}[[Category: QC Commands]]
* The [[$collisiontext]] [[QC command]] is used to define a breakable model's ''custom gibset'' (''generic'' gibs are defined by [[Prop Data#Gibs|$keyvalues - prop_data - breakable_model]]).
 
The [[$collisiontext]] [[QC command]] is used to define a breakable model's ''custom gibset'' (''generic'' gibs are defined by [[Prop Data#Gibs|$keyvalues - prop_data - breakable_model]]).
 
{{tip|Use [[$autocenter]] to ensure gibs spawn in the correct position relative to the breaking model.}}
{{tip|Use [[$autocenter]] to ensure gibs spawn in the correct position relative to the breaking model.}}
* {{todo| is [[propdata]] also required when using $collisiontext ?}}


== QC syntax example ==
== QC syntax example ==
  [[$collisiontext]]
  [[$collisiontext]]
  {  
  {  
  break { [[$collisiontext#model|"model"]] "mycustomgib1" [[$collisiontext#health|"health"]] "1" [[$collisiontext#fadetime|"fadetime"]] "0" }  
  break { [[#model|"model"]] "mycustomgib1" [[#health|"health"]] "1" [[#fadetime|"fadetime"]] "0" }  
  break { "model" "mycustomgib1" "health" "1" "fadetime" "0" }  
  break { "model" "mycustomgib2" "health" "1" "fadetime" "0" }  
  }
  }



Revision as of 09:17, 6 May 2008

Stub

This article or section is a stub. You can help by expanding it.

The $collisiontext QC command is used to define a breakable model's custom gibset (generic gibs are defined by $keyvalues - prop_data - breakable_model).

Tip.pngTip:Use $autocenter to ensure gibs spawn in the correct position relative to the breaking model.
  • Todo:  is propdata also required when using $collisiontext ?

QC syntax example

$collisiontext
{ 
	break { "model" "mycustomgib1" "health" "1" "fadetime" "0" } 
	break { "model" "mycustomgib2" "health" "1" "fadetime" "0" } 
}

break options

model

  • specifies the name of the .mdl to use as a gib.

ragdoll

  • Todo: guess: specifies the name of a ragdoll model to break into, eg when zombies get cut in half ?

offset

health

fadetime

fademindist

fademaxdist

debris

burst

placementbone

placementattachment