Mouse Trap: Difference between revisions

From PZwiki
mNo edit summary
m (Distribution table update)
 
(25 intermediate revisions by 11 users not shown)
Line 1: Line 1:
{{languages}}
{{Header|Project Zomboid|Items|Trapping}}
{{header|The Game World|Items|type=Trap|version=Version 40|incver=43}}{{Infobox trap
{{Page version|41.78.16}}
| display_name = Mouse Trap
{{Infobox tile
| name_colour = Trap
|name=Mouse Trap
| name_text_colour = Trap
|image=MouseTrap.png
| image = MouseTrap.png
|icon=Mousetrap.png
| image_width =
|icon_name=Mouse Trap
| alternate_image = Mousetrap.png
|category=Item
| alternate_name = Mouse Trap
|weight=0.3
| alternate_link =
|size=1
| category = Item
|function=Catch [[animals]]
| weight = 0.3
<!--Properties-->
| strength = 50
|health=50
| animals = [[File:Mouse.png|link=Mouse]] [[File:Rat.png|link=Rat]]
|strength=50
| placement =  
|animals=[[File:Mouse.png|link=Mouse]] [[File:Rat.png|link=Rat]]
| ingredients =  
<!--Disassemble-->
| class_name = Base.TrapMouse
|destroy=true
}}A '''mouse trap''' is a small sized trap used by beginner trappers.
|products=[[Scrap Wood]]
<!--Technical-->
|item_id=Base.TrapMouse
|tile_id=constructedobjects_01_18
}}
A '''mouse trap''' is a small-sized trap used by beginner trappers.


==Usage==
==Usage==
A mouse trap is one of several traps used in {{T|trapping}} to catch a variety of {{T|animals|wildlife}}.
A mouse trap is one of several traps used in [[trapping]] to catch a variety of [[animals|wildlife]]. However, it is the only trap that cannot be crafted.
 
===Trapping===
===Trapping===
{{Main|Trapping}}
{{Main|Trapping}}
Cage traps can be used to catch {{T|mouse|mice}} and {{T|rat}}s.
Cage traps can be used to catch [[mouse|mice]] and [[rat]]s.
{| width="100px" style="text-align:left;"
{| width="100px" style="text-align:left;"
|+ '''''Catch chance:'''''
|+ '''''Catch chance:'''''
| [[File:Mouse.png|32px|link=Dead Mouse|Mouse]] || 20%
| [[File:Mouse.png|32px|link=Dead Mouse|Mouse]] || 30%
|-
|-
| [[File:Rat.png|32px|link=Dead Rat|Rat]] || 15%
| [[File:Rat.png|32px|link=Dead Rat|Rat]] || 25%
|}
|}


==Distribution==
==Distribution==
Mouse traps can be found in kitchen counters.
The loot distributions can be found in the table(s) below.
 
<!--BOT FLAG|TrapMouse|41.78.16-->
{{clear}}
<div class="togglebox theme-red">
    <div>TrapMouse distribution
        <span class="mw-customtoggle-togglebox-TrapMouse" title="{{int:show}} / {{int:hide}}" style="float:right; padding-right:30px; padding-top:4px; font-size:0.7em; font-weight:normal;">{{int:show}} / {{int:hide}}</span></div>
    <div class="mw-collapsible mw-collapsed" id="mw-customcollapsible-togglebox-TrapMouse">
    <div class="toggle-content"><div style="display: flex;"><div style="float:left;">
    {| class="wikitable theme-red" style="margin-right:15px; width:95%;"
    |+ {{ll|Containers}}
    ! Building / Room
    ! Container
    ! Rolls
    ! Chance
    |-
    | closet
    | {{ll|crate}}
    | 4
    | 10.0
    |-
    | gardenstore
    | {{ll|counter}}
    | 4
    | 8.0
    |-
    | gasstorage
    | {{ll|counter}}
    | 4
    | 10.0
    |-
    | kitchen
    | {{ll|counter}}
    | 4
    | 8.0
    |-
    | toolstore
    | {{ll|counter}}
    | 4
    | 4.0
    |}
