Merge pull request #387 from Jay-Sparrow/antags

Lewd Antag
This commit is contained in:
Dahlular
2020-08-31 02:41:58 -06:00
committed by GitHub
10 changed files with 431 additions and 12 deletions
+35 -1
View File
@@ -453,7 +453,7 @@
else
target_antag = target
var/new_obj_type = input("Select objective type:", "Objective type", def_value) as null|anything in list("assassinate", "maroon", "debrain", "protect", "destroy", "prevent", "hijack", "escape", "survive", "martyr", "steal", "download", "nuclear", "capture", "absorb", "custom")
var/new_obj_type = input("Select objective type:", "Objective type", def_value) as null|anything in list("assassinate", "maroon", "debrain", "protect", "destroy", "prevent", "hijack", "escape", "survive", "martyr", "steal", "download", "nuclear", "capture", "absorb", "noncon", "custom")
if (!new_obj_type)
return
@@ -555,6 +555,40 @@
new_objective.owner = src
new_objective.target_amount = target_number
//Hyper objective
if ("noncon")
//new_objective = new /datum/objective/noncon
//new_objective.owner = src
var/list/possible_targets = list("Free lewd objective")
for(var/datum/mind/possible_target in SSticker.minds)
if ((possible_target != src) && ishuman(possible_target.current))
possible_targets += possible_target.current
var/mob/def_target = null
var/list/objective_list = typecacheof(list(/datum/objective/assassinate, /datum/objective/protect, /datum/objective/debrain, /datum/objective/maroon))
if (is_type_in_typecache(objective, objective_list) && objective.target)
def_target = objective.target.current
var/mob/new_target = input("Select target:", "Objective target", def_target) as null|anything in possible_targets
if (!new_target)
return
var/objective_path = text2path("/datum/objective/[new_obj_type]")
if (new_target == "Free lewd objective")
new_objective = new objective_path
new_objective.owner = src
new_objective.target = null
new_objective.explanation_text = "Free lewd objective"
objectives += new_objective
else
new_objective = new objective_path
new_objective.owner = src
new_objective.target = new_target.mind
//Will display as special role if the target is set as MODE. Ninjas/commandos/nuke ops.
new_objective.update_explanation_text()
objectives += new_objective
if ("custom")
var/expl = stripped_input(usr, "Custom objective:", "Objective", objective ? objective.explanation_text : "")
if (!expl)