PAI overlay on PDAs (#71602)

## About The Pull Request
Adds a small overlay when pais are inserted into your pda


![image](https://user-images.githubusercontent.com/73374039/204449843-1e8b91ea-e2d1-46c2-8f8a-05ded8fbc0d7.png)


![image](https://user-images.githubusercontent.com/73374039/204449876-4e4d649a-1246-47a2-b693-bc7af931c85e.png)
## Why It's Good For The Game
This was another legacy feature that was removed with modpdas, and other
servers (like bee, though i personally dont agree with the creator.)
have it already. sooooo why not make one for tg
## Changelog
🆑
imageadd: indicator when a pda contains a pai
/🆑

Co-authored-by: etherware-novice <candy@notarealaddr.com>
This commit is contained in:
texan-down-under
2022-12-03 18:13:28 -06:00
committed by GitHub
parent d7e803af09
commit 31fcfad96c
4 changed files with 6 additions and 0 deletions
@@ -204,6 +204,7 @@ GLOBAL_LIST_EMPTY(TabletMessengers) // a list of all active messengers, similar
user.put_in_hands(inserted_pai)
balloon_alert(user, "removed pAI")
inserted_pai = null
update_appearance(UPDATE_ICON)
return TRUE
// Gets IDs/access levels from card slot. Would be useful when/if PDAs would become modular PCs. //guess what
@@ -414,6 +415,7 @@ GLOBAL_LIST_EMPTY(TabletMessengers) // a list of all active messengers, similar
inserted_pai = null
if(inserted_disk == gone)
inserted_disk = null
update_appearance(UPDATE_ICON)
return ..()
// On-click handling. Turns on the computer if it's off and opens the GUI.
@@ -723,6 +725,7 @@ GLOBAL_LIST_EMPTY(TabletMessengers) // a list of all active messengers, similar
return
inserted_pai = attacking_item
balloon_alert(user, "inserted pai")
update_appearance(UPDATE_ICON)
return
if(istype(attacking_item, /obj/item/stock_parts/cell))
@@ -192,6 +192,7 @@
usr.put_in_hands(inserted_pai)
to_chat(usr, span_notice("You remove [inserted_pai] from the [name]."))
inserted_pai = null
update_appearance(UPDATE_ICON)
if("interact")
inserted_pai.attack_self(usr)
return UI_UPDATE
@@ -72,6 +72,8 @@
. += mutable_appearance(initial(icon), "id_overlay")
if(light_on)
. += mutable_appearance(initial(icon), "light_overlay")
if(inserted_pai)
. += mutable_appearance(initial(icon), "pai_inserted")
/obj/item/modular_computer/pda/attack_ai(mob/user)
to_chat(user, span_notice("It doesn't feel right to snoop around like that..."))