From: Schuyler Duryee Date: Thu, 2 Oct 2025 08:51:20 +0000 (-0700) Subject: Add utility knife/box cutter (#39567) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=368d4dd273a740998a298088c8a3df26f30877b0;p=space-station-14.git Add utility knife/box cutter (#39567) * add sprites for box cutter * move box cutter to melee, add yaml * remove unneeded soundHit yaml * add opening sound effect to box cutter * modify sprites to look more like actual box cutters * add BoxCutter tag and add to belts * rename box cutter to utility knife * remove accidental backtick * move utility knife to correct place in tags * remove SECOND accidental backtick?? * Fix utility knife arbitrage by reducing steel to 50 * Reduce damage to 4 * Reduce knife bounty reward to $2000 * modify utility knife icon to be larger * Make utility knife extendable/retractable * move slicing out of ComponentToggler * change utility knife extend/retract sound * Use TiniestShark's larger inhand images for utility knife * utilty knife is now only Slicing when activated --- diff --git a/Resources/Audio/Weapons/attributions.yml b/Resources/Audio/Weapons/attributions.yml index 310b01b728..989e2472f6 100644 --- a/Resources/Audio/Weapons/attributions.yml +++ b/Resources/Audio/Weapons/attributions.yml @@ -82,8 +82,13 @@ license: "CC0-1.0" copyright: "Taken from ScreamStudio on freesound.org" source: "https://freesound.org/people/ScreamStudio/sounds/392617/" - + - files: ["pop.ogg"] license: "CC0-1.0" copyright: "Taken from 0ne_one111yt on freesound.org" source: "https://freesound.org/people/0ne_one111yt/sounds/478213/" + +- files: ["utilityknifeopen.ogg, utilityknifeclose.ogg"] + license: "CC0-1.0" + copyright: "Taken from FilmOrbit on freesound.org" + source: "https://freesound.org/s/554299/" diff --git a/Resources/Audio/Weapons/utilityknifeclose.ogg b/Resources/Audio/Weapons/utilityknifeclose.ogg new file mode 100644 index 0000000000..8c620d2165 Binary files /dev/null and b/Resources/Audio/Weapons/utilityknifeclose.ogg differ diff --git a/Resources/Audio/Weapons/utilityknifeopen.ogg b/Resources/Audio/Weapons/utilityknifeopen.ogg new file mode 100644 index 0000000000..5053c8089c Binary files /dev/null and b/Resources/Audio/Weapons/utilityknifeopen.ogg differ diff --git a/Resources/Prototypes/Catalog/Bounties/bounties.yml b/Resources/Prototypes/Catalog/Bounties/bounties.yml index 28adfb16ac..60fa5147b8 100644 --- a/Resources/Prototypes/Catalog/Bounties/bounties.yml +++ b/Resources/Prototypes/Catalog/Bounties/bounties.yml @@ -202,14 +202,16 @@ - type: cargoBounty id: BountyKnife - reward: 6000 + reward: 2000 description: bounty-description-knife entries: - name: bounty-item-knife amount: 5 whitelist: components: - - Sharp + - Sharp + tags: + - UtilityKnife # required because retracted utility knives are not Sharp - type: cargoBounty id: BountyLemon diff --git a/Resources/Prototypes/Entities/Clothing/Belt/belts.yml b/Resources/Prototypes/Entities/Clothing/Belt/belts.yml index 06c38cc694..5273fa1453 100644 --- a/Resources/Prototypes/Entities/Clothing/Belt/belts.yml +++ b/Resources/Prototypes/Entities/Clothing/Belt/belts.yml @@ -35,6 +35,7 @@ - GPS - WeldingMask - RemoteSignaller + - UtilityKnife components: - StationMap - SprayPainter @@ -120,6 +121,7 @@ - HolofanProjector - Multitool - AppraisalTool + - UtilityKnife components: - StationMap - SprayPainter diff --git a/Resources/Prototypes/Entities/Objects/Weapons/Melee/knife.yml b/Resources/Prototypes/Entities/Objects/Weapons/Melee/knife.yml index aadf15153e..bd20659696 100644 --- a/Resources/Prototypes/Entities/Objects/Weapons/Melee/knife.yml +++ b/Resources/Prototypes/Entities/Objects/Weapons/Melee/knife.yml @@ -336,3 +336,67 @@ - ItemMask restitution: 0.3 friction: 0.2 + +- type: entity + name: utility knife + parent: BaseItem + id: UtilityKnife + description: A knife with a retractable, tiny blade. Useful as a box cutter and letter opener, among other things. + components: + - type: Appearance + - type: ComponentToggler + components: + - type: Execution + doAfterDuration: 4.0 + - type: Sharp + - type: Utensil + types: + - Knife + - type: Tool + qualities: + - Slicing + useSound: + path: /Audio/Items/Culinary/chop.ogg + - type: Item + size: Tiny + sprite: Objects/Weapons/Melee/utility_knife.rsi + - type: ItemToggle + soundActivate: + path: /Audio/Weapons/utilityknifeopen.ogg + soundDeactivate: + path: /Audio/Weapons/utilityknifeclose.ogg + - type: ItemToggleMeleeWeapon + activatedSoundOnHit: + path: /Audio/Weapons/bladeslice.ogg + activatedDamage: + types: + Slash: 4 + - type: MeleeWeapon + wideAnimationRotation: -135 + attackRate: 1 + damage: + types: + Blunt: 1 + - type: PhysicalComposition + materialComposition: + Steel: 50 + - type: Sprite + sprite: Objects/Weapons/Melee/utility_knife.rsi + layers: + - state: utility_knife_handle + - state: utility_knife_blade + visible: false + map: [ "blade" ] + - type: Tag + tags: + - Knife + - UtilityKnife + - type: ToggleableVisuals + spriteLayer: blade + inhandVisuals: + left: + - state: inhand-left-blade + right: + - state: inhand-right-blade + - type: UseDelay + delay: 0.2 diff --git a/Resources/Prototypes/Recipes/Lathes/Packs/cargo.yml b/Resources/Prototypes/Recipes/Lathes/Packs/cargo.yml index 6ca2ef8566..8160cef767 100644 --- a/Resources/Prototypes/Recipes/Lathes/Packs/cargo.yml +++ b/Resources/Prototypes/Recipes/Lathes/Packs/cargo.yml @@ -5,6 +5,7 @@ recipes: - AppraisalTool - Pickaxe + - UtilityKnife - type: latheRecipePack id: CargoBoardsStatic diff --git a/Resources/Prototypes/Recipes/Lathes/cargo.yml b/Resources/Prototypes/Recipes/Lathes/cargo.yml index 0679132ec0..8c0f1e07f2 100644 --- a/Resources/Prototypes/Recipes/Lathes/cargo.yml +++ b/Resources/Prototypes/Recipes/Lathes/cargo.yml @@ -12,3 +12,10 @@ completetime: 4 materials: Steel: 500 + +- type: latheRecipe + id: UtilityKnife + result: UtilityKnife + completetime: 2 + materials: + Steel: 100 diff --git a/Resources/Prototypes/tags.yml b/Resources/Prototypes/tags.yml index 184daa337a..6b705abf48 100644 --- a/Resources/Prototypes/tags.yml +++ b/Resources/Prototypes/tags.yml @@ -1460,6 +1460,9 @@ - type: Tag id: UtilityBelt +- type: Tag + id: UtilityKnife + - type: Tag id: Vegetable diff --git a/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/icon.png b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/icon.png new file mode 100644 index 0000000000..9f41d1a08e Binary files /dev/null and b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/icon.png differ diff --git a/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-left-blade.png b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-left-blade.png new file mode 100644 index 0000000000..b53a19e938 Binary files /dev/null and b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-left-blade.png differ diff --git a/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-left.png b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-left.png new file mode 100644 index 0000000000..5c64f929e1 Binary files /dev/null and b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-left.png differ diff --git a/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-right-blade.png b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-right-blade.png new file mode 100644 index 0000000000..acddabce4c Binary files /dev/null and b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-right-blade.png differ diff --git a/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-right.png b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-right.png new file mode 100644 index 0000000000..4abf5049bd Binary files /dev/null and b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/inhand-right.png differ diff --git a/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/meta.json b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/meta.json new file mode 100644 index 0000000000..6d96094dee --- /dev/null +++ b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/meta.json @@ -0,0 +1,36 @@ +{ + "version": 1, + "license": "CC-BY-SA-3.0", + "copyright": "Icon sprited for SS14 by GitHub user sudobeans. Inhand sprites sprited for SS14 by Github user TiniestShark.", + "size": { + "x": 32, + "y": 32 + }, + "states": [ + { + "name": "icon" + }, + { + "name": "utility_knife_blade" + }, + { + "name": "utility_knife_handle" + }, + { + "name": "inhand-left", + "directions": 4 + }, + { + "name": "inhand-right", + "directions": 4 + }, + { + "name": "inhand-right-blade", + "directions": 4 + }, + { + "name": "inhand-left-blade", + "directions": 4 + } + ] +} diff --git a/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/utility_knife_blade.png b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/utility_knife_blade.png new file mode 100644 index 0000000000..07599b94f5 Binary files /dev/null and b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/utility_knife_blade.png differ diff --git a/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/utility_knife_handle.png b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/utility_knife_handle.png new file mode 100644 index 0000000000..9769850ddd Binary files /dev/null and b/Resources/Textures/Objects/Weapons/Melee/utility_knife.rsi/utility_knife_handle.png differ