fancier throws, fancier bullet casings, fancier window destruction, fancier bottle smashing (#7997)
This commit is contained in:
@@ -536,12 +536,16 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
|
||||
callback = CALLBACK(src, .proc/after_throw, callback) //replace their callback with our own
|
||||
. = ..(target, range, speed, thrower, spin, diagonals_first, callback)
|
||||
|
||||
|
||||
/obj/item/proc/after_throw(datum/callback/callback)
|
||||
if (callback) //call the original callback
|
||||
. = callback.Invoke()
|
||||
throw_speed = initial(throw_speed) //explosions change this.
|
||||
item_flags &= ~IN_INVENTORY
|
||||
var/matrix/M = matrix(transform)
|
||||
M.Turn(rand(-170, 170))
|
||||
transform = M
|
||||
pixel_x = rand(-12, 12)
|
||||
pixel_y = rand(-12, 12)
|
||||
|
||||
/obj/item/proc/remove_item_from_storage(atom/newLoc) //please use this if you're going to snowflake an item out of a obj/item/storage
|
||||
if(!newLoc)
|
||||
|
||||
@@ -266,6 +266,9 @@ GLOBAL_LIST_INIT(plastitaniumglass_recipes, list(
|
||||
if("large")
|
||||
pixel_x = rand(-5, 5)
|
||||
pixel_y = rand(-5, 5)
|
||||
var/matrix/M = matrix(transform)
|
||||
M.Turn(rand(-170, 170))
|
||||
transform = M
|
||||
|
||||
/obj/item/shard/afterattack(atom/A as mob|obj, mob/user, proximity)
|
||||
. = ..()
|
||||
|
||||
Reference in New Issue
Block a user