Cage Trap: Difference between revisions

From PZwiki
m (→‎top: category project: "The Game World")
m (Automated Formatting)
(17 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{Languages}}{{Header|Project Zomboid|Items|type=Trap|version=Version 40|incver=43}}{{Infobox trap
{{Header|Project Zomboid|Items|Trapping}}
|display_name=Cage Trap
{{Page version|41.78.16}}
|name_colour=Trap
{{Infobox tile
|name_text_colour=Trap
|name=Cage Trap
|image=CageTrapAnim.gif
|image=CageTrapAnim.gif
|image_width=
|icon=TrapCage.png
|alternate_image=TrapCage.png
|icon_name=Cage Trap
|alternate_name=Cage Trap
<!--General-->
|alternate_link=
|category=Trapping
|category=Item
|weight=1.0
|weight=1.0
|size=1
|function=Catch [[animals]]
<!--Properties-->
|health=50
|strength=20
|strength=20
|animals=[[File:Rabbit.png|link=Rabbit]] [[File:Squirrel.png|link=Squirrel]]
|animals=[[File:Rabbit.png|link=Rabbit]] [[File:Squirrel.png|link=Squirrel]]
|placement=
<!--Build-->
|ingredients=5 × {{T|Wire}}
|crafting=true
|class_name=Base.TrapCage
|build_skill=[[The Hunter Magazine|The Hunter Magazine Vol. 3]]
}}A '''cage trap''' is a medium sized trap used by journeyman trappers.
|build_skill2=[[Trapping]]
|build_level2=3
|ingredients=[[Wire]] (5 units)
<!--Disassemble-->
|destroy=true
|products=[[Wire]]
<!--Technical-->
|item_id=Base.TrapCage
|tile_id=constructedobjects_01_8
}}
A '''cage trap''' is a medium-sized trap used by journeyman trappers.


==Usage==
==Usage==
A cage trap is one of several traps used in {{T|trapping}} to catch a variety of {{T|animals|wildlife}}.
A cage trap is one of several traps used in [[trapping]] to catch a variety of [[animals|wildlife]].


