mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 20:48:56 +01:00
[MIRROR] Refactor, improve, and rename canUseTopic to be can_perform_action [MDB IGNORE] (#19391)
* Refactor, improve, and rename canUseTopic to be can_perform_action * updoot * https://github.com/tgstation/tgstation/pull/72876 https://github.com/tgstation/tgstation/pull/72876 --------- Co-authored-by: Tim <timothymtorres@gmail.com> Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com>
This commit is contained in:
@@ -115,7 +115,7 @@
|
||||
updateDialog(usr) // make sure updates when complete
|
||||
|
||||
/datum/song/Topic(href, href_list)
|
||||
if(!usr.canUseTopic(parent, be_close = TRUE, no_dexterity = FALSE, no_tk = FALSE, need_hands = FALSE, floor_okay = TRUE))
|
||||
if(!usr.can_perform_action(parent, ALLOW_RESTING))
|
||||
usr << browse(null, "window=instrument")
|
||||
usr.unset_machine()
|
||||
return
|
||||
|
||||
@@ -20,7 +20,9 @@
|
||||
if(!(anchored || can_play_unanchored) || !ismob(music_player))
|
||||
return STOP_PLAYING
|
||||
var/mob/user = music_player
|
||||
if(!user.canUseTopic(src, FALSE, TRUE, FALSE, FALSE)) //can play with TK and while resting because fun.
|
||||
|
||||
if(!ISADVANCEDTOOLUSER(user))
|
||||
to_chat(src, span_warning("You don't have the dexterity to do this!"))
|
||||
return STOP_PLAYING
|
||||
|
||||
/obj/structure/musician/ui_interact(mob/user)
|
||||
|
||||
Reference in New Issue
Block a user