</div>
    </div><div style="clear:both;"></div>
    {| class="wikitable theme-red" style="width:98%;"
    |+ {{ll|Foraging}}
    ! rowspan="2" | Amount
    ! rowspan="2" | Skill level
    ! rowspan="2" | Biomes
    ! colspan="4" style="text-align:center;" | Weather modifiers
    ! colspan="3" style="text-align:center;" | Month modifiers
    |-
    ! Snow
    ! Rain
    ! Day
    ! Night
    ! Months available
    ! Bonus months
    ! Malus months
    |-
    | ---
    | 8
    | DeepForest  1
    | -
    | -
    | -
    | -
    | -
    | -
    | -
    |}
    </div></div><div class="toggle large mw-customtoggle-togglebox-TrapMouse" title="{{int:show}}/{{int:hide}}"></div></div>
<!--END BOT FLAG|TrapMouse|41.78.16-->


==Code==
==Code==
'''''From newitems.txt (Project Zomboid directory/media/scripts/)'''''
{{CodeBox|
{{Retrieved|version=40|incver=43}}
 
<pre> item TrapMouse
===Item===
Weight = 0.3,
{{CodeSnip
Type = Normal,
  | lang = java
DisplayName = Mouse Trap,
  | line = true
Icon = Mousetrap,
  | start = 2312
Trap   = true,
  | source = newitems.txt
MetalValue = 2,</pre>
  | retrieved = true
  | version = 41.78.16
  | code =
item TrapMouse
    {
        DisplayCategory = Trapping,
        Weight = 0.3,
        Type = Normal,
        DisplayName = Mouse Trap,
        Icon = Mousetrap,
        Trap   =   true,
        MetalValue = 2,
    }
}}
 
===Tile===
{{CodeSnip
  | lang = lua
  | line = false
  | path = ProjectZomboid\media\lua\server\Traps
  | source = TrapDefinition.lua
  | retrieved = true
  | version = 41.78.16
  | code =
local mouseTrap = {};
mouseTrap.type = "Base.TrapMouse";
mouseTrap.sprite = "constructedobjects_01_18";
mouseTrap.closedSprite = "constructedobjects_01_19";
mouseTrap.trapStrength = 50;
mouseTrap.destroyItem = "Base.UnusableWood";
table.insert(Traps, mouseTrap);
  }}
}}


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


{{Navbox/Tools}}
{{Navbox items|survival}}

Latest revision as of 16:08, 24 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]
Mouse Trap
MouseTrap.png
[[File:{{{icon2}}}|Mouse Trap|]]
[[File:{{{icon3}}}|Mouse Trap|]]
[[File:{{{icon4}}}|Mouse Trap|]]
[[File:{{{icon5}}}|Mouse Trap|]]
General
Category
Item
EncumbranceMoodle Icon HeavyLoad.png
0.3
Size
1 tile
Function
Catch animals
Properties
Health
50
Strength
50
Animals
Mouse.png Rat.png
Destroy
Products
Technical
Item ID(s)
Base.TrapMouse
Tile ID(s)
constructedobjects_01_18

A mouse trap is a small-sized trap used by beginner trappers.

Usage

A mouse trap is one of several traps used in trapping to catch a variety of wildlife. However, it is the only trap that cannot be crafted.

Trapping

Main article: Trapping

Cage traps can be used to catch mice and rats.

Catch chance:
Mouse 30%
Rat 25%

Distribution

The loot distributions can be found in the table(s) below.

TrapMouse distribution Show / Hide
Containers
Building / Room Container Rolls Chance
closet crate 4 10.0
gardenstore counter 4 8.0
gasstorage counter 4 10.0
kitchen counter 4 8.0
toolstore counter 4 4.0
Foraging
Amount Skill level Biomes Weather modifiers Month modifiers
Snow Rain Day Night Months available Bonus months Malus months
--- 8 DeepForest 1 - - - - - - -

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 TrapMouse
    {
        DisplayCategory = Trapping,
        Weight	=	0.3,
        Type	=	Normal,
        DisplayName	=	Mouse Trap,
        Icon	=	Mousetrap,
        Trap    =   true,
        MetalValue = 2,
    }

Tile

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

Retrieved: Build 41.78.16
local mouseTrap = {};
mouseTrap.type = "Base.TrapMouse";
mouseTrap.sprite = "constructedobjects_01_18";
mouseTrap.closedSprite = "constructedobjects_01_19";
mouseTrap.trapStrength = 50;
mouseTrap.destroyItem = "Base.UnusableWood";
table.insert(Traps, mouseTrap);

See also