-
Notifications
You must be signed in to change notification settings - Fork 33
PB_UTIL.Paperclip
srockw edited this page Mar 26, 2026
·
2 revisions
Paperclips extend from SMODS.Sticker, so everything in this documentation applies unless otherwise stated.
A table of all Paperclip keys can be found at PB_UTIL.Paperclips; however, the utility functions described below should handle most use cases without you having to access this table yourself.
-
Optional parameters (defaults):
-
shiny = false: This makes the Paperclip render with a shiny shader. Used for Gold and Platinum clips. -
special = false: Special Paperclips are unable to be randomly generated by default. Used for the Platinum clip.
-
-
PB_UTIL.is_paperclip(str)-
strshould be the full key of a potential paperclip (including mod prefix). If it is a valid paperclip object, returns true. Otherwise returns false.
-
-
PB_UTIL.has_paperclip(card)- If
cardcurrently has a paperclip, this function returns two values: the key of the paperclip and the config table of the paperclip. Otherwise returns nil.
- If
-
PB_UTIL.count_paperclips(args)- If
args.areaexists, this function iterates over the specified cardarea and counts all the non-debuffed cards with paperclips inside it. Ifargs.allow_debuffis true, it counts debuffed paperclips as well, and ifargs.exclude_highlightedis true, it will not count any paperclips on cards that are currently selected. Returns the number of paperclips counted.
- If
-
PB_UTIL.remove_paperclip(card)- Removes the paperclip attached to the specified card. Doesn't return anything.
-
PB_UTIL.set_paperclip(card, key)-
keyshould be the full key of a paperclip (including mod prefix). If that's the case, this function removes the previous paperclip on the specified card (if it exists) and applies the paperclip given bykeyto it.
-
-
PB_UTIL.poll_paperclip(seed, include_special)-
seedis a pseudorandom seed string. This function randomly picks the key of a paperclip and returns it; it will only pick paperclips marked as "special" ifinclude_specialis true.
-
-
PB_UTIL.is_special_clip(clip)- If
clipis the key of a special paperclip, this function returns true. Otherwise returns false.
- If
-
PB_UTIL.paperclip_tooltip(key)-
keyshould be the full key of a paperclip (including mod prefix). Returns a table that can be appended toinfo_queuewithin an object'sloc_varsfunction. If the key is not valid it will return nil.
-