diff --git a/README.txt b/README.txt index 2a3b32c68ad..08043875383 100644 --- a/README.txt +++ b/README.txt @@ -1,6 +1,6 @@ baystation 12 -Website: http://whoopshop.com +Website: http://baystation12.net/ Code: https://github.com/Baystation12/Baystation12 IRC: irc://irc.sorcery.net/bs12 diff --git a/baystation12.dme b/baystation12.dme index 1e8635b68d0..647e95ad1be 100644 --- a/baystation12.dme +++ b/baystation12.dme @@ -338,6 +338,7 @@ #include "code\game\dna.dm" #include "code\game\dna_mutations.dm" #include "code\game\hud.dm" +#include "code\game\json.dm" #include "code\game\landmarks.dm" #include "code\game\master_controller.dm" #include "code\game\prisonshuttle.dm" @@ -441,6 +442,7 @@ #include "code\game\machinery\rechargestation.dm" #include "code\game\machinery\requests_console.dm" #include "code\game\machinery\robot_fabricator.dm" +#include "code\game\machinery\scanner.dm" #include "code\game\machinery\seed_extractor.dm" #include "code\game\machinery\shieldgen.dm" #include "code\game\machinery\sink.dm" diff --git a/code/game/cellautomata.dm b/code/game/cellautomata.dm index 46449af5378..a61ed7262b7 100644 --- a/code/game/cellautomata.dm +++ b/code/game/cellautomata.dm @@ -123,7 +123,7 @@ //Crispy fullban /world/Reboot(var/reason) spawn(0) - world << sound(pick('newroundsexy.ogg','apcdestroyed.ogg','bangindonk.ogg')) // random end sounds!! - LastyBatsy + //world << sound(pick('newroundsexy.ogg','apcdestroyed.ogg','bangindonk.ogg')) // random end sounds!! - LastyBatsy No, no random end sounds. - Miniature //if(prob(40)) // for(var/mob/M in world) // if(M.client) @@ -132,7 +132,7 @@ // for(var/mob/M in world) // if(M.client) // M << sound('apcdestroyed.ogg') - + send2irc(world.url,"Server Rebooting!") for(var/client/C) if (config.server) //if you set a server location in config.txt, it sends you there instead of trying to reconnect to the same world address. -- NeoFite C << link("byond://[config.server]") diff --git a/code/game/gamemodes/gameticker.dm b/code/game/gamemodes/gameticker.dm index 2cad4558abf..f18f35a30bc 100644 --- a/code/game/gamemodes/gameticker.dm +++ b/code/game/gamemodes/gameticker.dm @@ -173,6 +173,7 @@ var/global/datum/controller/gameticker/ticker else feedback_set_details("end_proper","proper completion") world << "\blue Restarting in [restart_timeout/10] seconds" + // send2irc(world.url,"Server Rebooting!") feedback_set_details("round_end","[time2text(world.realtime)]") if(blackbox) diff --git a/code/game/json.dm b/code/game/json.dm new file mode 100644 index 00000000000..94bd63052c1 --- /dev/null +++ b/code/game/json.dm @@ -0,0 +1,102 @@ + +var/jsonpath = "/home/bay12/public_html" +var/dmepath = "/home/bay12/git/baystation12.dme" +var/makejson = 1 //temp +proc/makejson() + + if(!makejson) + return + fdel("[jsonpath]/info.json") + //usr << "Error cant delete json" + //else + //usr << "Deleted json in public html" + fdel("info.json") + //usr << "error cant delete local json" + //else + //usr << "Deleted local json" + var/F = file("info.json") + if(!isfile(F)) + return + var/mode + if(ticker) + if(ticker.current_state == 1) + mode = "Round Setup" + else if(ticker.hide_mode) + mode = "SECRET" + else + mode = master_mode + var/playerscount = 0 + var/players = "" + var/admins = "no" + for(var/client/C) + playerscount++ + if(C.holder) + if(!C.stealth) + admins = "yes" + players += "[C.key];" + else + players += "[C.fakekey];" + else + players += "[C.key];" + F << "{\"mode\":\"[mode]\",\"players\" : \"[players]\",\"playercount\" : \"[playerscount]\",\"admin\" : \"[admins]\",\"time\" : \"[time2text(world.realtime,"MM/DD - hh:mm")]\"}" + fcopy("info.json","[jsonpath]/info.json") + +/proc/switchmap(newmap,newpath) + var/oldmap + var/obj/mapinfo/M = locate() + + if(M) + oldmap = M.mapname + + else + message_admins("Did not locate mapinfo object. Go bug the mapper to add a /obj/mapinfo to their map!\n For now, you can probably spawn one manually. If you do, be sure to set it's mapname var correctly, or else you'll just get an error again.") + return + + message_admins("Current map: [oldmap]") + var/text = file2text(dmepath) + var/path = "#include \"maps/[oldmap].dmm\"" + var/xpath = "#include \"maps/[newpath].dmm\"" + var/loc = findtext(text,path,1,0) + if(!loc) + path = "#include \"maps\\[oldmap].dmm\"" + xpath = "#include \"maps\\[newpath].dmm\"" + loc = findtext(text,path,1,0) + if(!loc) + message_admins("Could not find '#include \"maps\\[oldmap].dmm\"' or '\"maps/[oldmap].dmm\"' in the bs12.dme. The mapinfo probably has an incorrect mapname var. Alternatively, could not find the .dme itself, at [dmepath].") + return + + var/rest = copytext(text, loc + length(path)) + text = copytext(text,1,loc) + text += "\n[xpath]" + text += rest +/* for(var/A in lines) + if(findtext(A,path,1,0)) + lineloc = lines.Find(A,1,0) + lines[lineloc] = xpath + world << "FOUND"*/ + fdel(dmepath) + var/file = file(dmepath) + file << text + message_admins("Compiling...") + shell("./recompile") + message_admins("Done") + world.Reboot("Switching to [newmap]") + +obj/mapinfo + invisibility = 101 + var/mapname = "thismap" + var/decks = 4 +proc/GetMapInfo() + var/obj/mapinfo/M = locate() + world << M.name + world << M.mapname +client/proc/ChangeMap(var/X as text) + set name = "Change Map" + set category = "Admin" + switchmap(X,X) +proc/send2irc(msg,msg2) + shell("python26 nudge.py [msg] [msg2]") +proc/send2adminirc(channel,msg) + world << channel << " "<< msg + shell("python26 nudge.py '[channel]' [msg]") +p //test \ No newline at end of file diff --git a/code/game/machinery/scanner.dm b/code/game/machinery/scanner.dm new file mode 100644 index 00000000000..857ed1dbbfc --- /dev/null +++ b/code/game/machinery/scanner.dm @@ -0,0 +1,140 @@ +//not a computer +obj/machinery/scanner + name = "Identity Analyser" + var/outputdir = 0 + icon = 'stationobjs.dmi' + icon_state = "scanner_idle" + density = 1 + anchored = 1 + var/lastuser = null + +obj/machinery/scanner/New() + if(!outputdir) + switch(dir) + if(1) + outputdir = 2 + if(2) + outputdir = 1 + if(4) + outputdir = 8 + if(8) + outputdir = 4 + if(!outputdir) + outputdir = 8 + +/obj/machinery/scanner/process() + if(stat & NOPOWER) + return + use_power(50) + +/obj/machinery/scanner/power_change() + if(!powered()) + spawn(rand(0, 15)) + icon_state = "scanner_off" + stat |= NOPOWER + else + icon_state = "scanner_idle" + stat &= ~NOPOWER + +obj/machinery/scanner/attack_hand(mob/living/carbon/human/user) + if(stat & NOPOWER) + return + if(!ishuman(user) || lastuser == user.real_name) + return + use_power(500) + flick("scanner_on",src) + lastuser = user.real_name + var/mname = user.real_name + var/dna = user.dna.unique_enzymes + var/bloodtype = user.b_type + var/fingerprint = md5(user.dna.uni_identity) + var/list/marks = list() + var/age = user.age + var/gender = user.gender + /* no dbstuff yet + var/DBQuery/cquery = dbcon.NewQuery("SELECT * from jobban WHERE ckey='[user.ckey]'") + if(!cquery.Execute()) return + else + while(cquery.NextRow()) + var/list/row = cquery.GetRowData() + marks += row["rank"] + */ + var/text = {" +
Report

