Ports ambition system. (#4142)

Ports the ambition system from bay that lets antags set the ambition for themselves that displays at round end. Has no effect on the round. And removes a clown check.
This commit is contained in:
Ron
2018-01-26 13:06:35 -05:00
committed by Werner
parent 769eec1bca
commit 8093c534be
6 changed files with 51 additions and 6 deletions

View File

@@ -69,6 +69,7 @@
//put this here for easier tracking ingame
var/datum/money_account/initial_account
var/ambitions
/datum/mind/New(var/key)
src.key = key
@@ -114,6 +115,9 @@
var/output = "<B>[current.real_name]'s Memory</B><HR>"
output += memory
if(ambitions)
output += "<HR><B>Ambitions:</B> [ambitions]<br>"
if(objectives.len>0)
output += "<HR><B>Objectives:</B>"
@@ -156,6 +160,7 @@
else
out += "None."
out += "<br><a href='?src=\ref[src];obj_add=1'>\[add\]</a>"
out += "<b>Ambitions:</b> [ambitions ? ambitions : "None"] <a href='?src=\ref[src];amb_edit=\ref[src]'>\[edit\]</a></br>"
usr << browse(out, "window=edit_memory[src]")
/datum/mind/Topic(href, href_list)
@@ -195,6 +200,13 @@
if (isnull(new_memo)) return
memory = new_memo
else if (href_list["amb_edit"])
var/new_ambition = input("Enter a new ambition", "Memory",src.ambitions) as null|message
if(isnull(new_ambition))
return
src.ambitions = sanitize(new_ambition)
src.current << "<span class='warning'>Your ambitions have been changed by higher powers, they are now: [src.ambitions]</span>"
else if (href_list["obj_edit"] || href_list["obj_add"])
var/datum/objective/objective
var/objective_pos