mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Merge pull request #724 from Datraen/Telecrystal-Item
Telecrystal item implementation + More
This commit is contained in:
@@ -13,7 +13,7 @@ var/global/list/obj/item/device/pda/PDAs = list()
|
||||
slot_flags = SLOT_ID | SLOT_BELT
|
||||
|
||||
//Main variables
|
||||
var/pdachoice = 1
|
||||
var/pdachoice = 3
|
||||
var/owner = null
|
||||
var/default_cartridge = 0 // Access level defined by cartridge
|
||||
var/obj/item/weapon/cartridge/cartridge = null //current cartridge
|
||||
@@ -319,9 +319,13 @@ var/global/list/obj/item/device/pda/PDAs = list()
|
||||
new /obj/item/weapon/pen(src)
|
||||
pdachoice = isnull(H) ? 1 : (ishuman(H) ? H.pdachoice : 1)
|
||||
switch(pdachoice)
|
||||
if(1) icon = 'icons/obj/pda.dmi'
|
||||
if(2) icon = 'icons/obj/pda_slim.dmi'
|
||||
if(3) icon = 'icons/obj/pda_old.dmi'
|
||||
else icon = 'icons/obj/pda.dmi'
|
||||
else
|
||||
icon = 'icons/obj/pda_old.dmi'
|
||||
log_debug("Invalid switch for PDA, defaulting to old PDA icons. [pdachoice] chosen.")
|
||||
|
||||
|
||||
/obj/item/device/pda/proc/can_use()
|
||||
|
||||
|
||||
20
code/game/objects/items/devices/telecrystal.dm
Normal file
20
code/game/objects/items/devices/telecrystal.dm
Normal file
@@ -0,0 +1,20 @@
|
||||
/*
|
||||
Telecrystal item
|
||||
Does nothing if not suitable antag type, checks for accept_tcrystals = 1 in a mob's mind.
|
||||
For new antags, make sure to add "player.mind.accept_tcrystals = 1" if you want tradable tcrystals.
|
||||
*/
|
||||
/obj/item/device/telecrystal
|
||||
name = "red crystal"
|
||||
desc = "A strange, red, glowing crystal."
|
||||
icon = 'icons/obj/stock_parts.dmi'
|
||||
icon_state = "telecrystal"
|
||||
item_state = "telecrystal"
|
||||
force = 5
|
||||
|
||||
/obj/item/device/telecrystal/attack_self(mob/user as mob)
|
||||
if(user.mind.accept_tcrystals) //Checks to see if antag type allows for tcrystals
|
||||
user.mind.tcrystals += 1
|
||||
user.drop_from_inventory(src)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
@@ -385,6 +385,12 @@ datum/uplink_item/dd_SortValue()
|
||||
item_cost = 3
|
||||
path = /obj/item/weapon/storage/secure/briefcase/money
|
||||
desc = "A briefcase with 10,000 untraceable thalers for funding your sneaky activities."
|
||||
|
||||
/datum/uplink_item/item/tools/crystal
|
||||
name = "Tradable Crystal"
|
||||
item_cost = 1
|
||||
path = /obj/item/device/telecrystal
|
||||
desc = "A telecrystal that can be transferred from one user to another. Be sure not to give it to just anyone."
|
||||
|
||||
/***********
|
||||
* Implants *
|
||||
|
||||
Reference in New Issue
Block a user