+ Name: [mname] + Age: [age] + Sex: [gender] + DNA: [dna] + Blood Type: [bloodtype] + Fingerprint: [fingerprint] + + Black Marks:
"} + for(var/A in marks) + text += "\red[A]
" + user << "\blue You feel a sting as the scanner sucks all your information out of you and sticks it in it's database." + var/turf/T = get_step(src,outputdir) + var/obj/item/weapon/paper/print = new(T) + print.name = "[mname] Report" + print.info = text + print.stamped = 1 + + for(var/datum/data/record/test in data_core.general) + if (test.fields["name"] == mname) + return + + var/datum/data/record/G = new() + var/datum/data/record/M = new() + var/datum/data/record/S = new() + var/datum/data/record/L = new() + G.fields["rank"] = "Unassigned" + G.fields["name"] = mname + G.fields["id"] = text("[]", add_zero(num2hex(rand(1, 1.6777215E7)), 6)) + M.fields["name"] = G.fields["name"] + M.fields["id"] = G.fields["id"] + S.fields["name"] = G.fields["name"] + S.fields["id"] = G.fields["id"] + if(gender == FEMALE) + G.fields["sex"] = "Female" + else + G.fields["sex"] = "Male" + G.fields["age"] = text("[]", age) + G.fields["fingerprint"] = text("[]", fingerprint) + G.fields["p_stat"] = "Active" + G.fields["m_stat"] = "Stable" + M.fields["b_type"] = text("[]", bloodtype) + M.fields["b_dna"] = dna + M.fields["mi_dis"] = "None" + M.fields["mi_dis_d"] = "No minor disabilities have been declared." + M.fields["ma_dis"] = "None" + M.fields["ma_dis_d"] = "No major disabilities have been diagnosed." + M.fields["alg"] = "None" + M.fields["alg_d"] = "No allergies have been detected in this patient." + M.fields["cdi"] = "None" + M.fields["cdi_d"] = "No diseases have been diagnosed at the moment." + M.fields["notes"] = "No notes." + S.fields["criminal"] = "None" + S.fields["mi_crim"] = "None" + S.fields["mi_crim_d"] = "No minor crime convictions." + S.fields["ma_crim"] = "None" + S.fields["ma_crim_d"] = "No major crime convictions." + S.fields["notes"] = "No notes." + + //Begin locked reporting + L.fields["name"] = mname + L.fields["sex"] = gender + L.fields["age"] = age + L.fields["id"] = md5("[mname][user.mind.assigned_role]") + L.fields["rank"] = "Unknown" + L.fields["b_type"] = bloodtype + L.fields["b_dna"] = dna + L.fields["enzymes"] = user.dna.struc_enzymes + L.fields["identity"] = user.dna.uni_identity + L.fields["image"] = getFlatIcon(user,0)//What the person looks like. Naked, in this case. + //End locked reporting + + data_core.general += G + data_core.medical += M + data_core.security += S + data_core.locked += L + + diff --git a/code/game/vote.dm b/code/game/vote.dm index 7dbe6c6cce9..93155476e47 100644 --- a/code/game/vote.dm +++ b/code/game/vote.dm @@ -74,7 +74,7 @@ world << "Result is change to \red [wintext]" world.save_mode(winner) - if(ticker) + if(ticker.current_state != 1) world <<"\red World will reboot in 10 seconds" feedback_set_details("end_error","mode vote - [winner]") diff --git a/code/modules/admin/admin.dm b/code/modules/admin/admin.dm index 89684bc2d47..47cc72bc567 100644 --- a/code/modules/admin/admin.dm +++ b/code/modules/admin/admin.dm @@ -2152,7 +2152,7 @@ feedback_set_details("round_end","[time2text(world.realtime)]") if(blackbox) blackbox.save_all_data_to_sql() - + //send2irc(world.url,"Server Rebooting!") sleep(50) world.Reboot() diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm index 087bf09b1b9..14d703cf080 100644 --- a/code/modules/mob/mob.dm +++ b/code/modules/mob/mob.dm @@ -678,7 +678,7 @@ world.update_status() ..() - + makejson() if (join_motd) src << "
[join_motd]
" @@ -696,6 +696,7 @@ spawn(0) if(holder) del(holder) + makejson() return ..() /mob/proc/can_use_hands() diff --git a/config/admins.txt b/config/admins.txt index 08f2869fee0..063b55edc49 100644 --- a/config/admins.txt +++ b/config/admins.txt @@ -3,7 +3,7 @@ arcalane - Game Admin cacophony - Game Admin cajoes - Game Admin cib - Game Master -compactninja - Game Admin +compactninja - Game Master headswe - Game Master iaryni - Game Master masterofapples - Game Admin diff --git a/html/changelog.html b/html/changelog.html index 5fd7e3c5357..564e5f1a351 100644 --- a/html/changelog.html +++ b/html/changelog.html @@ -25,14 +25,14 @@
Baystation 12

- Forum:
http://whoopshop.com

- Guides and information wiki:
http://wiki.whoopshop.com

+ Forum:
http://baystation12.net

+ Guides and information wiki:
http://wiki.baystation12.net

Visit our IRC channel:
#bs12 on sorcery.net

-

Read the player guidelines!

+

Read the player guidelines!

Github change history

diff --git a/icons/obj/stationobjs.dmi b/icons/obj/stationobjs.dmi index 1c92b1415e5..e2b315e0c69 100644 Binary files a/icons/obj/stationobjs.dmi and b/icons/obj/stationobjs.dmi differ