Files
VOREStation/code/modules/clothing/accessories/permits.dm
T
Cameron Lennox d5849910e5 Begin clickcode attack_self fix (#18797)
* Begin clickcode attack_self fix

Begins the work to make everything call back to parent for attack_self so that signals are sacred.

* Makes MORE things call the attack_self() parent

Yes, I could make special_handling a var on obj/item HOWEVER i want it to be specific so it can be tracked down later and ONLY the objects that use it can be refactored instead of sitting there literally forever and it just becoming 'a thing'.

* Finishes making the rest of attack_self call parent.

As mentioned, things such as 'specialty_goggles' 'special_handling' and the such are only there to help with attack_self until the attack_self is recoded for those items.

* begone foul demon

* some more cleanup

* These

* GOD this was annoying

* yeh

* Fix this

* fLARES

* Thesee too

* toys!

* Even more!

* More fixes

* Even more

* rest of em

* these too

* Update syndie.dm

* hardref clear

* Update code/game/gamemodes/nuclear/pinpointer.dm

* Update code/game/objects/effects/mines.dm

* Update code/game/objects/items/blueprints_vr.dm

* Update code/game/objects/items/blueprints_vr.dm

* Update code/game/objects/items/contraband_vr.dm

* Update code/game/objects/items/crayons.dm

* Update code/game/objects/items/crayons.dm

* Update code/game/objects/items/gunbox.dm

* Update code/game/objects/items/gunbox.dm

* Update code/game/objects/items/gunbox_vr.dm

* Update code/game/objects/items/gunbox_vr.dm

* Update code/game/objects/items/weapons/gift_wrappaper.dm

* Update code/game/objects/items/crayons.dm

* Update code/game/objects/items/crayons.dm

* Update code/game/objects/items/gunbox.dm

* these too

* Update maintpanel_stack.dm

* angry warning

* Fixes packaged snacks.

Fixes improper var default.

* Special handling for these

* proper poly types

* Fixes magclaws

Makes the 'features' it had just part  of base magboots that can be adjusted via varswap.

* Fixes jackets

Fixes https://github.com/VOREStation/VOREStation/issues/18941

* Small bugfix

Makes p_Theyre properly capitialize
Makes examine show proper wording

* Update gift_wrappaper.dm
2025-12-29 13:21:10 -05:00

52 lines
1.7 KiB
Plaintext

//This'll be used for gun permits, such as for heads of staff, antags, and bartenders
/obj/item/clothing/accessory/permit
name = "permit"
desc = "A permit for something."
icon = 'icons/obj/card_new.dmi'
icon_state = "permit-generic"
w_class = ITEMSIZE_TINY
slot = ACCESSORY_SLOT_MEDAL
var/owner = 0 //To prevent people from just renaming the thing if they steal it
special_handling = TRUE
/obj/item/clothing/accessory/permit/attack_self(mob/user)
. = ..(user)
if(.)
return TRUE
if(isliving(user))
if(!owner)
set_name(user.name)
to_chat(user, "[src] registers your name.")
else
to_chat(user, "[src] already has an owner!")
/obj/item/clothing/accessory/permit/proc/set_name(var/new_name)
owner = 1
if(new_name)
src.name += " ([new_name])"
desc += " It belongs to [new_name]."
/obj/item/clothing/accessory/permit/emag_act(var/remaining_charges, var/mob/user)
to_chat(user, "You reset the naming locks on [src]!")
owner = 0
/obj/item/clothing/accessory/permit/gun
name = "weapon permit"
desc = "A card indicating that the owner is allowed to carry a firearm."
icon_state = "permit-security"
/obj/item/clothing/accessory/permit/gun/bar
name = "bar shotgun permit"
desc = "A card indicating that the owner is allowed to carry a shotgun in the bar."
/obj/item/clothing/accessory/permit/gun/planetside
name = "planetside gun permit"
desc = "A card indicating that the owner is allowed to carry a firearm while on the surface."
icon_state = "permit-science"
/obj/item/clothing/accessory/permit/drone
name = "drone identification card"
desc = "A card issued by the EIO, indicating that the owner is a Drone Intelligence. Drones are mandated to carry this card within SolGov space, by law."
icon_state = "permit-drone"