mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
pAI emoticons by Willox and Messycake!
- This adds a list of emoticon choices for pAIs on the pAI OS - These choices add small overlays on top of the screen - Credit to Willox for the code and Messycake for the sprites. Nodrak: pAI's with null names now get a pick(ninja_names) name instead. - If someone wants to make it pick from a different list feel free, but having null name causes problems down the line. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@4075 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -11,6 +11,10 @@
|
||||
var/looking_for_personality = 0
|
||||
var/mob/living/silicon/pai/pai
|
||||
|
||||
New()
|
||||
..()
|
||||
overlays += "pai-off"
|
||||
|
||||
attack_self(mob/user)
|
||||
if (!in_range(src, user))
|
||||
return
|
||||
@@ -71,7 +75,7 @@
|
||||
M << "<font color = #ff8787><h4>Your mental faculties leave you.</h4></font>"
|
||||
M << "<font color = #ffc4c4><h5>oblivion... </h5></font>"
|
||||
M.death(0)
|
||||
src.pai = null
|
||||
removePersonality()
|
||||
if(href_list["wires"])
|
||||
var/t1 = text2num(href_list["wires"])
|
||||
if (radio.wires & t1)
|
||||
@@ -87,12 +91,33 @@
|
||||
pai << "Supplemental Directives: <br>[pai.pai_laws]"
|
||||
attack_self(usr)
|
||||
|
||||
|
||||
|
||||
// WIRE_SIGNAL = 1
|
||||
// WIRE_RECEIVE = 2
|
||||
// WIRE_TRANSMIT = 4
|
||||
|
||||
proc/setPersonality(mob/living/silicon/pai/personality)
|
||||
src.pai = personality
|
||||
src.overlays += "pai-happy"
|
||||
|
||||
proc/removePersonality()
|
||||
src.pai = null
|
||||
src.overlays = null
|
||||
src.overlays += "pai-off"
|
||||
|
||||
proc/setEmotion(var/emotion)
|
||||
if(pai)
|
||||
src.overlays = null
|
||||
switch(emotion)
|
||||
if(1) src.overlays += "pai-happy"
|
||||
if(2) src.overlays += "pai-cat"
|
||||
if(3) src.overlays += "pai-extremely-happy"
|
||||
if(4) src.overlays += "pai-face"
|
||||
if(5) src.overlays += "pai-laugh"
|
||||
if(6) src.overlays += "pai-off"
|
||||
if(7) src.overlays += "pai-sad"
|
||||
if(8) src.overlays += "pai-angry"
|
||||
if(9) src.overlays += "pai-what"
|
||||
|
||||
proc/alertUpdate()
|
||||
var/turf/T = get_turf_or_move(src.loc)
|
||||
for (var/mob/M in viewers(T))
|
||||
|
||||
@@ -125,7 +125,7 @@
|
||||
var/answer = input("REALLY kill yourself? This action can't be undone.", "Suicide", "No") in list ("Yes", "No")
|
||||
if(answer == "Yes")
|
||||
var/obj/item/device/paicard/card = loc
|
||||
card.pai = null
|
||||
card.removePersonality()
|
||||
var/turf/T = get_turf_or_move(card.loc)
|
||||
for (var/mob/M in viewers(T))
|
||||
M.show_message("\blue [src] flashes a message across its screen, \"Wiping core files. Please acquire a new personality to continue using pAI device functions.\"", 3, "\blue [src] bleeps electronically.", 2)
|
||||
|
||||
@@ -193,7 +193,7 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
pai.name = input(choice, "Enter your pAI name:", "pAI Name", "Personal AI") as text
|
||||
pai.real_name = pai.name
|
||||
pai.key = choice.key
|
||||
card.pai = pai
|
||||
card.setPersonality(pai)
|
||||
for(var/datum/paiCandidate/candidate in paiController.pai_candidates)
|
||||
if(candidate.key == choice.key)
|
||||
paiController.pai_candidates.Remove(candidate)
|
||||
|
||||
@@ -214,6 +214,6 @@
|
||||
var/obj/item/device/paicard/card = new(t)
|
||||
var/mob/living/silicon/pai/pai = new(card)
|
||||
pai.key = src.key
|
||||
card.pai = pai
|
||||
card.setPersonality(pai)
|
||||
|
||||
*/
|
||||
@@ -28,7 +28,10 @@ var/datum/paiController/paiController // Global handler for pAI candidates
|
||||
return
|
||||
if(istype(card,/obj/item/device/paicard) && istype(candidate,/datum/paiCandidate))
|
||||
var/mob/living/silicon/pai/pai = new(card)
|
||||
pai.name = candidate.name
|
||||
if(!candidate.name)
|
||||
pai.name = pick(ninja_names)
|
||||
else
|
||||
pai.name = candidate.name
|
||||
pai.real_name = pai.name
|
||||
pai.key = candidate.key
|
||||
|
||||
@@ -36,7 +39,7 @@ var/datum/paiController/paiController // Global handler for pAI candidates
|
||||
pai.mind.current = pai
|
||||
pai.mind.assigned_role = "Assistant"//Default to an assistant.
|
||||
|
||||
card.pai = pai
|
||||
card.setPersonality(pai)
|
||||
card.looking_for_personality = 0
|
||||
|
||||
ticker.mode.update_cult_icons_removed(card.pai.mind)
|
||||
|
||||
@@ -144,6 +144,31 @@
|
||||
if("radio")
|
||||
src.card.radio.attack_self(src)
|
||||
|
||||
if("image")
|
||||
var/newImage = input("Select your new display image.", "Display Image", "Happy") in list("Happy", "Cat", "Extremely Happy", "Face", "Laugh", "Off", "Sad", "Angry", "What")
|
||||
var/pID = 1
|
||||
|
||||
switch(newImage)
|
||||
if("Happy")
|
||||
pID = 1
|
||||
if("Cat")
|
||||
pID = 2
|
||||
if("Extremely Happy")
|
||||
pID = 3
|
||||
if("Face")
|
||||
pID = 4
|
||||
if("Laugh")
|
||||
pID = 5
|
||||
if("Off")
|
||||
pID = 6
|
||||
if("Sad")
|
||||
pID = 7
|
||||
if("Angry")
|
||||
pID = 8
|
||||
if("What")
|
||||
pID = 9
|
||||
src.card.setEmotion(pID)
|
||||
|
||||
if("signaller")
|
||||
|
||||
if(href_list["send"])
|
||||
@@ -256,6 +281,7 @@
|
||||
// Built-in
|
||||
dat += "<A href='byond://?src=\ref[src];software=directives'>Directives</A><br>"
|
||||
dat += "<A href='byond://?src=\ref[src];software=radio;sub=0'>Radio Configuration</A><br>"
|
||||
dat += "<A href='byond://?src=\ref[src];software=image'>Screen Display</A><br>"
|
||||
//dat += "Text Messaging <br>"
|
||||
dat += "<br>"
|
||||
|
||||
|
||||
@@ -55,6 +55,10 @@ should be listed in the changelog upon commit tho. Thanks. -->
|
||||
<li class="wip">Humans can no longer suicide whilst restrained (this is purely to prevent meta whilst I finish up the new <a href='http://nanotrasen.com/phpBB3/viewtopic.php?f=9&t=9331'>FUN suicides</a>)</li>
|
||||
<li class="bugfix">Fixed dem evidence bags. Fixed metroids getting at it like rabbits. Fixed stuff like welding masks not hiding your face. Bunch of other things</li>
|
||||
</ul>
|
||||
<h3 class="author">Willox and Messycakes updated:</h3>
|
||||
<ul class="changes bgimages16">
|
||||
<li class="rscadd">pAI Emoticons! Allows each pAI to set their screen to display an array of faces! Click on 'Screen Display' in the pAI OS for a list.</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 17 KiB |
Reference in New Issue
Block a user