diff --git a/code/WorkInProgress/Cael_Aislinn/BirdMan/birdman.dm b/code/WorkInProgress/Cael_Aislinn/BirdMan/birdman.dm index 45206ccc9ee..34872f32851 100644 --- a/code/WorkInProgress/Cael_Aislinn/BirdMan/birdman.dm +++ b/code/WorkInProgress/Cael_Aislinn/BirdMan/birdman.dm @@ -46,8 +46,8 @@ - var/husk = (mutations & HUSK) - //var/obese = (mutations & FAT) + var/husk = (HUSK in mutations) + //var/obese = (FAT in mutation) stand_icon.Blend(new /icon('birdman.dmi', "chest_[g]_s"), ICON_OVERLAY) lying_icon.Blend(new /icon('birdman.dmi', "chest_[g]_l"), ICON_OVERLAY) diff --git a/code/WorkInProgress/Cael_Aislinn/Tajara/tajaran.dm b/code/WorkInProgress/Cael_Aislinn/Tajara/tajaran.dm index 3541f135f6d..8f4a741ff74 100644 --- a/code/WorkInProgress/Cael_Aislinn/Tajara/tajaran.dm +++ b/code/WorkInProgress/Cael_Aislinn/Tajara/tajaran.dm @@ -43,19 +43,19 @@ // lol var/fat = "" - /*if (mutations & FAT) + /*if (FAT in mutation) fat = "fat"*/ /* - if (mutations & HULK) + if (HULK in mutations) overlays += image("icon" = 'genetics.dmi', "icon_state" = "hulk[fat][!lying ? "_s" : "_l"]") */ - if (mutations & COLD_RESISTANCE) + if (COLD_RESISTANCE in mutations) overlays += image("icon" = 'genetics.dmi', "icon_state" = "fire[fat][!lying ? "_s" : "_l"]") - if (mutations & TK) + if (TK in mutations) overlays += image("icon" = 'genetics.dmi', "icon_state" = "telekinesishead[fat][!lying ? "_s" : "_l"]") - if (mutations & LASER) + if (LASER in mutations) overlays += image("icon" = 'genetics.dmi', "icon_state" = "lasereyes[!lying ? "_s" : "_l"]") if (mutantrace) @@ -141,7 +141,7 @@ // Uniform if(w_uniform) - /*if (mutations & FAT && !(w_uniform.flags & ONESIZEFITSALL)) + /*if ((FAT in mutations) && !(w_uniform.flags & ONESIZEFITSALL)) src << "\red You burst out of the [w_uniform.name]!" var/obj/item/clothing/c = w_uniform u_equip(c) @@ -157,7 +157,7 @@ var/t1 = w_uniform.color if (!t1) t1 = icon_state - /*if (mutations & FAT) + /*if (FAT in mutations) overlays += image("icon" = 'uniform_fat.dmi', "icon_state" = "[t1][!lying ? "_s" : "_l"]", "layer" = MOB_LAYER) else*/ overlays += image("icon" = 'uniform.dmi', "icon_state" = text("[][]",t1, (!(lying) ? "_s" : "_l")), "layer" = MOB_LAYER) @@ -269,7 +269,7 @@ var/tail_shown = 1 if (wear_suit) - /*if (mutations & FAT && !(wear_suit.flags & ONESIZEFITSALL)) + /*if ((FAT in mutations) && !(wear_suit.flags & ONESIZEFITSALL)) src << "\red You burst out of the [wear_suit.name]!" var/obj/item/clothing/c = wear_suit u_equip(c) @@ -463,8 +463,8 @@ - var/husk = (mutations & HUSK) - //var/obese = (mutations & FAT) + var/husk = (HUSK in mutations) + //var/obese = (FAT in mutations) stand_icon.Blend(new /icon('tajaran.dmi', "chest_[g]_s"), ICON_OVERLAY) lying_icon.Blend(new /icon('tajaran.dmi', "chest_[g]_l"), ICON_OVERLAY) diff --git a/code/defines/obj/weapon.dm b/code/defines/obj/weapon.dm index 8343001fc8b..769e393ed9f 100644 --- a/code/defines/obj/weapon.dm +++ b/code/defines/obj/weapon.dm @@ -67,7 +67,7 @@ user << "\red You don't have the dexterity to do this!" return - if ((user.mutations & CLUMSY) && prob(50)) + if ((CLUMSY in user.mutations) && prob(50)) user << "\red The rod slips out of your hand and hits your head." user.take_organ_damage(10) user.Paralyse(20) diff --git a/code/game/algorithm.dm b/code/game/algorithm.dm index e5c5f350471..3789a2227fc 100644 --- a/code/game/algorithm.dm +++ b/code/game/algorithm.dm @@ -17,6 +17,8 @@ Starting up. [time2text(world.timeofday, "hh:mm.ss")] --------------------- "} + href_logfile = file("data/logs/[time2text(world.realtime, "YYYY/MM-Month/DD-Day")] hrefs.html") + jobban_loadbanfile() jobban_updatelegacybans() LoadBans() diff --git a/code/game/gamemodes/traitor/traitor.dm b/code/game/gamemodes/traitor/traitor.dm index c80099fb9ca..2747c30b92f 100644 --- a/code/game/gamemodes/traitor/traitor.dm +++ b/code/game/gamemodes/traitor/traitor.dm @@ -212,7 +212,7 @@ if (traitor_mob.mind) if (traitor_mob.mind.assigned_role == "Clown") traitor_mob << "Your training has allowed you to overcome your clownish nature, allowing you to wield weapons without harming yourself." - traitor_mob.mutations &= ~CLUMSY + traitor_mob.mutations.Remove(CLUMSY) // find a radio! toolbox(es), backpack, belt, headset, pockets var/loc = "" diff --git a/code/game/objects/items/tk_grab.dm b/code/game/objects/items/tk_grab.dm index 02e5c30730f..a621dec8d4a 100644 --- a/code/game/objects/items/tk_grab.dm +++ b/code/game/objects/items/tk_grab.dm @@ -114,7 +114,7 @@ //equip_if_possible(obj/item/W, slot, del_on_fail = 1) /* if(istype(user, /mob/living/carbon)) - if(user:mutations & TK && get_dist(source, user) <= 7) + if((TK in user:mutations) && get_dist(source, user) <= 7) if(user:equipped()) return 0 var/X = source:x var/Y = source:y diff --git a/code/game/objects/items/weapons/papers_bins.dm b/code/game/objects/items/weapons/papers_bins.dm index ce9c2710827..e284daf9ca9 100644 --- a/code/game/objects/items/weapons/papers_bins.dm +++ b/code/game/objects/items/weapons/papers_bins.dm @@ -96,7 +96,7 @@ NOTEBOOK set category = "Object" set src in usr - if ((usr.mutations & CLUMSY) && prob(50)) + if ((CLUMSY in usr.mutations) && prob(50)) usr << text("\red You cut yourself on the paper.") return var/n_name = input(usr, "What would you like to label the paper?", "Paper Labelling", null) as text diff --git a/code/modules/admin/IsBanned.dm b/code/modules/admin/IsBanned.dm index 94f81aafa21..aa0f8129bf3 100644 --- a/code/modules/admin/IsBanned.dm +++ b/code/modules/admin/IsBanned.dm @@ -1,10 +1,10 @@ //Blocks an attempt to connect before even creating our client datum thing. world/IsBanned(key,address,computer_id) - if(ckey(key) in admins) - return ..() +// if(ckey(key) in admins) +// return ..() //Guest Checking - if( !guests_allowed && IsGuestKey(key) ) + if(IsGuestKey(key)) log_access("Failed Login: [key] - Guests not allowed") message_admins("\blue Failed Login: [key] - Guests not allowed") return list("reason"="guest", "desc"="\nReason: Guests not allowed.brb") diff --git a/code/modules/admin/NewBan.dm b/code/modules/admin/NewBan.dm index 4ad0979f1a8..b479a7f0938 100644 --- a/code/modules/admin/NewBan.dm +++ b/code/modules/admin/NewBan.dm @@ -2,9 +2,7 @@ var/CMinutes = null var/savefile/Banlist - /proc/CheckBan(var/ckey, var/id, var/address) - if(!Banlist) // if Banlist cannot be located for some reason LoadBans() // try to load the bans if(!Banlist) // uh oh, can't find bans! @@ -18,11 +16,11 @@ var/savefile/Banlist if( "[ckey][id]" in Banlist.dir ) Banlist.cd = "[ckey][id]" if (Banlist["temp"]) - if (!GetBanExp(Banlist["minutes"])) + if (!GetExp(Banlist["minutes"])) ClearTempbans() return 0 else - .["desc"] = "\nReason: [Banlist["reason"]]\nExpires: [GetBanExp(Banlist["minutes"])]\nBy: [Banlist["bannedby"]][appeal]" + .["desc"] = "\nReason: [Banlist["reason"]]\nExpires: [GetExp(Banlist["minutes"])]\nBy: [Banlist["bannedby"]][appeal]" else Banlist.cd = "/base/[ckey][id]" .["desc"] = "\nReason: [Banlist["reason"]]\nExpires: PERMENANT\nBy: [Banlist["bannedby"]][appeal]" @@ -34,7 +32,7 @@ var/savefile/Banlist var/matches if( ckey == Banlist["key"] ) matches += "ckey" - if( id == Banlist["id"] && Banlist["skipIdCheck"] == 0) + if( id == Banlist["id"] ) if(matches) matches += "/" matches += "id" @@ -45,11 +43,11 @@ var/savefile/Banlist if(matches) if(Banlist["temp"]) - if (!GetBanExp(Banlist["minutes"])) + if (!GetExp(Banlist["minutes"])) ClearTempbans() return 0 else - .["desc"] = "\nReason: [Banlist["reason"]]\nExpires: [GetBanExp(Banlist["minutes"])]\nBy: [Banlist["bannedby"]][appeal]" + .["desc"] = "\nReason: [Banlist["reason"]]\nExpires: [GetExp(Banlist["minutes"])]\nBy: [Banlist["bannedby"]][appeal]" else .["desc"] = "\nReason: [Banlist["reason"]]\nExpires: PERMENANT\nBy: [Banlist["bannedby"]][appeal]" .["reason"] = matches @@ -63,16 +61,15 @@ var/savefile/Banlist /proc/LoadBans() Banlist = new("data/banlist.bdb") - log_admin("Loading Banlist") + log_admin("Loading banlist.") if (!length(Banlist.dir)) log_admin("Banlist is empty.") if (!Banlist.dir.Find("base")) log_admin("Banlist missing base dir.") Banlist.dir.Add("base") - Banlist.cd = "/base" - else if (Banlist.dir.Find("base")) - Banlist.cd = "/base" + + Banlist.cd = "/base" ClearTempbans() return 1 @@ -112,7 +109,6 @@ var/savefile/Banlist Banlist.cd = "/base/[ckey][computerid]" Banlist["key"] << ckey Banlist["id"] << computerid - Banlist["skipIdCheck"] << 0 Banlist["reason"] << reason Banlist["bannedby"] << bannedby Banlist["temp"] << temp @@ -149,7 +145,7 @@ var/savefile/Banlist return 1 -/proc/GetBanExp(minutes as num) +/proc/GetExp(minutes as num) UpdateTime() var/exp = minutes - CMinutes if (exp <= 0) @@ -172,7 +168,7 @@ var/savefile/Banlist for (var/A in Banlist.dir) count++ Banlist.cd = "/base/[A]" - dat += text("(U)(E)(K) Key: [Banlist["key"]] ([Banlist["temp"] ? "[GetBanExp(Banlist["minutes"]) ? GetBanExp(Banlist["minutes"]) : "Removal pending" ]" : "Permaban"])(By: [Banlist["bannedby"]])(Reason: [Banlist["reason"]])") + dat += text("(U)(E)(K) Key: [Banlist["key"]] ([Banlist["temp"] ? "[GetExp(Banlist["minutes"]) ? GetExp(Banlist["minutes"]) : "Removal pending" ]" : "Permaban"])(By: [Banlist["bannedby"]])(Reason: [Banlist["reason"]])") dat += "" dat = "
Bans: (U) = Unban , (E) = Edit Ban , (K) = Remove Computer ID - ([count] Bans)
[dat]" diff --git a/code/modules/admin/admin.dm b/code/modules/admin/admin.dm index f0d7113b7d2..945884743e6 100644 --- a/code/modules/admin/admin.dm +++ b/code/modules/admin/admin.dm @@ -282,10 +282,10 @@ var/global/BSACooldown = 0 if(!reason) return - log_admin("[key_name(usr)] edited [banned_key]'s ban. Reason: [reason] Duration: [GetBanExp(mins + CMinutes)]") + log_admin("[key_name(usr)] edited [banned_key]'s ban. Reason: [reason] Duration: [GetExp(mins + CMinutes)]") - ban_unban_log_save("[key_name(usr)] edited [banned_key]'s ban. Reason: [reason] Duration: [GetBanExp(mins + CMinutes)]") - message_admins("\blue [key_name_admin(usr)] edited [banned_key]'s ban. Reason: [reason] Duration: [GetBanExp(mins + CMinutes)]", 1) + ban_unban_log_save("[key_name(usr)] edited [banned_key]'s ban. Reason: [reason] Duration: [GetExp(mins + CMinutes)]") + message_admins("\blue [key_name_admin(usr)] edited [banned_key]'s ban. Reason: [reason] Duration: [GetExp(mins + CMinutes)]", 1) Banlist.cd = "/base/[banfolder]" Banlist["reason"] << reason Banlist["temp"] << temp diff --git a/code/modules/mob/new_player/login.dm b/code/modules/mob/new_player/login.dm index 06d5b0e5cf7..2718a1e8312 100644 --- a/code/modules/mob/new_player/login.dm +++ b/code/modules/mob/new_player/login.dm @@ -11,8 +11,6 @@ mind.key = key mind.current = src - spawn() Playmusic() // git some tunes up in heeyaa~ - var/starting_loc = pick(newplayer_start) if(!starting_loc) starting_loc = locate(1,1,1) loc = starting_loc @@ -28,7 +26,7 @@ if(watch_locations.len>0) loc = pick(watch_locations) - if(!preferences.savefile_load(src, 0)) + if(!preferences.savefile_load(src, 1)) preferences.ShowChoices(src) if(!client.changes) changes() @@ -37,11 +35,16 @@ if(!client.changes && preferences.lastchangelog!=lastchangelog) changes() preferences.lastchangelog = lastchangelog - preferences.savefile_save(src) + preferences.savefile_save(src, 1) + + if(preferences.pregame_music) + spawn() Playmusic() // git some tunes up in heeyaa~ + + if(client.has_news()) + src << "There are some unread news for you! Please make sure to read all news, as they may contain important updates about roleplay rules or canon." + + new_player_panel() - spawn(10) - if(client) - new_player_panel() //PDA Resource Initialisation =======================================================> /* Quick note: local dream daemon instances don't seem to cache images right. Might be diff --git a/code/modules/power/lighting.dm b/code/modules/power/lighting.dm index 2da8917d376..616627c64a2 100644 --- a/code/modules/power/lighting.dm +++ b/code/modules/power/lighting.dm @@ -230,7 +230,7 @@ continue M.show_message("[user.name] smashed the light!", 3, "You hear a tinkle of breaking glass", 2) if(on && (W.flags & CONDUCT)) - //if(!user.mutations & COLD_RESISTANCE) + //if(!(COLD_RESISTANCE in user.mutations)) if (prob(12)) electrocute_mob(user, get_area(src), src, 0.3) broken() @@ -245,7 +245,7 @@ var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread s.set_up(3, 1, src) s.start() - //if(!user.mutations & COLD_RESISTANCE) + //if(!(COLD_RESISTANCE in user.mutations)) if (prob(75)) electrocute_mob(user, get_area(src), src, rand(0.7,1.0)) diff --git a/code/unused/hivebot/hivebot.dm b/code/unused/hivebot/hivebot.dm index 0c11474d467..f782878bfae 100644 --- a/code/unused/hivebot/hivebot.dm +++ b/code/unused/hivebot/hivebot.dm @@ -158,7 +158,7 @@ src.now_pushing = 1 if(ismob(AM)) var/mob/tmob = AM - /*if(istype(tmob, /mob/living/carbon/human) && tmob.mutations & FAT) + /*if(istype(tmob, /mob/living/carbon/human) && (FAT in tmob.mutations)) if(prob(20)) for(var/mob/M in viewers(src, null)) if(M.client) diff --git a/code/unused/hivebot/life.dm b/code/unused/hivebot/life.dm index b87152cf328..27a7542963b 100644 --- a/code/unused/hivebot/life.dm +++ b/code/unused/hivebot/life.dm @@ -116,7 +116,7 @@ handle_regular_hud_updates() - if (src.stat == 2 || src.mutations & XRAY) + if (src.stat == 2 || XRAY in src.mutations) src.sight |= SEE_TURFS src.sight |= SEE_MOBS src.sight |= SEE_OBJS