Help:Boilerplate weapon

From PZwiki
Revision as of 15:30, 20 June 2018 by Connall (talk | contribs) (Changed protection level for "Help:Boilerplate weapon" ([Edit=Allow only autoconfirmed users] (indefinite) [Move=Allow only administrators] (indefinite)))


   Page Updated @ Version: 36.40   
   Navigation - Main Index -> Community -> Templates -> Boilerplates -> Boilerplate Weapons   
This boilerplate is used for giving a new page a standard look. Copy the code below and add it to your new page before adding the relevant content. This boilerplate is currently in an early format and we are likely to add and change sections as time goes on. If you wish to suggest improvements to this boilerplate please use the Help_talk:Boilerplate_weapons discussion page.
The current code and result of the code are shown below. Anything starting with !< -- and ends with --> is removable and will not affect the template.



<!--Comment: This section is for the language and the format of the page. The languages section is used for linking pages. So a example might be {{languages|Nails}} in which every page is connected with a /## on the end will link to that specific page. Eg: Nails/es Nails/fr even if there contain redirects. The header format can be seen in the header template with working explanation. The header connects categories and Version no. PLEASE ENTER THE VERSION AND INCREMENT No. WHEN YOU MAKE A PAGE. It helps everyone else know how old the page is versionwise -->
__NOTOC__
{{languages}}
{{header|The Game World|Items|Weapons|version=Version 36|incver=40}}
<!--Comment: This section is for the infobox which will be positioned on the right of the page. Image.png is the default question mark image. The information can be pulled from the items/newitems.txt file in [Zomboid Folder\media\scripts] -->
{{Weapons
|image = Baseballbat.png 
|weapontype = Melee 
|ammo = None
|mindamage = 1
|maxdamage = 2
|condition = 1.5
|hands=Yes
|degrade = 10
|weight = 3.0
|id = 7828
}}
<!--Comment: Description of Item and General Information-->
A description of the item. Include [[Nails|links]] (example link is to Nails article) to other pages within the wiki where appropriate. Also try to mention how many uses it has and also where it was found. 

With weapons, try to mention swing speed, how many zombies it can hit (see code "maxhitcount" for amount of zombies hit), durability, range and usefulness. 

== Crafting ==
<!--Comment: Code in crafting template which uses the item. This is rare for weapons but is used on occasion. Remove if not applicable. See RecipeLookup Template for full list-->
{| class="wikitable sortable" style="text-align:center;" 
|- 
! Output
! class="unsortable" | Ingredients
! class="unsortable" | Description
! Skill Level
{{RecipeLookup|3001}}
|}

== Materials to Repair ==
<!--Comment: This uses the code found in the repair file [Zomboid Folder\media\scripts\fixing.txt] which defines what it costs to repair the weapon. The table below is a graphical representation of what is required to repair. -->
{| class="wikitable" style="text-align:center;" 
|-
! Item Repaired
! 1st Repair Materials = <br> 55% Repaired, 100% Success
!  <br> 20% Repaired, 95% Success
!  <br> 10% Repaired, 95% Success
!  <br> 10% Repaired, 95% Success
|-
|[[File:Baseball Bat.png|32px]] <br>
[[Baseball Bat]]
| [[File:Woodglue.png|32px]]<br>
[[Wood Glue]] <small>(2 Uses)</small><br>
<small>(Requires Carpentry Level 2)</small>
| [[File:DuctTape.png|32px]]<br>
[[Duct Tape]] <small>(2 Uses)</small>
| [[File:Glue.png|32px]]<br>
[[Glue]] <small>(2 Uses)</small>
| [[File:MATERIALScotchTape.png|32px]]<br>
[[Adhesive Tape]] <small>(4 Uses)</small>
|-
|}
=== Repair Code ===
<!--Comment: This is the code found in the repair file [Zomboid Folder\media\scripts\fixing.txt] which defines what it costs to repair the weapon.  -->
 
	fixing Fix Baseball Bat

     Require : BaseballBat,

       Fixer : Woodglue=2; Woodwork=2,
       Fixer : DuctTape=2,
       Fixer : Glue=2,
       Fixer : Scotchtape=4,
 

