mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-08-22 04:37:45 +01:00
Merge pull request #14069 from KillianKirilenko/kk-glasses
AR-Bs Employment Records
This commit is contained in:
@@ -423,6 +423,9 @@
|
||||
msg += "<span class='deptradio'>Physical status:</span> <a href='?src=\ref[src];medical=1'>\[[medical]\]</a>"
|
||||
msg += "<span class='deptradio'>Medical records:</span> <a href='?src=\ref[src];medrecord=`'>\[View\]</a> <a href='?src=\ref[src];medrecordadd=`'>\[Add comment\]</a>"
|
||||
|
||||
if(hasHUD(user,"best"))
|
||||
msg += "<span class='deptradio'>Employment records:</span> <a href='?src=\ref[src];emprecord=`'>\[View\]</a> <a href='?src=\ref[src];emprecordadd=`'>\[Add comment\]</a>"
|
||||
|
||||
|
||||
var/flavor_text = print_flavor_text()
|
||||
if(flavor_text)
|
||||
|
||||
@@ -80,6 +80,9 @@
|
||||
if("medical")
|
||||
if(omni.mode == "med" || omni.mode == "best")
|
||||
return TRUE
|
||||
if("best")
|
||||
if(omni.mode == "best")
|
||||
return TRUE
|
||||
|
||||
return FALSE
|
||||
|
||||
|
||||
@@ -569,6 +569,87 @@
|
||||
var/mob/living/silicon/robot/U = usr
|
||||
R.fields[text("com_[counter]")] = text("Made by [U.name] ([U.modtype] [U.braintype]) on [time2text(world.realtime, "DDD MMM DD hh:mm:ss")], [game_year]<BR>[t1]")
|
||||
|
||||
if (href_list["emprecord"])
|
||||
if(hasHUD(usr,"best"))
|
||||
var/perpname = "wot"
|
||||
var/read = 0
|
||||
|
||||
var/obj/item/weapon/card/id/I = GetIdCard()
|
||||
if(I)
|
||||
perpname = I.registered_name
|
||||
else
|
||||
perpname = name
|
||||
for (var/datum/data/record/E in data_core.general)
|
||||
if (E.fields["name"] == perpname)
|
||||
for (var/datum/data/record/R in data_core.general)
|
||||
if (R.fields["id"] == E.fields["id"])
|
||||
if(hasHUD(usr,"best"))
|
||||
to_chat(usr, "<b>Name:</b> [R.fields["name"]]")
|
||||
to_chat(usr, "<b>Assignment:</b> [R.fields["real_rank"]] ([R.fields["rank"]])")
|
||||
to_chat(usr, "<b>Home System:</b> [R.fields["home_system"]]")
|
||||
to_chat(usr, "<b>Citizenship:</b> [R.fields["citizenship"]]")
|
||||
to_chat(usr, "<b>Primary Employer:</b> [R.fields["personal_faction"]]")
|
||||
to_chat(usr, "<b>Religious Beliefs:</b> [R.fields["religion"]]")
|
||||
to_chat(usr, "<b>Notes:</b> [R.fields["notes"]]")
|
||||
to_chat(usr, "<a href='?src=\ref[src];emprecordComment=`'>\[View Comment Log\]</a>")
|
||||
read = 1
|
||||
|
||||
if(!read)
|
||||
to_chat(usr, "<font color='red'>Unable to locate a data core entry for this person.</font>")
|
||||
|
||||
if (href_list["emprecordComment"])
|
||||
if(hasHUD(usr,"best"))
|
||||
var/perpname = "wot"
|
||||
var/read = 0
|
||||
|
||||
var/obj/item/weapon/card/id/I = GetIdCard()
|
||||
if(I)
|
||||
perpname = I.registered_name
|
||||
else
|
||||
perpname = name
|
||||
for (var/datum/data/record/E in data_core.general)
|
||||
if (E.fields["name"] == perpname)
|
||||
for (var/datum/data/record/R in data_core.general)
|
||||
if (R.fields["id"] == E.fields["id"])
|
||||
if(hasHUD(usr,"best"))
|
||||
read = 1
|
||||
var/counter = 1
|
||||
while(R.fields[text("com_[]", counter)])
|
||||
to_chat(usr, "[R.fields[text("com_[]", counter)]]")
|
||||
counter++
|
||||
if (counter == 1)
|
||||
to_chat(usr, "No comment found")
|
||||
to_chat(usr, "<a href='?src=\ref[src];emprecordadd=`'>\[Add comment\]</a>")
|
||||
|
||||
if(!read)
|
||||
to_chat(usr, "<font color='red'>Unable to locate a data core entry for this person.</font>")
|
||||
|
||||
if (href_list["emprecordadd"])
|
||||
if(hasHUD(usr,"best"))
|
||||
var/perpname = "wot"
|
||||
var/obj/item/weapon/card/id/I = GetIdCard()
|
||||
if(I)
|
||||
perpname = I.registered_name
|
||||
else
|
||||
perpname = name
|
||||
for (var/datum/data/record/E in data_core.general)
|
||||
if (E.fields["name"] == perpname)
|
||||
for (var/datum/data/record/R in data_core.general)
|
||||
if (R.fields["id"] == E.fields["id"])
|
||||
if(hasHUD(usr,"best"))
|
||||
var/t1 = sanitize(tgui_input_text(usr, "Add Comment:", "Emp. records", null, null, multiline = TRUE, prevent_enter = TRUE))
|
||||
if ( !(t1) || usr.stat || usr.restrained() || !(hasHUD(usr,"best")) )
|
||||
return
|
||||
var/counter = 1
|
||||
while(R.fields[text("com_[]", counter)])
|
||||
counter++
|
||||
if(istype(usr,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/U = usr
|
||||
R.fields[text("com_[counter]")] = text("Made by [U.get_authentification_name()] ([U.get_assignment()]) on [time2text(world.realtime, "DDD MMM DD hh:mm:ss")], [game_year]<BR>[t1]")
|
||||
if(istype(usr,/mob/living/silicon/robot))
|
||||
var/mob/living/silicon/robot/U = usr
|
||||
R.fields[text("com_[counter]")] = text("Made by [U.name] ([U.modtype] [U.braintype]) on [time2text(world.realtime, "DDD MMM DD hh:mm:ss")], [game_year]<BR>[t1]")
|
||||
|
||||
if (href_list["lookitem"])
|
||||
var/obj/item/I = locate(href_list["lookitem"])
|
||||
src.examinate(I)
|
||||
|
||||
Reference in New Issue
Block a user