eh it works

This commit is contained in:
deathride58
2017-10-11 18:03:58 -04:00
parent 10cecff362
commit bd18903e13
3 changed files with 24 additions and 11 deletions
+6 -6
View File
@@ -1,6 +1,6 @@
/datum/controller/subsystem/ticker/proc/generate_crew_objectives()
for(var/datum/mind/crewMind in SSticker.minds)
if(prob(2) && !issilicon(crewMind.current) && !jobban_isbanned(crewMind, "Syndicate") && GLOB.miscreants_allowed && ROLE_MISCREANT in crewMind.current.client.prefs.be_special)
if(prob(5) && !issilicon(crewMind.current) && !jobban_isbanned(crewMind, "Syndicate") && GLOB.miscreants_allowed && ROLE_MISCREANT in crewMind.current.client.prefs.be_special)
generate_miscreant_objectives(crewMind)
else
if(CONFIG_GET(flag/allow_crew_objectives))
@@ -16,7 +16,8 @@
return
if(!crewMind.assigned_role)
return
var/list/validobjs = get_valid_crew_objs(ckey(crewMind.assigned_role))
var/list/validobjs = crewobjjobs["[ckey(crewMind.assigned_role)]"]
//var/list/validobjs = get_valid_crew_objs(ckey(crewMind.assigned_role))
if(!validobjs || !validobjs.len)
return
var/selectedObj = pick(validobjs)
@@ -28,15 +29,14 @@
to_chat(crewMind, "<B>As a part of Nanotrasen's anti-tide efforts, you have been assigned an optional objective. It will be checked at the end of the shift. <font color=red>Performing traitorous acts in pursuit of your objective may result in termination of your employment.</font></B>")
to_chat(crewMind, "<B>Your optional objective:</B> [newObjective.explanation_text]")
/datum/controller/subsystem/ticker/proc/get_valid_crew_objs(var/job = "")//taken from old hippie with adjustments
var/list/objpaths = typesof(/datum/objective/crew)
/*/datum/controller/subsystem/ticker/proc/get_valid_crew_objs(var/job = "")//taken from old hippie with adjustments
var/list/objlist = list()
for(var/hoorayhackyshit in objpaths)
for(var/hoorayhackyshit in crewobjlist)
var/datum/objective/crew/obj = hoorayhackyshit //dm is not a sane language in any way, shape, or form.
var/list/availableto = splittext(initial(obj.jobs),",")
if(job in availableto)
objlist += obj
return objlist
return objlist*/
/datum/objective/crew/
var/jobs = ""