Skip to content

Commit

Permalink
I hope that's done
Browse files Browse the repository at this point in the history
  • Loading branch information
AyIong committed Nov 16, 2023
1 parent 496a7a5 commit 597ff34
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions modular_ss220/objects/code/card_skins.dm
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
if(user.a_intent == INTENT_HARM)
to_chat(user, span_warning("Вы срываете наклейку с карты!"))
playsound(user.loc, 'sound/items/poster_ripped.ogg', 50, 1)
remove_skin()
remove_skin(delete = TRUE)
else
to_chat(user, span_notice("Вы начинаете аккуратно снимать наклейку с карты."))
if(!do_after(user, 5 SECONDS, target = src, progress = TRUE))
Expand All @@ -52,7 +52,6 @@
skin_applied.forceMove(get_turf(user))
remove_skin()


/obj/item/card/id/proc/apply_skin(obj/item/id_skin/skin, mob/user)
if(skin_applied)
to_chat(usr, span_warning("На карте уже есть наклейка, сначала соскребите её!"))
Expand All @@ -76,8 +75,9 @@
add_overlay(card_skin)
return TRUE

/obj/item/card/id/proc/remove_skin()
qdel(skin_applied)
/obj/item/card/id/proc/remove_skin(delete = FALSE)
if(delete)
qdel(skin_applied)
skin_applied = null
desc = initial(desc)
overlays.Cut()
Expand Down

0 comments on commit 597ff34

Please sign in to comment.