== Code ==
<!--Comment: Current location of Code in directory for updating purposes. Example below shows how to lay it out. ''''' is for bold italic.-->
'''''From items.txt (Project Zomboid directory/media/scripts/)'''''
<!--Comment: Example code taken from file. Items.txt and Newitems.txt are usually the source of the information at this time for basic items. Nowiki is used to display the text only, example used is RoastingPan shells.-->

 <nowiki>	
	item BaseballBat
		MaxRange			= 1.5,
		WeaponSprite			= Baseballbat,
		MinAngle			= 0.2,
		Type				= Weapon,
		MinimumSwingTime		= 3,
		KnockBackOnNoDeath		= TRUE,
		SwingAmountBeforeImpact		= 0.02,
		Categories			= Blunt,
		ConditionLowerChanceOneIn	= 20,
		Weight				= 2,
		SplatN.umber			= 1,
		PushBackMod			= 0.5,
		MaxDamage			= 1.2,
		SubCategory			= Swinging,
		ConditionMax			= 15,
		MaxHitCount			= 2,
		DoorDamage			= 7,
		IdleAnim			= Idle_Weapon2,
		SwingAnim			= Bat,
		CriticalChance			= 10,
		WeaponWeight			= 2,
		DisplayName			= Baseball Bat,
		MinRange			= 0.61,
		SwingTime			= 3,
		HitAngleMod			= -30,
		MinDamage			= 0.8,
		KnockdownMod			= 2,
		SplatBloodOnNoDeath		= FALSE,
		Icon				= BaseballBat,
		RunAnim				= Run_Weapon2,
        	TwoHandWeapon 			= TRUE,
        	BreakSound  			= PZ_WoodSnap,
        	TreeDamage  			= 1,

</nowiki>

==See Also==
<!--Comment: Location of links to relevant guides eg: Weapons guide, construction etc-->
<!--Comment: Navbox placement here code example = {{Navbox/Construction}}, (see all current navboxs via the template section)-->
{{Navbox/Weapons}}



This code would produce the following:



   Page Updated @ Version: 36.40   
   Navigation - Main Index -> The Game World -> Items -> Weapons -> Boilerplate Items   

Template:Weapons A description of the item. Include links (example link is to Nails article) to other pages within the wiki where appropriate. Also try to mention how many uses it has and also where it was found.

With weapons, try to mention swing speed, how many zombies it can hit (see code "maxhitcount" for amount of zombies hit), durability, range and usefulness.

Crafting

Output Ingredients Description Skill Level












Materials to Repair

Item Repaired 1st Repair Materials =
55% Repaired, 100% Success

20% Repaired, 95% Success

10% Repaired, 95% Success

10% Repaired, 95% Success
File:Baseball Bat.png

Baseball Bat

Woodglue.png

Wood Glue (2 Uses)
(Requires Carpentry Level 2)

DuctTape.png

Duct Tape (2 Uses)

Glue.png

Glue (2 Uses)

MATERIALScotchTape.png

Adhesive Tape (4 Uses)

Repair Code

	fixing Fix Baseball Bat

     Require : BaseballBat,

       Fixer : Woodglue=2; Woodwork=2,
       Fixer : DuctTape=2,
       Fixer : Glue=2,
       Fixer : Scotchtape=4,
 

Code

From items.txt (Project Zomboid directory/media/scripts/)

	
	item BaseballBat
		MaxRange			= 1.5,
		WeaponSprite			= Baseballbat,
		MinAngle			= 0.2,
		Type				= Weapon,
		MinimumSwingTime		= 3,
		KnockBackOnNoDeath		= TRUE,
		SwingAmountBeforeImpact		= 0.02,
		Categories			= Blunt,
		ConditionLowerChanceOneIn	= 20,
		Weight				= 2,
		SplatN.umber			= 1,
		PushBackMod			= 0.5,
		MaxDamage			= 1.2,
		SubCategory			= Swinging,
		ConditionMax			= 15,
		MaxHitCount			= 2,
		DoorDamage			= 7,
		IdleAnim			= Idle_Weapon2,
		SwingAnim			= Bat,
		CriticalChance			= 10,
		WeaponWeight			= 2,
		DisplayName			= Baseball Bat,
		MinRange			= 0.61,
		SwingTime			= 3,
		HitAngleMod			= -30,
		MinDamage			= 0.8,
		KnockdownMod			= 2,
		SplatBloodOnNoDeath		= FALSE,
		Icon				= BaseballBat,
		RunAnim				= Run_Weapon2,
        	TwoHandWeapon 			= TRUE,
        	BreakSound  			= PZ_WoodSnap,
        	TreeDamage  			= 1,


See Also

Template:Navbox/Weapons