diff --git a/code/modules/mob/living/silicon/ai/ai.dm b/code/modules/mob/living/silicon/ai/ai.dm
index 14b45795273..904d021e166 100644
--- a/code/modules/mob/living/silicon/ai/ai.dm
+++ b/code/modules/mob/living/silicon/ai/ai.dm
@@ -26,8 +26,6 @@ var/list/ai_list = list()
//var/list/laws = list()
var/alarms = list("Motion"=list(), "Fire"=list(), "Atmosphere"=list(), "Power"=list(), "Camera"=list())
var/viewalerts = 0
- var/lawcheck[1]
- var/ioncheck[1]
var/icon/holo_icon//Default is assigned when AI is created.
var/obj/item/device/pda/ai/aiPDA = null
var/obj/item/device/multitool/aiMulti = null
@@ -335,25 +333,6 @@ var/list/ai_list = list()
else
src << "Unable to locate the holopad."
- if (href_list["lawc"]) // Toggling whether or not a law gets stated by the State Laws verb --NeoFite
- var/L = text2num(href_list["lawc"])
- switch(lawcheck[L+1])
- if ("Yes") lawcheck[L+1] = "No"
- if ("No") lawcheck[L+1] = "Yes"
-// src << text ("Switching Law [L]'s report status to []", lawcheck[L+1])
- checklaws()
-
- if (href_list["lawi"]) // Toggling whether or not a law gets stated by the State Laws verb --NeoFite
- var/L = text2num(href_list["lawi"])
- switch(ioncheck[L])
- if ("Yes") ioncheck[L] = "No"
- if ("No") ioncheck[L] = "Yes"
-// src << text ("Switching Law [L]'s report status to []", lawcheck[L+1])
- checklaws()
-
- if (href_list["laws"]) // With how my law selection code works, I changed statelaws from a verb to a proc, and call it through my law selection panel. --NeoFite
- statelaws()
-
if (href_list["track"])
var/mob/target = locate(href_list["track"]) in mob_list
var/mob/living/silicon/ai/A = locate(href_list["track2"]) in mob_list
@@ -704,3 +683,9 @@ var/list/ai_list = list()
src.current = camera
src.current.SetLuminosity(AI_CAMERA_LUMINOSITY)
camera_light_on = world.timeofday + 1 * 20 // Update the light every 2 seconds.
+
+/mob/living/silicon/ai/verb/outputlaws()
+ set category = "AI Commands"
+ set name = "State Laws"
+
+ checklaws()
diff --git a/code/modules/mob/living/silicon/ai/laws.dm b/code/modules/mob/living/silicon/ai/laws.dm
index b4cc83867f2..00c40f11edd 100644
--- a/code/modules/mob/living/silicon/ai/laws.dm
+++ b/code/modules/mob/living/silicon/ai/laws.dm
@@ -50,100 +50,3 @@
/mob/living/silicon/ai/proc/clear_supplied_laws()
src.laws_sanity_check()
src.laws.clear_supplied_laws()
-
-
-
-
-
-/mob/living/silicon/ai/proc/statelaws() // -- TLE
-// set category = "AI Commands"
-// set name = "State Laws"
- src.say("Current Active Laws:")
- //src.laws_sanity_check()
- //src.laws.show_laws(world)
- var/number = 1
- sleep(10)
-
-
-
- if (src.laws.zeroth)
- if (src.lawcheck[1] == "Yes") //This line and the similar lines below make sure you don't state a law unless you want to. --NeoFite
- src.say("0. [src.laws.zeroth]")
- sleep(10)
-
- for (var/index = 1, index <= src.laws.ion.len, index++)
- var/law = src.laws.ion[index]
- var/num = ionnum()
- if (length(law) > 0)
- if (src.ioncheck[index] == "Yes")
- src.say("[num]. [law]")
- sleep(10)
-
- for (var/index = 1, index <= src.laws.inherent.len, index++)
- var/law = src.laws.inherent[index]
-
- if (length(law) > 0)
- if (src.lawcheck[index+1] == "Yes")
- src.say("[number]. [law]")
- sleep(10)
- number++
-
-
- for (var/index = 1, index <= src.laws.supplied.len, index++)
- var/law = src.laws.supplied[index]
-
- if (length(law) > 0)
- if(src.lawcheck.len >= number+1)
- if (src.lawcheck[number+1] == "Yes")
- src.say("[number]. [law]")
- sleep(10)
- number++
-
-
-/mob/living/silicon/ai/verb/checklaws() //Gives you a link-driven interface for deciding what laws the statelaws() proc will share with the crew. --NeoFite
- set category = "AI Commands"
- set name = "State Laws"
-
- var/list = "Which laws do you want to include when stating them for the crew?
"
-
-
-
- if (src.laws.zeroth)
- if (!src.lawcheck[1])
- src.lawcheck[1] = "No" //Given Law 0's usual nature, it defaults to NOT getting reported. --NeoFite
- list += {"[src.lawcheck[1]] 0: [src.laws.zeroth]
"}
-
- for (var/index = 1, index <= src.laws.ion.len, index++)
- var/law = src.laws.ion[index]
-
- if (length(law) > 0)
-
-
- if (!src.ioncheck[index])
- src.ioncheck[index] = "Yes"
- list += {"[src.ioncheck[index]] [ionnum()]: [law]
"}
- src.ioncheck.len += 1
-
- var/number = 1
- for (var/index = 1, index <= src.laws.inherent.len, index++)
- var/law = src.laws.inherent[index]
-
- if (length(law) > 0)
- src.lawcheck.len += 1
-
- if (!src.lawcheck[number+1])
- src.lawcheck[number+1] = "Yes"
- list += {"[src.lawcheck[number+1]] [number]: [law]
"}
- number++
-
- for (var/index = 1, index <= src.laws.supplied.len, index++)
- var/law = src.laws.supplied[index]
- if (length(law) > 0)
- src.lawcheck.len += 1
- if (!src.lawcheck[number+1])
- src.lawcheck[number+1] = "Yes"
- list += {"[src.lawcheck[number+1]] [number]: [law]
"}
- number++
- list += {"
State Laws"}
-
- usr << browse(list, "window=laws")
\ No newline at end of file
diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm
index 73a17c7a8dc..b664e3b68cb 100644
--- a/code/modules/mob/living/silicon/robot/robot.dm
+++ b/code/modules/mob/living/silicon/robot/robot.dm
@@ -58,6 +58,7 @@
var/obj/item/weapon/tank/internal = null //Hatred. Used if a borg has a jetpack.
+
/mob/living/silicon/robot/New(loc,var/syndie = 0)
spark_system = new /datum/effect/effect/system/spark_spread()
spark_system.set_up(5, 0, src)
@@ -903,6 +904,7 @@
else
src << "Module isn't activated"
installed_modules()
+
return
/mob/living/silicon/robot/proc/radio_menu()
@@ -993,4 +995,12 @@
if(wires.LockedCut())
state = 1
lockcharge = state
- update_canmove()
\ No newline at end of file
+ update_canmove()
+
+
+
+/mob/living/silicon/robot/verb/outputlaws()
+ set category = "Robot Commands"
+ set name = "State Laws"
+
+ checklaws()
\ No newline at end of file
diff --git a/code/modules/mob/living/silicon/silicon.dm b/code/modules/mob/living/silicon/silicon.dm
index 0bd9c9e967b..7598fa6edbc 100644
--- a/code/modules/mob/living/silicon/silicon.dm
+++ b/code/modules/mob/living/silicon/silicon.dm
@@ -11,6 +11,9 @@
var/list/alarm_types_show = list("Motion" = 0, "Fire" = 0, "Atmosphere" = 0, "Power" = 0, "Camera" = 0)
var/list/alarm_types_clear = list("Motion" = 0, "Fire" = 0, "Atmosphere" = 0, "Power" = 0, "Camera" = 0)
+ var/lawcheck[1]
+ var/ioncheck[1]
+
/mob/living/silicon/proc/cancelAlarm()
return
@@ -144,4 +147,113 @@
return 0
if (bot.connected_ai == ai)
return 1
- return 0
\ No newline at end of file
+ return 0
+
+/mob/living/silicon/Topic(href, href_list)
+ if (href_list["lawc"]) // Toggling whether or not a law gets stated by the State Laws verb --NeoFite
+ var/L = text2num(href_list["lawc"])
+ switch(lawcheck[L+1])
+ if ("Yes") lawcheck[L+1] = "No"
+ if ("No") lawcheck[L+1] = "Yes"
+// src << text ("Switching Law [L]'s report status to []", lawcheck[L+1])
+ checklaws()
+
+ if (href_list["lawi"]) // Toggling whether or not a law gets stated by the State Laws verb --NeoFite
+ var/L = text2num(href_list["lawi"])
+ switch(ioncheck[L])
+ if ("Yes") ioncheck[L] = "No"
+ if ("No") ioncheck[L] = "Yes"
+// src << text ("Switching Law [L]'s report status to []", lawcheck[L+1])
+ checklaws()
+
+ if (href_list["laws"]) // With how my law selection code works, I changed statelaws from a verb to a proc, and call it through my law selection panel. --NeoFite
+ statelaws()
+
+ return
+
+
+/mob/living/silicon/proc/statelaws() // -- TLE
+
+ src.say("Current Active Laws:")
+ //src.laws_sanity_check()
+ //src.laws.show_laws(world)
+ var/number = 1
+ sleep(10)
+
+
+
+ if (src.laws.zeroth)
+ if (src.lawcheck[1] == "Yes") //This line and the similar lines below make sure you don't state a law unless you want to. --NeoFite
+ src.say("0. [src.laws.zeroth]")
+ sleep(10)
+
+ for (var/index = 1, index <= src.laws.ion.len, index++)
+ var/law = src.laws.ion[index]
+ var/num = ionnum()
+ if (length(law) > 0)
+ if (src.ioncheck[index] == "Yes")
+ src.say("[num]. [law]")
+ sleep(10)
+
+ for (var/index = 1, index <= src.laws.inherent.len, index++)
+ var/law = src.laws.inherent[index]
+
+ if (length(law) > 0)
+ if (src.lawcheck[index+1] == "Yes")
+ src.say("[number]. [law]")
+ sleep(10)
+ number++
+
+
+ for (var/index = 1, index <= src.laws.supplied.len, index++)
+ var/law = src.laws.supplied[index]
+
+ if (length(law) > 0)
+ if(src.lawcheck.len >= number+1)
+ if (src.lawcheck[number+1] == "Yes")
+ src.say("[number]. [law]")
+ sleep(10)
+ number++
+
+
+/mob/living/silicon/proc/checklaws() //Gives you a link-driven interface for deciding what laws the statelaws() proc will share with the crew. --NeoFite
+
+ var/list = "Which laws do you want to include when stating them for the crew?
"
+
+ if (src.laws.zeroth)
+ if (!src.lawcheck[1])
+ src.lawcheck[1] = "No" //Given Law 0's usual nature, it defaults to NOT getting reported. --NeoFite
+ list += {"[src.lawcheck[1]] 0: [src.laws.zeroth]
"}
+
+ for (var/index = 1, index <= src.laws.ion.len, index++)
+ var/law = src.laws.ion[index]
+
+ if (length(law) > 0)
+ if (!src.ioncheck[index])
+ src.ioncheck[index] = "Yes"
+ list += {"[src.ioncheck[index]] [ionnum()]: [law]
"}
+ src.ioncheck.len += 1
+
+ var/number = 1
+ for (var/index = 1, index <= src.laws.inherent.len, index++)
+ var/law = src.laws.inherent[index]
+
+ if (length(law) > 0)
+ src.lawcheck.len += 1
+
+ if (!src.lawcheck[number+1])
+ src.lawcheck[number+1] = "Yes"
+ list += {"[src.lawcheck[number+1]] [number]: [law]
"}
+ number++
+
+ for (var/index = 1, index <= src.laws.supplied.len, index++)
+ var/law = src.laws.supplied[index]
+ if (length(law) > 0)
+ src.lawcheck.len += 1
+ if (!src.lawcheck[number+1])
+ src.lawcheck[number+1] = "Yes"
+ list += {"[src.lawcheck[number+1]] [number]: [law]
"}
+ number++
+ list += {"
State Laws"}
+
+ usr << browse(list, "window=laws")
\ No newline at end of file