Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Creating custom weapons - basics: Difference between revisions

From TF2 Classified Wiki
mNo edit summary
mNo edit summary
 
(One intermediate revision by the same user not shown)
Line 269: Line 269:
"<item ID>"
"<item ID>"
{
{
<...>
"attributes"
"attributes"
{
{
Line 287: Line 288:
}
}
}
}
<...>
}
}
}
}
Line 304: Line 306:


<pre>
<pre>
"40000"
"items_game"
{
{
"name" "can headshot VISIBLE"
<...>
"attribute_class" "can_headshot"
"attributes"
"description_format" "value_is_additive"
{
"stored_as_integer" "1"
"40000"
{
"description_string" "#Attrib_RevolverUseHitLocations"
"name" "can headshot VISIBLE"
"attribute_class" "can_headshot"
"description_format" "value_is_additive"
"stored_as_integer" "1"
 
"description_string" "#Attrib_RevolverUseHitLocations"
}
}
}
}
</pre>
</pre>
Line 331: Line 340:


<pre>
<pre>
"attributes"
"items_game"
{
{
"can headshot VISIBLE"
"items"
{
{
"attribute_class" "can_headshot"
"<item ID>"
"value" "1"
{
}
<...>
"damage bonus"
"attributes"
{
{
"attribute_class" "mult_dmg"
"can headshot VISIBLE"
"value" "1.33"
{
}
"attribute_class" "can_headshot"
"clip size penalty"
"value" "1"
{
}
"attribute_class" "mult_clipsize"
"damage bonus"
"value" "0.5"
{
"attribute_class" "mult_dmg"
"value" "1.33"
}
"clip size penalty"
{
"attribute_class" "mult_clipsize"
"value" "0.5"
}
}
<...>
}
}
}
}
}
Line 359: Line 379:


<pre>
<pre>
"40000"
"items_game"
{
{
"name" "can headshot VISIBLE"
<...>
"attribute_class" "can_headshot"
"attributes"
"description_format" "value_is_additive"
{
"stored_as_integer" "1"
"40000"
{
"description_string" "#Attrib_RevolverUseHitLocations"
"name" "can headshot VISIBLE"
"effect_type" "positive"
"attribute_class" "can_headshot"
"description_format" "value_is_additive"
"stored_as_integer" "1"
"description_string" "#Attrib_RevolverUseHitLocations"
"effect_type" "positive"
}
}
}
}
</pre>
</pre>
Line 382: Line 409:


<pre>
<pre>
"item_logname" "pistol_test"
"items_game"
"item_iconname" "winger"
{
"items"
{
"<item ID>"
{
<...>
"item_logname" "pistol_test"
"item_iconname" "winger"


"item_class" "tf_weapon_pistol"
"item_class" "tf_weapon_pistol"


"item_slot" "secondary"
"item_slot" "secondary"
"anim_slot" "secondary"
"anim_slot" "secondary"


"model_player" "models/workshop/weapons/c_models/c_winger_pistol/c_winger_pistol.mdl"
"model_player" "models/workshop/weapons/c_models/c_winger_pistol/c_winger_pistol.mdl"
"image_inventory" "backpack/workshop/weapons/c_models/c_winger_pistol/c_winger_pistol"
"image_inventory" "backpack/workshop/weapons/c_models/c_winger_pistol/c_winger_pistol"


"attach_to_hands" "1"
"attach_to_hands" "1"


"used_by_classes"
"used_by_classes"
{
{
"scout" "1"
"scout" "1"
"engineer" "1"
"engineer" "1"
}
<...>
}
}
}
}
</pre>
</pre>
Line 415: Line 453:


<pre>
<pre>
"model_player_per_class"
"items_game"
{
{
"engineer" "models/weapons/v_models/v_pistol_engineer.mdl"
"items"
"scout" "models/weapons/v_models/v_pistol_scout.mdl"
{
"<item ID>"
{
<...>
"model_player_per_class"
{
"engineer" "models/weapons/v_models/v_pistol_engineer.mdl"
"scout" "models/weapons/v_models/v_pistol_scout.mdl"
}
<...>
}
}
}
}
</pre>
</pre>