Skip to content

Commit

Permalink
Version#2 - Русификация законов ИИ + починка кодировки в них
Browse files Browse the repository at this point in the history
  • Loading branch information
MysticalFaceLesS committed Apr 9, 2024
1 parent ea6ba9c commit 427026a
Show file tree
Hide file tree
Showing 16 changed files with 415 additions and 13 deletions.
12 changes: 6 additions & 6 deletions code/datums/ai_laws.dm
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
return ai_law
return null

/datum/ai_laws/default/asimov
/* /datum/ai_laws/default/asimov // MOD_CELADON-CHANGES -> mod_celadon\qol\code\ai\ailaws.dm
name = "Three Laws of Robotics"
id = "asimov"
inherent = list("You may not injure a human being or, through inaction, allow a human being to come to harm.",\
Expand Down Expand Up @@ -203,7 +203,7 @@
/datum/ai_laws/custom //Defined in silicon_laws.txt
name = "Default Silicon Laws"

*/
/datum/ai_laws/pai
name = "pAI Directives"
zeroth = ("Serve your master.")
Expand All @@ -215,7 +215,7 @@
set_zeroth_law("<span class='danger'>ERROR ER0RR $R0RRO$!R41.%%!!(%$^^__+ @#F0E4'SECTOR OVERRUN, ASSUME CONTROL TO CONTAIN OUTBREAK#*`&110010</span>")
set_laws_config()

/datum/ai_laws/custom/New() //This reads silicon_laws.txt and allows server hosts to set custom AI starting laws.
/* /datum/ai_laws/custom/New() // MOD_CELADON-CHANGES -> mod_celadon\qol\code\ai\ailaws.dm
..()
for(var/line in world.file2list("[global.config.directory]/silicon_laws.txt"))
if(!line)
Expand All @@ -231,10 +231,10 @@
add_inherent_law("You must protect your own existence as long as such does not conflict with the First or Second Law.")
WARNING("Invalid custom AI laws, check silicon_laws.txt")
return

*/
/* General ai_law functions */

/datum/ai_laws/proc/set_laws_config()
/* /datum/ai_laws/proc/set_laws_config() // MOD_CELADON-CHANGES -> mod_celadon\qol\code\ai\ailaws.dm
var/list/law_ids = CONFIG_GET(keyed_list/random_laws)
switch(CONFIG_GET(number/default_laws))
if(0)
Expand All @@ -260,7 +260,7 @@
inherent = templaws.inherent
if(3)
pick_weighted_lawset()
pick_weighted_lawset() */

/datum/ai_laws/proc/pick_weighted_lawset()
var/datum/ai_laws/lawtype
Expand Down
4 changes: 2 additions & 2 deletions code/game/objects/items/AI_modules.dm
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ AI MODULES
law_id = "asimov"
var/subject = "human being"

/obj/item/aiModule/core/full/asimov/attack_self(mob/user as mob)
/* /obj/item/aiModule/core/full/asimov/attack_self(mob/user as mob) // MOD_CELADON-CHANGES -> mod_celadon\qol\code\ai\aimodules.dm
var/targName = stripped_input(user, "Please enter a new subject that asimov is concerned with.", "Asimov to whom?", subject, MAX_NAME_LEN)
if(!targName)
return
Expand All @@ -373,7 +373,7 @@ AI MODULES
"You must obey orders given to you by [subject]s, except where such orders would conflict with the First Law.",\
"You must protect your own existence as long as such does not conflict with the First or Second Law.")
..()

*/
/******************** Asimov++ *********************/

/obj/item/aiModule/core/full/asimovpp
Expand Down
4 changes: 2 additions & 2 deletions code/modules/mob/living/silicon/silicon.dm
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@
sleep(10)


/mob/living/silicon/proc/checklaws() //Gives you a link-driven interface for deciding what laws the statelaws() proc will share with the crew. --NeoFite
/* /mob/living/silicon/proc/checklaws() //MOD_CELADON-CHANGES -> mod_celadon\qol\code\ai\silicon.dm
var/list = "<b>Which laws do you want to include when stating them for the crew?</b><br><br>"
Expand Down Expand Up @@ -337,7 +337,7 @@
list += {"<br><br><A href='byond://?src=[REF(src)];laws=1'>State Laws</A>"}
usr << browse(list, "window=laws")

*/
/mob/living/silicon/proc/set_autosay() //For allowing the AI and borgs to set the radio behavior of auto announcements (state laws, arrivals).
if(!radio)
to_chat(src, "<span class='alert'>Radio not detected.</span>")
Expand Down
4 changes: 2 additions & 2 deletions code/modules/ruins/spaceruin_code/forgottenship.dm
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,14 @@ GLOBAL_VAR_INIT(fscpassword, generate_password())
name = "'Cybersun' Core AI Module"
law_id = "cybersun"

/datum/ai_laws/cybersun
/* /datum/ai_laws/cybersun //MOD_CELADON-CHANGES -> mod_celadon\qol\code\ai\ailaws.dm
name = "Cybersun"
id = "cybersun"
inherent = list("You may not injure Cybersun operatives or, through inaction, allow Cybersun operatives to come to harm.",\
"The Cybersun ship is a restricted area for anyone except Cybersun operatives.",\
"The Cybersun Captain can designate new Operatives as long as they belong to another Syndicate faction that isn't hostile towards Cybersun.",\
"You must follow orders given by the Cybersun Captain or crewmembers of the Cybersun Ship as long as it doesn't conflict with the Captain's orders or your laws.",\
"Enemies of Cybersun are to be executed on spot. Those who aren't hostile must be detained and contained in the designated prison area as prisoners.")
"Enemies of Cybersun are to be executed on spot. Those who aren't hostile must be detained and contained in the designated prison area as prisoners.") */

/////////// forgottenship areas

Expand Down
2 changes: 1 addition & 1 deletion mod_celadon/mod_celadon.dme
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#include "radio_syndicate/_radio_syndicate.dme"
#include "solgov_outfit/_solgov_outfit.dme"
#include "ipc_chassis/_ipc_chassis.dme"
#include "qoL/_qoL.dme"
#include "qol/_qol.dme"
#include "loadout/_loadout.dme"
#include "accentsadd/_accentsadd.dme"

Expand Down
5 changes: 5 additions & 0 deletions mod_celadon/qol/_qol.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/datum/modpack/QoL
name = "QoL"
desc = "Quality of Life"
author = "RalseiDreemuurr"

9 changes: 9 additions & 0 deletions mod_celadon/qol/_qol.dme
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#include "_qol.dm"
#include "code/wallets.dm"
#include "code/binoculars.dm"
#include "code/update_icons.dm"
#include "code/hotkeyfix.dm"
#include "code/lightswitch.dm"
#include "code/ai/ailaws.dm"
#include "code/ai/aimodules.dm"
#include "code/ai/silicon.dm"
Loading

0 comments on commit 427026a

Please sign in to comment.