mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-28 07:20:09 +01:00
Melee Toy, Sprites - Dino Grabber (#19900)
Adds a dino grabber toy to the game. It counts as a weapon, and uses modified whip code to have a chance of disarming people. Its also now in the warehouse spawn pool as a rare item, with the weight of 1.75. It should only show up every 2-3 rounds. Also adds an object sprite and in hand sprites. --------- Signed-off-by: courierbravo <73250577+courierbravo@users.noreply.github.com> Co-authored-by: Fluffy <65877598+FluffyGhoster@users.noreply.github.com> Co-authored-by: Hazelrat <ric.whe.don@gmail.com>
This commit is contained in:
co-authored by
Fluffy
Hazelrat
parent
bef0f2694e
commit
86d7e8237e
@@ -200,3 +200,47 @@
|
||||
desc = "A ceremonial sword issued to Sol marine officers as part of their dress uniform."
|
||||
icon_state = "marineofficersword"
|
||||
item_state = "marineofficersword"
|
||||
|
||||
/obj/item/melee/dinograbber
|
||||
name = "dino grabber"
|
||||
desc = "A plastic T-Rex head on a thin aluminum tube. A piece of string links the jaw and a trigger, allowing you to grab \
|
||||
objects with it. Perfect for annoying your friends!"
|
||||
icon = 'icons/obj/dinograbber.dmi'
|
||||
icon_state = "dinograbber"
|
||||
item_state = "dinograbber"
|
||||
contained_sprite = TRUE
|
||||
slot_flags = SLOT_BELT
|
||||
force = 0
|
||||
throwforce = 0
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
throw_speed = 7
|
||||
throw_range = 15
|
||||
attack_verb = list("grabbed at")
|
||||
var/drop_result = FALSE
|
||||
|
||||
/obj/item/melee/dinograbber/attack(mob/living/target_mob, mob/living/user, target_zone)
|
||||
..()
|
||||
|
||||
if(!ishuman(target_mob))
|
||||
return
|
||||
drop_result = FALSE
|
||||
|
||||
// 20% chance to disarm someone per hit, not including the chance to miss with the weapon
|
||||
if(prob(20))
|
||||
// If hit in a valid zone, check and drop the item held in the respective hand, only working for items that are weight class small or below
|
||||
switch(target_zone)
|
||||
if(BP_L_HAND, BP_L_ARM)
|
||||
if(target_mob.l_hand && (target_mob.l_hand != src) && target_mob.l_hand.w_class <= WEIGHT_CLASS_SMALL)
|
||||
target_mob.drop_l_hand()
|
||||
drop_result = TRUE
|
||||
|
||||
if(BP_R_HAND, BP_R_ARM)
|
||||
if(target_mob.r_hand && (target_mob.r_hand != src) && target_mob.r_hand.w_class <= WEIGHT_CLASS_SMALL)
|
||||
target_mob.drop_r_hand()
|
||||
drop_result = TRUE
|
||||
|
||||
// Visible messages for either result.
|
||||
if(drop_result)
|
||||
user.visible_message(SPAN_DANGER("\The [user] disarms \the [target_mob] with \the [src]!"), SPAN_NOTICE("You successfully disarm \the [target_mob] with \the [src]!"))
|
||||
else
|
||||
user.visible_message(SPAN_DANGER("\The [user] fail to disarm \the [target_mob] with \the [src]!"), SPAN_NOTICE("You fail to disarm \the [target_mob] with \the [src]!"))
|
||||
|
||||
@@ -149,3 +149,4 @@
|
||||
to_chat(target_mob, SPAN_WARNING("<b> You have been banned FOR NO REISIN by [user]</b>"))
|
||||
to_chat(user, SPAN_WARNING(" You have <b>BANNED</b> [target_mob]"))
|
||||
playsound(loc, 'sound/effects/adminhelp.ogg', 15)
|
||||
|
||||
|
||||
@@ -164,4 +164,7 @@ STOCK_ITEM_RARE(pistols, 1)
|
||||
var/type = pickweight(pistols)
|
||||
new type(L)
|
||||
|
||||
STOCK_ITEM_RARE(dinograbber, 1.75)
|
||||
new /obj/item/melee/dinograbber(L)
|
||||
|
||||
STOCK_ITEM_RARE(nothing, 0)
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
################################
|
||||
# Example Changelog File
|
||||
#
|
||||
# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb.
|
||||
#
|
||||
# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.)
|
||||
# When it is, any changes listed below will disappear.
|
||||
#
|
||||
# Valid Prefixes:
|
||||
# bugfix
|
||||
# - (fixes bugs)
|
||||
# wip
|
||||
# - (work in progress)
|
||||
# qol
|
||||
# - (quality of life)
|
||||
# soundadd
|
||||
# - (adds a sound)
|
||||
# sounddel
|
||||
# - (removes a sound)
|
||||
# rscadd
|
||||
# - (adds a feature)
|
||||
# rscdel
|
||||
# - (removes a feature)
|
||||
# imageadd
|
||||
# - (adds an image or sprite)
|
||||
# imagedel
|
||||
# - (removes an image or sprite)
|
||||
# spellcheck
|
||||
# - (fixes spelling or grammar)
|
||||
# experiment
|
||||
# - (experimental change)
|
||||
# balance
|
||||
# - (balance changes)
|
||||
# code_imp
|
||||
# - (misc internal code change)
|
||||
# refactor
|
||||
# - (refactors code)
|
||||
# config
|
||||
# - (makes a change to the config files)
|
||||
# admin
|
||||
# - (makes changes to administrator tools)
|
||||
# server
|
||||
# - (miscellaneous changes to server)
|
||||
#################################
|
||||
|
||||
# Your name.
|
||||
author: CourierBravo
|
||||
|
||||
# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again.
|
||||
delete-after: True
|
||||
|
||||
# Any changes you've made. See valid prefix list above.
|
||||
# INDENT WITH TWO SPACES. NOT TABS. SPACES.
|
||||
# SCREW THIS UP AND IT WON'T WORK.
|
||||
# Also, this gets changed to [] after reading. Just remove the brackets when you add new shit.
|
||||
# Please surround your changes in double quotes ("). It works without them, but if you use certain characters it screws up compiling. The quotes will not show up in the changelog.
|
||||
changes:
|
||||
- rscadd: "Added the Dino Grabber. A toy weapon, that does no damage. But, it has a 1 in 5 chance of disarming a target you attack with it. Works the same way as whips, so targeting anywhere but the hands will not trigger the disarm."
|
||||
- rscadd: "Added the Dino Grabber to the warehouse rare item spawn pool."
|
||||
- imageadd: "Added an object sprite and in hand sprites for the dino grabber. Thanks to @_bluebeerry for the object sprite."
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
Reference in New Issue
Block a user