mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-19 19:13:30 +01:00
Slightly refactors storage item insertion (#24429)
* everything is on fire * silent trait check * how did it even become CRLF * minor formatting * fix icon updating and adds silent insertion to global trait list * adds the new parameter to documentation - whoops! * pain * contra review * contra review again, reduces amount of checks for user in the loops --------- Co-authored-by: cybercapitalism <98280110+cybercapitalism@users.noreply.github.com>
This commit is contained in:
@@ -296,7 +296,7 @@
|
||||
if(egg != /obj/item/fish_eggs) // Don't harvest duds
|
||||
egg = new egg(get_turf(user)) //Spawn the egg at the user's feet
|
||||
if(fish_bag?.can_be_inserted(egg))
|
||||
fish_bag.handle_item_insertion(egg)
|
||||
fish_bag.handle_item_insertion(egg, user)
|
||||
else
|
||||
duds++
|
||||
egg_list.Remove(egg) //Remove the egg from the egg_list
|
||||
@@ -350,7 +350,7 @@
|
||||
if(fish_item)
|
||||
var/obj/item/I = new fish_item(get_turf(user))
|
||||
if(fish_bag?.can_be_inserted(I))
|
||||
fish_bag.handle_item_insertion(I)
|
||||
fish_bag.handle_item_insertion(I, user)
|
||||
user.visible_message("[user.name] scoops \a [fish_name] from [src].", "You scoop \a [fish_name] out of [src].")
|
||||
kill_fish(fish_to_scoop) //Kill the caught fish from the tank
|
||||
|
||||
|
||||
Reference in New Issue
Block a user