Key Ring: Difference between revisions

From PZwiki
(→‎Code: Codebox Update)
m (Automated CodeBox update)
(10 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{Languages}}
{{Header|Project Zomboid|Items|Equipment|Security}}
{{Header|Project Zomboid|Items|Baggage|type=Baggage|version=Version 41|incver=50}}
{{Page version|41.78.16}}
{{Stub}}
{{Stub}}
{{Infobox container
{{Infobox item
| display_name = Key Ring
|name=Key Ring
| name_colour = Container
|model=KeyRing_Model.png
| name_text_colour = Container
|icon=KeyRing.png
| image = KeyRing_Model.png
|icon_name=Key Ring
| alternate_image= KeyRing.png
|category=Container
| alternate_name= Key Ring
|weight=0
| category = Container
|capacity={{Tooltip|1|Cannot hold anything other than keys}}
| weight = 0
|metal_value=5
| capacity = {{Tooltip|1|Cannot hold anything other than keys}}
|item_id=Base.KeyRing
}}
}}
A '''key ring''' is a container for storing keys.
 
A '''key ring''' is a container for storing [[Security#Keys|keys]].


==Usage==
==Usage==
When keys are found, they can be put into the key ring to reduce clutter in your inventory. Items that are not keys cannot be put on the key ring. [[Car Key|Car keys]], [[Padlock]] and [[Combination Padlock]] can be put on the key ring.
A key ring is used to store keys, reducing clutter in the player's inventory. It can only be used to store keys or key related items, including: [[Car Key|car keys]], [[padlock]]s and [[Combination Padlock|combination padlocks]].


Keys can be used to lock or unlock their respective [[Door|doors]], including [[Car Door|vehicle doors]].
===Items it can store===
{| class="wikitable theme-red" style="text-align:center;"
!Item
! [[File:Moodle_Icon_HeavyLoad.png|link=Moodles#Heavy Load|Encumbrance]]
! Lock/Unlock
|-
| [[File:Key1.png]][[File:Key2.png]][[File:Key3.png]][[File:Key4.png]][[File:Key5.png]]<br>[[Key|Key (door)]]
| 0
| [[File:DoorKnob.png|link=Doorknob]]
|-
| [[File:CarKey.png]]<br>[[Car Key]]
| 0
| [[Vehicles]]
|-
| [[File:KeyPadlock1.png]]<br>[[Key (Padlock)]]
| 0
| [[File:Padlock.png|link=Padlock]]
|-
| [[File:Padlock.png]]<br>[[Padlock]]
| 0.2
| [[File:Wooden Crate1.png|link=Wooden Crate|32px]][[File:Wooden Crate2.png|link=Wooden Crate|32px]][[File:MetalCrate.png|link=Metal Crate|32px]]
|-
| [[File:PadlockDigital.png]]<br>[[Combination Padlock]]
| 0.2
| [[File:Wooden Crate1.png|link=Wooden Crate|32px]][[File:Wooden Crate2.png|link=Wooden Crate|32px]][[File:MetalCrate.png|link=Metal Crate|32px]]
|}


==Distribution==
==Distribution==
A key ring is given to the player automatically when the character is created. There is a 40% chance to spawn with the key to the house the player spawned in.
The loot distributions can be found in the table(s) below.


A key is a common item. Although it is possible to find keys in [[containers]] such as [[Containers#Counters|counters]], [[Containers#Bedroom Storage|dressers]], and [[Containers#Crates|crates]], it is much more common to find them on the [[corpse]]s of [[zombie]]s that were inside or in the vicinity of the building. If a [[door]] exists, it is likely to have a key that corresponds to it.  
{| class="mw-collapsible mw-collapsed wikitable theme-red" data-expandtext="{{int:show}}" data-collapsetext="{{int:hide}}" style="text-align:center; min-width:24em;"
! colspan="4" | Containers
|-
! Building/Room
! Container
! style="width: 3.2em;" | Rolls
! style="width: 3.2em;" | Chance
|-
|clothingstore
|[[displaycase]]  
|4
|4
|}Every character will start with a key ring, therefore it can be found on every [[zombie]]. It has a 40% chance to spawn with the key to the house the character started in.


==Variants==
==Code==
Door Keys:
 
[[File:Key1.png]] [[File:Key2.png]] [[File:Key3.png]] [[File:Key4.png]] [[File:Key5.png]]
 
Padlock Key:
 
[[File:KeyPadlock1.png]]
 
Car Key:
 
[[File:CarKey.png]]
 
== Code ==
{{CodeBox
{{CodeBox
| {{CodeSnip
| {{CodeSnip
   | lang = java
   | lang = java
   | line = true
   | line = true
   | start =  
   | start = 2954
   | source = newitems.txt
   | source = newitems.txt
   | retrieved = true
   | retrieved = true
   | version = 41.50
   | version = 41.78.16
   | code =
   | code =
item KeyRing
item KeyRing
{
    {
  Weight             = 0,
        DisplayCategory = Container,
  Type               = Container,
        Weight = 0,
  DisplayName         = Key Ring,
        Type = Container,
  Icon               = KeyRing,
        DisplayName = Key Ring,
  Capacity           = 1,
        Icon = KeyRing,
  OnlyAcceptCategory = Key,
        Capacity = 1,
  MetalValue         = 5,
        OnlyAcceptCategory = Key,
}
        MetalValue = 5,
  }}
        WorldStaticModel = KeyRing_Ground,
    }  
}}
}}
}}


Line 64: Line 91:
{| class="wikitable theme-red" width="550" style="text-align: center;"
{| class="wikitable theme-red" width="550" style="text-align: center;"
|-
|-
! colspan="2" | Alpha  
! colspan="2" | Alpha
|-
|-
| Ver31.9 || Added to game.
| Ver31.9 || Added to game.
Line 77: Line 104:
*[[Padlock]]
*[[Padlock]]


{{Navbox equipment}}
[[Category:Wearable containers]]
 
{{Navbox equipment|containers}}

Revision as of 10:55, 26 March 2024

UI Tick.png
This page has been revised for the current stable version (41.78.16).
Help by adding any missing content. [edit]
Notebook.png
This article may need more content.
Editors are encouraged to add new material to the page while expanding upon current topics.
Key Ring
KeyRing Model.png
General
Category
Container
Encumbrance
Moodle Icon HeavyLoad.png
0
Properties
Capacity
1
Technical
Item ID
Base.KeyRing

A key ring is a container for storing keys.

Usage

A key ring is used to store keys, reducing clutter in the player's inventory. It can only be used to store keys or key related items, including: car keys, padlocks and combination padlocks.

Items it can store

Item Encumbrance Lock/Unlock
Key1.pngKey2.pngKey3.pngKey4.pngKey5.png
Key (door)
0 DoorKnob.png
CarKey.png
Car Key
0 Vehicles
KeyPadlock1.png
Key (Padlock)
0 Padlock.png
Padlock.png
Padlock
0.2 Wooden Crate1.pngWooden Crate2.pngMetalCrate.png
PadlockDigital.png
Combination Padlock
0.2 Wooden Crate1.pngWooden Crate2.pngMetalCrate.png

Distribution

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

Containers
Building/Room Container Rolls Chance
clothingstore displaycase 4 4

Every character will start with a key ring, therefore it can be found on every zombie. It has a 40% chance to spawn with the key to the house the character started in.

Code

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

Source: ProjectZomboid\media\scripts\newitems.txt

Retrieved: Build 41.78.16
item KeyRing
    {
        DisplayCategory = Container,
        Weight	=	0,
        Type	=	Container,
        DisplayName	=	Key Ring,
        Icon	=	KeyRing,
        Capacity	=	1,
        OnlyAcceptCategory = Key,
        MetalValue = 5,
        WorldStaticModel = KeyRing_Ground,
    }

History

Alpha
Ver31.9 Added to game.
Ver35.26 Now only a 40% chance to spawn with your house key.

See also