===Trapping===
===Trapping===
{{Main|Trapping}}
{{Main|Trapping}}
Cage traps can be used to catch {{T|rabbit}}s and {{T|squirrel}}s.
Cage traps can be used to catch [[rabbit]]s and [[squirrel]]s.
{| width="100px" style="text-align:left;"
{| width="100px" style="text-align:left;"
|+ '''''Catch chance:'''''
|+ '''''Catch chance:'''''
Line 31: Line 44:


==Crafting==
==Crafting==
To craft a cage trap, the player must have picked either the {{T|Occupation#Park Ranger|"Park Ranger" occupation}} or {{T|Traits|"Hunter" trait}} during character creation. Otherwise it will be learnt after reading ''[[The Hunter Magazine|The Hunter Magazine Vol.3]]'' and craftable after reaching trapping level 3.
To craft a cage trap, the player must have picked either the {{ll|Occupation#Park Ranger|"Park Ranger" occupation}} or [[Traits|"Hunter" trait]] during character creation. Otherwise, it will be learned after reading ''[[The Hunter Magazine|The Hunter Magazine Vol.3]]'' and craftable after reaching trapping level 3.


===Trapping===
===Trapping===
{{Main|Trapping}}
{{Main|Trapping}}
{{Crafting header|ing=1}}
{{Crafting/sandbox2
{{Crafting hunting|001|ing=1}}
|cage_trap
|}
}}


==Code==
==Code==
'''''From newitems.txt (Project Zomboid directory/media/scripts/)'''''
{{CodeBox|
{{Retrieved|version=41|incver=50}}
 
<pre>
===Item===
item TrapCage
{{CodeSnip
Weight = 1,
  | lang = java
Type = Normal,
  | line = true
DisplayName = Cage Trap,
  | start = 2301
Icon = TrapCage,
  | source = newitems.txt
Trap   = true,
  | retrieved = true
MetalValue = 10,
  | version = 41.78.16
</pre>
  | code =
item TrapCage
    {
        DisplayCategory = Trapping,
        Weight = 1,
        Type = Normal,
        DisplayName = Cage Trap,
        Icon = TrapCage,
        Trap   =   true,
        MetalValue = 10,
    }
}}
 
===Tile===
{{CodeSnip
  | lang = lua
  | line = false
  | path = ProjectZomboid\media\lua\server\Traps
  | source = TrapDefinition.lua
  | retrieved = true
  | version = 41.78.16
  | code =
local cageTrap = {};
cageTrap.type = "Base.TrapCage";
cageTrap.sprite = "constructedobjects_01_8";
cageTrap.northSprite = "constructedobjects_01_11";
cageTrap.closedSprite = "constructedobjects_01_9";
cageTrap.northClosedSprite = "constructedobjects_01_10";
cageTrap.trapStrength = 20;
cageTrap.destroyItem = "Base.Wire";
table.insert(Traps, cageTrap);
  }}
}}


==See also==
==See also==
*{{T|Trap Crate}}
*[[Trap Crate]]
*{{T|Trap Box}}
*[[Trap Box]]
*{{T|Snare Trap}}
*[[Snare Trap]]
*{{T|Stick Trap}}
*[[Stick Trap]]
 
{{Navbox equipment}}


[[Category:Trapping]]
{{Navbox items|survival}}

Revision as of 07:06, 14 April 2024

UI Tick.png
This page has been revised for the current stable version (41.78.16).
Help by adding any missing content. [edit]
Cage Trap
CageTrapAnim.gif
[[File:{{{icon2}}}|Cage Trap|]]
[[File:{{{icon3}}}|Cage Trap|]]
[[File:{{{icon4}}}|Cage Trap|]]
[[File:{{{icon5}}}|Cage Trap|]]
General
Category
Trapping
EncumbranceMoodle Icon HeavyLoad.png
1.0
Size
1 tile
Function
Catch animals
Properties
Health
50
Strength
20
Animals
Rabbit.png Squirrel.png
Crafting
Ingredients
Wire (5 units)
Destroy
Products
Technical
Item ID(s)
Base.TrapCage
Tile ID(s)
constructedobjects_01_8

A cage trap is a medium-sized trap used by journeyman trappers.

Usage

A cage trap is one of several traps used in trapping to catch a variety of wildlife.

Trapping

Main article: Trapping

Cage traps can be used to catch rabbits and squirrels.

Catch chance:
Rabbit 40%
Squirrel 40%

Crafting

To craft a cage trap, the player must have picked either the "Park Ranger" occupation or "Hunter" trait during character creation. Otherwise, it will be learned after reading The Hunter Magazine Vol.3 and craftable after reaching trapping level 3.

Trapping

Main article: Trapping
Product Ingredients Tools Requirements Workstation XP
TrapCage.png
Cage Trap
Wire.png Wire ×5 unit(s) none Trapping 3
(and)
MagazineHunting3.png
The Hunter Magazine Vol.3
none none

Code

Code icon.png Code snippet! This section contains source code from Project ZomboidShow / Hide

Item

Source: ProjectZomboid\media\scripts\newitems.txt

Retrieved: Build 41.78.16
item TrapCage
    {
        DisplayCategory = Trapping,
        Weight	=	1,
        Type	=	Normal,
        DisplayName	=	Cage Trap,
        Icon	=	TrapCage,
        Trap    =   true,
        MetalValue = 10,
    }

Tile

Source: ProjectZomboid\media\lua\server\Traps\TrapDefinition.lua

Retrieved: Build 41.78.16
local cageTrap = {};
cageTrap.type = "Base.TrapCage";
cageTrap.sprite = "constructedobjects_01_8";
cageTrap.northSprite = "constructedobjects_01_11";
cageTrap.closedSprite = "constructedobjects_01_9";
cageTrap.northClosedSprite = "constructedobjects_01_10";
cageTrap.trapStrength = 20;
cageTrap.destroyItem = "Base.Wire";
table.insert(Traps, cageTrap);

See also