diff --git a/code/__HELPERS/files.dm b/code/__HELPERS/files.dm index f102a96adf..6fc48ded6a 100644 --- a/code/__HELPERS/files.dm +++ b/code/__HELPERS/files.dm @@ -47,12 +47,12 @@ var/time_to_wait = GLOB.fileaccess_timer - world.time if(time_to_wait > 0) to_chat(src, "Error: file_spam_check(): Spam. Please wait [DisplayTimeText(time_to_wait)].") - return 1 + return TRUE var/delay = FTPDELAY if(holder) delay *= ADMIN_FTPDELAY_MODIFIER GLOB.fileaccess_timer = world.time + delay - return 0 + return FALSE #undef FTPDELAY #undef ADMIN_FTPDELAY_MODIFIER diff --git a/code/__HELPERS/game.dm b/code/__HELPERS/game.dm index 7dd96e00f0..e4c6b403e0 100644 --- a/code/__HELPERS/game.dm +++ b/code/__HELPERS/game.dm @@ -94,8 +94,8 @@ if(C == must_be_alone) continue if(our_area == get_area(C)) - return 0 - return 1 + return FALSE + return TRUE //We used to use linear regression to approximate the answer, but Mloc realized this was actually faster. //And lo and behold, it is, and it's more accurate to boot. @@ -263,7 +263,7 @@ while(Y1!=Y2) T=locate(X1,Y1,Z) if(IS_OPAQUE_TURF(T)) - return 0 + return FALSE Y1+=s else var/m=(32*(Y2-Y1)+(PY2-PY1))/(32*(X2-X1)+(PX2-PX1)) @@ -279,8 +279,8 @@ X1+=signX //Line exits tile horizontally T=locate(X1,Y1,Z) if(IS_OPAQUE_TURF(T)) - return 0 - return 1 + return FALSE + return TRUE #undef SIGNV @@ -289,13 +289,9 @@ var/turf/Bturf = get_turf(B) if(!Aturf || !Bturf) - return 0 + return FALSE - if(inLineOfSight(Aturf.x,Aturf.y, Bturf.x,Bturf.y,Aturf.z)) - return 1 - - else - return 0 + return inLineOfSight(Aturf.x,Aturf.y, Bturf.x,Bturf.y,Aturf.z) /proc/try_move_adjacent(atom/movable/AM, trydir) var/turf/T = get_turf(AM) diff --git a/code/__HELPERS/text.dm b/code/__HELPERS/text.dm index cf58c075c7..6b20b96962 100644 --- a/code/__HELPERS/text.dm +++ b/code/__HELPERS/text.dm @@ -257,15 +257,15 @@ /proc/text_in_list(haystack, list/needle_list, start=1, end=0) for(var/needle in needle_list) if(findtext(haystack, needle, start, end)) - return 1 - return 0 + return TRUE + return FALSE //Like above, but case sensitive /proc/text_in_list_case(haystack, list/needle_list, start=1, end=0) for(var/needle in needle_list) if(findtextEx(haystack, needle, start, end)) - return 1 - return 0 + return TRUE + return FALSE //Adds 'char' ahead of 'text' until there are 'count' characters total /proc/add_leading(text, count, char = " ") diff --git a/code/__HELPERS/unsorted.dm b/code/__HELPERS/unsorted.dm index 0b396ce67a..9b1f6ec3c8 100644 --- a/code/__HELPERS/unsorted.dm +++ b/code/__HELPERS/unsorted.dm @@ -669,28 +669,28 @@ GLOBAL_LIST_INIT(WALLITEMS_INVERSE, typecacheof(list( //Direction works sometimes if(is_type_in_typecache(O, GLOB.WALLITEMS_INVERSE)) if(O.dir == turn(dir, 180)) - return 1 + return TRUE else if(O.dir == dir) - return 1 + return TRUE //Some stuff doesn't use dir properly, so we need to check pixel instead //That's exactly what get_turf_pixel() does if(get_turf_pixel(O) == locdir) - return 1 + return TRUE if(is_type_in_typecache(O, GLOB.WALLITEMS_EXTERNAL) && check_external) if(is_type_in_typecache(O, GLOB.WALLITEMS_INVERSE)) if(O.dir == turn(dir, 180)) - return 1 + return TRUE else if(O.dir == dir) - return 1 + return TRUE //Some stuff is placed directly on the wallturf (signs) for(var/obj/O in locdir) if(is_type_in_typecache(O, GLOB.WALLITEMS) && check_external != 2) if(O.pixel_x == 0 && O.pixel_y == 0) - return 1 - return 0 + return TRUE + return FALSE /proc/format_text(text) return replacetext(replacetext(text,"\proper ",""),"\improper ","") @@ -976,13 +976,13 @@ B --><-- A /atom/proc/contains(atom/A) if(!A) - return 0 + return FALSE for(var/atom/location = A.loc, location, location = location.loc) if(location == src) - return 1 + return TRUE /proc/flick_overlay_static(O, atom/A, duration) - set waitfor = 0 + set waitfor = FALSE if(!A || !O) return A.add_overlay(O) diff --git a/code/_onclick/adjacent.dm b/code/_onclick/adjacent.dm index c9746fae98..db2f62052f 100644 --- a/code/_onclick/adjacent.dm +++ b/code/_onclick/adjacent.dm @@ -11,7 +11,7 @@ to check that the mob is not inside of something */ /atom/proc/Adjacent(atom/neighbor) // basic inheritance, unused - return 0 + return // Not a sane use of the function and (for now) indicative of an error elsewhere /area/Adjacent(atom/neighbor) @@ -57,9 +57,9 @@ if(!src.ClickCross(get_dir(src,T1), border_only = 1, target_atom = target, mover = mover)) continue // could not enter src - return 1 // we don't care about our own density + return TRUE // we don't care about our own density - return 0 + return FALSE /* Adjacency (to anything else): @@ -78,11 +78,11 @@ // This is necessary for storage items not on your person. /obj/item/Adjacent(atom/neighbor, recurse = 1) if(neighbor == loc) - return 1 + return TRUE if(isitem(loc)) if(recurse > 0) return loc.Adjacent(neighbor,recurse - 1) - return 0 + return FALSE return ..() /* @@ -99,7 +99,7 @@ if( O.flags_1&ON_BORDER_1) // windows are on border, check them first if( O.dir & target_dir || O.dir & (O.dir-1) ) // full tile windows are just diagonals mechanically - return 0 //O.dir&(O.dir-1) is false for any cardinal direction, but true for diagonal ones + return FALSE //O.dir&(O.dir-1) is false for any cardinal direction, but true for diagonal ones else if( !border_only ) // dense, not on border, cannot pass over - return 0 - return 1 + return FALSE + return TRUE diff --git a/code/_onclick/drag_drop.dm b/code/_onclick/drag_drop.dm index f70b6a86a6..d40d0e6550 100644 --- a/code/_onclick/drag_drop.dm +++ b/code/_onclick/drag_drop.dm @@ -78,13 +78,13 @@ . = automatic /atom/proc/IsAutoclickable() - . = 1 + return TRUE /obj/screen/IsAutoclickable() - . = 0 + return FALSE /obj/screen/click_catcher/IsAutoclickable() - . = 1 + return TRUE /client/MouseDrag(src_object,atom/over_object,src_location,over_location,src_control,over_control,params) var/list/L = params2list(params) diff --git a/code/_onclick/hud/action_button.dm b/code/_onclick/hud/action_button.dm index 2809f851b0..1f58877451 100644 --- a/code/_onclick/hud/action_button.dm +++ b/code/_onclick/hud/action_button.dm @@ -40,7 +40,7 @@ /obj/screen/movable/action_button/Click(location,control,params) if (!can_use(usr)) - return + return FALSE var/list/modifiers = params2list(params) if(modifiers["shift"]) @@ -68,7 +68,7 @@ desc = "Shift-click any button to reset its position, and Control-click it to lock it in place. Alt-click this button to reset all buttons to their default positions." icon = 'icons/mob/actions.dmi' icon_state = "bg_default" - var/hidden = 0 + var/hidden = FALSE var/hide_icon = 'icons/mob/actions.dmi' var/hide_state = "hide" var/show_state = "show" @@ -78,7 +78,7 @@ /obj/screen/movable/action_button/hide_toggle/Initialize() . = ..() var/static/list/icon_cache = list() - + var/cache_key = "[hide_icon][hide_state]" hide_appearance = icon_cache[cache_key] if(!hide_appearance) diff --git a/code/_onclick/hud/pai.dm b/code/_onclick/hud/pai.dm index a5f19e263f..ca4bf1a5bc 100644 --- a/code/_onclick/hud/pai.dm +++ b/code/_onclick/hud/pai.dm @@ -83,14 +83,15 @@ required_software = "host scan" /obj/screen/pai/host_monitor/Click() - if(!..()) + . = ..() + if(!.) return var/mob/living/silicon/pai/pAI = usr if(iscarbon(pAI.card.loc)) pAI.hostscan.attack(pAI.card.loc, pAI) else to_chat(src, "You are not being carried by anyone!") - return 0 + return FALSE /obj/screen/pai/crew_manifest name = "Crew Manifest" diff --git a/code/_onclick/other_mobs.dm b/code/_onclick/other_mobs.dm index eed8baa133..e777f4a177 100644 --- a/code/_onclick/other_mobs.dm +++ b/code/_onclick/other_mobs.dm @@ -81,7 +81,7 @@ */ /mob/living/carbon/RestrainedClickOn(atom/A) - return 0 + return /mob/living/carbon/human/RangedAttack(atom/A, mouseparams) . = ..() diff --git a/code/controllers/failsafe.dm b/code/controllers/failsafe.dm index 3ce770b66d..75d5cb22da 100644 --- a/code/controllers/failsafe.dm +++ b/code/controllers/failsafe.dm @@ -31,7 +31,7 @@ GLOBAL_REAL(Failsafe, /datum/controller/failsafe) Initialize() /datum/controller/failsafe/Initialize() - set waitfor = 0 + set waitfor = FALSE Failsafe.Loop() if(!QDELETED(src)) qdel(src) //when Loop() returns, we delete ourselves and let the mc recreate us diff --git a/code/controllers/globals.dm b/code/controllers/globals.dm index 707adfc83f..714f22f38d 100644 --- a/code/controllers/globals.dm +++ b/code/controllers/globals.dm @@ -22,13 +22,13 @@ GLOBAL_REAL(GLOB, /datum/controller/global_vars) /datum/controller/global_vars/Destroy(force) // This is done to prevent an exploit where admins can get around protected vars - SHOULD_CALL_PARENT(0) + SHOULD_CALL_PARENT(FALSE) return QDEL_HINT_IWILLGC /datum/controller/global_vars/stat_entry() if(!statclick) statclick = new/obj/effect/statclick/debug(null, "Initializing...", src) - + stat("Globals:", statclick.update("Edit")) /datum/controller/global_vars/vv_edit_var(var_name, var_value) diff --git a/code/controllers/master.dm b/code/controllers/master.dm index ffe29172f2..b3a94cf171 100644 --- a/code/controllers/master.dm +++ b/code/controllers/master.dm @@ -39,7 +39,7 @@ GLOBAL_REAL(Master, /datum/controller/master) = new ///Only run ticker subsystems for the next n ticks. var/skip_ticks = 0 - var/make_runtime = 0 + var/make_runtime = FALSE var/initializations_finished_with_no_players_logged_in //I wonder what this could be? diff --git a/code/controllers/subsystem.dm b/code/controllers/subsystem.dm index 16558f5870..cd029b58ed 100644 --- a/code/controllers/subsystem.dm +++ b/code/controllers/subsystem.dm @@ -23,7 +23,7 @@ var/priority = FIRE_PRIORITY_DEFAULT /// [Subsystem Flags][SS_NO_INIT] to control binary behavior. Flags must be set at compile time or before preinit finishes to take full effect. (You can also restart the mc to force them to process again) - var/flags = 0 + var/flags = NONE /// This var is set to TRUE after the subsystem has been initialized. var/initialized = FALSE diff --git a/code/controllers/subsystem/acid.dm b/code/controllers/subsystem/acid.dm index 25d080a1b1..49c4f58ffa 100644 --- a/code/controllers/subsystem/acid.dm +++ b/code/controllers/subsystem/acid.dm @@ -12,7 +12,7 @@ SUBSYSTEM_DEF(acid) return ..() -/datum/controller/subsystem/acid/fire(resumed = 0) +/datum/controller/subsystem/acid/fire(resumed = FALSE) if (!resumed) src.currentrun = processing.Copy() diff --git a/code/controllers/subsystem/air.dm b/code/controllers/subsystem/air.dm index 71b82973c6..a2744cb27b 100644 --- a/code/controllers/subsystem/air.dm +++ b/code/controllers/subsystem/air.dm @@ -70,7 +70,7 @@ SUBSYSTEM_DEF(air) return ..() -/datum/controller/subsystem/air/fire(resumed = 0) +/datum/controller/subsystem/air/fire(resumed = FALSE) var/timer = TICK_USAGE_REAL if(currentpart == SSAIR_REBUILD_PIPENETS) @@ -90,7 +90,7 @@ SUBSYSTEM_DEF(air) cost_pipenets = MC_AVERAGE(cost_pipenets, TICK_DELTA_TO_MS(TICK_USAGE_REAL - timer)) if(state != SS_RUNNING) return - resumed = 0 + resumed = FALSE currentpart = SSAIR_ATMOSMACHINERY if(currentpart == SSAIR_ATMOSMACHINERY) @@ -99,7 +99,7 @@ SUBSYSTEM_DEF(air) cost_atmos_machinery = MC_AVERAGE(cost_atmos_machinery, TICK_DELTA_TO_MS(TICK_USAGE_REAL - timer)) if(state != SS_RUNNING) return - resumed = 0 + resumed = FALSE currentpart = SSAIR_ACTIVETURFS if(currentpart == SSAIR_ACTIVETURFS) @@ -108,7 +108,7 @@ SUBSYSTEM_DEF(air) cost_turfs = MC_AVERAGE(cost_turfs, TICK_DELTA_TO_MS(TICK_USAGE_REAL - timer)) if(state != SS_RUNNING) return - resumed = 0 + resumed = FALSE currentpart = SSAIR_EXCITEDGROUPS if(currentpart == SSAIR_EXCITEDGROUPS) @@ -117,7 +117,7 @@ SUBSYSTEM_DEF(air) cost_groups = MC_AVERAGE(cost_groups, TICK_DELTA_TO_MS(TICK_USAGE_REAL - timer)) if(state != SS_RUNNING) return - resumed = 0 + resumed = FALSE currentpart = SSAIR_HIGHPRESSURE if(currentpart == SSAIR_HIGHPRESSURE) @@ -126,7 +126,7 @@ SUBSYSTEM_DEF(air) cost_highpressure = MC_AVERAGE(cost_highpressure, TICK_DELTA_TO_MS(TICK_USAGE_REAL - timer)) if(state != SS_RUNNING) return - resumed = 0 + resumed = FALSE currentpart = SSAIR_HOTSPOTS if(currentpart == SSAIR_HOTSPOTS) @@ -135,7 +135,7 @@ SUBSYSTEM_DEF(air) cost_hotspots = MC_AVERAGE(cost_hotspots, TICK_DELTA_TO_MS(TICK_USAGE_REAL - timer)) if(state != SS_RUNNING) return - resumed = 0 + resumed = FALSE currentpart = SSAIR_SUPERCONDUCTIVITY if(currentpart == SSAIR_SUPERCONDUCTIVITY) @@ -144,13 +144,13 @@ SUBSYSTEM_DEF(air) cost_superconductivity = MC_AVERAGE(cost_superconductivity, TICK_DELTA_TO_MS(TICK_USAGE_REAL - timer)) if(state != SS_RUNNING) return - resumed = 0 + resumed = FALSE currentpart = SSAIR_REBUILD_PIPENETS SStgui.update_uis(SSair) //Lightning fast debugging motherfucker -/datum/controller/subsystem/air/proc/process_pipenets(resumed = 0) +/datum/controller/subsystem/air/proc/process_pipenets(resumed = FALSE) if (!resumed) src.currentrun = networks.Copy() //cache for sanic speed (lists are references anyways) @@ -169,7 +169,7 @@ SUBSYSTEM_DEF(air) if(istype(atmos_machine, /obj/machinery/atmospherics)) pipenets_needing_rebuilt += atmos_machine -/datum/controller/subsystem/air/proc/process_atmos_machinery(resumed = 0) +/datum/controller/subsystem/air/proc/process_atmos_machinery(resumed = FALSE) var/seconds = wait * 0.1 if (!resumed) src.currentrun = atmos_machinery.Copy() @@ -184,7 +184,7 @@ SUBSYSTEM_DEF(air) return -/datum/controller/subsystem/air/proc/process_super_conductivity(resumed = 0) +/datum/controller/subsystem/air/proc/process_super_conductivity(resumed = FALSE) if (!resumed) src.currentrun = active_super_conductivity.Copy() //cache for sanic speed (lists are references anyways) @@ -196,7 +196,7 @@ SUBSYSTEM_DEF(air) if(MC_TICK_CHECK) return -/datum/controller/subsystem/air/proc/process_hotspots(resumed = 0) +/datum/controller/subsystem/air/proc/process_hotspots(resumed = FALSE) if (!resumed) src.currentrun = hotspots.Copy() //cache for sanic speed (lists are references anyways) @@ -212,7 +212,7 @@ SUBSYSTEM_DEF(air) return -/datum/controller/subsystem/air/proc/process_high_pressure_delta(resumed = 0) +/datum/controller/subsystem/air/proc/process_high_pressure_delta(resumed = FALSE) while (high_pressure_delta.len) var/turf/open/T = high_pressure_delta[high_pressure_delta.len] high_pressure_delta.len-- @@ -221,7 +221,7 @@ SUBSYSTEM_DEF(air) if(MC_TICK_CHECK) return -/datum/controller/subsystem/air/proc/process_active_turfs(resumed = 0) +/datum/controller/subsystem/air/proc/process_active_turfs(resumed = FALSE) //cache for sanic speed var/fire_count = times_fired if (!resumed) @@ -236,7 +236,7 @@ SUBSYSTEM_DEF(air) if (MC_TICK_CHECK) return -/datum/controller/subsystem/air/proc/process_excited_groups(resumed = 0) +/datum/controller/subsystem/air/proc/process_excited_groups(resumed = FALSE) if (!resumed) src.currentrun = excited_groups.Copy() //cache for sanic speed (lists are references anyways) @@ -262,7 +262,7 @@ SUBSYSTEM_DEF(air) T.remove_atom_colour(TEMPORARY_COLOUR_PRIORITY, COLOR_VIBRANT_LIME) #endif if(istype(T)) - T.excited = 0 + T.excited = FALSE if(T.excited_group) T.excited_group.garbage_collect() @@ -271,7 +271,7 @@ SUBSYSTEM_DEF(air) #ifdef VISUALIZE_ACTIVE_TURFS T.add_atom_colour(COLOR_VIBRANT_LIME, TEMPORARY_COLOUR_PRIORITY) #endif - T.excited = 1 + T.excited = TRUE active_turfs |= T if(currentpart == SSAIR_ACTIVETURFS) currentrun |= T @@ -370,7 +370,7 @@ SUBSYSTEM_DEF(air) else EG.add_turf(ET) if (!ET.excited) - ET.excited = 1 + ET.excited = TRUE . += ET /turf/open/space/resolve_active_graph() return list() diff --git a/code/controllers/subsystem/discord.dm b/code/controllers/subsystem/discord.dm index 2bd0ad695d..f53c983acf 100644 --- a/code/controllers/subsystem/discord.dm +++ b/code/controllers/subsystem/discord.dm @@ -42,14 +42,14 @@ SUBSYSTEM_DEF(discord) var/list/reverify_cache = list() var/notify_file = file("data/notify.json") /// Is TGS enabled (If not we won't fire because otherwise this is useless) - var/enabled = 0 + var/enabled = FALSE /datum/controller/subsystem/discord/Initialize(start_timeofday) // Check for if we are using TGS, otherwise return and disables firing if(world.TgsAvailable()) - enabled = 1 // Allows other procs to use this (Account linking, etc) + enabled = TRUE // Allows other procs to use this (Account linking, etc) else - can_fire = 0 // We dont want excess firing + can_fire = FALSE // We dont want excess firing return ..() // Cancel try diff --git a/code/controllers/subsystem/events.dm b/code/controllers/subsystem/events.dm index 1c74266d6a..43cce09c44 100644 --- a/code/controllers/subsystem/events.dm +++ b/code/controllers/subsystem/events.dm @@ -25,7 +25,7 @@ SUBSYSTEM_DEF(events) return ..() -/datum/controller/subsystem/events/fire(resumed = 0) +/datum/controller/subsystem/events/fire(resumed = FALSE) if(!resumed) checkEvent() //only check these if we aren't resuming a paused fire src.currentrun = running.Copy() diff --git a/code/controllers/subsystem/ipintel.dm b/code/controllers/subsystem/ipintel.dm index fca394924d..fb0ddead09 100644 --- a/code/controllers/subsystem/ipintel.dm +++ b/code/controllers/subsystem/ipintel.dm @@ -2,13 +2,13 @@ SUBSYSTEM_DEF(ipintel) name = "XKeyScore" init_order = INIT_ORDER_XKEYSCORE flags = SS_NO_FIRE - var/enabled = 0 //disable at round start to avoid checking reconnects + var/enabled = FALSE //disable at round start to avoid checking reconnects var/throttle = 0 var/errors = 0 var/list/cache = list() /datum/controller/subsystem/ipintel/Initialize(timeofday, zlevel) - enabled = 1 + enabled = TRUE . = ..() diff --git a/code/controllers/subsystem/job.dm b/code/controllers/subsystem/job.dm index 8d8874f1f7..cefc91b710 100644 --- a/code/controllers/subsystem/job.dm +++ b/code/controllers/subsystem/job.dm @@ -45,7 +45,7 @@ SUBSYSTEM_DEF(job) var/list/all_jobs = subtypesof(/datum/job) if(!all_jobs.len) to_chat(world, "Error setting up jobs, no job datums found") - return 0 + return FALSE for(var/J in all_jobs) var/datum/job/job = new J() @@ -62,7 +62,7 @@ SUBSYSTEM_DEF(job) name_occupations[job.title] = job type_occupations[J] = job - return 1 + return TRUE /datum/controller/subsystem/job/proc/GetJob(rank) @@ -189,8 +189,8 @@ SUBSYSTEM_DEF(job) continue var/mob/dead/new_player/candidate = pick(candidates) if(AssignRole(candidate, command_position)) - return 1 - return 0 + return TRUE + return FALSE //This proc is called at the start of the level loop of DivideOccupations() and will cause head jobs to be checked before any other jobs of the same level @@ -209,10 +209,10 @@ SUBSYSTEM_DEF(job) AssignRole(candidate, command_position) /datum/controller/subsystem/job/proc/FillAIPosition() - var/ai_selected = 0 + var/ai_selected = FALSE var/datum/job/job = GetJob("AI") if(!job) - return 0 + return FALSE for(var/i = job.total_positions, i > 0, i--) for(var/level in level_order) var/list/candidates = list() @@ -223,8 +223,8 @@ SUBSYSTEM_DEF(job) ai_selected++ break if(ai_selected) - return 1 - return 0 + return TRUE + return FALSE /** Proc DivideOccupations diff --git a/code/controllers/subsystem/machines.dm b/code/controllers/subsystem/machines.dm index f356009569..60bf8314db 100644 --- a/code/controllers/subsystem/machines.dm +++ b/code/controllers/subsystem/machines.dm @@ -27,7 +27,7 @@ SUBSYSTEM_DEF(machines) return ..() -/datum/controller/subsystem/machines/fire(resumed = 0) +/datum/controller/subsystem/machines/fire(resumed = FALSE) if (!resumed) for(var/datum/powernet/Powernet in powernets) Powernet.reset() //reset the power state. diff --git a/code/controllers/subsystem/mobs.dm b/code/controllers/subsystem/mobs.dm index 5a7dd30ce3..94140c0f8f 100644 --- a/code/controllers/subsystem/mobs.dm +++ b/code/controllers/subsystem/mobs.dm @@ -24,7 +24,7 @@ SUBSYSTEM_DEF(mobs) dead_players_by_zlevel.len++ dead_players_by_zlevel[dead_players_by_zlevel.len] = list() -/datum/controller/subsystem/mobs/fire(resumed = 0) +/datum/controller/subsystem/mobs/fire(resumed = FALSE) var/seconds = wait * 0.1 if (!resumed) src.currentrun = GLOB.mob_living_list.Copy() diff --git a/code/controllers/subsystem/pai.dm b/code/controllers/subsystem/pai.dm index 342392ec67..c563e2a745 100644 --- a/code/controllers/subsystem/pai.dm +++ b/code/controllers/subsystem/pai.dm @@ -68,7 +68,7 @@ SUBSYSTEM_DEF(pai) if("submit") if(candidate) - candidate.ready = 1 + candidate.ready = TRUE for(var/obj/item/paicard/p in pai_card_list) if(!p.pai) p.alertUpdate() @@ -195,4 +195,4 @@ SUBSYSTEM_DEF(pai) var/description var/role var/comments - var/ready = 0 + var/ready = FALSE diff --git a/code/controllers/subsystem/processing/processing.dm b/code/controllers/subsystem/processing/processing.dm index 454709e1d5..f099c3afb2 100644 --- a/code/controllers/subsystem/processing/processing.dm +++ b/code/controllers/subsystem/processing/processing.dm @@ -14,7 +14,7 @@ SUBSYSTEM_DEF(processing) msg = "[stat_tag]:[length(processing)]" return ..() -/datum/controller/subsystem/processing/fire(resumed = 0) +/datum/controller/subsystem/processing/fire(resumed = FALSE) if (!resumed) currentrun = processing.Copy() //cache for sanic speed (lists are references anyways) @@ -34,5 +34,5 @@ SUBSYSTEM_DEF(processing) ///This proc is called on a datum if it is being processed in a subsystem. If you override this do not call parent, as it will return PROCESS_KILL. This is done to prevent objects that dont override process() from staying in the processing list /datum/proc/process() - set waitfor = 0 + set waitfor = FALSE return PROCESS_KILL diff --git a/code/controllers/subsystem/shuttle.dm b/code/controllers/subsystem/shuttle.dm index f989e5ff35..6281c98d19 100644 --- a/code/controllers/subsystem/shuttle.dm +++ b/code/controllers/subsystem/shuttle.dm @@ -303,7 +303,7 @@ SUBSYSTEM_DEF(shuttle) if (!SSticker.IsRoundInProgress()) return - var/callShuttle = 1 + var/callShuttle = TRUE for(var/thing in GLOB.shuttle_caller_list) if(isAI(thing)) @@ -319,7 +319,7 @@ SUBSYSTEM_DEF(shuttle) var/turf/T = get_turf(thing) if(T && is_station_level(T.z)) - callShuttle = 0 + callShuttle = FALSE break if(callShuttle) diff --git a/code/controllers/subsystem/spacedrift.dm b/code/controllers/subsystem/spacedrift.dm index 0e9aa01753..c1c7e2a872 100644 --- a/code/controllers/subsystem/spacedrift.dm +++ b/code/controllers/subsystem/spacedrift.dm @@ -13,7 +13,7 @@ SUBSYSTEM_DEF(spacedrift) return ..() -/datum/controller/subsystem/spacedrift/fire(resumed = 0) +/datum/controller/subsystem/spacedrift/fire(resumed = FALSE) if (!resumed) src.currentrun = processing.Copy() diff --git a/code/controllers/subsystem/tgui.dm b/code/controllers/subsystem/tgui.dm index 2fe7c64c72..511ab623da 100644 --- a/code/controllers/subsystem/tgui.dm +++ b/code/controllers/subsystem/tgui.dm @@ -33,7 +33,7 @@ SUBSYSTEM_DEF(tgui) msg = "P:[length(open_uis)]" return ..() -/datum/controller/subsystem/tgui/fire(resumed = 0) +/datum/controller/subsystem/tgui/fire(resumed = FALSE) if(!resumed) src.current_run = open_uis.Copy() // Cache for sanic speed (lists are references anyways) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index 98578c9134..02aff95593 100755 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -14,7 +14,7 @@ SUBSYSTEM_DEF(ticker) var/start_immediately = FALSE var/setup_done = FALSE //All game setup done including mode post setup and - var/hide_mode = 0 + var/hide_mode = FALSE var/datum/game_mode/mode = null var/login_music //music played in pregame lobby @@ -23,7 +23,7 @@ SUBSYSTEM_DEF(ticker) var/list/datum/mind/minds = list() //The characters in the game. Used for objective tracking. - var/delay_end = 0 //if set true, the round will not restart on it's own + var/delay_end = FALSE //if set true, the round will not restart on it's own var/admin_delay_notice = "" //a message to display to anyone who tries to restart the world after a delay var/ready_for_reboot = FALSE //all roundend preparation done with, all that's left is reboot @@ -32,7 +32,7 @@ SUBSYSTEM_DEF(ticker) ///Boolean to see if the game needs to set up a triumvirate ai (see tripAI.dm) var/triai = FALSE - var/tipped = 0 //Did we broadcast the tip of the day yet? + var/tipped = FALSE //Did we broadcast the tip of the day yet? var/selected_tip // What will be the tip of the day? var/timeLeft //pregame timer @@ -227,7 +227,7 @@ SUBSYSTEM_DEF(ticker) if(!mode) if(!runnable_modes.len) to_chat(world, "Unable to choose playable game mode. Reverting to pre-game lobby.") - return 0 + return FALSE mode = pickweight(runnable_modes) if(!mode) //too few roundtypes all run too recently mode = pick(runnable_modes) @@ -239,7 +239,7 @@ SUBSYSTEM_DEF(ticker) qdel(mode) mode = null SSjob.ResetOccupations() - return 0 + return FALSE CHECK_TICK //Configure mode and assign player to special mode stuff @@ -255,7 +255,7 @@ SUBSYSTEM_DEF(ticker) QDEL_NULL(mode) to_chat(world, "Error setting up [GLOB.master_mode]. Reverting to pre-game lobby.") SSjob.ResetOccupations() - return 0 + return FALSE else message_admins("DEBUG: Bypassing prestart checks...") diff --git a/code/datums/action.dm b/code/datums/action.dm index 5952340136..8225d1e7f7 100644 --- a/code/datums/action.dm +++ b/code/datums/action.dm @@ -168,12 +168,13 @@ return ..() /datum/action/item_action/Trigger() - if(!..()) - return 0 + . = ..() + if(!.) + return FALSE if(target) var/obj/item/I = target I.ui_action_click(owner, src) - return 1 + return TRUE /datum/action/item_action/ApplyIcon(obj/screen/movable/action_button/current_button, force) if(button_icon && button_icon_state) @@ -315,7 +316,7 @@ if(istype(target, /obj/item/hierophant_club)) var/obj/item/hierophant_club/H = target if(H.teleporting) - return 0 + return FALSE return ..() /datum/action/item_action/toggle_helmet_flashlight @@ -384,7 +385,7 @@ /datum/action/item_action/jetpack_stabilization/IsAvailable() var/obj/item/tank/jetpack/J = target if(!istype(J) || !J.on) - return 0 + return FALSE return ..() /datum/action/item_action/hands_free @@ -439,7 +440,7 @@ /datum/action/item_action/organ_action/IsAvailable() var/obj/item/organ/I = target if(!I.owner) - return 0 + return FALSE return ..() /datum/action/item_action/organ_action/toggle/New(Target) @@ -586,12 +587,12 @@ /datum/action/innate/Trigger() if(!..()) - return 0 + return FALSE if(!active) Activate() else Deactivate() - return 1 + return TRUE /datum/action/innate/proc/Activate() return diff --git a/code/datums/browser.dm b/code/datums/browser.dm index 0d44759a6f..96ac651fda 100644 --- a/code/datums/browser.dm +++ b/code/datums/browser.dm @@ -198,7 +198,7 @@ opentime = 0 /datum/browser/modal/open(use_onclose) - set waitfor = 0 + set waitfor = FALSE opentime = world.time if (stealfocus) diff --git a/code/datums/components/honkspam.dm b/code/datums/components/honkspam.dm index 73b5e3335a..7f2069d18d 100644 --- a/code/datums/components/honkspam.dm +++ b/code/datums/components/honkspam.dm @@ -2,9 +2,10 @@ // used ONLY on april's fool. I moved it to a component so it could be // used in other places +//This is copypasted on other obj so if you are readin this go refactor it, start on objs with var/limiting_spam /datum/component/honkspam dupe_mode = COMPONENT_DUPE_UNIQUE - var/spam_flag = FALSE + var/limiting_spam = FALSE /datum/component/honkspam/Initialize() if(!isitem(parent)) @@ -12,11 +13,11 @@ RegisterSignal(parent, COMSIG_ITEM_ATTACK_SELF, .proc/interact) /datum/component/honkspam/proc/reset_spamflag() - spam_flag = FALSE + limiting_spam = FALSE /datum/component/honkspam/proc/interact(mob/user) - if(!spam_flag) - spam_flag = TRUE + if(!limiting_spam) + limiting_spam = TRUE var/obj/item/parent_item = parent playsound(parent_item.loc, 'sound/items/bikehorn.ogg', 50, TRUE) addtimer(CALLBACK(src, .proc/reset_spamflag), 2 SECONDS) diff --git a/code/datums/components/mood.dm b/code/datums/components/mood.dm index 65da13931e..6ef4d2e31c 100644 --- a/code/datums/components/mood.dm +++ b/code/datums/components/mood.dm @@ -257,7 +257,7 @@ else if(the_event.timeout) addtimer(CALLBACK(src, .proc/clear_event, null, category), the_event.timeout, TIMER_UNIQUE|TIMER_OVERRIDE) - return 0 //Don't have to update the event. + return //Don't have to update the event. var/list/params = args.Copy(4) params.Insert(1, parent) the_event = new type(arglist(params)) @@ -276,7 +276,7 @@ category = REF(category) var/datum/mood_event/event = mood_events[category] if(!event) - return 0 + return mood_events -= category qdel(event) diff --git a/code/datums/components/spawner.dm b/code/datums/components/spawner.dm index 8600a59de0..af7bd20079 100644 --- a/code/datums/components/spawner.dm +++ b/code/datums/components/spawner.dm @@ -40,9 +40,9 @@ /datum/component/spawner/proc/try_spawn_mob() var/atom/P = parent if(spawned_mobs.len >= max_mobs) - return 0 + return if(spawn_delay > world.time) - return 0 + return spawn_delay = world.time + spawn_time var/chosen_mob_type = pick(mob_types) var/mob/living/simple_animal/L = new chosen_mob_type(P.loc) diff --git a/code/datums/components/summoning.dm b/code/datums/components/summoning.dm index 9109e26b30..f23229c9d8 100644 --- a/code/datums/components/summoning.dm +++ b/code/datums/components/summoning.dm @@ -52,11 +52,11 @@ /datum/component/summoning/proc/do_spawn_mob(atom/spawn_location, summoner) if(spawned_mobs.len >= max_mobs) - return 0 + return if(last_spawned_time > world.time) - return 0 + return if(!prob(spawn_chance)) - return 0 + return last_spawned_time = world.time + spawn_delay var/chosen_mob_type = pick(mob_types) var/mob/living/simple_animal/L = new chosen_mob_type(spawn_location) diff --git a/code/datums/datum.dm b/code/datums/datum.dm index 1061bc3e77..2c94fcaa76 100644 --- a/code/datums/datum.dm +++ b/code/datums/datum.dm @@ -92,7 +92,7 @@ * Returns [QDEL_HINT_QUEUE] */ /datum/proc/Destroy(force=FALSE, ...) - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) tag = null datum_flags &= ~DF_USE_TAG //In case something tries to REF us weak_reference = null //ensure prompt GCing of weakref. diff --git a/code/datums/diseases/advance/advance.dm b/code/datums/diseases/advance/advance.dm index e703176154..8e9fc5755e 100644 --- a/code/datums/diseases/advance/advance.dm +++ b/code/datums/diseases/advance/advance.dm @@ -136,11 +136,11 @@ /datum/disease/advance/IsSame(datum/disease/advance/D) if(!(istype(D, /datum/disease/advance))) - return 0 + return FALSE if(GetDiseaseID() != D.GetDiseaseID()) - return 0 - return 1 + return FALSE + return TRUE // Returns the advance disease with a different reference memory. /datum/disease/advance/Copy() @@ -178,8 +178,8 @@ /datum/disease/advance/proc/HasSymptom(datum/symptom/S) for(var/datum/symptom/symp in symptoms) if(symp.type == S.type) - return 1 - return 0 + return TRUE + return FALSE // Will generate new unique symptoms, use this if there are none. Returns a list of symptoms that were generated. /datum/disease/advance/proc/GenerateSymptoms(level_min, level_max, amount_get = 0) diff --git a/code/datums/diseases/transformation.dm b/code/datums/diseases/transformation.dm index 5a62dacbbc..b573233c83 100644 --- a/code/datums/diseases/transformation.dm +++ b/code/datums/diseases/transformation.dm @@ -110,7 +110,7 @@ desc = "Monkeys with this disease will bite humans, causing humans to mutate into a monkey." severity = DISEASE_SEVERITY_BIOHAZARD stage_prob = 4 - visibility_flags = 0 + visibility_flags = NONE agent = "Kongey Vibrion M-909" new_form = /mob/living/carbon/monkey bantype = ROLE_MONKEY @@ -172,7 +172,7 @@ agent = "R2D2 Nanomachines" desc = "This disease, actually acute nanomachine infection, converts the victim into a cyborg." severity = DISEASE_SEVERITY_BIOHAZARD - visibility_flags = 0 + visibility_flags = NONE stage1 = list() stage2 = list("Your joints feel stiff.", "Beep...boop..") stage3 = list("Your joints feel very stiff.", "Your skin feels loose.", "You can feel something move...inside.") @@ -209,7 +209,7 @@ agent = "Rip-LEY Alien Microbes" desc = "This disease changes the victim into a xenomorph." severity = DISEASE_SEVERITY_BIOHAZARD - visibility_flags = 0 + visibility_flags = NONE stage1 = list() stage2 = list("Your throat feels scratchy.", "Kill...") stage3 = list("Your throat feels very scratchy.", "Your skin feels tight.", "You can feel something move...inside.") @@ -242,7 +242,7 @@ agent = "Advanced Mutation Toxin" desc = "This highly concentrated extract converts anything into more of itself." severity = DISEASE_SEVERITY_BIOHAZARD - visibility_flags = 0 + visibility_flags = NONE stage1 = list("You don't feel very well.") stage2 = list("Your skin feels a little slimy.") stage3 = list("Your appendages are melting away.", "Your limbs begin to lose their shape.") @@ -275,7 +275,7 @@ agent = "Fell Doge Majicks" desc = "This disease transforms the victim into a corgi." severity = DISEASE_SEVERITY_BIOHAZARD - visibility_flags = 0 + visibility_flags = NONE stage1 = list("BARK.") stage2 = list("You feel the need to wear silly hats.") stage3 = list("Must... eat... chocolate....", "YAP") @@ -305,7 +305,7 @@ desc = "A 'gift' from somewhere terrible." stage_prob = 20 severity = DISEASE_SEVERITY_BIOHAZARD - visibility_flags = 0 + visibility_flags = NONE stage1 = list("Your stomach rumbles.") stage2 = list("Your skin feels saggy.") stage3 = list("Your appendages are melting away.", "Your limbs begin to lose their shape.") @@ -324,7 +324,7 @@ agent = "Tranquility" desc = "Consuming the flesh of a Gondola comes at a terrible price." severity = DISEASE_SEVERITY_BIOHAZARD - visibility_flags = 0 + visibility_flags = NONE stage1 = list("You seem a little lighter in your step.") stage2 = list("You catch yourself smiling for no reason.") stage3 = list("A cruel sense of calm overcomes you.", "You can't feel your arms!", "You let go of the urge to hurt clowns.") diff --git a/code/datums/dna.dm b/code/datums/dna.dm index 82833241d5..e6aaf50246 100644 --- a/code/datums/dna.dm +++ b/code/datums/dna.dm @@ -221,8 +221,8 @@ /datum/dna/proc/is_same_as(datum/dna/D) if(uni_identity == D.uni_identity && mutation_index == D.mutation_index && real_name == D.real_name) if(species.type == D.species.type && features == D.features && blood_type == D.blood_type) - return 1 - return 0 + return TRUE + return FALSE /datum/dna/proc/update_instability(alert=TRUE) stability = 100 @@ -438,7 +438,7 @@ /datum/dna/proc/check_block_string(mutation) if((LAZYLEN(mutation_index) > DNA_MUTATION_BLOCKS) || !(mutation in mutation_index)) - return 0 + return FALSE return is_gene_active(mutation) /datum/dna/proc/is_gene_active(mutation) @@ -549,7 +549,7 @@ /proc/scramble_dna(mob/living/carbon/M, ui=FALSE, se=FALSE, probability) if(!M.has_dna()) - return 0 + return FALSE if(se) for(var/i=1, i<=DNA_MUTATION_BLOCKS, i++) if(prob(probability)) @@ -560,7 +560,7 @@ if(prob(probability)) M.dna.uni_identity = setblock(M.dna.uni_identity, i, random_string(DNA_BLOCK_SIZE, GLOB.hex_characters)) M.updateappearance(mutations_overlay_update=1) - return 1 + return TRUE //value in range 1 to values. values must be greater than 0 //all arguments assumed to be positive integers diff --git a/code/datums/elements/_element.dm b/code/datums/elements/_element.dm index 015267b596..004c11071d 100644 --- a/code/datums/elements/_element.dm +++ b/code/datums/elements/_element.dm @@ -18,7 +18,7 @@ /// Activates the functionality defined by the element on the given target datum /datum/element/proc/Attach(datum/target) - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) if(type == /datum/element) return ELEMENT_INCOMPATIBLE SEND_SIGNAL(target, COMSIG_ELEMENT_ATTACH, src) @@ -30,7 +30,7 @@ SIGNAL_HANDLER SEND_SIGNAL(source, COMSIG_ELEMENT_DETACH, src) - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) UnregisterSignal(source, COMSIG_PARENT_QDELETING) /datum/element/Destroy(force) diff --git a/code/datums/martial/boxing.dm b/code/datums/martial/boxing.dm index d351a1f8ae..2760c333ec 100644 --- a/code/datums/martial/boxing.dm +++ b/code/datums/martial/boxing.dm @@ -23,7 +23,7 @@ "You avoid [A]'s [atk_verb]!", "You hear a swoosh!", COMBAT_MESSAGE_RANGE, A) to_chat(A, "Your [atk_verb] misses [D]!") log_combat(A, D, "attempted to hit", atk_verb) - return 0 + return FALSE var/obj/item/bodypart/affecting = D.get_bodypart(ran_zone(A.zone_selected)) @@ -46,7 +46,7 @@ D.apply_effect(200,EFFECT_KNOCKDOWN,armor_block) D.SetSleeping(100) log_combat(A, D, "knocked out (boxing) ") - return 1 + return TRUE /obj/item/clothing/gloves/boxing var/datum/martial_art/boxing/style = new diff --git a/code/datums/martial/krav_maga.dm b/code/datums/martial/krav_maga.dm index 3e989d30b6..7406723cb9 100644 --- a/code/datums/martial/krav_maga.dm +++ b/code/datums/martial/krav_maga.dm @@ -75,20 +75,20 @@ if("neck_chop") streak = "" neck_chop(A,D) - return 1 + return TRUE if("leg_sweep") streak = "" leg_sweep(A,D) - return 1 + return TRUE if("quick_choke")//is actually lung punch streak = "" quick_choke(A,D) - return 1 - return 0 + return TRUE + return FALSE /datum/martial_art/krav_maga/proc/leg_sweep(mob/living/carbon/human/A, mob/living/carbon/human/D) if(D.stat || D.IsParalyzed()) - return 0 + return FALSE var/obj/item/bodypart/affecting = D.get_bodypart(BODY_ZONE_CHEST) var/armor_block = D.run_armor_check(affecting, MELEE) D.visible_message("[A] leg sweeps [D]!", \ @@ -98,7 +98,7 @@ D.apply_damage(rand(20,30), STAMINA, affecting, armor_block) D.Knockdown(60) log_combat(A, D, "leg sweeped") - return 1 + return TRUE /datum/martial_art/krav_maga/proc/quick_choke(mob/living/carbon/human/A, mob/living/carbon/human/D)//is actually lung punch D.visible_message("[A] pounds [D] on the chest!", \ @@ -109,7 +109,7 @@ D.losebreath = clamp(D.losebreath + 5, 0, 10) D.adjustOxyLoss(10) log_combat(A, D, "quickchoked") - return 1 + return TRUE /datum/martial_art/krav_maga/proc/neck_chop(mob/living/carbon/human/A, mob/living/carbon/human/D) D.visible_message("[A] karate chops [D]'s neck!", \ @@ -120,17 +120,17 @@ if(D.silent <= 10) D.silent = clamp(D.silent + 10, 0, 10) log_combat(A, D, "neck chopped") - return 1 + return TRUE /datum/martial_art/krav_maga/grab_act(mob/living/carbon/human/A, mob/living/carbon/human/D) if(check_streak(A,D)) - return 1 + return TRUE log_combat(A, D, "grabbed (Krav Maga)") ..() /datum/martial_art/krav_maga/harm_act(mob/living/carbon/human/A, mob/living/carbon/human/D) if(check_streak(A,D)) - return 1 + return TRUE log_combat(A, D, "punched") var/obj/item/bodypart/affecting = D.get_bodypart(ran_zone(A.zone_selected)) var/armor_block = D.run_armor_check(affecting, MELEE) @@ -150,11 +150,11 @@ "You're [picked_hit_type]ed by [A]!", "You hear a sickening sound of flesh hitting flesh!", COMBAT_MESSAGE_RANGE, A) to_chat(A, "You [picked_hit_type] [D]!") log_combat(A, D, "[picked_hit_type] with [name]") - return 1 + return TRUE /datum/martial_art/krav_maga/disarm_act(mob/living/carbon/human/A, mob/living/carbon/human/D) if(check_streak(A,D)) - return 1 + return TRUE var/obj/item/bodypart/affecting = D.get_bodypart(ran_zone(A.zone_selected)) var/armor_block = D.run_armor_check(affecting, MELEE) if((D.mobility_flags & MOBILITY_STAND)) @@ -176,7 +176,7 @@ if(prob(D.getStaminaLoss())) D.visible_message("[D] sputters and recoils in pain!", "You recoil in pain as you are jabbed in a nerve!") D.drop_all_held_items() - return 1 + return TRUE //Krav Maga Gloves diff --git a/code/datums/martial/wrestling.dm b/code/datums/martial/wrestling.dm index 8342897b9f..04c7bc91ae 100644 --- a/code/datums/martial/wrestling.dm +++ b/code/datums/martial/wrestling.dm @@ -22,24 +22,24 @@ if("drop") streak = "" drop(A,D) - return 1 + return TRUE if("strike") streak = "" strike(A,D) - return 1 + return TRUE if("kick") streak = "" kick(A,D) - return 1 + return TRUE if("throw") streak = "" throw_wrassle(A,D) - return 1 + return TRUE if("slam") streak = "" slam(A,D) - return 1 - return 0 + return TRUE + return FALSE /datum/action/slam name = "Slam (Cinch) - Slam a grappled opponent into the floor." @@ -158,11 +158,11 @@ if (get_dist(A, D) > 1) to_chat(A, "[D] is too far away!") - return 0 + return if (!isturf(A.loc) || !isturf(D.loc)) to_chat(A, "You can't throw [D] from here!") - return 0 + return A.setDir(turn(A.dir, 90)) var/turf/T = get_step(A, A.dir) @@ -171,7 +171,7 @@ D.forceMove(T) D.setDir(get_dir(D, A)) else - return 0 + return sleep(delay) @@ -180,11 +180,11 @@ if (get_dist(A, D) > 1) to_chat(A, "[D] is too far away!") - return 0 + return if (!isturf(A.loc) || !isturf(D.loc)) to_chat(A, "You can't throw [D] from here!") - return 0 + return D.forceMove(A.loc) // Maybe this will help with the wallthrowing bug. @@ -198,7 +198,7 @@ D.emote("scream") D.throw_at(T, 10, 4, A, TRUE, TRUE, callback = CALLBACK(D, /mob/living/carbon/human.proc/Paralyze, 20)) log_combat(A, D, "has thrown with wrestling") - return 0 + return /datum/martial_art/wrestling/proc/FlipAnimation(mob/living/carbon/human/D) set waitfor = FALSE @@ -247,7 +247,7 @@ A.pixel_y = 0 D.pixel_x = 0 D.pixel_y = 0 - return 0 + return if (!isturf(A.loc) || !isturf(D.loc)) to_chat(A, "You can't slam [D] here!") @@ -255,7 +255,7 @@ A.pixel_y = 0 D.pixel_x = 0 D.pixel_y = 0 - return 0 + return else if (A) A.pixel_x = 0 @@ -263,7 +263,7 @@ if (D) D.pixel_x = 0 D.pixel_y = 0 - return 0 + return sleep(1) @@ -275,11 +275,11 @@ if (get_dist(A, D) > 1) to_chat(A, "[D] is too far away!") - return 0 + return if (!isturf(A.loc) || !isturf(D.loc)) to_chat(A, "You can't slam [D] here!") - return 0 + return D.forceMove(A.loc) @@ -318,7 +318,7 @@ log_combat(A, D, "body-slammed") - return 0 + return /datum/martial_art/wrestling/proc/CheckStrikeTurf(mob/living/carbon/human/A, turf/T) if (A && (T && isturf(T) && get_dist(A, T) <= 1)) @@ -401,12 +401,12 @@ A.adjustBruteLoss(rand(10,20)) A.Paralyze(60) to_chat(A, "[D] is too far away!") - return 0 + return if (!isturf(A.loc) || !isturf(D.loc)) A.pixel_y = 0 to_chat(A, "You can't drop onto [D] from here!") - return 0 + return if(A) animate(A, transform = matrix(90, MATRIX_ROTATE), time = 1, loop = 0) diff --git a/code/datums/mind.dm b/code/datums/mind.dm index a6bc5a3a3f..562882b03d 100644 --- a/code/datums/mind.dm +++ b/code/datums/mind.dm @@ -34,7 +34,7 @@ var/name //replaces mob/var/original_name var/ghostname //replaces name for observers name if set var/mob/living/current - var/active = 0 + var/active = FALSE var/memory @@ -779,7 +779,7 @@ /mob/proc/sync_mind() mind_initialize() //updates the mind (or creates and initializes one if one doesn't exist) - mind.active = 1 //indicates that the mind is currently synced with a client + mind.active = TRUE //indicates that the mind is currently synced with a client /datum/mind/proc/has_martialart(string) if(martial_art && martial_art.id == string) diff --git a/code/game/area/areas.dm b/code/game/area/areas.dm index e02f51946a..91da87f1a2 100644 --- a/code/game/area/areas.dm +++ b/code/game/area/areas.dm @@ -451,9 +451,9 @@ GLOBAL_LIST_EMPTY(teleportlocs) /area/proc/powered(chan) // return true if the area has power to given channel if(!requires_power) - return 1 + return TRUE if(always_unpowered) - return 0 + return FALSE switch(chan) if(AREA_USAGE_EQUIP) return power_equip @@ -462,13 +462,13 @@ GLOBAL_LIST_EMPTY(teleportlocs) if(AREA_USAGE_ENVIRON) return power_environ - return 0 + return FALSE /** - * Space is not powered ever, so this returns 0 + * Space is not powered ever, so this returns false */ /area/space/powered(chan) //Nope.avi - return 0 + return FALSE /** * Called when the area power status changes diff --git a/code/game/area/areas/holodeck.dm b/code/game/area/areas/holodeck.dm index 0fec5debd2..35f5314deb 100644 --- a/code/game/area/areas/holodeck.dm +++ b/code/game/area/areas/holodeck.dm @@ -6,7 +6,7 @@ area_flags = VALID_TERRITORY | UNIQUE_AREA | NOTELEPORT | HIDDEN_AREA var/obj/machinery/computer/holodeck/linked - var/restricted = 0 // if true, program goes on emag list + var/restricted = FALSE // if true, program goes on emag list /* Power tracking: Use the holodeck computer's power grid @@ -33,7 +33,7 @@ /area/holodeck/use_power(amount, chan) if(!linked) - return 0 + return FALSE var/area/A = get_area(linked) ASSERT(!istype(A, /area/holodeck)) return ..() @@ -102,28 +102,28 @@ /area/holodeck/rec_center/medical name = "Holodeck - Emergency Medical" - restricted = 1 + restricted = TRUE /area/holodeck/rec_center/thunderdome1218 name = "Holodeck - 1218 AD" - restricted = 1 + restricted = TRUE /area/holodeck/rec_center/burn name = "Holodeck - Atmospheric Burn Test" - restricted = 1 + restricted = TRUE /area/holodeck/rec_center/wildlife name = "Holodeck - Wildlife Simulation" - restricted = 1 + restricted = TRUE /area/holodeck/rec_center/bunker name = "Holodeck - Holdout Bunker" - restricted = 1 + restricted = TRUE /area/holodeck/rec_center/anthophila name = "Holodeck - Anthophila" - restricted = 1 + restricted = TRUE /area/holodeck/rec_center/refuel name = "Holodeck - Refueling Station" - restricted = 1 + restricted = TRUE diff --git a/code/game/atoms.dm b/code/game/atoms.dm index 40fb1eef94..354f9b6d09 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -643,7 +643,7 @@ /// Updates the overlays of the atom /atom/proc/update_overlays() - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) . = list() SEND_SIGNAL(src, COMSIG_ATOM_UPDATE_OVERLAYS, .) @@ -1482,10 +1482,10 @@ return max_grav if(isspaceturf(T)) // Turf never has gravity - return FALSE + return 0 if(istype(T, /turf/open/transparent/openspace)) //openspace in a space area doesn't get gravity if(istype(get_area(T), /area/space)) - return FALSE + return 0 var/area/A = get_area(T) if(A.has_gravity) // Areas which always has gravity diff --git a/code/game/atoms_movable.dm b/code/game/atoms_movable.dm index 5d6187ecd6..3a93d6c5c2 100644 --- a/code/game/atoms_movable.dm +++ b/code/game/atoms_movable.dm @@ -605,38 +605,38 @@ */ /atom/movable/proc/Process_Spacemove(movement_dir = 0) if(has_gravity(src)) - return 1 + return TRUE if(pulledby) - return 1 + return TRUE if(throwing) - return 1 + return TRUE if(!isturf(loc)) - return 1 + return TRUE if(locate(/obj/structure/lattice) in range(1, get_turf(src))) //Not realistic but makes pushing things in space easier - return 1 + return TRUE - return 0 + return FALSE /// Only moves the object if it's under no gravity /atom/movable/proc/newtonian_move(direction) if(!loc || Process_Spacemove(0)) inertia_dir = 0 - return 0 + return FALSE inertia_dir = direction if(!direction) - return 1 + return TRUE inertia_last_loc = loc SSspacedrift.processing[src] = src - return 1 + return TRUE /atom/movable/proc/throw_impact(atom/hit_atom, datum/thrownthing/throwingdatum) - set waitfor = 0 + set waitfor = FALSE var/hitpush = TRUE var/impact_signal = SEND_SIGNAL(src, COMSIG_MOVABLE_IMPACT, hit_atom, throwingdatum) if(impact_signal & COMPONENT_MOVABLE_IMPACT_FLIP_HITPUSH) diff --git a/code/game/communications.dm b/code/game/communications.dm index 9d7daeeec7..615a829e4c 100644 --- a/code/game/communications.dm +++ b/code/game/communications.dm @@ -150,7 +150,7 @@ GLOBAL_LIST_INIT(reverseradiochannels, list( if(range) start_point = get_turf(source) if(!start_point) - return 0 + return //Send the data for(var/current_filter in filter_list) diff --git a/code/game/data_huds.dm b/code/game/data_huds.dm index 0044d18f10..8b582dd647 100644 --- a/code/game/data_huds.dm +++ b/code/game/data_huds.dm @@ -24,13 +24,13 @@ /datum/atom_hud/data/human/medical/basic/proc/check_sensors(mob/living/carbon/human/H) if(!istype(H)) - return 0 + return FALSE var/obj/item/clothing/under/U = H.w_uniform if(!istype(U)) - return 0 + return FALSE if(U.sensor_mode <= SENSOR_VITALS) - return 0 - return 1 + return FALSE + return TRUE /datum/atom_hud/data/human/medical/basic/add_to_single_hud(mob/M, mob/living/carbon/H) if(check_sensors(H)) diff --git a/code/game/gamemodes/changeling/traitor_chan.dm b/code/game/gamemodes/changeling/traitor_chan.dm index e722505c2d..80cdc0105c 100644 --- a/code/game/gamemodes/changeling/traitor_chan.dm +++ b/code/game/gamemodes/changeling/traitor_chan.dm @@ -17,12 +17,13 @@ var/const/changeling_amount = 1 //hard limit on changelings if scaling is turned off /datum/game_mode/traitor/changeling/can_start() - if(!..()) - return 0 + . = ..() + if(!.) + return possible_changelings = get_players_for_role(ROLE_CHANGELING) if(possible_changelings.len < required_enemies) - return 0 - return 1 + return FALSE + return TRUE /datum/game_mode/traitor/changeling/pre_setup() if(CONFIG_GET(flag/protect_roles_from_antagonist)) diff --git a/code/game/gamemodes/cult/cult.dm b/code/game/gamemodes/cult/cult.dm index 519f4646fb..d637632801 100644 --- a/code/game/gamemodes/cult/cult.dm +++ b/code/game/gamemodes/cult/cult.dm @@ -48,8 +48,6 @@ Cultists: Carry out Nar'Sie's will.\n\ Crew: Prevent the cult from expanding and drive it out." - var/finished = 0 - var/acolytes_needed = 10 //for the survive objective var/acolytes_survived = 0 @@ -145,9 +143,9 @@ if(cult_mind.current.onCentCom() || cult_mind.current.onSyndieBase()) acolytes_survived++ if(acolytes_survived>=acolytes_needed) - return 0 + return FALSE else - return 1 + return TRUE /datum/game_mode/cult/generate_report() diff --git a/code/game/gamemodes/devil/devil_agent/devil_agent.dm b/code/game/gamemodes/devil/devil_agent/devil_agent.dm index c8fb62faba..e3ccca09ac 100644 --- a/code/game/gamemodes/devil/devil_agent/devil_agent.dm +++ b/code/game/gamemodes/devil/devil_agent/devil_agent.dm @@ -40,5 +40,5 @@ outsellobjective.target = target_mind outsellobjective.update_explanation_text() D.objectives += outsellobjective - return 1 - return 0 + return TRUE + return FALSE diff --git a/code/game/gamemodes/dynamic/dynamic_rulesets.dm b/code/game/gamemodes/dynamic/dynamic_rulesets.dm index b47c0a4fd5..406b515e76 100644 --- a/code/game/gamemodes/dynamic/dynamic_rulesets.dm +++ b/code/game/gamemodes/dynamic/dynamic_rulesets.dm @@ -50,7 +50,7 @@ /// A flag that determines how the ruleset is handled /// HIGHLANDER_RULESET are rulesets can end the round. /// TRAITOR_RULESET and MINOR_RULESET can't end the round and have no difference right now. - var/flags = 0 + var/flags = NONE /// Pop range per requirement. If zero defaults to mode's pop_per_requirement. var/pop_per_requirement = 0 /// Requirements are the threat level requirements per pop range. diff --git a/code/game/gamemodes/dynamic/dynamic_rulesets_roundstart.dm b/code/game/gamemodes/dynamic/dynamic_rulesets_roundstart.dm index 3d7e95b986..b285ad0076 100644 --- a/code/game/gamemodes/dynamic/dynamic_rulesets_roundstart.dm +++ b/code/game/gamemodes/dynamic/dynamic_rulesets_roundstart.dm @@ -714,7 +714,7 @@ cost = 0 requirements = list(101,101,101,101,101,101,101,101,101,101) var/meteordelay = 2000 - var/nometeors = 0 + var/nometeors = FALSE var/rampupdelta = 5 /datum/dynamic_ruleset/roundstart/meteor/rule_process() diff --git a/code/game/gamemodes/game_mode.dm b/code/game/gamemodes/game_mode.dm index 3c65135dbe..df2a1e9953 100644 --- a/code/game/gamemodes/game_mode.dm +++ b/code/game/gamemodes/game_mode.dm @@ -69,20 +69,20 @@ playerC++ if(!GLOB.Debug2) if(playerC < required_players || (maximum_players >= 0 && playerC > maximum_players)) - return 0 + return FALSE antag_candidates = get_players_for_role(antag_flag) if(!GLOB.Debug2) if(antag_candidates.len < required_enemies) - return 0 - return 1 + return FALSE + return TRUE else message_admins("DEBUG: GAME STARTING WITHOUT PLAYER NUMBER CHECKS, THIS WILL PROBABLY BREAK SHIT.") - return 1 + return TRUE ///Attempts to select players for special roles the mode might have. /datum/game_mode/proc/pre_setup() - return 1 + return TRUE ///Everyone should now be on the station and have their normal gear. This is the place to give the special roles extra things /datum/game_mode/proc/post_setup(report) //Gamemodes can override the intercept report. Passing TRUE as the argument will force a report. @@ -119,7 +119,7 @@ addtimer(CALLBACK(src, .proc/send_intercept, 0), rand(waittime_l, waittime_h)) generate_station_goals() gamemode_ready = TRUE - return 1 + return TRUE ///Handles late-join antag assignments @@ -159,10 +159,10 @@ switch(SSshuttle.emergency.mode) //Rounds on the verge of ending don't get new antags, they just run out if(SHUTTLE_STRANDED, SHUTTLE_ESCAPE) - return 1 + return TRUE if(SHUTTLE_CALL) if(SSshuttle.emergency.timeLeft(1) < initial(SSshuttle.emergencyCallTime)*0.5) - return 1 + return TRUE var/matc = CONFIG_GET(number/midround_antag_time_check) if(world.time >= (matc * 600)) @@ -199,7 +199,7 @@ //somewhere between 1 and 3 minutes from now if(!CONFIG_GET(keyed_list/midround_antag)[SSticker.mode.config_tag]) round_converted = 0 - return 1 + return TRUE for(var/mob/living/carbon/human/H in antag_candidates) if(H.client) replacementmode.make_antag_chance(H) @@ -210,7 +210,7 @@ ///Called by the gameSSticker /datum/game_mode/process() - return 0 + return //For things that do not die easily /datum/game_mode/proc/are_special_antags_dead() @@ -234,41 +234,41 @@ if(Player.mind) if(Player.mind.special_role || LAZYLEN(Player.mind.antag_datums)) continuous_sanity_checked = 1 - return 0 + return FALSE if(!continuous_sanity_checked) message_admins("The roundtype ([config_tag]) has no antagonists, continuous round has been defaulted to on and midround_antag has been defaulted to off.") continuous[config_tag] = TRUE midround_antag[config_tag] = FALSE SSshuttle.clearHostileEnvironment(src) - return 0 + return FALSE if(living_antag_player && living_antag_player.mind && isliving(living_antag_player) && living_antag_player.stat != DEAD && !isnewplayer(living_antag_player) &&!isbrain(living_antag_player) && (living_antag_player.mind.special_role || LAZYLEN(living_antag_player.mind.antag_datums))) - return 0 //A resource saver: once we find someone who has to die for all antags to be dead, we can just keep checking them, cycling over everyone only when we lose our mark. + return FALSE //A resource saver: once we find someone who has to die for all antags to be dead, we can just keep checking them, cycling over everyone only when we lose our mark. for(var/mob/Player in GLOB.alive_mob_list) if(Player.mind && Player.stat != DEAD && !isnewplayer(Player) &&!isbrain(Player) && Player.client && (Player.mind.special_role || LAZYLEN(Player.mind.antag_datums))) //Someone's still antagging but is their antagonist datum important enough to skip mulligan? for(var/datum/antagonist/antag_types in Player.mind.antag_datums) if(antag_types.prevent_roundtype_conversion) living_antag_player = Player //they were an important antag, they're our new mark - return 0 + return FALSE if(!are_special_antags_dead()) return FALSE if(!continuous[config_tag] || force_ending) - return 1 + return TRUE else round_converted = convert_roundtype() if(!round_converted) if(round_ends_with_antag_death) - return 1 + return TRUE else midround_antag[config_tag] = 0 - return 0 + return FALSE - return 0 + return FALSE /datum/game_mode/proc/send_intercept() diff --git a/code/game/gamemodes/meteor/meteors.dm b/code/game/gamemodes/meteor/meteors.dm index 8545f4500e..30f38889cc 100644 --- a/code/game/gamemodes/meteor/meteors.dm +++ b/code/game/gamemodes/meteor/meteors.dm @@ -92,7 +92,7 @@ GLOBAL_LIST_INIT(meteorsC, list(/obj/effect/meteor/dust)) //for space dust event var/hitpwr = 2 //Level of ex_act to be called on hit. var/dest pass_flags = PASSTABLE - var/heavy = 0 + var/heavy = FALSE var/meteorsound = 'sound/effects/meteorimpact.ogg' var/z_original var/threat = 0 // used for determining which meteors are most interesting @@ -245,7 +245,7 @@ GLOBAL_LIST_INIT(meteorsC, list(/obj/effect/meteor/dust)) //for space dust event name = "big meteor" icon_state = "large" hits = 6 - heavy = 1 + heavy = TRUE dropamt = 4 threat = 10 @@ -258,7 +258,7 @@ GLOBAL_LIST_INIT(meteorsC, list(/obj/effect/meteor/dust)) //for space dust event name = "flaming meteor" icon_state = "flaming" hits = 5 - heavy = 1 + heavy = TRUE meteorsound = 'sound/effects/bamf.ogg' meteordrop = list(/obj/item/stack/ore/plasma) threat = 20 @@ -271,7 +271,7 @@ GLOBAL_LIST_INIT(meteorsC, list(/obj/effect/meteor/dust)) //for space dust event /obj/effect/meteor/irradiated name = "glowing meteor" icon_state = "glowing" - heavy = 1 + heavy = TRUE meteordrop = list(/obj/item/stack/ore/uranium) threat = 15 @@ -288,7 +288,7 @@ GLOBAL_LIST_INIT(meteorsC, list(/obj/effect/meteor/dust)) //for space dust event icon_state = "meateor" desc = "Just... don't think too hard about where this thing came from." hits = 2 - heavy = 1 + heavy = TRUE meteorsound = 'sound/effects/blobattack.ogg' meteordrop = list(/obj/item/reagent_containers/food/snacks/meat/slab/human, /obj/item/reagent_containers/food/snacks/meat/slab/human/mutant, /obj/item/organ/heart, /obj/item/organ/lungs, /obj/item/organ/tongue, /obj/item/organ/appendix/) var/meteorgibs = /obj/effect/gibspawner/generic @@ -340,7 +340,7 @@ GLOBAL_LIST_INIT(meteorsC, list(/obj/effect/meteor/dust)) //for space dust event desc = "Your life briefly passes before your eyes the moment you lay them on this monstrosity." hits = 30 hitpwr = 1 - heavy = 1 + heavy = TRUE meteorsound = 'sound/effects/bamf.ogg' meteordrop = list(/obj/item/stack/ore/plasma) threat = 50 @@ -371,7 +371,7 @@ GLOBAL_LIST_INIT(meteorsSPOOKY, list(/obj/effect/meteor/pumpkin)) icon = 'icons/obj/meteor_spooky.dmi' icon_state = "pumpkin" hits = 10 - heavy = 1 + heavy = TRUE dropamt = 1 meteordrop = list(/obj/item/clothing/head/hardhat/pumpkinhead, /obj/item/reagent_containers/food/snacks/grown/pumpkin) threat = 100 diff --git a/code/game/gamemodes/objective.dm b/code/game/gamemodes/objective.dm index 06cba32461..0b309bcc31 100644 --- a/code/game/gamemodes/objective.dm +++ b/code/game/gamemodes/objective.dm @@ -8,8 +8,8 @@ GLOBAL_LIST(admin_objective_list) //Prefilled admin assignable objective list var/team_explanation_text //For when there are multiple owners. var/datum/mind/target = null //If they are focused on a particular person. var/target_amount = 0 //If they are focused on a particular number. Steal objectives have their own counter. - var/completed = 0 //currently only used for custom objectives. - var/martyr_compatible = 0 //If the objective is compatible with martyr objective, i.e. if you can still do it while dead. + var/completed = FALSE //currently only used for custom objectives. + var/martyr_compatible = FALSE //If the objective is compatible with martyr objective, i.e. if you can still do it while dead. /datum/objective/New(text) if(text) @@ -170,7 +170,7 @@ GLOBAL_LIST(admin_objective_list) //Prefilled admin assignable objective list /datum/objective/assassinate name = "assasinate" var/target_role_type=FALSE - martyr_compatible = 1 + martyr_compatible = TRUE /datum/objective/assassinate/find_target_by_role(role, role_type=FALSE,invert=FALSE) if(!invert) @@ -191,7 +191,7 @@ GLOBAL_LIST(admin_objective_list) //Prefilled admin assignable objective list admin_simple_target_pick(admin) /datum/objective/assassinate/internal - var/stolen = 0 //Have we already eliminated this target? + var/stolen = FALSE //Have we already eliminated this target? /datum/objective/assassinate/internal/update_explanation_text() ..() @@ -224,7 +224,7 @@ GLOBAL_LIST(admin_objective_list) //Prefilled admin assignable objective list /datum/objective/maroon name = "maroon" var/target_role_type=FALSE - martyr_compatible = 1 + martyr_compatible = TRUE /datum/objective/maroon/find_target_by_role(role, role_type=FALSE,invert=FALSE) if(!invert) @@ -279,7 +279,7 @@ GLOBAL_LIST(admin_objective_list) //Prefilled admin assignable objective list /datum/objective/protect//The opposite of killing a dude. name = "protect" - martyr_compatible = 1 + martyr_compatible = TRUE var/target_role_type = FALSE var/human_check = TRUE @@ -350,7 +350,7 @@ GLOBAL_LIST(admin_objective_list) //Prefilled admin assignable objective list name = "hijack" explanation_text = "Hijack the shuttle to ensure no loyalist Nanotrasen crew escape alive and out of custody." team_explanation_text = "Hijack the shuttle to ensure no loyalist Nanotrasen crew escape alive and out of custody. Leave no team member behind." - martyr_compatible = 0 //Technically you won't get both anyway. + martyr_compatible = FALSE //Technically you won't get both anyway. /datum/objective/hijack/check_completion() // Requires all owners to escape. if(SSshuttle.emergency.mode != SHUTTLE_ENDGAME) @@ -378,7 +378,7 @@ GLOBAL_LIST(admin_objective_list) //Prefilled admin assignable objective list /datum/objective/purge name = "no mutants on shuttle" explanation_text = "Ensure no mutant humanoid species are present aboard the escape shuttle." - martyr_compatible = 1 + martyr_compatible = TRUE /datum/objective/purge/check_completion() if(SSshuttle.emergency.mode != SHUTTLE_ENDGAME) @@ -393,7 +393,7 @@ GLOBAL_LIST(admin_objective_list) //Prefilled admin assignable objective list /datum/objective/robot_army name = "robot army" explanation_text = "Have at least eight active cyborgs synced to you." - martyr_compatible = 0 + martyr_compatible = FALSE /datum/objective/robot_army/check_completion() var/counter = 0 @@ -497,7 +497,7 @@ GLOBAL_LIST(admin_objective_list) //Prefilled admin assignable objective list /datum/objective/nuclear name = "nuclear" explanation_text = "Destroy the station with a nuclear device." - martyr_compatible = 1 + martyr_compatible = TRUE /datum/objective/nuclear/check_completion() if(SSticker && SSticker.mode && SSticker.mode.station_was_nuked) @@ -509,7 +509,7 @@ GLOBAL_LIST_EMPTY(possible_items) name = "steal" var/datum/objective_item/targetinfo = null //Save the chosen item datum so we can access it later. var/obj/item/steal_target = null //Needed for custom objectives (they're just items, not datums). - martyr_compatible = 0 + martyr_compatible = FALSE /datum/objective/steal/get_target() return steal_target @@ -793,7 +793,7 @@ GLOBAL_LIST_EMPTY(possible_items_special) /datum/objective/destroy name = "destroy AI" - martyr_compatible = 1 + martyr_compatible = TRUE /datum/objective/destroy/find_target(dupe_search_range) var/list/possible_targets = active_ais(1) @@ -891,7 +891,7 @@ GLOBAL_LIST_EMPTY(possible_items_special) //////////////////////////////// /datum/objective/changeling_team_objective //Abstract type - martyr_compatible = 0 //Suicide is not teamwork! + martyr_compatible = FALSE //Suicide is not teamwork! explanation_text = "Changeling Friendship!" var/min_lings = 3 //Minimum amount of lings for this team objective to be possible var/escape_objective_compatible = FALSE diff --git a/code/game/gamemodes/objective_items.dm b/code/game/gamemodes/objective_items.dm index 8251619012..b1a6cf48c8 100644 --- a/code/game/gamemodes/objective_items.dm +++ b/code/game/gamemodes/objective_items.dm @@ -136,8 +136,8 @@ /datum/objective_item/steal/functionalai/check_special_completion(obj/item/aicard/C) for(var/mob/living/silicon/ai/A in C) if(isAI(A) && A.stat != DEAD) //See if any AI's are alive inside that card. - return 1 - return 0 + return TRUE + return FALSE /datum/objective_item/steal/blueprints name = "the station blueprints." diff --git a/code/game/gamemodes/sandbox/airlock_maker.dm b/code/game/gamemodes/sandbox/airlock_maker.dm index ab98aa80b4..9f1cba51a8 100644 --- a/code/game/gamemodes/sandbox/airlock_maker.dm +++ b/code/game/gamemodes/sandbox/airlock_maker.dm @@ -21,7 +21,7 @@ var/require_all = 1 var/paintjob = "none" - var/glassdoor = 0 + var/glassdoor = FALSE var/doorname = "airlock" diff --git a/code/game/gamemodes/sandbox/h_sandbox.dm b/code/game/gamemodes/sandbox/h_sandbox.dm index 952b1093ba..8f801af25d 100644 --- a/code/game/gamemodes/sandbox/h_sandbox.dm +++ b/code/game/gamemodes/sandbox/h_sandbox.dm @@ -4,7 +4,7 @@ GLOBAL_VAR_INIT(hsboxspawn, TRUE) sandbox = new/datum/h_sandbox sandbox.owner = src.ckey if(src.client.holder) - sandbox.admin = 1 + sandbox.admin = TRUE add_verb(src, /mob/proc/sandbox_panel) /mob/proc/sandbox_panel() @@ -14,7 +14,7 @@ GLOBAL_VAR_INIT(hsboxspawn, TRUE) /datum/h_sandbox var/owner = null - var/admin = 0 + var/admin = FALSE var/static/clothinfo = null var/static/reaginfo = null diff --git a/code/game/machinery/_machinery.dm b/code/game/machinery/_machinery.dm index 7bc293bf44..604b9bdc27 100644 --- a/code/game/machinery/_machinery.dm +++ b/code/game/machinery/_machinery.dm @@ -266,12 +266,12 @@ Class Procs: /obj/machinery/proc/auto_use_power() if(!powered(power_channel)) - return 0 + return FALSE if(use_power == 1) use_power(idle_power_usage,power_channel) else if(use_power >= 2) use_power(active_power_usage,power_channel) - return 1 + return TRUE ///Called when we want to change the value of the `is_operational` variable. Boolean. @@ -370,11 +370,11 @@ Class Procs: /obj/machinery/Topic(href, href_list) ..() if(!can_interact(usr)) - return 1 + return TRUE if(!usr.canUseTopic(src)) - return 1 + return TRUE add_fingerprint(usr) - return 0 + return FALSE //////////////////////////////////////////////////////////////////////////////////////////// @@ -467,7 +467,7 @@ Class Procs: M.icon_state = "box_1" /obj/machinery/obj_break(damage_flag) - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) . = ..() if(!(machine_stat & BROKEN) && !(flags_1 & NODECONSTRUCT_1)) set_machine_stat(machine_stat | BROKEN) @@ -513,8 +513,8 @@ Class Procs: I.play_tool_sound(src, 50) setDir(turn(dir,-90)) to_chat(user, "You rotate [src].") - return 1 - return 0 + return TRUE + return FALSE /obj/proc/can_be_unfasten_wrench(mob/user, silent) //if we can unwrench this object; returns SUCCESSFUL_UNFASTEN and FAILED_UNFASTEN, which are both TRUE, or CANT_UNFASTEN, which isn't. if(!(isfloorturf(loc) || istype(loc, /turf/open/indestructible)) && !anchored) diff --git a/code/game/machinery/autolathe.dm b/code/game/machinery/autolathe.dm index 5b1d2d54f7..b1eed4cbaf 100644 --- a/code/game/machinery/autolathe.dm +++ b/code/game/machinery/autolathe.dm @@ -17,7 +17,7 @@ var/list/L = list() var/list/LL = list() var/hacked = FALSE - var/disabled = 0 + var/disabled = FALSE var/shocked = FALSE var/hack_wire var/disable_wire diff --git a/code/game/machinery/camera/tracking.dm b/code/game/machinery/camera/tracking.dm index 1b4b01f204..bb0424a773 100644 --- a/code/game/machinery/camera/tracking.dm +++ b/code/game/machinery/camera/tracking.dm @@ -96,14 +96,14 @@ return if(!target.can_track(usr)) - U.tracking = 1 + U.tracking = TRUE if(!cameraticks) to_chat(U, "Target is not near any active cameras. Attempting to reacquire...") cameraticks++ if(cameraticks > 9) U.cameraFollow = null to_chat(U, "Unable to reacquire, cancelling track...") - tracking = 0 + tracking = FALSE return else sleep(10) @@ -111,7 +111,7 @@ else cameraticks = 0 - U.tracking = 0 + U.tracking = FALSE if(U.eyeobj) U.eyeobj.setLoc(get_turf(target)) diff --git a/code/game/machinery/computer/_computer.dm b/code/game/machinery/computer/_computer.dm index 5c83748afe..9a9eef0371 100644 --- a/code/game/machinery/computer/_computer.dm +++ b/code/game/machinery/computer/_computer.dm @@ -25,8 +25,8 @@ /obj/machinery/computer/process() if(machine_stat & (NOPOWER|BROKEN)) - return 0 - return 1 + return FALSE + return TRUE /obj/machinery/computer/update_overlays() . = ..() diff --git a/code/game/machinery/computer/card.dm b/code/game/machinery/computer/card.dm index 025b0f0843..5647c35146 100644 --- a/code/game/machinery/computer/card.dm +++ b/code/game/machinery/computer/card.dm @@ -514,10 +514,10 @@ GLOBAL_VAR_INIT(time_last_changed_position, 0) var/datum/job/j = SSjob.GetJob(edit_job_target) if(!j) updateUsrDialog() - return 0 + return if(can_open_job(j) != 1) updateUsrDialog() - return 0 + return if(opened_positions[edit_job_target] >= 0) GLOB.time_last_changed_position = world.time / 10 j.total_positions++ @@ -531,10 +531,10 @@ GLOBAL_VAR_INIT(time_last_changed_position, 0) var/datum/job/j = SSjob.GetJob(edit_job_target) if(!j) updateUsrDialog() - return 0 + return if(can_close_job(j) != 1) updateUsrDialog() - return 0 + return //Allow instant closing without cooldown if a position has been opened before if(opened_positions[edit_job_target] <= 0) GLOB.time_last_changed_position = world.time / 10 @@ -549,7 +549,7 @@ GLOBAL_VAR_INIT(time_last_changed_position, 0) var/datum/job/j = SSjob.GetJob(priority_target) if(!j) updateUsrDialog() - return 0 + return var/priority = TRUE if(j in SSjob.prioritized_jobs) SSjob.prioritized_jobs -= j diff --git a/code/game/machinery/computer/medical.dm b/code/game/machinery/computer/medical.dm index ac4dcd4abc..9bc3af8e22 100644 --- a/code/game/machinery/computer/medical.dm +++ b/code/game/machinery/computer/medical.dm @@ -559,14 +559,12 @@ continue /obj/machinery/computer/med_data/proc/canUseMedicalRecordsConsole(mob/user, message = 1, record1, record2) - if(user) - if(message) - if(authenticated) - if(user.canUseTopic(src, !issilicon(user))) - if(!record1 || record1 == active1) - if(!record2 || record2 == active2) - return 1 - return 0 + if(user && message && authenticated) + if(user.canUseTopic(src, !issilicon(user))) + if(!record1 || record1 == active1) + if(!record2 || record2 == active2) + return TRUE + return FALSE /obj/machinery/computer/med_data/laptop name = "medical laptop" diff --git a/code/game/machinery/computer/security.dm b/code/game/machinery/computer/security.dm index 8079e39726..ed3bc77d8b 100644 --- a/code/game/machinery/computer/security.dm +++ b/code/game/machinery/computer/security.dm @@ -855,12 +855,11 @@ What a mess.*/ continue /obj/machinery/computer/secure_data/proc/canUseSecurityRecordsConsole(mob/user, message1 = 0, record1, record2) - if(user) - if(authenticated) - if(user.canUseTopic(src, !issilicon(user))) - if(!trim(message1)) - return 0 - if(!record1 || record1 == active1) - if(!record2 || record2 == active2) - return 1 - return 0 + if(user && authenticated) + if(user.canUseTopic(src, !issilicon(user))) + if(!trim(message1)) + return FALSE + if(!record1 || record1 == active1) + if(!record2 || record2 == active2) + return TRUE + return FALSE diff --git a/code/game/machinery/constructable_frame.dm b/code/game/machinery/constructable_frame.dm index eaca2b74ab..efd71785d7 100644 --- a/code/game/machinery/constructable_frame.dm +++ b/code/game/machinery/constructable_frame.dm @@ -31,7 +31,7 @@ /obj/structure/frame/machine/examine(user) . = ..() if(state == 3 && req_components && req_component_names) - var/hasContent = 0 + var/hasContent = FALSE var/requires = "It requires" for(var/i = 1 to req_components.len) @@ -41,7 +41,7 @@ continue var/use_and = i == req_components.len requires += "[(hasContent ? (use_and ? ", and" : ",") : "")] [amt] [amt == 1 ? req_component_names[tname] : "[req_component_names[tname]]\s"]" - hasContent = 1 + hasContent = TRUE if(hasContent) . += "[requires]." @@ -267,9 +267,9 @@ to_chat(user, "You add [P] to [src].") components += P req_components[I]-- - return 1 + return TRUE to_chat(user, "You cannot add that to the machine!") - return 0 + return FALSE if(user.a_intent == INTENT_HARM) return ..() diff --git a/code/game/machinery/doors/airlock_types.dm b/code/game/machinery/doors/airlock_types.dm index 09307a846f..275022e643 100644 --- a/code/game/machinery/doors/airlock_types.dm +++ b/code/game/machinery/doors/airlock_types.dm @@ -472,11 +472,11 @@ /obj/machinery/door/airlock/cult/allowed(mob/living/L) if(!density) - return 1 + return TRUE if(friendly || iscultist(L) || istype(L, /mob/living/simple_animal/shade) || isconstruct(L)) if(!stealthy) new openingoverlaytype(loc) - return 1 + return TRUE else if(!stealthy) new /obj/effect/temp_visual/cult/sac(loc) @@ -486,7 +486,7 @@ flash_color(L, flash_color="#960000", flash_time=20) L.Paralyze(40) L.throw_at(throwtarget, 5, 1,src) - return 0 + return FALSE /obj/machinery/door/airlock/cult/proc/conceal() icon = 'icons/obj/doors/airlocks/station/maintenance.dmi' diff --git a/code/game/machinery/embedded_controller/embedded_controller_base.dm b/code/game/machinery/embedded_controller/embedded_controller_base.dm index 5d0165189d..2d9cc6cf98 100644 --- a/code/game/machinery/embedded_controller/embedded_controller_base.dm +++ b/code/game/machinery/embedded_controller/embedded_controller_base.dm @@ -35,15 +35,16 @@ /obj/machinery/embedded_controller/proc/return_text() /obj/machinery/embedded_controller/proc/post_signal(datum/signal/signal, comm_line) - return 0 + return /obj/machinery/embedded_controller/receive_signal(datum/signal/signal) if(istype(signal) && program) program.receive_signal(signal) /obj/machinery/embedded_controller/Topic(href, href_list) - if(..()) - return 0 + . = ..() + if(.) + return if(program) program.receive_user_command(href_list["command"]) diff --git a/code/game/machinery/lightswitch.dm b/code/game/machinery/lightswitch.dm index 72590088a0..5978c0b7fa 100644 --- a/code/game/machinery/lightswitch.dm +++ b/code/game/machinery/lightswitch.dm @@ -52,7 +52,7 @@ area.power_change() /obj/machinery/light_switch/power_change() - SHOULD_CALL_PARENT(0) + SHOULD_CALL_PARENT(FALSE) if(area == get_area(src)) return ..() diff --git a/code/game/machinery/magnet.dm b/code/game/machinery/magnet.dm index 4c18e747af..39ceb21041 100644 --- a/code/game/machinery/magnet.dm +++ b/code/game/machinery/magnet.dm @@ -201,8 +201,8 @@ var/speed = 1 // lowest = 1, highest = 10 var/list/rpath = list() // real path of the magnet, used in iterator - var/moving = 0 // 1 if scheduled to loop - var/looping = 0 // 1 if looping + var/moving = TRUE // true if scheduled to loop + var/looping = TRUE // true if looping var/datum/radio_frequency/radio_connection @@ -301,7 +301,7 @@ if("setpath") var/newpath = stripped_input(usr, "Please define a new path!", "New Path", path, MAX_MESSAGE_LEN) if(newpath && newpath != "") - moving = 0 // stop moving + moving = FALSE // stop moving path = newpath pathpos = 1 // reset position filter_path() // renders rpath @@ -323,7 +323,7 @@ if(machine_stat & (BROKEN|NOPOWER)) break - looping = 1 + looping = TRUE // Prepare the radio signal var/datum/signal/signal = new(list("code" = code)) @@ -353,7 +353,7 @@ else sleep(12-speed) - looping = 0 + looping = FALSE /obj/machinery/magnetic_controller/proc/filter_path() diff --git a/code/game/machinery/medical_kiosk.dm b/code/game/machinery/medical_kiosk.dm index 0b2f4f5db7..4f72b94eab 100644 --- a/code/game/machinery/medical_kiosk.dm +++ b/code/game/machinery/medical_kiosk.dm @@ -234,7 +234,7 @@ if(altPatient.reagents.reagent_list.len) //Chemical Analysis details. for(var/datum/reagent/R in altPatient.reagents.reagent_list) chemical_list += list(list("name" = R.name, "volume" = round(R.volume, 0.01))) - if(R.overdosed == 1) + if(R.overdosed) overdose_list += list(list("name" = R.name)) if(altPatient.reagents.addiction_list.len) diff --git a/code/game/machinery/newscaster.dm b/code/game/machinery/newscaster.dm index 04fc034ff8..83441347ea 100644 --- a/code/game/machinery/newscaster.dm +++ b/code/game/machinery/newscaster.dm @@ -13,7 +13,7 @@ GLOBAL_LIST_EMPTY(allCasters) var/body ="" var/list/authorCensorTime = list() var/list/bodyCensorTime = list() - var/is_admin_message = 0 + var/is_admin_message = FALSE var/icon/img = null var/time_stamp = "" var/list/datum/newscaster/feed_comment/comments = list() @@ -61,11 +61,11 @@ GLOBAL_LIST_EMPTY(allCasters) var/list/datum/newscaster/feed_message/messages = list() var/locked = FALSE var/author = "" - var/censored = 0 + var/censored = FALSE var/list/authorCensorTime = list() var/list/DclassCensorTime = list() var/authorCensor - var/is_admin_channel = 0 + var/is_admin_channel = FALSE /datum/newscaster/feed_channel/proc/returnAuthor(censor) if(censor == -1) @@ -110,7 +110,7 @@ GLOBAL_LIST_EMPTY(allCasters) CreateFeedChannel("Station Announcements", "SS13", 1) wanted_issue = new /datum/newscaster/wanted_message -/datum/newscaster/feed_network/proc/CreateFeedChannel(channel_name, author, locked, adminChannel = 0) +/datum/newscaster/feed_network/proc/CreateFeedChannel(channel_name, author, locked, adminChannel = FALSE) var/datum/newscaster/feed_channel/newChannel = new /datum/newscaster/feed_channel newChannel.channel_name = channel_name newChannel.author = author @@ -118,7 +118,7 @@ GLOBAL_LIST_EMPTY(allCasters) newChannel.is_admin_channel = adminChannel network_channels += newChannel -/datum/newscaster/feed_network/proc/SubmitArticle(msg, author, channel_name, datum/picture/picture, adminMessage = 0, allow_comments = 1, update_alert = TRUE) +/datum/newscaster/feed_network/proc/SubmitArticle(msg, author, channel_name, datum/picture/picture, adminMessage = FALSE, allow_comments = TRUE, update_alert = TRUE) var/datum/newscaster/feed_message/newMsg = new /datum/newscaster/feed_message newMsg.author = author newMsg.body = msg @@ -138,8 +138,8 @@ GLOBAL_LIST_EMPTY(allCasters) lastAction ++ newMsg.creationTime = lastAction -/datum/newscaster/feed_network/proc/submitWanted(criminal, body, scanned_user, datum/picture/picture, adminMsg = 0, newMessage = 0) - wanted_issue.active = 1 +/datum/newscaster/feed_network/proc/submitWanted(criminal, body, scanned_user, datum/picture/picture, adminMsg = FALSE, newMessage = FALSE) + wanted_issue.active = TRUE wanted_issue.criminal = criminal wanted_issue.body = body wanted_issue.scannedUser = scanned_user @@ -153,7 +153,7 @@ GLOBAL_LIST_EMPTY(allCasters) N.update_icon() /datum/newscaster/feed_network/proc/deleteWanted() - wanted_issue.active = 0 + wanted_issue.active = FALSE wanted_issue.criminal = null wanted_issue.body = null wanted_issue.scannedUser = null @@ -273,9 +273,9 @@ GLOBAL_LIST_EMPTY(allCasters) dat+= "
Re-scan User" dat+= "

Exit" if(securityCaster) - var/wanted_already = 0 + var/wanted_already = FALSE if(GLOB.news_network.wanted_issue.active) - wanted_already = 1 + wanted_already = TRUE dat+="
Feed Security functions:
" dat+="
[(wanted_already) ? ("Manage") : ("Publish")] \"Wanted\" Issue" dat+="
Censor Feed Stories" @@ -334,10 +334,10 @@ GLOBAL_LIST_EMPTY(allCasters) dat+="There is already a Feed channel under your name.
" if(channel_name=="" || channel_name == "\[REDACTED\]") dat+="Invalid channel name.
" - var/check = 0 + var/check = FALSE for(var/datum/newscaster/feed_channel/FC in GLOB.news_network.network_channels) if(FC.channel_name == channel_name) - check = 1 + check = TRUE break if(check) dat+="Channel name already in use.
" @@ -436,10 +436,10 @@ GLOBAL_LIST_EMPTY(allCasters) dat+="
Back" if(14) dat+="Wanted Issue Handler:" - var/wanted_already = 0 + var/wanted_already = FALSE var/end_param = 1 if(GLOB.news_network.wanted_issue.active) - wanted_already = 1 + wanted_already = TRUE end_param = 2 if(wanted_already) dat+="
A wanted issue is already in Feed Circulation. You can edit or cancel it below.
" @@ -516,10 +516,10 @@ GLOBAL_LIST_EMPTY(allCasters) existing_authors += GLOB.news_network.redactedText else existing_authors += FC.author - var/check = 0 + var/check = FALSE for(var/datum/newscaster/feed_channel/FC in GLOB.news_network.network_channels) if(FC.channel_name == channel_name) - check = 1 + check = TRUE break if(channel_name == "" || channel_name == "\[REDACTED\]" || scanned_user == "Unknown" || check || (scanned_user in existing_authors) ) screen=7 @@ -578,10 +578,7 @@ GLOBAL_LIST_EMPTY(allCasters) screen=11 updateUsrDialog() else if(href_list["menu_wanted"]) - var/already_wanted = 0 if(GLOB.news_network.wanted_issue.active) - already_wanted = 1 - if(already_wanted) channel_name = GLOB.news_network.wanted_issue.criminal msg = GLOB.news_network.wanted_issue.body screen = 14 @@ -971,17 +968,17 @@ GLOBAL_LIST_EMPTY(allCasters) /obj/item/newspaper/proc/notContent(list/L) if(!L.len) - return 0 + return FALSE for(var/i=L.len;i>0;i--) var/num = abs(L[i]) if(creationTime <= num) continue else if(L[i] > 0) - return 1 + return TRUE else - return 0 - return 0 + return FALSE + return FALSE /obj/item/newspaper/Topic(href, href_list) var/mob/living/U = usr diff --git a/code/game/machinery/recycler.dm b/code/game/machinery/recycler.dm index b041b9aca5..90a8f3e308 100644 --- a/code/game/machinery/recycler.dm +++ b/code/game/machinery/recycler.dm @@ -10,7 +10,7 @@ circuit = /obj/item/circuitboard/machine/recycler var/safety_mode = FALSE // Temporarily stops machine if it detects a mob var/icon_name = "grinder-o" - var/blood = 0 + var/bloody = FALSE var/eat_dir = WEST var/amount_produced = 50 var/crush_damage = 1000 @@ -76,7 +76,7 @@ var/is_powered = !(machine_stat & (BROKEN|NOPOWER)) if(safety_mode) is_powered = FALSE - icon_state = icon_name + "[is_powered]" + "[(blood ? "bld" : "")]" // add the blood tag at the end + icon_state = icon_name + "[is_powered]" + "[(bloody ? "bld" : "")]" // add the blood tag at the end /obj/machinery/recycler/CanAllowThrough(atom/movable/AM) . = ..() @@ -181,8 +181,8 @@ L.say("ARRRRRRRRRRRGH!!!", forced="recycler grinding") add_mob_blood(L) - if(!blood && !issilicon(L)) - blood = TRUE + if(!bloody && !issilicon(L)) + bloody = TRUE update_icon() // Instantly lie down, also go unconscious from the pain, before you die. diff --git a/code/game/machinery/slotmachine.dm b/code/game/machinery/slotmachine.dm index c1ec1a0781..f989b6ceed 100644 --- a/code/game/machinery/slotmachine.dm +++ b/code/game/machinery/slotmachine.dm @@ -26,7 +26,7 @@ light_color = LIGHT_COLOR_BROWN var/money = 3000 //How much money it has CONSUMED var/plays = 0 - var/working = 0 + var/working = FALSE var/balance = 0 //How much money is in the machine, ready to be CONSUMED. var/jackpots = 0 var/paymode = HOLOCHIP //toggles between HOLOCHIP/COIN, defined above @@ -229,15 +229,17 @@ /obj/machinery/computer/slot_machine/proc/can_spin(mob/user) if(machine_stat & NOPOWER) to_chat(user, "The slot machine has no power!") + return FALSE if(machine_stat & BROKEN) to_chat(user, "The slot machine is broken!") + return FALSE if(working) to_chat(user, "You need to wait until the machine stops spinning before you can play again!") - return 0 + return FALSE if(balance < SPIN_PRICE) to_chat(user, "Insufficient money to play!") - return 0 - return 1 + return FALSE + return TRUE /obj/machinery/computer/slot_machine/proc/toggle_reel_spin(value, delay = 0) //value is 1 or 0 aka on or off for(var/list/reel in reels) diff --git a/code/game/machinery/suit_storage_unit.dm b/code/game/machinery/suit_storage_unit.dm index c52a5bccbe..0b693f28d0 100644 --- a/code/game/machinery/suit_storage_unit.dm +++ b/code/game/machinery/suit_storage_unit.dm @@ -360,7 +360,7 @@ dump_contents() /obj/machinery/suit_storage_unit/proc/resist_open(mob/user) - if(!state_open && occupant && (user in src) && user.stat == 0) // Check they're still here. + if(!state_open && occupant && (user in src) && user.stat == CONSCIOUS) // Check they're still here. visible_message("You see [user] burst out of [src]!", \ "You escape the cramped confines of [src]!") open_machine() diff --git a/code/game/machinery/syndicatebeacon.dm b/code/game/machinery/syndicatebeacon.dm index edeec36ef1..78c52b44a4 100644 --- a/code/game/machinery/syndicatebeacon.dm +++ b/code/game/machinery/syndicatebeacon.dm @@ -13,7 +13,7 @@ verb_say = "states" var/cooldown = 0 - var/active = 0 + var/active = FALSE var/icontype = "beacon" @@ -26,7 +26,7 @@ if(singulo.z == z) singulo.target = src icon_state = "[icontype]1" - active = 1 + active = TRUE if(user) to_chat(user, "You activate the beacon.") @@ -36,7 +36,7 @@ if(singulo.target == src) singulo.target = null icon_state = "[icontype]0" - active = 0 + active = FALSE if(user) to_chat(user, "You deactivate the beacon.") diff --git a/code/game/machinery/teleporter.dm b/code/game/machinery/teleporter.dm index 4beb14a523..96bbf82aff 100644 --- a/code/game/machinery/teleporter.dm +++ b/code/game/machinery/teleporter.dm @@ -13,7 +13,7 @@ circuit = /obj/item/circuitboard/machine/teleporter_hub var/accuracy = 0 var/obj/machinery/teleport/station/power_station - var/calibrated //Calibration prevents mutation + var/calibrated = FALSE//Calibration prevents mutation /obj/machinery/teleport/hub/Initialize() . = ..() @@ -83,7 +83,7 @@ log_game("[human] ([key_name(human)]) was turned into a fly person") human.apply_effect((rand(120 - accuracy * 40, 180 - accuracy * 60)), EFFECT_IRRADIATE, 0) - calibrated = 0 + calibrated = FALSE return /obj/machinery/teleport/hub/update_icon_state() diff --git a/code/game/machinery/washing_machine.dm b/code/game/machinery/washing_machine.dm index 1b5f1800b6..60c0800370 100644 --- a/code/game/machinery/washing_machine.dm +++ b/code/game/machinery/washing_machine.dm @@ -139,7 +139,7 @@ GLOBAL_LIST_INIT(dye_registry, list( density = TRUE state_open = TRUE var/busy = FALSE - var/bloody_mess = 0 + var/bloody_mess = FALSE var/obj/item/color_source var/max_wash_capacity = 5 @@ -264,7 +264,7 @@ GLOBAL_LIST_INIT(dye_registry, list( /obj/item/clothing/shoes/sneakers/machine_wash(obj/machinery/washing_machine/WM) if(chained) - chained = 0 + chained = FALSE slowdown = SHOES_SLOWDOWN new /obj/item/restraints/handcuffs(loc) ..() diff --git a/code/game/mecha/equipment/tools/other_tools.dm b/code/game/mecha/equipment/tools/other_tools.dm index dde9a408d0..da6648f3c4 100644 --- a/code/game/mecha/equipment/tools/other_tools.dm +++ b/code/game/mecha/equipment/tools/other_tools.dm @@ -45,10 +45,10 @@ var/turf/pos = get_turf(src) for(var/turf/T in get_area_turfs(thearea.type)) if(!T.density && pos.z == T.z) - var/clear = 1 + var/clear = TRUE for(var/obj/O in T) if(O.density) - clear = 0 + clear = FALSE break if(clear) L+=T diff --git a/code/game/objects/buckling.dm b/code/game/objects/buckling.dm index 5379de7329..82564664fd 100644 --- a/code/game/objects/buckling.dm +++ b/code/game/objects/buckling.dm @@ -1,7 +1,7 @@ /atom/movable - var/can_buckle = 0 + var/can_buckle = FALSE var/buckle_lying = -1 //bed-like behaviour, forces mob.lying = buckle_lying if != -1 - var/buckle_requires_restraints = 0 //require people to be handcuffed before being able to buckle. eg: pipes + var/buckle_requires_restraints = FALSE //require people to be handcuffed before being able to buckle. eg: pipes var/list/mob/living/buckled_mobs = null //list() var/max_buckled_mobs = 1 var/buckle_prevents_pull = FALSE @@ -15,10 +15,10 @@ if(buckled_mobs.len > 1) var/unbuckled = input(user, "Who do you wish to unbuckle?","Unbuckle Who?") as null|mob in sortNames(buckled_mobs) if(user_unbuckle_mob(unbuckled,user)) - return 1 + return TRUE else if(user_unbuckle_mob(buckled_mobs[1],user)) - return 1 + return TRUE /atom/movable/attackby(obj/item/W, mob/user, params) if(!can_buckle || !istype(W, /obj/item/riding_offhand) || !user.Adjacent(src)) diff --git a/code/game/objects/effects/alien_acid.dm b/code/game/objects/effects/alien_acid.dm index adabf3b706..3c40c1366f 100644 --- a/code/game/objects/effects/alien_acid.dm +++ b/code/game/objects/effects/alien_acid.dm @@ -32,10 +32,9 @@ return ..() /obj/effect/acid/process() - . = 1 if(!target) qdel(src) - return 0 + return FALSE if(prob(5)) playsound(loc, 'sound/items/welder.ogg', 100, TRUE) @@ -50,7 +49,8 @@ acid_level = max(acid_level - (5 + 2*round(sqrt(acid_level))), 0) if(acid_level <= 0) qdel(src) - return 0 + return FALSE + return TRUE /obj/effect/acid/Crossed(AM as mob|obj) . = ..() diff --git a/code/game/objects/effects/decals/cleanable/aliens.dm b/code/game/objects/effects/decals/cleanable/aliens.dm index 6c3a455edd..f4cd4357fa 100644 --- a/code/game/objects/effects/decals/cleanable/aliens.dm +++ b/code/game/objects/effects/decals/cleanable/aliens.dm @@ -27,7 +27,7 @@ mergeable_decal = FALSE /obj/effect/decal/cleanable/xenoblood/xgibs/proc/streak(list/directions) - set waitfor = 0 + set waitfor = FALSE var/direction = pick(directions) for(var/i = 0, i < pick(1, 200; 2, 150; 3, 50), i++) sleep(2) diff --git a/code/game/objects/effects/decals/cleanable/humans.dm b/code/game/objects/effects/decals/cleanable/humans.dm index ceb5f82d4c..4500755446 100644 --- a/code/game/objects/effects/decals/cleanable/humans.dm +++ b/code/game/objects/effects/decals/cleanable/humans.dm @@ -227,5 +227,5 @@ /obj/effect/decal/cleanable/blood/footprints/can_bloodcrawl_in() if((blood_state != BLOOD_STATE_OIL) && (blood_state != BLOOD_STATE_NOT_BLOODY)) - return 1 - return 0 + return TRUE + return FALSE diff --git a/code/game/objects/effects/decals/cleanable/robots.dm b/code/game/objects/effects/decals/cleanable/robots.dm index 79059b51f3..0d7c5f8e09 100644 --- a/code/game/objects/effects/decals/cleanable/robots.dm +++ b/code/game/objects/effects/decals/cleanable/robots.dm @@ -13,7 +13,7 @@ beauty = -50 /obj/effect/decal/cleanable/robot_debris/proc/streak(list/directions) - set waitfor = 0 + set waitfor = FALSE var/direction = pick(directions) for (var/i = 0, i < pick(1, 200; 2, 150; 3, 50), i++) sleep(2) diff --git a/code/game/objects/effects/effect_system/effects_foam.dm b/code/game/objects/effects/effect_system/effects_foam.dm index 770dcf9d62..0431da86ca 100644 --- a/code/game/objects/effects/effect_system/effects_foam.dm +++ b/code/game/objects/effects/effect_system/effects_foam.dm @@ -162,14 +162,14 @@ /obj/effect/particle_effect/foam/proc/foam_mob(mob/living/L) if(lifetime<1) - return 0 + return FALSE if(!istype(L)) - return 0 + return FALSE var/fraction = 1/initial(reagent_divisor) if(lifetime % reagent_divisor) reagents.expose(L, VAPOR, fraction) lifetime-- - return 1 + return TRUE /obj/effect/particle_effect/foam/proc/spread_foam() var/turf/t_loc = get_turf(src) diff --git a/code/game/objects/effects/effect_system/effects_other.dm b/code/game/objects/effects/effect_system/effects_other.dm index 3f2b6ecaf9..520e251a2a 100644 --- a/code/game/objects/effects/effect_system/effects_other.dm +++ b/code/game/objects/effects/effect_system/effects_other.dm @@ -85,11 +85,11 @@ /datum/effect_system/reagents_explosion var/amount // TNT equivalent - var/flashing = 0 // does explosion creates flash effect? + var/flashing = FALSE // does explosion creates flash effect? var/flashing_factor = 0 // factor of how powerful the flash effect relatively to the explosion var/explosion_message = 1 //whether we show a message to mobs. -/datum/effect_system/reagents_explosion/set_up(amt, loca, flash = 0, flash_fact = 0, message = 1) +/datum/effect_system/reagents_explosion/set_up(amt, loca, flash = FALSE, flash_fact = 0, message = TRUE) amount = amt explosion_message = message if(isturf(loca)) diff --git a/code/game/objects/effects/effect_system/effects_smoke.dm b/code/game/objects/effects/effect_system/effects_smoke.dm index ce2742ace3..438a80e329 100644 --- a/code/game/objects/effects/effect_system/effects_smoke.dm +++ b/code/game/objects/effects/effect_system/effects_smoke.dm @@ -12,7 +12,7 @@ layer = FLY_LAYER anchored = TRUE mouse_opacity = MOUSE_OPACITY_TRANSPARENT - animate_movement = 0 + animate_movement = FALSE var/amount = 4 var/lifetime = 5 var/opaque = 1 //whether the smoke can block the view when in enough amount @@ -49,23 +49,23 @@ lifetime-- if(lifetime < 1) kill_smoke() - return 0 + return FALSE for(var/mob/living/L in range(0,src)) smoke_mob(L) - return 1 + return TRUE /obj/effect/particle_effect/smoke/proc/smoke_mob(mob/living/carbon/C) if(!istype(C)) - return 0 + return FALSE if(lifetime<1) - return 0 + return FALSE if(C.internal != null || C.has_smoke_protection()) - return 0 + return FALSE if(C.smoke_delay) - return 0 + return FALSE C.smoke_delay++ addtimer(CALLBACK(src, .proc/remove_smoke_delay, C), 10) - return 1 + return TRUE /obj/effect/particle_effect/smoke/proc/remove_smoke_delay(mob/living/carbon/C) if(C) @@ -126,11 +126,12 @@ lifetime = 8 /obj/effect/particle_effect/smoke/bad/smoke_mob(mob/living/carbon/M) - if(..()) + . = ..() + if(.) M.drop_all_held_items() M.adjustOxyLoss(1) M.emote("cough") - return 1 + return TRUE /obj/effect/particle_effect/smoke/bad/Crossed(atom/movable/AM, oldloc) . = ..() @@ -148,7 +149,7 @@ /obj/effect/particle_effect/smoke/freezing name = "nanofrost smoke" color = "#B2FFFF" - opaque = 0 + opaque = FALSE /datum/effect_system/smoke_spread/freezing effect_type = /obj/effect/particle_effect/smoke/freezing @@ -226,7 +227,8 @@ /obj/effect/particle_effect/smoke/chem/process() - if(..()) + . = ..() + if(.) var/turf/T = get_turf(src) var/fraction = 1/initial(lifetime) for(var/atom/movable/AM in T) @@ -237,20 +239,20 @@ reagents.expose(AM, TOUCH, fraction) reagents.expose(T, TOUCH, fraction) - return 1 + return TRUE /obj/effect/particle_effect/smoke/chem/smoke_mob(mob/living/carbon/M) if(lifetime<1) - return 0 + return FALSE if(!istype(M)) - return 0 + return FALSE var/mob/living/carbon/C = M if(C.internal != null || C.has_smoke_protection()) - return 0 + return FALSE var/fraction = 1/initial(lifetime) reagents.copy_to(C, fraction*reagents.total_volume) reagents.expose(M, INGEST, fraction) - return 1 + return TRUE diff --git a/code/game/objects/effects/effect_system/effects_water.dm b/code/game/objects/effects/effect_system/effects_water.dm index 44d9c48554..6d71fe9c2c 100644 --- a/code/game/objects/effects/effect_system/effects_water.dm +++ b/code/game/objects/effects/effect_system/effects_water.dm @@ -14,10 +14,10 @@ /obj/effect/particle_effect/water/Move(turf/newloc) if (--src.life < 1) qdel(src) - return 0 + return FALSE if(newloc.density) - return 0 - .=..() + return FALSE + return ..() /obj/effect/particle_effect/water/Bump(atom/A) if(reagents) diff --git a/code/game/objects/effects/effects.dm b/code/game/objects/effects/effects.dm index 7e18077c84..23204da7d0 100644 --- a/code/game/objects/effects/effects.dm +++ b/code/game/objects/effects/effects.dm @@ -5,7 +5,7 @@ icon = 'icons/effects/effects.dmi' resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF | FREEZE_PROOF move_resist = INFINITY - obj_flags = 0 + obj_flags = NONE vis_flags = VIS_INHERIT_PLANE /obj/effect/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1, attack_dir) @@ -18,7 +18,7 @@ return /obj/effect/mech_melee_attack(obj/mecha/M) - return 0 + return /obj/effect/blob_act(obj/structure/blob/B) return @@ -45,7 +45,6 @@ /obj/effect/singularity_act() qdel(src) - return 0 /obj/effect/ConveyorMove() return diff --git a/code/game/objects/effects/overlays.dm b/code/game/objects/effects/overlays.dm index 62cb31f1b6..a036eb0c12 100644 --- a/code/game/objects/effects/overlays.dm +++ b/code/game/objects/effects/overlays.dm @@ -50,8 +50,10 @@ mouse_opacity = MOUSE_OPACITY_TRANSPARENT anchored = TRUE vis_flags = NONE - var/unused = 0 //When detected to be unused it gets set to world.time, after a while it gets removed - var/cache_expiration = 2 MINUTES // overlays which go unused for 2 minutes get cleaned up + ///When detected to be unused it gets set to world.time, after a while it gets removed + var/unused = 0 + ///overlays which go unused for this amount of time get cleaned up + var/cache_expiration = 2 MINUTES /obj/effect/overlay/atmos_excited name = "excited group" diff --git a/code/game/objects/effects/step_triggers.dm b/code/game/objects/effects/step_triggers.dm index f8da95fee3..be6e574d65 100644 --- a/code/game/objects/effects/step_triggers.dm +++ b/code/game/objects/effects/step_triggers.dm @@ -56,7 +56,7 @@ return var/atom/movable/AM = A var/curtiles = 0 - var/stopthrow = 0 + var/stopthrow = FALSE for(var/obj/effect/step_trigger/thrower/T in orange(2, src)) if(AM in T.affecting) return @@ -82,11 +82,11 @@ if(!nostop) for(var/obj/effect/step_trigger/T in get_step(AM, direction)) if(T.stopper && T != src) - stopthrow = 1 + stopthrow = TRUE else for(var/obj/effect/step_trigger/teleporter/T in get_step(AM, direction)) if(T.stopper) - stopthrow = 1 + stopthrow = TRUE if(AM) var/predir = AM.dir diff --git a/code/game/objects/effects/temporary_visuals/cult.dm b/code/game/objects/effects/temporary_visuals/cult.dm index 93bf8c498b..1a77d2427c 100644 --- a/code/game/objects/effects/temporary_visuals/cult.dm +++ b/code/game/objects/effects/temporary_visuals/cult.dm @@ -1,11 +1,11 @@ //temporary visual effects(/obj/effect/temp_visual) used by cult stuff /obj/effect/temp_visual/cult icon = 'icons/effects/cult_effects.dmi' - randomdir = 0 + randomdir = FALSE duration = 10 /obj/effect/temp_visual/cult/sparks - randomdir = 1 + randomdir = TRUE name = "blood sparks" icon_state = "bloodsparkles" diff --git a/code/game/objects/items.dm b/code/game/objects/items.dm index 48dd5f9021..5d5d560ee2 100644 --- a/code/game/objects/items.dm +++ b/code/game/objects/items.dm @@ -460,7 +460,7 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb return ITALICS | REDUCE_RANGE /obj/item/proc/dropped(mob/user, silent = FALSE) - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) for(var/X in actions) var/datum/action/A = X A.Remove(user) @@ -474,7 +474,7 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb /// called just as an item is picked up (loc is not yet changed) /obj/item/proc/pickup(mob/user) - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) SEND_SIGNAL(src, COMSIG_ITEM_PICKUP, user) item_flags |= IN_INVENTORY @@ -491,7 +491,7 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb * * Initial is used to indicate whether or not this is the initial equipment (job datums etc) or just a player doing it */ /obj/item/proc/equipped(mob/user, slot, initial = FALSE) - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) SEND_SIGNAL(src, COMSIG_ITEM_EQUIPPED, user, slot) for(var/X in actions) var/datum/action/A = X diff --git a/code/game/objects/items/RCD.dm b/code/game/objects/items/RCD.dm index d41036342a..ecf8975139 100644 --- a/code/game/objects/items/RCD.dm +++ b/code/game/objects/items/RCD.dm @@ -810,7 +810,7 @@ RLD playsound(src.loc, 'sound/machines/click.ogg', 50, TRUE) if(do_after(user, decondelay, target = A)) if(!useResource(deconcost, user)) - return 0 + return FALSE activate() qdel(A) return TRUE @@ -871,9 +871,9 @@ RLD playsound(src.loc, 'sound/effects/light_flicker.ogg', 50, TRUE) if(do_after(user, floordelay, target = A)) if(!istype(F)) - return 0 + return FALSE if(!useResource(floorcost, user)) - return 0 + return FALSE activate() var/destination = get_turf(A) var/obj/machinery/light/floor/FL = new /obj/machinery/light/floor(destination) diff --git a/code/game/objects/items/airlock_painter.dm b/code/game/objects/items/airlock_painter.dm index fd6ebbf903..94f2045adc 100644 --- a/code/game/objects/items/airlock_painter.dm +++ b/code/game/objects/items/airlock_painter.dm @@ -44,9 +44,9 @@ if(can_use(user)) ink.charges-- playsound(src.loc, 'sound/effects/spray2.ogg', 50, TRUE) - return 1 + return TRUE else - return 0 + return FALSE //This proc only checks if the painter can be used. //Call this if you don't want the painter to be used right after this check, for example @@ -54,12 +54,12 @@ /obj/item/airlock_painter/proc/can_use(mob/user) if(!ink) to_chat(user, "There is no toner cartridge installed in [src]!") - return 0 + return FALSE else if(ink.charges < 1) to_chat(user, "[src] is out of ink!") - return 0 + return FALSE else - return 1 + return TRUE /obj/item/airlock_painter/suicide_act(mob/user) var/obj/item/organ/lungs/L = user.getorganslot(ORGAN_SLOT_LUNGS) diff --git a/code/game/objects/items/body_egg.dm b/code/game/objects/items/body_egg.dm index cc4fd287c8..95bbccf460 100644 --- a/code/game/objects/items/body_egg.dm +++ b/code/game/objects/items/body_egg.dm @@ -14,14 +14,14 @@ if(iscarbon(loc)) Insert(loc) -/obj/item/organ/body_egg/Insert(mob/living/carbon/M, special = 0) +/obj/item/organ/body_egg/Insert(mob/living/carbon/M, special = FALSE) ..() ADD_TRAIT(owner, TRAIT_XENO_HOST, TRAIT_GENERIC) ADD_TRAIT(owner, TRAIT_XENO_IMMUNE, "xeno immune") owner.med_hud_set_status() INVOKE_ASYNC(src, .proc/AddInfectionImages, owner) -/obj/item/organ/body_egg/Remove(mob/living/carbon/M, special = 0) +/obj/item/organ/body_egg/Remove(mob/living/carbon/M, special = FALSE) if(owner) REMOVE_TRAIT(owner, TRAIT_XENO_HOST, TRAIT_GENERIC) REMOVE_TRAIT(owner, TRAIT_XENO_IMMUNE, "xeno immune") diff --git a/code/game/objects/items/chainsaw.dm b/code/game/objects/items/chainsaw.dm index 4cd293dbff..3ca29de015 100644 --- a/code/game/objects/items/chainsaw.dm +++ b/code/game/objects/items/chainsaw.dm @@ -88,5 +88,5 @@ if(attack_type == PROJECTILE_ATTACK) owner.visible_message("Ranged attacks just make [owner] angrier!") playsound(src, pick('sound/weapons/bulletflyby.ogg', 'sound/weapons/bulletflyby2.ogg', 'sound/weapons/bulletflyby3.ogg'), 75, TRUE) - return 1 - return 0 + return TRUE + return FALSE diff --git a/code/game/objects/items/chrono_eraser.dm b/code/game/objects/items/chrono_eraser.dm index 4399e69af0..375d407ef5 100644 --- a/code/game/objects/items/chrono_eraser.dm +++ b/code/game/objects/items/chrono_eraser.dm @@ -112,9 +112,9 @@ var/turf/currentpos = get_turf(src) var/mob/living/user = loc if((currentpos == startpos) && (field in view(CHRONO_BEAM_RANGE, currentpos)) && (user.mobility_flags & MOBILITY_STAND) && (user.stat == CONSCIOUS)) - return 1 + return TRUE field_disconnect(F) - return 0 + return FALSE /obj/item/gun/energy/chrono_gun/proc/pass_mind(datum/mind/M) if(TED) @@ -170,7 +170,6 @@ var/obj/item/gun/energy/chrono_gun/gun = null var/tickstokill = 15 var/mutable_appearance/mob_underlay - var/preloaded = 0 var/RPpos = null var/attached = TRUE //if the gun arg isn't included initially, then the chronofield will work without one diff --git a/code/game/objects/items/cigs_lighters.dm b/code/game/objects/items/cigs_lighters.dm index 79482b3563..b88352ef77 100644 --- a/code/game/objects/items/cigs_lighters.dm +++ b/code/game/objects/items/cigs_lighters.dm @@ -519,7 +519,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM smoketime = 0 chem_volume = 100 list_reagents = null - var/packeditem = 0 + var/packeditem = FALSE /obj/item/clothing/mask/cigarette/pipe/Initialize() . = ..() @@ -537,11 +537,11 @@ CIGARETTE PACKETS ARE IN FANCY.DM if(ismob(loc)) var/mob/living/M = loc to_chat(M, "Your [name] goes out.") - lit = 0 + lit = FALSE icon_state = icon_off inhand_icon_state = icon_off M.update_inv_wear_mask() - packeditem = 0 + packeditem = FALSE name = "empty [initial(name)]" STOP_PROCESSING(SSobj, src) return @@ -557,7 +557,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM if(G.dry == 1) to_chat(user, "You stuff [O] into [src].") smoketime = 400 - packeditem = 1 + packeditem = TRUE name = "[O.name]-packed [initial(name)]" if(O.reagents) O.reagents.trans_to(src, O.reagents.total_volume, transfered_by = user) @@ -580,7 +580,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM var/turf/location = get_turf(user) if(lit) user.visible_message("[user] puts out [src].", "You put out [src].") - lit = 0 + lit = FALSE icon_state = icon_off inhand_icon_state = icon_off STOP_PROCESSING(SSobj, src) @@ -588,7 +588,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM if(!lit && smoketime > 0) to_chat(user, "You empty [src] onto [location].") new /obj/effect/decal/cleanable/ash(location) - packeditem = 0 + packeditem = FALSE smoketime = 0 reagents.clear_reagents() name = "empty [initial(name)]" @@ -626,7 +626,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM light_power = 0.6 light_color = LIGHT_COLOR_FIRE light_on = FALSE - var/lit = 0 + var/lit = FALSE var/fancy = TRUE var/overlay_state var/overlay_list = list( @@ -849,8 +849,8 @@ CIGARETTE PACKETS ARE IN FANCY.DM w_class = WEIGHT_CLASS_TINY var/chem_volume = 100 var/vapetime = 0 //this so it won't puff out clouds every tick - var/screw = 0 // kinky - var/super = 0 //for the fattest vapes dude. + var/screw = FALSE // kinky + var/super = FALSE //for the fattest vapes dude. /obj/item/clothing/mask/vape/suicide_act(mob/user) user.visible_message("[user] is puffin hard on dat vape, [user.p_they()] trying to join the vape life on a whole notha plane!")//it doesn't give you cancer, it is cancer @@ -888,12 +888,12 @@ CIGARETTE PACKETS ARE IN FANCY.DM if(screw && !(obj_flags & EMAGGED))//also kinky if(!super) cut_overlays() - super = 1 + super = TRUE to_chat(user, "You increase the voltage of [src].") add_overlay("vapeopen_med") else cut_overlays() - super = 0 + super = FALSE to_chat(user, "You decrease the voltage of [src].") add_overlay("vapeopen_low") @@ -908,7 +908,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM if(!(obj_flags & EMAGGED)) cut_overlays() obj_flags |= EMAGGED - super = 0 + super = FALSE to_chat(user, "You maximize the voltage of [src].") add_overlay("vapeopen_high") var/datum/effect_system/spark_spread/sp = new /datum/effect_system/spark_spread //for effect diff --git a/code/game/objects/items/devices/camera_bug.dm b/code/game/objects/items/devices/camera_bug.dm index fe2de57337..9302e5cb56 100644 --- a/code/game/objects/items/devices/camera_bug.dm +++ b/code/game/objects/items/devices/camera_bug.dm @@ -62,15 +62,15 @@ /obj/item/camera_bug/check_eye(mob/user) if ( loc != user || user.incapacitated() || user.is_blind() || !current ) user.unset_machine() - return 0 + return FALSE var/turf/T_user = get_turf(user.loc) var/turf/T_current = get_turf(current) if(T_user.z != T_current.z || !current.can_use()) to_chat(user, "[src] has lost the signal.") current = null user.unset_machine() - return 0 - return 1 + return FALSE + return TRUE /obj/item/camera_bug/on_unset_machine(mob/user) user.reset_perspective(null) diff --git a/code/game/objects/items/devices/geiger_counter.dm b/code/game/objects/items/devices/geiger_counter.dm index 48e6d58d48..1425adc604 100644 --- a/code/game/objects/items/devices/geiger_counter.dm +++ b/code/game/objects/items/devices/geiger_counter.dm @@ -161,15 +161,15 @@ if(I.tool_behaviour == TOOL_SCREWDRIVER && (obj_flags & EMAGGED)) if(scanning) to_chat(user, "Turn off [src] before you perform this action!") - return 0 + return FALSE user.visible_message("[user] unscrews [src]'s maintenance panel and begins fiddling with its innards...", "You begin resetting [src]...") if(!I.use_tool(src, user, 40, volume=50)) - return 0 + return FALSE user.visible_message("[user] refastens [src]'s maintenance panel!", "You reset [src] to its factory settings!") obj_flags &= ~EMAGGED radiation_count = 0 update_icon() - return 1 + return TRUE else return ..() @@ -178,7 +178,7 @@ return ..() if(!scanning) to_chat(usr, "[src] must be on to reset its radiation level!") - return 0 + return radiation_count = 0 to_chat(usr, "You flush [src]'s radiation counts, resetting it to normal.") update_icon() @@ -188,7 +188,7 @@ return if(scanning) to_chat(user, "Turn off [src] before you perform this action!") - return 0 + return to_chat(user, "You override [src]'s radiation storing protocols. It will now generate small doses of radiation, and stored rads are now projected into creatures you scan.") obj_flags |= EMAGGED diff --git a/code/game/objects/items/devices/scanners.dm b/code/game/objects/items/devices/scanners.dm index 797168179e..b7656dd7df 100644 --- a/code/game/objects/items/devices/scanners.dm +++ b/code/game/objects/items/devices/scanners.dm @@ -409,7 +409,7 @@ GENE SCANNER if(M.reagents.reagent_list.len) render_list += "Subject contains the following reagents:\n" for(var/datum/reagent/R in M.reagents.reagent_list) - render_list += "[round(R.volume, 0.001)] units of [R.name][R.overdosed == 1 ? " - OVERDOSING" : "."]\n" + render_list += "[round(R.volume, 0.001)] units of [R.name][R.overdosed ? " - OVERDOSING" : "."]\n" else render_list += "Subject contains no reagents.\n" if(M.reagents.addiction_list.len) diff --git a/code/game/objects/items/devices/taperecorder.dm b/code/game/objects/items/devices/taperecorder.dm index 3c4c856eaf..2301a5516d 100644 --- a/code/game/objects/items/devices/taperecorder.dm +++ b/code/game/objects/items/devices/taperecorder.dm @@ -13,13 +13,13 @@ custom_materials = list(/datum/material/iron=60, /datum/material/glass=30) force = 2 throwforce = 0 - var/recording = 0 - var/playing = 0 + var/recording = FALSE + var/playing = FALSE var/playsleepseconds = 0 var/obj/item/tape/mytape var/starting_tape_type = /obj/item/tape/random - var/open_panel = 0 - var/canprint = 1 + var/open_panel = FALSE + var/canprint = TRUE var/list/icons_available = list() var/icon_directory = 'icons/effects/icons.dmi' @@ -47,13 +47,13 @@ else if(!playing) icons_available += list("Record" = image(icon = icon_directory, icon_state = "record")) - + if(playing) icons_available += list("Pause" = image(icon = icon_directory, icon_state = "pause")) else if(!recording) icons_available += list("Play" = image(icon = icon_directory, icon_state = "play")) - + if(canprint && !recording && !playing) icons_available += list("Print Transcript" = image(icon = icon_directory, icon_state = "print")) if(mytape) @@ -147,7 +147,7 @@ mytape.used_capacity++ used++ sleep(10) - recording = 0 + recording = FALSE update_icon() else to_chat(usr, "The tape is full.") @@ -161,13 +161,13 @@ return if(recording) - recording = 0 + recording = FALSE mytape.timestamp += mytape.used_capacity mytape.storedinfo += "\[[time2text(mytape.used_capacity * 10,"mm:ss")]\] Recording stopped." to_chat(usr, "Recording stopped.") return else if(playing) - playing = 0 + playing = FALSE var/turf/T = get_turf(src) T.visible_message("Tape Recorder: Playback stopped.") update_icon() @@ -194,7 +194,7 @@ for(var/i = 1, used < max, sleep(10 * playsleepseconds)) if(!mytape) break - if(playing == 0) + if(playing == FALSE) break if(mytape.storedinfo.len < i) break @@ -211,7 +211,7 @@ playsleepseconds = 1 i++ - playing = 0 + playing = FALSE update_icon() @@ -222,7 +222,7 @@ if(mytape.ruined) to_chat(user, "The tape inside the [src] appears to be broken.") return - + update_available_icons() if(icons_available) var/selection = show_radial_menu(user, src, icons_available, radius = 38, require_near = TRUE, tooltips = TRUE) @@ -289,7 +289,7 @@ var/used_capacity = 0 var/list/storedinfo = list() var/list/timestamp = list() - var/ruined = 0 + var/ruined = FALSE /obj/item/tape/fire_act(exposed_temperature, exposed_volume) ruin() @@ -306,12 +306,12 @@ //repeatedly if(!ruined) add_overlay("ribbonoverlay") - ruined = 1 + ruined = TRUE /obj/item/tape/proc/fix() cut_overlay("ribbonoverlay") - ruined = 0 + ruined = FALSE /obj/item/tape/attackby(obj/item/I, mob/user, params) diff --git a/code/game/objects/items/extinguisher.dm b/code/game/objects/items/extinguisher.dm index b0a55aa5bb..b5bc00308c 100644 --- a/code/game/objects/items/extinguisher.dm +++ b/code/game/objects/items/extinguisher.dm @@ -108,7 +108,7 @@ if(reagents.total_volume == reagents.maximum_volume) to_chat(user, "\The [src] is already full!") safety = safety_save - return 1 + return TRUE var/obj/structure/reagent_dispensers/W = target //will it work? var/transferred = W.reagents.trans_to(src, max_water, transfered_by = user) if(transferred > 0) @@ -119,9 +119,9 @@ else to_chat(user, "\The [W] is empty!") safety = safety_save - return 1 + return TRUE else - return 0 + return FALSE /obj/item/extinguisher/afterattack(atom/target, mob/user , flag) . = ..() diff --git a/code/game/objects/items/grenades/ghettobomb.dm b/code/game/objects/items/grenades/ghettobomb.dm index 80b820d667..cc0d7e335a 100644 --- a/code/game/objects/items/grenades/ghettobomb.dm +++ b/code/game/objects/items/grenades/ghettobomb.dm @@ -13,7 +13,7 @@ throw_range = 7 flags_1 = CONDUCT_1 slot_flags = ITEM_SLOT_BELT - active = 0 + active = FALSE det_time = 50 display_timer = 0 var/check_parts = FALSE diff --git a/code/game/objects/items/implants/implant_chem.dm b/code/game/objects/items/implants/implant_chem.dm index a7f98646d2..44900a5673 100644 --- a/code/game/objects/items/implants/implant_chem.dm +++ b/code/game/objects/items/implants/implant_chem.dm @@ -38,7 +38,7 @@ /obj/item/implant/chem/activate(cause) . = ..() if(!cause || !imp_in) - return 0 + return var/mob/living/carbon/R = imp_in var/injectamount = null if (cause == "action_button") diff --git a/code/game/objects/items/implants/implant_mindshield.dm b/code/game/objects/items/implants/implant_mindshield.dm index 78732e7e94..163940267c 100644 --- a/code/game/objects/items/implants/implant_mindshield.dm +++ b/code/game/objects/items/implants/implant_mindshield.dm @@ -59,8 +59,8 @@ L.sec_hud_set_implants() if(target.stat != DEAD && !silent) to_chat(target, "Your mind suddenly feels terribly vulnerable. You are no longer safe from brainwashing.") - return 1 - return 0 + return TRUE + return FALSE /obj/item/implanter/mindshield name = "implanter (mindshield)" diff --git a/code/game/objects/items/implants/implant_misc.dm b/code/game/objects/items/implants/implant_misc.dm index 87c11c5450..09f910f8c0 100644 --- a/code/game/objects/items/implants/implant_misc.dm +++ b/code/game/objects/items/implants/implant_misc.dm @@ -2,7 +2,7 @@ name = "firearms authentication implant" desc = "Lets you shoot your guns." icon_state = "auth" - activated = 0 + activated = FALSE /obj/item/implant/weapons_auth/get_data() var/dat = {"Implant Specifications:
@@ -67,7 +67,7 @@ /obj/item/implant/health name = "health implant" - activated = 0 + activated = FALSE var/healthstring = "" /obj/item/implant/health/proc/sensehealth() diff --git a/code/game/objects/items/implants/implantchair.dm b/code/game/objects/items/implants/implantchair.dm index 193049d998..2d0b25b958 100644 --- a/code/game/objects/items/implants/implantchair.dm +++ b/code/game/objects/items/implants/implantchair.dm @@ -164,11 +164,11 @@ /obj/machinery/implantchair/genepurge/implant_action(mob/living/carbon/human/H,mob/user) if(!istype(H)) - return 0 + return FALSE H.set_species(/datum/species/human, 1)//lizards go home purrbation_remove(H)//remove cats H.dna.remove_all_mutations()//hulks out - return 1 + return TRUE /obj/machinery/implantchair/brainwash diff --git a/code/game/objects/items/mop.dm b/code/game/objects/items/mop.dm index 540e6bf33e..51b3af2c79 100644 --- a/code/game/objects/items/mop.dm +++ b/code/game/objects/items/mop.dm @@ -13,7 +13,6 @@ attack_verb_continuous = list("mops", "bashes", "bludgeons", "whacks") attack_verb_simple = list("mop", "bash", "bludgeon", "whack") resistance_flags = FLAMMABLE - var/mopping = 0 var/mopcount = 0 var/mopcap = 15 var/mopspeed = 15 diff --git a/code/game/objects/items/robot/robot_parts.dm b/code/game/objects/items/robot/robot_parts.dm index 1e6360c7dd..1e1db65be3 100644 --- a/code/game/objects/items/robot/robot_parts.dm +++ b/code/game/objects/items/robot/robot_parts.dm @@ -256,8 +256,8 @@ if(!O) return if(M.laws && M.laws.id != DEFAULT_AI_LAWID) - aisync = 0 - lawsync = 0 + aisync = FALSE + lawsync = FALSE O.laws = M.laws M.laws.associate(O) @@ -266,14 +266,14 @@ O.custom_name = created_name O.locked = panel_locked if(!aisync) - lawsync = 0 + lawsync = FALSE O.connected_ai = null else O.notify_ai(NEW_BORG) if(forced_ai) O.connected_ai = forced_ai if(!lawsync) - O.lawupdate = 0 + O.lawupdate = FALSE if(M.laws.id == DEFAULT_AI_LAWID) O.make_laws() diff --git a/code/game/objects/items/stacks/rods.dm b/code/game/objects/items/stacks/rods.dm index 2c7758db40..365289345e 100644 --- a/code/game/objects/items/stacks/rods.dm +++ b/code/game/objects/items/stacks/rods.dm @@ -1,8 +1,8 @@ GLOBAL_LIST_INIT(rod_recipes, list ( \ new/datum/stack_recipe("grille", /obj/structure/grille, 2, time = 10, one_per_turf = TRUE, on_floor = FALSE), \ - new/datum/stack_recipe("table frame", /obj/structure/table_frame, 2, time = 10, one_per_turf = 1, on_floor = 1), \ - new/datum/stack_recipe("scooter frame", /obj/item/scooter_frame, 10, time = 25, one_per_turf = 0), \ - new/datum/stack_recipe("linen bin", /obj/structure/bedsheetbin/empty, 2, time = 5, one_per_turf = 0), \ + new/datum/stack_recipe("table frame", /obj/structure/table_frame, 2, time = 10, one_per_turf = TRUE, on_floor = TRUE), \ + new/datum/stack_recipe("scooter frame", /obj/item/scooter_frame, 10, time = 25, one_per_turf = FALSE), \ + new/datum/stack_recipe("linen bin", /obj/structure/bedsheetbin/empty, 2, time = 5, one_per_turf = FALSE), \ new/datum/stack_recipe("railing", /obj/structure/railing, 3, time = 18, window_checks = TRUE), \ )) diff --git a/code/game/objects/items/stacks/sheets/mineral.dm b/code/game/objects/items/stacks/sheets/mineral.dm index c86b3c8fe3..0c27a9b503 100644 --- a/code/game/objects/items/stacks/sheets/mineral.dm +++ b/code/game/objects/items/stacks/sheets/mineral.dm @@ -24,10 +24,10 @@ Mineral Sheets */ GLOBAL_LIST_INIT(sandstone_recipes, list ( \ - new/datum/stack_recipe("pile of dirt", /obj/machinery/hydroponics/soil, 3, time = 10, one_per_turf = 1, on_floor = 1), \ - new/datum/stack_recipe("sandstone door", /obj/structure/mineral_door/sandstone, 10, one_per_turf = 1, on_floor = 1), \ - new/datum/stack_recipe("Assistant Statue", /obj/structure/statue/sandstone/assistant, 5, one_per_turf = 1, on_floor = 1), \ - new/datum/stack_recipe("Breakdown into sand", /obj/item/stack/ore/glass, 1, one_per_turf = 0, on_floor = 1) \ + new/datum/stack_recipe("pile of dirt", /obj/machinery/hydroponics/soil, 3, time = 10, one_per_turf = TRUE, on_floor = TRUE), \ + new/datum/stack_recipe("sandstone door", /obj/structure/mineral_door/sandstone, 10, one_per_turf = TRUE, on_floor = TRUE), \ + new/datum/stack_recipe("Assistant Statue", /obj/structure/statue/sandstone/assistant, 5, one_per_turf = TRUE, on_floor = TRUE), \ + new/datum/stack_recipe("Breakdown into sand", /obj/item/stack/ore/glass, 1, one_per_turf = FALSE, on_floor = TRUE) \ )) /obj/item/stack/sheet/mineral/sandstone diff --git a/code/game/objects/items/stacks/stack.dm b/code/game/objects/items/stacks/stack.dm index 2a9ec5cf4b..376c424e7f 100644 --- a/code/game/objects/items/stacks/stack.dm +++ b/code/game/objects/items/stacks/stack.dm @@ -84,7 +84,7 @@ update_icon() /obj/item/stack/proc/get_main_recipes() - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) return list()//empty list /obj/item/stack/proc/update_weight() @@ -369,8 +369,8 @@ return source.energy < cost if(amount < 1) qdel(src) - return 1 - return 0 + return TRUE + return FALSE /obj/item/stack/proc/add(amount) if (is_cyborg) diff --git a/code/game/objects/items/stacks/wrap.dm b/code/game/objects/items/stacks/wrap.dm index 40f3d8f292..d673021ee1 100644 --- a/code/game/objects/items/stacks/wrap.dm +++ b/code/game/objects/items/stacks/wrap.dm @@ -53,16 +53,16 @@ return SHAME /obj/item/proc/can_be_package_wrapped() //can the item be wrapped with package wrapper into a delivery package - return 1 + return TRUE /obj/item/storage/can_be_package_wrapped() - return 0 + return FALSE /obj/item/storage/box/can_be_package_wrapped() - return 1 + return TRUE /obj/item/small_delivery/can_be_package_wrapped() - return 0 + return FALSE /obj/item/stack/package_wrap/afterattack(obj/target, mob/user, proximity) . = ..() diff --git a/code/game/objects/items/storage/book.dm b/code/game/objects/items/storage/book.dm index d848e06749..15384d7014 100644 --- a/code/game/objects/items/storage/book.dm +++ b/code/game/objects/items/storage/book.dm @@ -158,7 +158,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "burning", if (!heal_mode) return ..() - var/smack = 1 + var/smack = TRUE if (M.stat != DEAD) if(chaplain && user == M) @@ -166,7 +166,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "burning", return if(prob(60) && bless(M, user)) - smack = 0 + smack = FALSE else if(iscarbon(M)) var/mob/living/carbon/C = M if(!istype(C.head, /obj/item/clothing/head/helmet)) diff --git a/code/game/objects/items/storage/boxes.dm b/code/game/objects/items/storage/boxes.dm index 0e1c273fe1..f7bae8b357 100644 --- a/code/game/objects/items/storage/boxes.dm +++ b/code/game/objects/items/storage/boxes.dm @@ -72,7 +72,7 @@ /obj/item/storage/box/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/stack/package_wrap)) - return 0 + return FALSE return ..() //Mime spell boxes diff --git a/code/game/objects/items/storage/secure.dm b/code/game/objects/items/storage/secure.dm index c4df38c448..67b8000bc0 100644 --- a/code/game/objects/items/storage/secure.dm +++ b/code/game/objects/items/storage/secure.dm @@ -17,9 +17,9 @@ var/icon_opened = "secure0" var/code = "" var/l_code = null - var/l_set = 0 - var/l_setshort = 0 - var/l_hacking = 0 + var/l_set = FALSE + var/l_setshort = FALSE + var/l_hacking = FALSE var/open = FALSE w_class = WEIGHT_CLASS_NORMAL desc = "This shouldn't exist. If it does, create an issue report." @@ -44,15 +44,15 @@ if (W.tool_behaviour == TOOL_WIRECUTTER) to_chat(user, "[src] is protected from this sort of tampering, yet it appears the internal memory wires can still be pulsed.") if ((W.tool_behaviour == TOOL_MULTITOOL) && (!l_hacking)) - if(open == 1) + if(open == TRUE) to_chat(user, "Now attempting to reset internal memory, please hold.") - l_hacking = 1 + l_hacking = TRUE if (W.use_tool(src, user, 400)) to_chat(user, "Internal memory reset - lock has been disengaged.") - l_set = 0 - l_hacking = 0 + l_set = FALSE + l_hacking = FALSE else - l_hacking = 0 + l_hacking = FALSE else to_chat(user, "You must unscrew the service panel before you can pulse the wiring!") return @@ -84,10 +84,10 @@ return if (href_list["type"]) if (href_list["type"] == "E") - if ((l_set == 0) && (length(code) == 5) && (!l_setshort) && (code != "ERROR")) + if (!l_set && (length(code) == 5) && (!l_setshort) && (code != "ERROR")) l_code = code - l_set = 1 - else if ((code == l_code) && (l_set == 1)) + l_set = TRUE + else if ((code == l_code) && l_set) SEND_SIGNAL(src, COMSIG_TRY_STORAGE_SET_LOCKSTATE, FALSE) cut_overlays() add_overlay(icon_opened) diff --git a/code/game/objects/items/tanks/watertank.dm b/code/game/objects/items/tanks/watertank.dm index ce2b709512..b33ea6bf97 100644 --- a/code/game/objects/items/tanks/watertank.dm +++ b/code/game/objects/items/tanks/watertank.dm @@ -117,7 +117,7 @@ possible_transfer_amounts = list(25,50,100) volume = 500 item_flags = NOBLUDGEON | ABSTRACT // don't put in storage - slot_flags = 0 + slot_flags = NONE var/obj/item/watertank/tank diff --git a/code/game/objects/items/tools/weldingtool.dm b/code/game/objects/items/tools/weldingtool.dm index d9b6d1d792..a200e63a17 100644 --- a/code/game/objects/items/tools/weldingtool.dm +++ b/code/game/objects/items/tools/weldingtool.dm @@ -213,8 +213,8 @@ set_light_on(FALSE) switched_on(user) update_icon() - return 0 - return 1 + return FALSE + return TRUE //Switches the welder on /obj/item/weldingtool/proc/switched_on(mob/user) @@ -336,7 +336,7 @@ max_fuel = 10 w_class = WEIGHT_CLASS_TINY custom_materials = list(/datum/material/iron=30, /datum/material/glass=10) - change_icons = 0 + change_icons = FALSE /obj/item/weldingtool/mini/flamethrower_screwdriver() return @@ -349,7 +349,7 @@ toolspeed = 0.1 light_system = NO_LIGHT_SUPPORT light_range = 0 - change_icons = 0 + change_icons = FALSE /obj/item/weldingtool/abductor/process() if(get_fuel() <= max_fuel) diff --git a/code/game/objects/items/weaponry.dm b/code/game/objects/items/weaponry.dm index 0f60485e4f..3d12584d25 100644 --- a/code/game/objects/items/weaponry.dm +++ b/code/game/objects/items/weaponry.dm @@ -931,8 +931,8 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301 if(attack_type == PROJECTILE_ATTACK) owner.visible_message("[owner] deflects [attack_text] with [src]!") playsound(src, pick('sound/weapons/bulletflyby.ogg', 'sound/weapons/bulletflyby2.ogg', 'sound/weapons/bulletflyby3.ogg'), 75, TRUE) - return 1 + return TRUE else owner.visible_message("[owner] parries [attack_text] with [src]!") - return 1 - return 0 + return TRUE + return FALSE diff --git a/code/game/objects/structures/artstuff.dm b/code/game/objects/structures/artstuff.dm index 36fd522695..2cb503f7d3 100644 --- a/code/game/objects/structures/artstuff.dm +++ b/code/game/objects/structures/artstuff.dm @@ -220,7 +220,7 @@ desc = "The perfect showcase for your favorite deathtrap memories." icon = 'icons/obj/decals.dmi' custom_materials = list(/datum/material/wood = 2000) - flags_1 = 0 + flags_1 = NONE icon_state = "frame-empty" result_path = /obj/structure/sign/painting diff --git a/code/game/objects/structures/beds_chairs/bed.dm b/code/game/objects/structures/beds_chairs/bed.dm index ae0d17c745..ef079d1270 100644 --- a/code/game/objects/structures/beds_chairs/bed.dm +++ b/code/game/objects/structures/beds_chairs/bed.dm @@ -79,9 +79,9 @@ . = ..() if(over_object == usr && Adjacent(usr)) if(!ishuman(usr) || !usr.canUseTopic(src, BE_CLOSE)) - return 0 + return FALSE if(has_buckled_mobs()) - return 0 + return FALSE usr.visible_message("[usr] collapses \the [src.name].", "You collapse \the [src.name].") var/obj/structure/bed/roller/B = new foldabletype(get_turf(src)) usr.put_in_hands(B) diff --git a/code/game/objects/structures/beds_chairs/chair.dm b/code/game/objects/structures/beds_chairs/chair.dm index a2182bbb14..d9d9c44915 100644 --- a/code/game/objects/structures/beds_chairs/chair.dm +++ b/code/game/objects/structures/beds_chairs/chair.dm @@ -325,8 +325,8 @@ /obj/item/chair/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK) if(attack_type == UNARMED_ATTACK && prob(hit_reaction_chance)) owner.visible_message("[owner] fends off [attack_text] with [src]!") - return 1 - return 0 + return TRUE + return FALSE /obj/item/chair/afterattack(atom/target, mob/living/carbon/user, proximity) . = ..() diff --git a/code/game/objects/structures/crates_lockers/closets.dm b/code/game/objects/structures/crates_lockers/closets.dm index 3eb0242339..252f6a3545 100644 --- a/code/game/objects/structures/crates_lockers/closets.dm +++ b/code/game/objects/structures/crates_lockers/closets.dm @@ -393,8 +393,8 @@ /obj/structure/closet/Exit(atom/movable/AM) open() if(AM.loc == src) - return 0 - return 1 + return FALSE + return TRUE /obj/structure/closet/container_resist_act(mob/living/user) if(opened) diff --git a/code/game/objects/structures/crates_lockers/closets/bodybag.dm b/code/game/objects/structures/crates_lockers/closets/bodybag.dm index 81cc66b9e7..2502d6eee8 100644 --- a/code/game/objects/structures/crates_lockers/closets/bodybag.dm +++ b/code/game/objects/structures/crates_lockers/closets/bodybag.dm @@ -18,7 +18,7 @@ drag_slowdown = 0 var/foldedbag_path = /obj/item/bodybag var/obj/item/bodybag/foldedbag_instance = null - var/tagged = 0 // so closet code knows to put the tag overlay back + var/tagged = FALSE // so closet code knows to put the tag overlay back /obj/structure/closet/body_bag/Destroy() // If we have a stored bag, and it's in nullspace (not in someone's hand), delete it. @@ -38,7 +38,7 @@ return if(t) name = "body bag - [t]" - tagged = 1 + tagged = TRUE update_icon() else name = "body bag" @@ -46,7 +46,7 @@ else if(I.tool_behaviour == TOOL_WIRECUTTER) to_chat(user, "You cut the tag off [src].") name = "body bag" - tagged = 0 + tagged = FALSE update_icon() /obj/structure/closet/body_bag/update_overlays() diff --git a/code/game/objects/structures/fireaxe.dm b/code/game/objects/structures/fireaxe.dm index 45b73f5cae..68cb6568c5 100644 --- a/code/game/objects/structures/fireaxe.dm +++ b/code/game/objects/structures/fireaxe.dm @@ -45,7 +45,7 @@ return to_chat(user, "You start fixing [src]...") if(do_after(user, 20, target = src) && G.use(2)) - broken = 0 + broken = FALSE obj_integrity = max_integrity update_icon() else if(open || broken) @@ -75,7 +75,7 @@ if(BURN) playsound(src.loc, 'sound/items/welder.ogg', 100, TRUE) -/obj/structure/fireaxecabinet/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1, attack_dir) +/obj/structure/fireaxecabinet/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = TRUE, attack_dir) if(open) return . = ..() diff --git a/code/game/objects/structures/girders.dm b/code/game/objects/structures/girders.dm index 833cf07cf6..ef878ed4c4 100644 --- a/code/game/objects/structures/girders.dm +++ b/code/game/objects/structures/girders.dm @@ -361,7 +361,7 @@ var/obj/item/stack/sheet/runed_metal/R = W if(R.get_amount() < 1) to_chat(user, "You need at least one sheet of runed metal to construct a runed wall!") - return 0 + return user.visible_message("[user] begins laying runed metal on [src]...", "You begin constructing a runed wall...") if(do_after(user, 50, target = src)) if(R.get_amount() < 1) @@ -428,7 +428,7 @@ var/obj/item/stack/tile/bronze/B = W if(B.get_amount() < 2) to_chat(user, "You need at least two bronze sheets to build a bronze wall!") - return 0 + return user.visible_message("[user] begins plating [src] with bronze...", "You begin constructing a bronze wall...") if(do_after(user, 50, target = src)) if(B.get_amount() < 2) diff --git a/code/game/objects/structures/guillotine.dm b/code/game/objects/structures/guillotine.dm index 86a2029172..f4779664e5 100644 --- a/code/game/objects/structures/guillotine.dm +++ b/code/game/objects/structures/guillotine.dm @@ -21,7 +21,7 @@ anchored = TRUE density = TRUE max_buckled_mobs = 1 - buckle_lying = FALSE + buckle_lying = 0 buckle_prevents_pull = TRUE layer = ABOVE_MOB_LAYER var/blade_status = GUILLOTINE_BLADE_RAISED diff --git a/code/game/objects/structures/janicart.dm b/code/game/objects/structures/janicart.dm index eedb3c3b43..9d3aa9c6f4 100644 --- a/code/game/objects/structures/janicart.dm +++ b/code/game/objects/structures/janicart.dm @@ -23,13 +23,13 @@ /obj/structure/janitorialcart/proc/wet_mop(obj/item/mop, mob/user) if(reagents.total_volume < 1) to_chat(user, "[src] is out of water!") - return 0 + return FALSE else var/obj/item/mop/M = mop reagents.trans_to(mop, M.mopcap, transfered_by = user) to_chat(user, "You wet [mop] in [src].") playsound(loc, 'sound/effects/slosh.ogg', 25, TRUE) - return 1 + return TRUE /obj/structure/janitorialcart/proc/put_in_cart(obj/item/I, mob/user) if(!user.transferItemToLoc(I, src)) diff --git a/code/game/objects/structures/petrified_statue.dm b/code/game/objects/structures/petrified_statue.dm index c8b8044692..fa30cb34eb 100644 --- a/code/game/objects/structures/petrified_statue.dm +++ b/code/game/objects/structures/petrified_statue.dm @@ -77,28 +77,28 @@ /mob/living/carbon/human/petrify(statue_timer) if(!isturf(loc)) - return 0 + return FALSE var/obj/structure/statue/petrified/S = new(loc, src, statue_timer) S.name = "statue of [name]" bleedsuppress = 1 S.copy_overlays(src) var/newcolor = list(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(0,0,0)) S.add_atom_colour(newcolor, FIXED_COLOUR_PRIORITY) - return 1 + return TRUE /mob/living/carbon/monkey/petrify(statue_timer) if(!isturf(loc)) - return 0 + return FALSE var/obj/structure/statue/petrified/S = new(loc, src, statue_timer) S.name = "statue of a monkey" S.icon_state = "monkey" - return 1 + return TRUE /mob/living/simple_animal/pet/dog/corgi/petrify(statue_timer) if(!isturf(loc)) - return 0 + return FALSE var/obj/structure/statue/petrified/S = new (loc, src, statue_timer) S.name = "statue of a corgi" S.icon_state = "corgi" S.desc = "If it takes forever, I will wait for you..." - return 1 + return TRUE diff --git a/code/game/objects/structures/statues.dm b/code/game/objects/structures/statues.dm index 9c881f7271..edcf6df50e 100644 --- a/code/game/objects/structures/statues.dm +++ b/code/game/objects/structures/statues.dm @@ -227,7 +227,7 @@ material_drop_type = /obj/item/stack/sheet/mineral/bananium impressiveness = 50 desc = "A bananium statue with a small engraving:'HOOOOOOONK'." - var/spam_flag = 0 + var/limiting_spam = FALSE /obj/structure/statue/bananium/clown name = "statue of a clown" @@ -250,10 +250,10 @@ ..() /obj/structure/statue/bananium/proc/honk() - if(!spam_flag) - spam_flag = TRUE + if(!limiting_spam) + limiting_spam = TRUE playsound(src.loc, 'sound/items/bikehorn.ogg', 50, TRUE) - addtimer(VARSET_CALLBACK(src, spam_flag, FALSE), 2 SECONDS) + addtimer(VARSET_CALLBACK(src, limiting_spam, FALSE), 2 SECONDS) /////////////////////sandstone///////////////////////////////////////// diff --git a/code/game/objects/structures/tables_racks.dm b/code/game/objects/structures/tables_racks.dm index d57f8388d1..c69100442d 100644 --- a/code/game/objects/structures/tables_racks.dm +++ b/code/game/objects/structures/tables_racks.dm @@ -536,7 +536,7 @@ canSmoothWith = null can_buckle = 1 buckle_lying = -1 - buckle_requires_restraints = 1 + buckle_requires_restraints = TRUE var/mob/living/carbon/human/patient = null var/obj/machinery/computer/operating/computer = null diff --git a/code/game/objects/structures/transit_tubes/transit_tube_construction.dm b/code/game/objects/structures/transit_tubes/transit_tube_construction.dm index 354a9f98cd..9ed25a0baf 100644 --- a/code/game/objects/structures/transit_tubes/transit_tube_construction.dm +++ b/code/game/objects/structures/transit_tubes/transit_tube_construction.dm @@ -9,7 +9,7 @@ density = FALSE layer = LOW_ITEM_LAYER //same as the built tube anchored = FALSE - var/flipped = 0 + var/flipped = FALSE var/build_type = /obj/structure/transit_tube var/flipped_build_type var/base_icon @@ -62,7 +62,7 @@ /obj/structure/c_transit_tube/station/flipped icon_state = "closed_station1" - flipped = 1 + flipped = TRUE build_type = /obj/structure/transit_tube/station/flipped flipped_build_type = /obj/structure/transit_tube/station @@ -77,7 +77,7 @@ /obj/structure/c_transit_tube/station/reverse/flipped icon_state = "closed_terminus1" - flipped = 1 + flipped = TRUE build_type = /obj/structure/transit_tube/station/reverse/flipped flipped_build_type = /obj/structure/transit_tube/station/reverse @@ -91,7 +91,7 @@ /obj/structure/c_transit_tube/station/dispenser/flipped icon_state = "closed_station1" - flipped = 1 + flipped = TRUE build_type = /obj/structure/transit_tube/station/dispenser/flipped flipped_build_type = /obj/structure/transit_tube/station/dispenser @@ -106,7 +106,7 @@ /obj/structure/c_transit_tube/station/dispenser/reverse/flipped icon_state = "closed_terminus1" - flipped = 1 + flipped = TRUE build_type = /obj/structure/transit_tube/station/dispenser/reverse/flipped flipped_build_type = /obj/structure/transit_tube/station/dispenser/reverse @@ -136,7 +136,7 @@ icon_state = "curved1" build_type = /obj/structure/transit_tube/curved/flipped flipped_build_type = /obj/structure/transit_tube/curved - flipped = 1 + flipped = TRUE /obj/structure/c_transit_tube/junction @@ -148,7 +148,7 @@ /obj/structure/c_transit_tube/junction/flipped icon_state = "junction1" - flipped = 1 + flipped = TRUE build_type = /obj/structure/transit_tube/junction/flipped flipped_build_type = /obj/structure/transit_tube/junction diff --git a/code/game/objects/structures/transit_tubes/transit_tube_pod.dm b/code/game/objects/structures/transit_tubes/transit_tube_pod.dm index 6159e6640a..961a37948b 100644 --- a/code/game/objects/structures/transit_tubes/transit_tube_pod.dm +++ b/code/game/objects/structures/transit_tubes/transit_tube_pod.dm @@ -98,7 +98,7 @@ return ..() /obj/structure/transit_tube_pod/proc/follow_tube() - set waitfor = 0 + set waitfor = FALSE if(moving) return diff --git a/code/game/objects/structures/window.dm b/code/game/objects/structures/window.dm index 092dcf2cbe..499ffe5c04 100644 --- a/code/game/objects/structures/window.dm +++ b/code/game/objects/structures/window.dm @@ -99,9 +99,9 @@ /obj/structure/window/CanAllowThrough(atom/movable/mover, turf/target) . = ..() if(istype(mover) && (mover.pass_flags & PASSGLASS)) - return 1 + return TRUE if(dir == FULLTILE_WINDOW_DIR) - return 0 //full tile window, you can't move into it! + return FALSE //full tile window, you can't move into it! var/attempted_dir = get_dir(loc, target) if(attempted_dir == dir) return @@ -120,10 +120,10 @@ /obj/structure/window/CheckExit(atom/movable/O, turf/target) if(istype(O) && (O.pass_flags & PASSGLASS)) - return 1 + return TRUE if(get_dir(O.loc, target) == dir) - return 0 - return 1 + return FALSE + return TRUE /obj/structure/window/attack_tk(mob/user) user.changeNext_move(CLICK_CD_MELEE) @@ -227,8 +227,8 @@ if(get_dir(user,src) & dir) for(var/obj/O in loc) if(!O.CanPass(user, user.loc, 1)) - return 0 - return 1 + return FALSE + return TRUE /obj/structure/window/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1) . = ..() @@ -337,11 +337,11 @@ /obj/structure/window/CanAStarPass(ID, to_dir) if(!density) - return 1 + return TRUE if((dir == FULLTILE_WINDOW_DIR) || (dir == to_dir)) - return 0 + return FALSE - return 1 + return TRUE /obj/structure/window/GetExplosionBlock() return reinf && fulltile ? real_explosion_block : 0 diff --git a/code/game/turfs/closed/_closed.dm b/code/game/turfs/closed/_closed.dm index e170533278..bb3a77d64d 100644 --- a/code/game/turfs/closed/_closed.dm +++ b/code/game/turfs/closed/_closed.dm @@ -30,7 +30,7 @@ return /turf/closed/indestructible/acid_act(acidpwr, acid_volume, acid_id) - return 0 + return FALSE /turf/closed/indestructible/Melt() to_be_destroyed = FALSE diff --git a/code/game/turfs/closed/minerals.dm b/code/game/turfs/closed/minerals.dm index 5780f3fb12..0cc9ae9be1 100644 --- a/code/game/turfs/closed/minerals.dm +++ b/code/game/turfs/closed/minerals.dm @@ -656,8 +656,8 @@ countdown(notify_admins) -/turf/closed/mineral/gibtonite/proc/countdown(notify_admins = 0) - set waitfor = 0 +/turf/closed/mineral/gibtonite/proc/countdown(notify_admins = FALSE) + set waitfor = FALSE while(istype(src, /turf/closed/mineral/gibtonite) && stage == GIBTONITE_ACTIVE && det_time > 0 && mineralAmt >= 1) det_time-- sleep(5) @@ -679,7 +679,7 @@ det_time = 0 visible_message("The chain reaction stopped! The gibtonite had [det_time] reactions left till the explosion!") -/turf/closed/mineral/gibtonite/gets_drilled(mob/user, triggered_by_explosion = 0) +/turf/closed/mineral/gibtonite/gets_drilled(mob/user, triggered_by_explosion = FALSE) if(stage == GIBTONITE_UNSTRUCK && mineralAmt >= 1) //Gibtonite deposit is activated playsound(src,'sound/effects/hit_on_shattered_glass.ogg',50,TRUE) explosive_reaction(user, triggered_by_explosion) @@ -688,7 +688,7 @@ var/turf/bombturf = get_turf(src) mineralAmt = 0 stage = GIBTONITE_DETONATE - explosion(bombturf,1,2,5, adminlog = 0) + explosion(bombturf,1,2,5, adminlog = FALSE) if(stage == GIBTONITE_STABLE) //Gibtonite deposit is now benign and extractable. Depending on how close you were to it blowing up before defusing, you get better quality ore. var/obj/item/gibtonite/G = new (src) if(det_time <= 0) diff --git a/code/game/turfs/closed/wall/reinf_walls.dm b/code/game/turfs/closed/wall/reinf_walls.dm index 648b3014ea..0c48b1a537 100644 --- a/code/game/turfs/closed/wall/reinf_walls.dm +++ b/code/game/turfs/closed/wall/reinf_walls.dm @@ -59,25 +59,25 @@ d_state = SUPPORT_LINES update_icon() to_chat(user, "You cut the outer grille.") - return 1 + return TRUE if(SUPPORT_LINES) if(W.tool_behaviour == TOOL_SCREWDRIVER) to_chat(user, "You begin unsecuring the support lines...") if(W.use_tool(src, user, 40, volume=100)) if(!istype(src, /turf/closed/wall/r_wall) || d_state != SUPPORT_LINES) - return 1 + return TRUE d_state = COVER update_icon() to_chat(user, "You unsecure the support lines.") - return 1 + return TRUE else if(W.tool_behaviour == TOOL_WIRECUTTER) W.play_tool_sound(src, 100) d_state = INTACT update_icon() to_chat(user, "You repair the outer grille.") - return 1 + return TRUE if(COVER) if(W.tool_behaviour == TOOL_WELDER) @@ -86,32 +86,32 @@ to_chat(user, "You begin slicing through the metal cover...") if(W.use_tool(src, user, 60, volume=100)) if(!istype(src, /turf/closed/wall/r_wall) || d_state != COVER) - return 1 + return TRUE d_state = CUT_COVER update_icon() to_chat(user, "You press firmly on the cover, dislodging it.") - return 1 + return TRUE if(W.tool_behaviour == TOOL_SCREWDRIVER) to_chat(user, "You begin securing the support lines...") if(W.use_tool(src, user, 40, volume=100)) if(!istype(src, /turf/closed/wall/r_wall) || d_state != COVER) - return 1 + return TRUE d_state = SUPPORT_LINES update_icon() to_chat(user, "The support lines have been secured.") - return 1 + return TRUE if(CUT_COVER) if(W.tool_behaviour == TOOL_CROWBAR) to_chat(user, "You struggle to pry off the cover...") if(W.use_tool(src, user, 100, volume=100)) if(!istype(src, /turf/closed/wall/r_wall) || d_state != CUT_COVER) - return 1 + return TRUE d_state = ANCHOR_BOLTS update_icon() to_chat(user, "You pry off the cover.") - return 1 + return TRUE if(W.tool_behaviour == TOOL_WELDER) if(!W.tool_start_check(user, amount=0)) @@ -123,28 +123,28 @@ d_state = COVER update_icon() to_chat(user, "The metal cover has been welded securely to the frame.") - return 1 + return TRUE if(ANCHOR_BOLTS) if(W.tool_behaviour == TOOL_WRENCH) to_chat(user, "You start loosening the anchoring bolts which secure the support rods to their frame...") if(W.use_tool(src, user, 40, volume=100)) if(!istype(src, /turf/closed/wall/r_wall) || d_state != ANCHOR_BOLTS) - return 1 + return TRUE d_state = SUPPORT_RODS update_icon() to_chat(user, "You remove the bolts anchoring the support rods.") - return 1 + return TRUE if(W.tool_behaviour == TOOL_CROWBAR) to_chat(user, "You start to pry the cover back into place...") if(W.use_tool(src, user, 20, volume=100)) if(!istype(src, /turf/closed/wall/r_wall) || d_state != ANCHOR_BOLTS) - return 1 + return TRUE d_state = CUT_COVER update_icon() to_chat(user, "The metal cover has been pried back into place.") - return 1 + return TRUE if(SUPPORT_RODS) if(W.tool_behaviour == TOOL_WELDER) @@ -153,32 +153,32 @@ to_chat(user, "You begin slicing through the support rods...") if(W.use_tool(src, user, 100, volume=100)) if(!istype(src, /turf/closed/wall/r_wall) || d_state != SUPPORT_RODS) - return 1 + return TRUE d_state = SHEATH update_icon() to_chat(user, "You slice through the support rods.") - return 1 + return TRUE if(W.tool_behaviour == TOOL_WRENCH) to_chat(user, "You start tightening the bolts which secure the support rods to their frame...") W.play_tool_sound(src, 100) if(W.use_tool(src, user, 40)) if(!istype(src, /turf/closed/wall/r_wall) || d_state != SUPPORT_RODS) - return 1 + return TRUE d_state = ANCHOR_BOLTS update_icon() to_chat(user, "You tighten the bolts anchoring the support rods.") - return 1 + return TRUE if(SHEATH) if(W.tool_behaviour == TOOL_CROWBAR) to_chat(user, "You struggle to pry off the outer sheath...") if(W.use_tool(src, user, 100, volume=100)) if(!istype(src, /turf/closed/wall/r_wall) || d_state != SHEATH) - return 1 + return TRUE to_chat(user, "You pry off the outer sheath.") dismantle_wall() - return 1 + return TRUE if(W.tool_behaviour == TOOL_WELDER) if(!W.tool_start_check(user, amount=0)) @@ -190,8 +190,8 @@ d_state = SUPPORT_RODS update_icon() to_chat(user, "You weld the support rods back together.") - return 1 - return 0 + return TRUE + return FALSE /turf/closed/wall/r_wall/update_icon() . = ..() diff --git a/code/game/turfs/open/_open.dm b/code/game/turfs/open/_open.dm index dd2a714c55..f80c206dc8 100644 --- a/code/game/turfs/open/_open.dm +++ b/code/game/turfs/open/_open.dm @@ -156,7 +156,7 @@ baseturfs = /turf/open/indestructible/airblock /turf/open/Initalize_Atmos(times_fired) - excited = 0 + excited = FALSE update_visuals() current_cycle = times_fired @@ -207,18 +207,18 @@ /turf/open/handle_slip(mob/living/carbon/C, knockdown_amount, obj/O, lube, paralyze_amount, force_drop) if(C.movement_type & FLYING) - return 0 + return FALSE if(has_gravity(src)) var/obj/buckled_obj if(C.buckled) buckled_obj = C.buckled if(!(lube&GALOSHES_DONT_HELP)) //can't slip while buckled unless it's lube. - return 0 + return FALSE else if(!(lube&SLIP_WHEN_CRAWLING) && (!(C.mobility_flags & MOBILITY_STAND) || !(C.status_flags & CANKNOCKDOWN))) // can't slip unbuckled mob if they're lying or can't fall. - return 0 + return FALSE if(C.m_intent == MOVE_INTENT_WALK && (lube&NO_SLIP_WHEN_WALKING)) - return 0 + return FALSE if(!(lube&SLIDE_ICE)) to_chat(C, "You slipped[ O ? " on the [O.name]" : ""]!") playsound(C.loc, 'sound/misc/slip.ogg', 50, TRUE, -3) @@ -247,7 +247,7 @@ if(C.force_moving) //If we're already slipping extend it qdel(C.force_moving) new /datum/forced_movement(C, get_ranged_target_turf(C, olddir, 1), 1, FALSE) //spinning would be bad for ice, fucks up the next dir - return 1 + return TRUE /turf/open/proc/MakeSlippery(wet_setting = TURF_WET_WATER, min_wet_time = 0, wet_time_to_add = 0, max_wet_time = MAXIMUM_WET_TIME, permanent) AddComponent(/datum/component/wet_floor, wet_setting, min_wet_time, wet_time_to_add, max_wet_time, permanent) diff --git a/code/game/turfs/open/floor.dm b/code/game/turfs/open/floor.dm index 6677a31d26..dc325c53f3 100644 --- a/code/game/turfs/open/floor.dm +++ b/code/game/turfs/open/floor.dm @@ -18,9 +18,9 @@ var/icon_plating = "plating" thermal_conductivity = 0.040 heat_capacity = 10000 - intact = 1 - var/broken = 0 - var/burnt = 0 + intact = TRUE + var/broken = FALSE + var/burnt = FALSE var/floor_tile = null //tile that this floor drops var/list/broken_states var/list/burnt_states @@ -200,8 +200,8 @@ /turf/open/floor/proc/remove_tile(mob/user, silent = FALSE, make_tile = TRUE, force_plating) if(broken || burnt) - broken = 0 - burnt = 0 + broken = FALSE + burnt = FALSE if(user && !silent) to_chat(user, "You remove the broken plating.") else diff --git a/code/game/turfs/open/floor/fancy_floor.dm b/code/game/turfs/open/floor/fancy_floor.dm index e38b0fd8f6..72d042a888 100644 --- a/code/game/turfs/open/floor/fancy_floor.dm +++ b/code/game/turfs/open/floor/fancy_floor.dm @@ -46,8 +46,8 @@ /turf/open/floor/wood/remove_tile(mob/user, silent = FALSE, make_tile = TRUE, force_plating) if(broken || burnt) - broken = 0 - burnt = 0 + broken = FALSE + burnt = FALSE if(user && !silent) to_chat(user, "You remove the broken planks.") else @@ -196,8 +196,9 @@ update_icon() /turf/open/floor/carpet/update_icon() - if(!..()) - return 0 + . = ..() + if(!.) + return if(!broken && !burnt) if(smoothing_flags) QUEUE_SMOOTH(src) diff --git a/code/game/turfs/open/floor/mineral_floor.dm b/code/game/turfs/open/floor/mineral_floor.dm index 89cc708e54..5b4a89651a 100644 --- a/code/game/turfs/open/floor/mineral_floor.dm +++ b/code/game/turfs/open/floor/mineral_floor.dm @@ -24,8 +24,9 @@ /turf/open/floor/mineral/update_icon() - if(!..()) - return 0 + . = ..() + if(!.) + return if(!broken && !burnt) if( !(icon_state in icons) ) icon_state = initial(icon_state) @@ -147,7 +148,7 @@ icon_state = "bananium" floor_tile = /obj/item/stack/tile/mineral/bananium icons = list("bananium","bananium_dam") - var/spam_flag = 0 + var/sound_cooldown = 0 /turf/open/floor/mineral/bananium/Entered(atom/movable/AM) .=..() @@ -171,14 +172,14 @@ honk() /turf/open/floor/mineral/bananium/proc/honk() - if(spam_flag < world.time) + if(sound_cooldown < world.time) playsound(src, 'sound/items/bikehorn.ogg', 50, TRUE) - spam_flag = world.time + 20 + sound_cooldown = world.time + 20 /turf/open/floor/mineral/bananium/proc/squeak() - if(spam_flag < world.time) + if(sound_cooldown < world.time) playsound(src, "clownstep", 50, TRUE) - spam_flag = world.time + 10 + sound_cooldown = world.time + 10 /turf/open/floor/mineral/bananium/airless initial_gas_mix = AIRLESS_ATMOS @@ -226,12 +227,12 @@ /turf/open/floor/mineral/uranium/proc/radiate() if(!active) if(world.time > last_event+15) - active = 1 + active = TRUE radiation_pulse(src, 10) for(var/turf/open/floor/mineral/uranium/T in orange(1,src)) T.radiate() last_event = world.time - active = 0 + active = FALSE return // ALIEN ALLOY diff --git a/code/game/turfs/open/floor/plasteel_floor.dm b/code/game/turfs/open/floor/plasteel_floor.dm index 5c96677878..00614c8039 100644 --- a/code/game/turfs/open/floor/plasteel_floor.dm +++ b/code/game/turfs/open/floor/plasteel_floor.dm @@ -14,8 +14,9 @@ ChangeTurf(/turf/open/floor/plating/rust) /turf/open/floor/plasteel/update_icon() - if(!..()) - return 0 + . = ..() + if(!.) + return if(!broken && !burnt) icon_state = icon_regular_floor diff --git a/code/game/turfs/open/river.dm b/code/game/turfs/open/river.dm index adc6b57960..6e4695b0fe 100644 --- a/code/game/turfs/open/river.dm +++ b/code/game/turfs/open/river.dm @@ -22,22 +22,22 @@ var/obj/effect/landmark/river_waypoint/W = A if (W.z != target_z || W.connected) continue - W.connected = 1 + W.connected = TRUE var/turf/cur_turf = get_turf(W) cur_turf.ChangeTurf(turf_type, new_baseturfs, CHANGETURF_IGNORE_AIR) var/turf/target_turf = get_turf(pick(river_nodes - W)) if(!target_turf) break - var/detouring = 0 + var/detouring = FALSE var/cur_dir = get_dir(cur_turf, target_turf) while(cur_turf != target_turf) if(detouring) //randomly snake around a bit if(prob(20)) - detouring = 0 + detouring = FALSE cur_dir = get_dir(cur_turf, target_turf) else if(prob(20)) - detouring = 1 + detouring = TRUE if(prob(50)) cur_dir = turn(cur_dir, 45) else @@ -48,7 +48,7 @@ cur_turf = get_step(cur_turf, cur_dir) var/area/new_area = get_area(cur_turf) if(!istype(new_area, whitelist_area) || (cur_turf.flags_1 & NO_LAVA_GEN_1)) //Rivers will skip ruins - detouring = 0 + detouring = FALSE cur_dir = get_dir(cur_turf, target_turf) cur_turf = get_step(cur_turf, cur_dir) continue @@ -62,7 +62,7 @@ /obj/effect/landmark/river_waypoint name = "river waypoint" - var/connected = 0 + var/connected = FALSE invisibility = INVISIBILITY_ABSTRACT diff --git a/code/game/turfs/open/space/space.dm b/code/game/turfs/open/space/space.dm index 0519926ca7..356f382c75 100644 --- a/code/game/turfs/open/space/space.dm +++ b/code/game/turfs/open/space/space.dm @@ -206,16 +206,16 @@ /turf/open/space/can_have_cabling() if(locate(/obj/structure/lattice/catwalk, src)) - return 1 - return 0 + return TRUE + return FALSE /turf/open/space/is_transition_turf() if(destination_x || destination_y || destination_z) - return 1 + return TRUE /turf/open/space/acid_act(acidpwr, acid_volume) - return 0 + return FALSE /turf/open/space/get_smooth_underlay_icon(mutable_appearance/underlay_appearance, turf/asking_turf, adjacency_dir) underlay_appearance.icon = 'icons/turf/space.dmi' diff --git a/code/modules/admin/admin_verbs.dm b/code/modules/admin/admin_verbs.dm index 39de5098c5..514b06977b 100644 --- a/code/modules/admin/admin_verbs.dm +++ b/code/modules/admin/admin_verbs.dm @@ -487,7 +487,7 @@ GLOBAL_PROTECT(admin_verbs_hideable) switch(choice) if(null) - return 0 + return if("Small Bomb (1, 2, 3, 3)") explosion(epicenter, 1, 2, 3, 3, TRUE, TRUE) if("Medium Bomb (2, 3, 4, 4)") diff --git a/code/modules/admin/callproc/callproc.dm b/code/modules/admin/callproc/callproc.dm index 1f60597e12..daff5ffeb1 100644 --- a/code/modules/admin/callproc/callproc.dm +++ b/code/modules/admin/callproc/callproc.dm @@ -130,7 +130,7 @@ GLOBAL_PROTECT(LastAdminCalledProc) /client/proc/callproc_datum(datum/A as null|area|mob|obj|turf) set category = "Debug" set name = "Atom ProcCall" - set waitfor = 0 + set waitfor = FALSE if(!check_rights(R_DEBUG)) return diff --git a/code/modules/admin/holder2.dm b/code/modules/admin/holder2.dm index e10c8dc15e..2dab412e0c 100644 --- a/code/modules/admin/holder2.dm +++ b/code/modules/admin/holder2.dm @@ -130,21 +130,21 @@ GLOBAL_PROTECT(href_token) /datum/admins/proc/check_for_rights(rights_required) if(rights_required && !(rights_required & rank.rights)) - return 0 - return 1 + return FALSE + return TRUE /datum/admins/proc/check_if_greater_rights_than_holder(datum/admins/other) if(!other) - return 1 //they have no rights + return TRUE //they have no rights if(rank.rights == R_EVERYTHING) - return 1 //we have all the rights + return TRUE //we have all the rights if(src == other) - return 1 //you always have more rights than yourself + return TRUE //you always have more rights than yourself if(rank.rights != other.rank.rights) if( (rank.rights & other.rank.rights) == other.rank.rights ) - return 1 //we have all the rights they have and more - return 0 + return TRUE //we have all the rights they have and more + return FALSE /datum/admins/vv_edit_var(var_name, var_value) return FALSE //nice try trialmin @@ -166,26 +166,26 @@ you will have to do something like if(client.rights & R_ADMIN) yourself. /proc/check_rights(rights_required, show_msg=1) if(usr && usr.client) if (check_rights_for(usr.client, rights_required)) - return 1 + return TRUE else if(show_msg) to_chat(usr, "Error: You do not have sufficient rights to do that. You require one of the following flags:[rights2text(rights_required," ")].", confidential = TRUE) - return 0 + return FALSE //probably a bit iffy - will hopefully figure out a better solution /proc/check_if_greater_rights_than(client/other) if(usr && usr.client) if(usr.client.holder) if(!other || !other.holder) - return 1 + return TRUE return usr.client.holder.check_if_greater_rights_than_holder(other.holder) - return 0 + return FALSE //This proc checks whether subject has at least ONE of the rights specified in rights_required. /proc/check_rights_for(client/subject, rights_required) if(subject && subject.holder) return subject.holder.check_for_rights(rights_required) - return 0 + return FALSE /proc/GenerateToken() . = "" diff --git a/code/modules/admin/secrets.dm b/code/modules/admin/secrets.dm index 3a51fa91ad..1dbab89d88 100644 --- a/code/modules/admin/secrets.dm +++ b/code/modules/admin/secrets.dm @@ -95,7 +95,7 @@ /datum/admins/proc/Secrets_topic(item,href_list) var/datum/round_event/E - var/ok = 0 + var/ok = FALSE switch(item) if("admin_log") var/dat = "Admin Log
" @@ -290,7 +290,7 @@ for(var/i in GLOB.human_list) var/mob/living/carbon/human/H = i INVOKE_ASYNC(H, /mob/living/carbon.proc/monkeyize) - ok = 1 + ok = TRUE if("allspecies") if(!check_rights(R_FUN)) @@ -709,7 +709,7 @@ to_chat(world, text("A secret has been activated by []!", usr.key), confidential = TRUE) /proc/portalAnnounce(announcement, playlightning) - set waitfor = 0 + set waitfor = FALSE if (playlightning) sound_to_playing_players('sound/magic/lightning_chargeup.ogg') sleep(80) diff --git a/code/modules/admin/verbs/adminhelp.dm b/code/modules/admin/verbs/adminhelp.dm index ae10d77657..76e9a07cd9 100644 --- a/code/modules/admin/verbs/adminhelp.dm +++ b/code/modules/admin/verbs/adminhelp.dm @@ -562,7 +562,7 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new) . = list("total" = list(), "noflags" = list(), "afk" = list(), "stealth" = list(), "present" = list()) for(var/client/X in GLOB.admins) .["total"] += X - if(requiredflags != 0 && !check_rights_for(X, requiredflags)) + if(requiredflags != NONE && !check_rights_for(X, requiredflags)) .["noflags"] += X else if(X.is_afk()) .["afk"] += X diff --git a/code/modules/admin/verbs/debug.dm b/code/modules/admin/verbs/debug.dm index 2677bdc82e..a5676a8e03 100644 --- a/code/modules/admin/verbs/debug.dm +++ b/code/modules/admin/verbs/debug.dm @@ -98,11 +98,11 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that available.Add(C) var/mob/choice = input("Choose a player to play the pAI", "Spawn pAI") in sortNames(available) if(!choice) - return 0 + return if(!isobserver(choice)) var/confirm = input("[choice.key] isn't ghosting right now. Are you sure you want to yank him out of them out of their body and place them in this pAI?", "Spawn pAI Confirmation", "No") in list("Yes", "No") if(confirm != "Yes") - return 0 + return var/obj/item/paicard/card = new(T) var/mob/living/silicon/pai/pai = new(card) @@ -590,12 +590,12 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that for(var/obj/machinery/power/emitter/E in GLOB.machines) if(E.anchored) - E.active = 1 + E.active = TRUE for(var/obj/machinery/field/generator/F in GLOB.machines) - if(F.active == 0) + if(F.active == FALSE) F.set_anchored(TRUE) - F.active = 1 + F.active = TRUE F.state = 2 F.power = 250 F.warming_up = 3 diff --git a/code/modules/admin/verbs/mapping.dm b/code/modules/admin/verbs/mapping.dm index b187de8f6b..843e53ee38 100644 --- a/code/modules/admin/verbs/mapping.dm +++ b/code/modules/admin/verbs/mapping.dm @@ -66,7 +66,7 @@ GLOBAL_PROTECT(admin_verbs_debug_mapping) icon_state = "yellow" /obj/effect/debugging/marker/Move() - return 0 + return FALSE /client/proc/camera_view() set category = "Mapping" @@ -111,7 +111,7 @@ GLOBAL_LIST_EMPTY(dirty_vars) if(!Master) alert(usr,"Master_controller not found.","Sec Camera Report") - return 0 + return FALSE var/list/obj/machinery/camera/CL = list() diff --git a/code/modules/admin/verbs/one_click_antag.dm b/code/modules/admin/verbs/one_click_antag.dm index 89e0827149..cef021f35c 100644 --- a/code/modules/admin/verbs/one_click_antag.dm +++ b/code/modules/admin/verbs/one_click_antag.dm @@ -69,10 +69,10 @@ H.mind.make_Traitor() candidates.Remove(H) - return 1 + return TRUE - return 0 + return FALSE /datum/admins/proc/makeChangelings() @@ -101,9 +101,9 @@ H.mind.make_Changeling() candidates.Remove(H) - return 1 + return TRUE - return 0 + return FALSE /datum/admins/proc/makeRevs() @@ -130,9 +130,9 @@ H = pick(candidates) H.mind.make_Rev() candidates.Remove(H) - return 1 + return TRUE - return 0 + return FALSE /datum/admins/proc/makeWizard() @@ -170,9 +170,9 @@ H.mind.make_Cultist() candidates.Remove(H) - return 1 + return TRUE - return 0 + return FALSE @@ -200,7 +200,7 @@ break //Making sure we have atleast 3 Nuke agents, because less than that is kinda bad if(agentcount < 3) - return 0 + return FALSE //Let's find the spawn locations var/leader_chosen = FALSE @@ -213,9 +213,9 @@ nuke_team = N.nuke_team else new_character.mind.add_antag_datum(/datum/antagonist/nukeop,nuke_team) - return 1 + return TRUE else - return 0 + return FALSE diff --git a/code/modules/admin/verbs/playsound.dm b/code/modules/admin/verbs/playsound.dm index 701351b238..6c992bdab8 100644 --- a/code/modules/admin/verbs/playsound.dm +++ b/code/modules/admin/verbs/playsound.dm @@ -16,7 +16,7 @@ admin_sound.channel = CHANNEL_ADMIN admin_sound.frequency = freq admin_sound.wait = 1 - admin_sound.repeat = 0 + admin_sound.repeat = FALSE admin_sound.status = SOUND_STREAM admin_sound.volume = vol diff --git a/code/modules/admin/verbs/randomverbs.dm b/code/modules/admin/verbs/randomverbs.dm index 52b6eff05c..dd4d7b5bf4 100644 --- a/code/modules/admin/verbs/randomverbs.dm +++ b/code/modules/admin/verbs/randomverbs.dm @@ -300,7 +300,7 @@ else to_chat(usr, "Error: create_xeno(): no suitable candidates.", confidential = TRUE) if(!istext(ckey)) - return 0 + return FALSE var/alien_caste = input(usr, "Please choose which caste to spawn.","Pick a caste",null) as null|anything in list("Queen","Praetorian","Hunter","Sentinel","Drone","Larva") var/obj/effect/landmark/spawn_here = GLOB.xeno_spawn.len ? pick(GLOB.xeno_spawn) : null @@ -319,7 +319,7 @@ if("Larva") new_xeno = new /mob/living/carbon/alien/larva(spawn_here) else - return 0 + return FALSE if(!spawn_here) SSjob.SendToLateJoin(new_xeno, FALSE) @@ -327,7 +327,7 @@ var/msg = "[key_name_admin(usr)] has spawned [ckey] as a filthy xeno [alien_caste]." message_admins(msg) admin_ticket_log(new_xeno, msg) - return 1 + return TRUE /* If a guy was gibbed and you want to revive him, this is a good way to do so. @@ -831,7 +831,7 @@ Traitors and the like can also be revived with the previous role mostly intact. /client/proc/toggle_nuke(obj/machinery/nuclearbomb/N in GLOB.nuke_list) set name = "Toggle Nuke" set category = "Admin - Events" - set popup_menu = 0 + set popup_menu = FALSE if(!check_rights(R_DEBUG)) return diff --git a/code/modules/antagonists/abductor/equipment/abduction_gear.dm b/code/modules/antagonists/abductor/equipment/abduction_gear.dm index 2b3050343c..0523b095fd 100644 --- a/code/modules/antagonists/abductor/equipment/abduction_gear.dm +++ b/code/modules/antagonists/abductor/equipment/abduction_gear.dm @@ -23,7 +23,7 @@ /obj/item/restraints/handcuffs ) var/mode = VEST_STEALTH - var/stealth_active = 0 + var/stealth_active = FALSE var/combat_cooldown = 10 var/datum/icon_snapshot/disguise var/stealth_armor = list(MELEE = 15, BULLET = 15, LASER = 15, ENERGY = 25, BOMB = 15, BIO = 15, RAD = 15, FIRE = 70, ACID = 70) @@ -70,7 +70,7 @@ /obj/item/clothing/suit/armor/abductor/vest/proc/ActivateStealth() if(disguise == null) return - stealth_active = 1 + stealth_active = TRUE if(ishuman(loc)) var/mob/living/carbon/human/M = loc new /obj/effect/temp_visual/dir_setting/ninja/cloak(get_turf(M), M.dir) @@ -84,7 +84,7 @@ /obj/item/clothing/suit/armor/abductor/vest/proc/DeactivateStealth() if(!stealth_active) return - stealth_active = 0 + stealth_active = FALSE if(ishuman(loc)) var/mob/living/carbon/human/M = loc new /obj/effect/temp_visual/dir_setting/ninja(get_turf(M), M.dir) @@ -876,4 +876,4 @@ Congratulations! You are now trained for invasive xenobiology research!"} inhand_icon_state = "bl_suit" worn_icon = 'icons/mob/clothing/under/syndicate.dmi' armor = list(melee = 0, bullet = 0, laser = 0, energy = 0, bomb = 10, bio = 10, rad = 0, fire = 0, acid = 0) - can_adjust = 0 + can_adjust = FALSE diff --git a/code/modules/antagonists/abductor/equipment/abduction_surgery.dm b/code/modules/antagonists/abductor/equipment/abduction_surgery.dm index 641c21bd5b..28e2d17448 100644 --- a/code/modules/antagonists/abductor/equipment/abduction_surgery.dm +++ b/code/modules/antagonists/abductor/equipment/abduction_surgery.dm @@ -6,13 +6,13 @@ /datum/surgery/organ_extraction/can_start(mob/user, mob/living/carbon/target) if(!ishuman(user)) - return 0 + return FALSE var/mob/living/carbon/human/H = user if(H.dna.species.id == "abductor") - return 1 + return TRUE for(var/obj/item/implant/abductor/A in H.implants) - return 1 - return 0 + return TRUE + return FALSE /datum/surgery_step/extract_organ diff --git a/code/modules/antagonists/abductor/equipment/gland.dm b/code/modules/antagonists/abductor/equipment/gland.dm index a9f31b8ecc..0fcb5357c6 100644 --- a/code/modules/antagonists/abductor/equipment/gland.dm +++ b/code/modules/antagonists/abductor/equipment/gland.dm @@ -73,8 +73,8 @@ active_mind_control = FALSE return TRUE -/obj/item/organ/heart/gland/Remove(mob/living/carbon/M, special = 0) - active = 0 +/obj/item/organ/heart/gland/Remove(mob/living/carbon/M, special = FALSE) + active = FALSE if(initial(uses) == 1) uses = initial(uses) var/datum/atom_hud/abductor/hud = GLOB.huds[DATA_HUD_ABDUCTOR] @@ -82,7 +82,7 @@ clear_mind_control() ..() -/obj/item/organ/heart/gland/Insert(mob/living/carbon/M, special = 0) +/obj/item/organ/heart/gland/Insert(mob/living/carbon/M, special = FALSE) ..() if(special != 2 && uses) // Special 2 means abductor surgery Start() @@ -97,14 +97,14 @@ if(!active) return if(!ownerCheck()) - active = 0 + active = FALSE return if(next_activation <= world.time) activate() uses-- next_activation = world.time + rand(cooldown_low,cooldown_high) if(!uses) - active = 0 + active = FALSE /obj/item/organ/heart/gland/proc/activate() return diff --git a/code/modules/antagonists/blob/blobstrains/_blobstrain.dm b/code/modules/antagonists/blob/blobstrains/_blobstrain.dm index f6c6110951..5a2d9b5ede 100644 --- a/code/modules/antagonists/blob/blobstrains/_blobstrain.dm +++ b/code/modules/antagonists/blob/blobstrains/_blobstrain.dm @@ -65,7 +65,7 @@ GLOBAL_LIST_INIT(valid_blobstrains, subtypesof(/datum/blobstrain) - list(/datum/ return /datum/blobstrain/proc/tesla_reaction(obj/structure/blob/B, power, coefficient = 1) //when the blob is hit by a tesla bolt, do this - return 1 //return 0 to ignore damage + return TRUE //return 0 to ignore damage /datum/blobstrain/proc/extinguish_reaction(obj/structure/blob/B, coefficient = 1) //when the blob is hit with water, do this return diff --git a/code/modules/antagonists/blob/blobstrains/energized_jelly.dm b/code/modules/antagonists/blob/blobstrains/energized_jelly.dm index f0ab16706a..1bf4b0b54f 100644 --- a/code/modules/antagonists/blob/blobstrains/energized_jelly.dm +++ b/code/modules/antagonists/blob/blobstrains/energized_jelly.dm @@ -15,7 +15,7 @@ return ..() /datum/blobstrain/reagent/energized_jelly/tesla_reaction(obj/structure/blob/B, power) - return 0 + return FALSE /datum/blobstrain/reagent/energized_jelly/emp_reaction(obj/structure/blob/B, severity) var/damage = rand(30, 50) - severity * rand(10, 15) diff --git a/code/modules/antagonists/blob/overmind.dm b/code/modules/antagonists/blob/overmind.dm index e1c09d065b..9cdacdc988 100644 --- a/code/modules/antagonists/blob/overmind.dm +++ b/code/modules/antagonists/blob/overmind.dm @@ -30,8 +30,8 @@ GLOBAL_LIST_EMPTY(blob_nodes) var/list/resource_blobs = list() var/free_strain_rerolls = 1 //one free strain reroll var/last_reroll_time = 0 //time since we last rerolled, used to give free rerolls - var/nodes_required = 1 //if the blob needs nodes to place resource and factory blobs - var/placed = 0 + var/nodes_required = TRUE //if the blob needs nodes to place resource and factory blobs + var/placed = FALSE var/manualplace_min_time = 600 //in deciseconds //a minute, to get bearings var/autoplace_max_time = 3600 //six minutes, as long as should be needed var/list/blobs_legit = list() @@ -271,13 +271,13 @@ GLOBAL_LIST_EMPTY(blob_nodes) if(B) forceMove(NewLoc) else - return 0 + return FALSE else var/area/A = get_area(NewLoc) if(isspaceturf(NewLoc) || istype(A, /area/shuttle)) //if unplaced, can't go on shuttles or space tiles - return 0 + return FALSE forceMove(NewLoc) - return 1 + return TRUE /mob/camera/blob/mind_initialize() . = ..() diff --git a/code/modules/antagonists/blob/powers.dm b/code/modules/antagonists/blob/powers.dm index 1e542f994c..40de8330ce 100644 --- a/code/modules/antagonists/blob/powers.dm +++ b/code/modules/antagonists/blob/powers.dm @@ -1,15 +1,15 @@ /mob/camera/blob/proc/can_buy(cost = 15) if(blob_points < cost) to_chat(src, "You cannot afford this, you need at least [cost] resources!") - return 0 + return FALSE add_points(-cost) - return 1 + return TRUE // Power verbs /mob/camera/blob/proc/place_blob_core(placement_override, pop_override = FALSE) if(placed && placement_override != -1) - return 1 + return TRUE if(!placement_override) if(!pop_override) for(var/mob/living/M in range(7, src)) @@ -17,34 +17,34 @@ continue if(M.client) to_chat(src, "There is someone too close to place your blob core!") - return 0 + return FALSE for(var/mob/living/M in view(13, src)) if(ROLE_BLOB in M.faction) continue if(M.client) to_chat(src, "Someone could see your blob core from here!") - return 0 + return FALSE var/turf/T = get_turf(src) if(T.density) to_chat(src, "This spot is too dense to place a blob core on!") - return 0 + return FALSE var/area/A = get_area(T) if(isspaceturf(T) || A && !(A.area_flags & BLOBS_ALLOWED)) to_chat(src, "You cannot place your core here!") - return 0 + return FALSE for(var/obj/O in T) if(istype(O, /obj/structure/blob)) if(istype(O, /obj/structure/blob/normal)) qdel(O) else to_chat(src, "There is already a blob here!") - return 0 + return FALSE else if(O.density) to_chat(src, "This spot is too dense to place a blob core on!") - return 0 + return FALSE if(!pop_override && world.time <= manualplace_min_time && world.time <= autoplace_max_time) to_chat(src, "It is too early to place your blob core!") - return 0 + return FALSE else if(placement_override == 1) var/turf/T = pick(GLOB.blobstart) forceMove(T) //got overrided? you're somewhere random, motherfucker @@ -58,7 +58,7 @@ core.update_icon() update_health_hud() placed = 1 - return 1 + return TRUE /mob/camera/blob/verb/transport_core() set category = "Blob" diff --git a/code/modules/antagonists/blob/structures/_blob.dm b/code/modules/antagonists/blob/structures/_blob.dm index 086f3835a0..6336fa4c7a 100644 --- a/code/modules/antagonists/blob/structures/_blob.dm +++ b/code/modules/antagonists/blob/structures/_blob.dm @@ -129,8 +129,8 @@ heal_timestamp = world.time + 20 update_icon() pulse_timestamp = world.time + 10 - return 1 //we did it, we were pulsed! - return 0 //oh no we failed + return TRUE//we did it, we were pulsed! + return FALSE //oh no we failed /obj/structure/blob/proc/ConsumeTile() for(var/atom/A in loc) @@ -163,7 +163,7 @@ else T = null if(!T) - return 0 + return var/make_blob = TRUE //can we make a blob? if(isspaceturf(T) && !(locate(/obj/structure/lattice) in T) && prob(80)) @@ -193,10 +193,10 @@ blob_attack_animation(T, controller) T.blob_act(src) //if we can't move in hit the turf again qdel(B) //we should never get to this point, since we checked before moving in. destroy the blob so we don't have two blobs on one tile - return null + return else blob_attack_animation(T, controller) //if we can't, animate that we attacked - return null + return /obj/structure/blob/emp_act(severity) . = ..() diff --git a/code/modules/antagonists/changeling/changeling.dm b/code/modules/antagonists/changeling/changeling.dm index b9feb88dec..0801c30a09 100644 --- a/code/modules/antagonists/changeling/changeling.dm +++ b/code/modules/antagonists/changeling/changeling.dm @@ -31,8 +31,8 @@ var/changelingID = "Changeling" var/geneticdamage = 0 var/was_absorbed = FALSE //if they were absorbed by another ling already. - var/isabsorbing = 0 - var/islinking = 0 + var/isabsorbing = FALSE + var/islinking = FALSE var/geneticpoints = 10 var/total_geneticspoints = 10 var/total_chem_storage = 75 @@ -210,12 +210,12 @@ if(canrespec) to_chat(owner.current, "We have removed our evolutions from this form, and are now ready to readapt.") reset_powers() - canrespec = 0 + canrespec = FALSE SSblackbox.record_feedback("tally", "changeling_power_purchase", 1, "Readapt") - return 1 + return TRUE else to_chat(owner.current, "You lack the power to readapt your evolutions!") - return 0 + return FALSE //Called in life() /datum/antagonist/changeling/proc/regenerate()//grants the HuD in life.dm @@ -276,7 +276,7 @@ if(verbose) to_chat(user, "[target] is not compatible with our biology.") return - return 1 + return TRUE /datum/antagonist/changeling/proc/create_profile(mob/living/carbon/human/H, protect = 0) @@ -348,8 +348,8 @@ var/datum/changelingprofile/removeprofile = get_profile_to_remove() if(removeprofile) stored_profiles -= removeprofile - return 1 - return 0 + return TRUE + return FALSE /datum/antagonist/changeling/proc/create_initial_profile() @@ -562,9 +562,9 @@ /datum/antagonist/changeling/roundend_report() var/list/parts = list() - var/changelingwin = 1 + var/changelingwin = TRUE if(!owner.current) - changelingwin = 0 + changelingwin = FALSE parts += printplayer(owner) @@ -579,7 +579,7 @@ parts += "Objective #[count]: [objective.explanation_text] Success!" else parts += "Objective #[count]: [objective.explanation_text] Fail." - changelingwin = 0 + changelingwin = FALSE count++ if(changelingwin) diff --git a/code/modules/antagonists/changeling/changeling_power.dm b/code/modules/antagonists/changeling/changeling_power.dm index c03f817b43..4df63b0437 100644 --- a/code/modules/antagonists/changeling/changeling_power.dm +++ b/code/modules/antagonists/changeling/changeling_power.dm @@ -58,10 +58,10 @@ the same goes for Remove(). if you override Remove(), call parent or else your p /datum/action/changeling/proc/sting_action(mob/user, mob/target) SSblackbox.record_feedback("nested tally", "changeling_powers", 1, list("[name]")) - return 0 + return FALSE /datum/action/changeling/proc/sting_feedback(mob/user, mob/target) - return 0 + return FALSE //Fairly important to remember to return 1 on success >.< @@ -91,7 +91,7 @@ the same goes for Remove(). if you override Remove(), call parent or else your p /datum/action/changeling/proc/can_be_used_by(mob/user) if(!user || QDELETED(user)) - return 0 + return FALSE if(!ishuman(user) && !ismonkey(user)) return FALSE if(req_human && !ishuman(user)) diff --git a/code/modules/antagonists/changeling/powers/headcrab.dm b/code/modules/antagonists/changeling/powers/headcrab.dm index 05bb3558a2..22cad0e0b7 100644 --- a/code/modules/antagonists/changeling/powers/headcrab.dm +++ b/code/modules/antagonists/changeling/powers/headcrab.dm @@ -38,6 +38,6 @@ I.forceMove(crab) crab.origin = M if(crab.origin) - crab.origin.active = 1 + crab.origin.active = TRUE crab.origin.transfer_to(crab) to_chat(crab, "You burst out of the remains of your former body in a shower of gore!") diff --git a/code/modules/antagonists/changeling/powers/tiny_prick.dm b/code/modules/antagonists/changeling/powers/tiny_prick.dm index dc2db854d4..0d73cc096f 100644 --- a/code/modules/antagonists/changeling/powers/tiny_prick.dm +++ b/code/modules/antagonists/changeling/powers/tiny_prick.dm @@ -87,12 +87,13 @@ ..() /datum/action/changeling/sting/transformation/can_sting(mob/user, mob/living/carbon/target) - if(!..()) + . = ..() + if(!.) return if((HAS_TRAIT(target, TRAIT_HUSK)) || !iscarbon(target) || (NOTRANSSTING in target.dna.species.species_traits)) to_chat(user, "Our sting appears ineffective against its DNA.") - return 0 - return 1 + return FALSE + return TRUE /datum/action/changeling/sting/transformation/sting_action(mob/user, mob/target) log_combat(user, target, "stung", "transformation sting", " new identity is '[selected_dna.dna.real_name]'") @@ -130,8 +131,8 @@ var/mob/living/L = target if((HAS_TRAIT(L, TRAIT_HUSK)) || !L.has_dna()) to_chat(user, "Our sting appears ineffective against its DNA.") - return 0 - return 1 + return FALSE + return TRUE /datum/action/changeling/sting/false_armblade/sting_action(mob/user, mob/target) log_combat(user, target, "stung", object="false armblade sting") diff --git a/code/modules/antagonists/cult/cult.dm b/code/modules/antagonists/cult/cult.dm index 6ab1d07350..0b030b5e9f 100644 --- a/code/modules/antagonists/cult/cult.dm +++ b/code/modules/antagonists/cult/cult.dm @@ -91,7 +91,7 @@ var/where = mob.equip_in_one_of_slots(T, slots) if(!where) to_chat(mob, "Unfortunately, you weren't able to get a [item_name]. This is very bad and you should adminhelp immediately (press F1).") - return 0 + return FALSE else to_chat(mob, "You have a [item_name] in your [where].") if(where == "backpack") diff --git a/code/modules/antagonists/cult/cult_comms.dm b/code/modules/antagonists/cult/cult_comms.dm index 525457fcbb..7310dc225f 100644 --- a/code/modules/antagonists/cult/cult_comms.dm +++ b/code/modules/antagonists/cult/cult_comms.dm @@ -141,7 +141,7 @@ /datum/action/innate/cult/master/IsAvailable() if(!owner.mind || !owner.mind.has_antag_datum(/datum/antagonist/cult/master) || GLOB.cult_narsie) - return 0 + return FALSE return ..() /datum/action/innate/cult/master/finalreck diff --git a/code/modules/antagonists/cult/cult_items.dm b/code/modules/antagonists/cult/cult_items.dm index 17382d0e88..d7ff7ad141 100644 --- a/code/modules/antagonists/cult/cult_items.dm +++ b/code/modules/antagonists/cult/cult_items.dm @@ -402,8 +402,8 @@ if(!current_charges) owner.visible_message("The runed shield around [owner] suddenly disappears!") owner.update_inv_wear_suit() - return 1 - return 0 + return TRUE + return FALSE /obj/item/clothing/suit/hooded/cultrobes/cult_shield/worn_overlays(isinhands) . = list() diff --git a/code/modules/antagonists/cult/runes.dm b/code/modules/antagonists/cult/runes.dm index f3865f348d..a51cd0bb8a 100644 --- a/code/modules/antagonists/cult/runes.dm +++ b/code/modules/antagonists/cult/runes.dm @@ -230,12 +230,12 @@ structure_check() searches for nearby cultist structures required for the invoca for(var/M in invokers) to_chat(M, "You need at least two invokers to convert [convertee]!") log_game("Offer rune failed - tried conversion with one invoker") - return 0 + return FALSE if(convertee.anti_magic_check(TRUE, TRUE, FALSE, 0)) //Not chargecost because it can be spammed for(var/M in invokers) to_chat(M, "Something is shielding [convertee]'s mind!") log_game("Offer rune failed - convertee had anti-magic") - return 0 + return FALSE var/brutedamage = convertee.getBruteLoss() var/burndamage = convertee.getFireLoss() if(brutedamage || burndamage) @@ -258,7 +258,7 @@ structure_check() searches for nearby cultist structures required for the invoca H.cultslurring = 0 if(prob(1) || SSevents.holidays && SSevents.holidays[APRIL_FOOLS]) H.say("You son of a bitch! I'm in.", forced = "That son of a bitch! They're in.") - return 1 + return TRUE /obj/effect/rune/convert/proc/do_sacrifice(mob/living/sacrificial, list/invokers) var/mob/living/first_invoker = invokers[1] diff --git a/code/modules/antagonists/devil/devil.dm b/code/modules/antagonists/devil/devil.dm index 1f5f68a39f..0add4f4a82 100644 --- a/code/modules/antagonists/devil/devil.dm +++ b/code/modules/antagonists/devil/devil.dm @@ -386,43 +386,43 @@ GLOBAL_LIST_INIT(devil_suffix, list(" the Red", " the Soulless", " the Master", if(iscarbon(body)) var/mob/living/carbon/H = body return H.reagents.has_reagent(/datum/reagent/water/holywater) - return 0 + return FALSE if(BANISH_COFFIN) return (body && istype(body.loc, /obj/structure/closet/crate/coffin)) if(BANISH_FORMALDYHIDE) if(iscarbon(body)) var/mob/living/carbon/H = body return H.reagents.has_reagent(/datum/reagent/toxin/formaldehyde) - return 0 + return FALSE if(BANISH_RUNES) if(body) for(var/obj/effect/decal/cleanable/crayon/R in range(0,body)) if (R.name == "rune") - return 1 - return 0 + return TRUE + return FALSE if(BANISH_CANDLES) if(body) var/count = 0 for(var/obj/item/candle/C in range(1,body)) count += C.lit if(count>=4) - return 1 - return 0 + return TRUE + return FALSE if(BANISH_DESTRUCTION) if(body) - return 0 - return 1 + return FALSE + return TRUE if(BANISH_FUNERAL_GARB) if(ishuman(body)) var/mob/living/carbon/human/H = body if(H.w_uniform && istype(H.w_uniform, /obj/item/clothing/under/misc/burial)) - return 1 - return 0 + return TRUE + return FALSE else for(var/obj/item/clothing/under/misc/burial/B in range(0,body)) if(B.loc == get_turf(B)) //Make sure it's not in someone's inventory or something. - return 1 - return 0 + return TRUE + return FALSE /datum/antagonist/devil/proc/hellish_resurrection(mob/living/body) message_admins("[key_name_admin(owner)] (true name is: [truename]) is resurrecting using hellish energy.") diff --git a/code/modules/antagonists/devil/true_devil/_true_devil.dm b/code/modules/antagonists/devil/true_devil/_true_devil.dm index a937c9c39d..eed7939a69 100644 --- a/code/modules/antagonists/devil/true_devil/_true_devil.dm +++ b/code/modules/antagonists/devil/true_devil/_true_devil.dm @@ -119,7 +119,7 @@ return ..() //flashes don't stop devils UNLESS it's their bane. /mob/living/carbon/true_devil/soundbang_act() - return 0 + return FALSE /mob/living/carbon/true_devil/get_ear_protection() return 2 @@ -146,7 +146,7 @@ /mob/living/carbon/true_devil/singularity_act() if(ascended) - return 0 + return FALSE return ..() //ATTACK GHOST IGNORING PARENT RETURN VALUE diff --git a/code/modules/antagonists/devil/true_devil/inventory.dm b/code/modules/antagonists/devil/true_devil/inventory.dm index a3d0dbdf58..b680a2c10e 100644 --- a/code/modules/antagonists/devil/true_devil/inventory.dm +++ b/code/modules/antagonists/devil/true_devil/inventory.dm @@ -1,8 +1,7 @@ /mob/living/carbon/true_devil/doUnEquip(obj/item/I, force, newloc, no_move, invdrop = TRUE, silent = FALSE) - if(..()) + . = ..() + if(.) update_inv_hands() - return 1 - return 0 /mob/living/carbon/true_devil/update_inv_hands() //TODO LORDPIDEY: Figure out how to make the hands line up properly. the l/r_hand_overlay should use the down sprite when facing down, left, or right, and the up sprite when facing up. diff --git a/code/modules/antagonists/morph/morph.dm b/code/modules/antagonists/morph/morph.dm index d6a9d9ee72..f2afc164eb 100644 --- a/code/modules/antagonists/morph/morph.dm +++ b/code/modules/antagonists/morph/morph.dm @@ -230,7 +230,7 @@ var/mob/dead/selected = pick_n_take(candidates) var/datum/mind/player_mind = new /datum/mind(selected.key) - player_mind.active = 1 + player_mind.active = TRUE if(!GLOB.xeno_spawn) return MAP_ERROR var/mob/living/simple_animal/hostile/morph/S = new /mob/living/simple_animal/hostile/morph(pick(GLOB.xeno_spawn)) diff --git a/code/modules/antagonists/ninja/ninja.dm b/code/modules/antagonists/ninja/ninja.dm index 3a1c8fec4d..110673043a 100644 --- a/code/modules/antagonists/ninja/ninja.dm +++ b/code/modules/antagonists/ninja/ninja.dm @@ -38,9 +38,9 @@ if(M.current && M.current.stat != DEAD) if(ishuman(M.current)) if(M.special_role) - possible_targets[M] = 0 //bad-guy + possible_targets[M] = FALSE //bad-guy else if(M.assigned_role in GLOB.command_positions) - possible_targets[M] = 1 //good-guy + possible_targets[M] = TRUE //good-guy var/list/possible_objectives = list(1,2,3,4) diff --git a/code/modules/antagonists/revenant/revenant.dm b/code/modules/antagonists/revenant/revenant.dm index 07a8f40027..475ed7ebbb 100644 --- a/code/modules/antagonists/revenant/revenant.dm +++ b/code/modules/antagonists/revenant/revenant.dm @@ -223,7 +223,7 @@ /mob/living/simple_animal/revenant/death() if(!revealed || stasis) //Revenants cannot die if they aren't revealed //or are already dead - return 0 + return stasis = TRUE to_chat(src, "NO! No... it's too late, you can feel your essence [pick("breaking apart", "drifting away")]...") notransform = TRUE diff --git a/code/modules/antagonists/slaughter/slaughterevent.dm b/code/modules/antagonists/slaughter/slaughterevent.dm index aeda14e67f..8015b9d6a7 100644 --- a/code/modules/antagonists/slaughter/slaughterevent.dm +++ b/code/modules/antagonists/slaughter/slaughterevent.dm @@ -20,7 +20,7 @@ var/mob/dead/selected = pick_n_take(candidates) var/datum/mind/player_mind = new /datum/mind(selected.key) - player_mind.active = 1 + player_mind.active = TRUE var/list/spawn_locs = list() for(var/obj/effect/landmark/carpspawn/L in GLOB.landmarks_list) diff --git a/code/modules/antagonists/wizard/equipment/artefact.dm b/code/modules/antagonists/wizard/equipment/artefact.dm index d2979a59c9..7afcf80b6c 100644 --- a/code/modules/antagonists/wizard/equipment/artefact.dm +++ b/code/modules/antagonists/wizard/equipment/artefact.dm @@ -20,7 +20,7 @@ var/spawn_amt = 1 var/activate_descriptor = "reality" var/rend_desc = "You should run now." - var/spawn_fast = 0 //if 1, ignores checking for mobs on loc before spawning + var/spawn_fast = FALSE //if TRUE, ignores checking for mobs on loc before spawning /obj/item/veilrender/attack_self(mob/user) if(charges > 0) @@ -39,7 +39,7 @@ anchored = TRUE var/spawn_path = /mob/living/simple_animal/cow //defaulty cows to prevent unintentional narsies var/spawn_amt_left = 20 - var/spawn_fast = 0 + var/spawn_fast = FALSE /obj/effect/rend/New(loc, spawn_type, spawn_amt, desc, spawn_fast) src.spawn_path = spawn_type diff --git a/code/modules/antagonists/wizard/equipment/soulstone.dm b/code/modules/antagonists/wizard/equipment/soulstone.dm index 4c19964544..d799ef6798 100644 --- a/code/modules/antagonists/wizard/equipment/soulstone.dm +++ b/code/modules/antagonists/wizard/equipment/soulstone.dm @@ -297,7 +297,7 @@ newstruct.cancel_camera() -/obj/item/soulstone/proc/init_shade(mob/living/carbon/human/T, mob/user, message_user = 0 , mob/shade_controller) +/obj/item/soulstone/proc/init_shade(mob/living/carbon/human/T, mob/user, message_user = FALSE, mob/shade_controller) if(!shade_controller) shade_controller = T new /obj/effect/decal/remains/human(T.loc) //Spawns a skeleton diff --git a/code/modules/atmospherics/environmental/LINDA_turf_tile.dm b/code/modules/atmospherics/environmental/LINDA_turf_tile.dm index 9b7eceb05b..d32f929861 100644 --- a/code/modules/atmospherics/environmental/LINDA_turf_tile.dm +++ b/code/modules/atmospherics/environmental/LINDA_turf_tile.dm @@ -285,7 +285,7 @@ var/const/PROBABILITY_OFFSET = 25 var/const/PROBABILITY_BASE_PRECENT = 75 var/max_force = sqrt(pressure_difference)*(MOVE_FORCE_DEFAULT / 5) - set waitfor = 0 + set waitfor = FALSE var/move_prob = 100 if (pressure_resistance > 0) move_prob = (pressure_difference/pressure_resistance*PROBABILITY_BASE_PRECENT)-PROBABILITY_OFFSET diff --git a/code/modules/atmospherics/gasmixtures/gas_mixture.dm b/code/modules/atmospherics/gasmixtures/gas_mixture.dm index 5085442516..9f5a5122c9 100644 --- a/code/modules/atmospherics/gasmixtures/gas_mixture.dm +++ b/code/modules/atmospherics/gasmixtures/gas_mixture.dm @@ -105,7 +105,7 @@ GLOBAL_LIST_INIT(gaslist_cache, init_gaslist_cache()) /// Calculate pressure in kilopascals /datum/gas_mixture/proc/return_pressure() - if(volume > 0) // to prevent division by zero + if(volume) // to prevent division by zero var/cached_gases = gases TOTAL_MOLES(cached_gases, .) . *= R_IDEAL_GAS_EQUATION * temperature / volume @@ -132,12 +132,12 @@ GLOBAL_LIST_INIT(gaslist_cache, init_gaslist_cache()) for(var/id in cached_gases) cached_gases[id][ARCHIVE] = cached_gases[id][MOLES] - return 1 + return TRUE ///Merges all air from giver into self. Deletes giver. Returns: 1 if we are mutable, 0 otherwise /datum/gas_mixture/proc/merge(datum/gas_mixture/giver) if(!giver) - return 0 + return FALSE //heat transfer if(abs(temperature - giver.temperature) > MINIMUM_TEMPERATURE_DELTA_TO_CONSIDER) @@ -154,7 +154,7 @@ GLOBAL_LIST_INIT(gaslist_cache, init_gaslist_cache()) ASSERT_GAS(giver_id, src) cached_gases[giver_id][MOLES] += giver_gases[giver_id][MOLES] - return 1 + return TRUE ///Proportionally removes amount of gas from the gas_mixture. ///Returns: gas_mixture with the gases removed diff --git a/code/modules/atmospherics/gasmixtures/immutable_mixtures.dm b/code/modules/atmospherics/gasmixtures/immutable_mixtures.dm index dcea095d3c..66ed5bc1c6 100644 --- a/code/modules/atmospherics/gasmixtures/immutable_mixtures.dm +++ b/code/modules/atmospherics/gasmixtures/immutable_mixtures.dm @@ -15,29 +15,29 @@ gases.Cut() /datum/gas_mixture/immutable/archive() - return 1 //nothing changes, so we do nothing and the archive is successful + return TRUE //nothing changes, so we do nothing and the archive is successful /datum/gas_mixture/immutable/merge() - return 0 //we're immutable. + return FALSE //we're immutable. /datum/gas_mixture/immutable/share(datum/gas_mixture/sharer, atmos_adjacent_turfs = 4) . = ..(sharer, 0) garbage_collect() /datum/gas_mixture/immutable/react() - return 0 //we're immutable. + return FALSE //we're immutable. /datum/gas_mixture/immutable/copy() return new type //we're immutable, so we can just return a new instance. /datum/gas_mixture/immutable/copy_from() - return 0 //we're immutable. + return FALSE //we're immutable. /datum/gas_mixture/immutable/copy_from_turf() - return 0 //we're immutable. + return FALSE //we're immutable. /datum/gas_mixture/immutable/parse_gas_string() - return 0 //we're immutable. + return FALSE //we're immutable. /datum/gas_mixture/immutable/temperature_share(datum/gas_mixture/sharer, conduction_coefficient, sharer_temperature, sharer_heat_capacity) . = ..() diff --git a/code/modules/atmospherics/machinery/airalarm.dm b/code/modules/atmospherics/machinery/airalarm.dm index b1a3c90711..5faac36c2f 100644 --- a/code/modules/atmospherics/machinery/airalarm.dm +++ b/code/modules/atmospherics/machinery/airalarm.dm @@ -448,16 +448,16 @@ /obj/machinery/airalarm/proc/shock(mob/user, prb) if((machine_stat & (NOPOWER))) // unpowered, no shock - return 0 + return FALSE if(!prob(prb)) - return 0 //you lucked out, no shock for you + return FALSE //you lucked out, no shock for you var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread s.set_up(5, 1, src) s.start() //sparks always. if (electrocute_mob(user, get_area(src), src, 1, TRUE)) - return 1 + return TRUE else - return 0 + return FALSE /obj/machinery/airalarm/proc/set_frequency(new_frequency) SSradio.remove_object(src, frequency) @@ -466,7 +466,7 @@ /obj/machinery/airalarm/proc/send_signal(target, list/command, atom/user)//sends signal 'command' to 'target'. Returns 0 if no radio connection, 1 otherwise if(!radio_connection) - return 0 + return FALSE var/datum/signal/signal = new(command) signal.data["tag"] = target @@ -474,7 +474,7 @@ signal.data["user"] = user radio_connection.post_signal(src, signal, RADIO_FROM_AIRALARM) - return 1 + return TRUE /obj/machinery/airalarm/proc/get_mode_name(mode_value) switch(mode_value) diff --git a/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm b/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm index 4597c0cc40..db4b1dc8fd 100644 --- a/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm +++ b/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm @@ -484,7 +484,7 @@ return // can't ventcrawl in or out of cryo. /obj/machinery/atmospherics/components/unary/cryo_cell/can_see_pipes() - return 0 // you can't see the pipe network when inside a cryo cell. + return FALSE // you can't see the pipe network when inside a cryo cell. /obj/machinery/atmospherics/components/unary/cryo_cell/return_temperature() var/datum/gas_mixture/G = airs[1] diff --git a/code/modules/atmospherics/machinery/components/unary_devices/vent_scrubber.dm b/code/modules/atmospherics/machinery/components/unary_devices/vent_scrubber.dm index 260c8a589d..483d86b91a 100644 --- a/code/modules/atmospherics/machinery/components/unary_devices/vent_scrubber.dm +++ b/code/modules/atmospherics/machinery/components/unary_devices/vent_scrubber.dm @@ -218,7 +218,7 @@ /obj/machinery/atmospherics/components/unary/vent_scrubber/receive_signal(datum/signal/signal) if(!is_operational || !signal.data["tag"] || (signal.data["tag"] != id_tag) || (signal.data["sigtype"]!="command")) - return 0 + return var/atom/signal_sender = signal.data["user"] diff --git a/code/modules/atmospherics/machinery/other/meter.dm b/code/modules/atmospherics/machinery/other/meter.dm index 17687f5f5d..2a7f3602b4 100644 --- a/code/modules/atmospherics/machinery/other/meter.dm +++ b/code/modules/atmospherics/machinery/other/meter.dm @@ -55,18 +55,18 @@ /obj/machinery/meter/process_atmos() if(!(target?.flags_1 & INITIALIZED_1)) icon_state = "meterX" - return 0 + return FALSE if(machine_stat & (BROKEN|NOPOWER)) icon_state = "meter0" - return 0 + return FALSE use_power(5) var/datum/gas_mixture/environment = target.return_air() if(!environment) icon_state = "meterX" - return 0 + return FALSE var/env_pressure = environment.return_pressure() if(env_pressure <= 0.15*ONE_ATMOSPHERE) diff --git a/code/modules/atmospherics/machinery/pipes/pipes.dm b/code/modules/atmospherics/machinery/pipes/pipes.dm index a8db804a53..55f39a5550 100644 --- a/code/modules/atmospherics/machinery/pipes/pipes.dm +++ b/code/modules/atmospherics/machinery/pipes/pipes.dm @@ -8,8 +8,8 @@ var/datum/pipeline/parent = null //Buckling - can_buckle = 1 - buckle_requires_restraints = 1 + can_buckle = TRUE + buckle_requires_restraints = TRUE buckle_lying = -1 /obj/machinery/atmospherics/pipe/New() diff --git a/code/modules/awaymissions/mission_code/Academy.dm b/code/modules/awaymissions/mission_code/Academy.dm index 0d8c5fcd0f..2c93f33367 100644 --- a/code/modules/awaymissions/mission_code/Academy.dm +++ b/code/modules/awaymissions/mission_code/Academy.dm @@ -62,9 +62,9 @@ /obj/singularity/academy - dissipate = 0 - move_self = 0 - grav_pull = 1 + dissipate = FALSE + move_self = FALSE + grav_pull = TRUE /obj/singularity/academy/admin_investigate_setup() return diff --git a/code/modules/awaymissions/mission_code/Cabin.dm b/code/modules/awaymissions/mission_code/Cabin.dm index 5194b7348e..33dfa19b50 100644 --- a/code/modules/awaymissions/mission_code/Cabin.dm +++ b/code/modules/awaymissions/mission_code/Cabin.dm @@ -122,8 +122,8 @@ /datum/map_generator_module/snow/checkPlaceAtom(turf/T) if(istype(T, /turf/open/floor/plating/asteroid/snow)) - return ..(T) - return 0 + return ..() + return FALSE /datum/map_generator_module/bottomlayer/snow spawnableTurfs = list(/turf/open/floor/plating/asteroid/snow/atmosphere = 100) diff --git a/code/modules/awaymissions/mission_code/stationCollision.dm b/code/modules/awaymissions/mission_code/stationCollision.dm index c13dda15ba..4858ec39dd 100644 --- a/code/modules/awaymissions/mission_code/stationCollision.dm +++ b/code/modules/awaymissions/mission_code/stationCollision.dm @@ -43,8 +43,7 @@ name ="retro laser" icon_state = "retro" desc = "An older model of the basic lasergun, no longer used by Nanotrasen's security or military forces." -// projectile_type = "/obj/projectile/practice" - clumsy_check = 0 //No sense in having a harmless gun blow up in the clowns face + clumsy_check = FALSE //No sense in having a harmless gun blow up in the clowns face //Syndicate sub-machine guns. /obj/item/gun/ballistic/automatic/c20r/sc_c20r @@ -68,7 +67,7 @@ /obj/item/gun/energy/laser/practice/sc_laser name = "Old laser" desc = "A once potent weapon, years of dust have collected in the chamber and lens of this weapon, weakening the beam significantly." - clumsy_check = 0 + clumsy_check = FALSE /* * Safe code hints diff --git a/code/modules/client/client_procs.dm b/code/modules/client/client_procs.dm index 03fa982b2a..923882a4f1 100644 --- a/code/modules/client/client_procs.dm +++ b/code/modules/client/client_procs.dm @@ -125,8 +125,8 @@ GLOBAL_LIST_INIT(blacklisted_builds, list( /client/proc/is_content_unlocked() if(!prefs.unlock_content) to_chat(src, "Become a BYOND member to access member-perks and features, as well as support the engine that makes this game possible. Only 10 bucks for 3 months! Click Here to find out more.") - return 0 - return 1 + return FALSE + return TRUE /* * Call back proc that should be checked in all paths where a client can send messages * @@ -157,11 +157,11 @@ GLOBAL_LIST_INIT(blacklisted_builds, list( total_message_count = 0 total_count_reset = 0 cmd_admin_mute(src, mute_type, 1) - return 1 + return TRUE //Otherwise just supress the message else if(cache >= SPAM_TRIGGER_AUTOMUTE) - return 1 + return TRUE if(CONFIG_GET(flag/automute_on) && !holder && last_message == message) @@ -169,21 +169,21 @@ GLOBAL_LIST_INIT(blacklisted_builds, list( if(src.last_message_count >= SPAM_TRIGGER_AUTOMUTE) to_chat(src, "You have exceeded the spam filter limit for identical messages. An auto-mute was applied.") cmd_admin_mute(src, mute_type, 1) - return 1 + return TRUE if(src.last_message_count >= SPAM_TRIGGER_WARNING) to_chat(src, "You are nearing the spam filter limit for identical messages.") - return 0 + return FALSE else last_message = message src.last_message_count = 0 - return 0 + return FALSE //This stops files larger than UPLOAD_LIMIT being sent from client to server via input(), client.Import() etc. /client/AllowUpload(filename, filelength) if(filelength > UPLOAD_LIMIT) to_chat(src, "Error: AllowUpload(): File Upload too large. Upload Limit: [UPLOAD_LIMIT/1024]KiB.") - return 0 - return 1 + return FALSE + return TRUE /////////// @@ -333,7 +333,7 @@ GLOBAL_LIST_INIT(blacklisted_builds, list( to_chat(src, "Because you are an admin, you are being allowed to walk past this limitation, But it is still STRONGLY suggested you upgrade") else qdel(src) - return 0 + return else if (byond_version < cwv) //We have words for this client. if(CONFIG_GET(flag/client_warn_popup)) var/msg = "Your version of byond may be getting out of date:
" @@ -353,11 +353,11 @@ GLOBAL_LIST_INIT(blacklisted_builds, list( if (!CONFIG_GET(flag/allow_webclient)) to_chat(src, "Web client is disabled") qdel(src) - return 0 + return if (CONFIG_GET(flag/webclient_only_byond_members) && !IsByondMember()) to_chat(src, "Sorry, but the web client is restricted to byond members only.") qdel(src) - return 0 + return if( (world.address == address || !address) && !GLOB.host ) GLOB.host = key diff --git a/code/modules/client/verbs/suicide.dm b/code/modules/client/verbs/suicide.dm index 625e448c5d..0cf9013d36 100644 --- a/code/modules/client/verbs/suicide.dm +++ b/code/modules/client/verbs/suicide.dm @@ -1,4 +1,4 @@ -/mob/var/suiciding = 0 +/mob/var/suiciding = FALSE /mob/proc/set_suicide(suicide_state) suiciding = suicide_state @@ -22,7 +22,7 @@ mmi.brainmob.suiciding = suicide_state /mob/living/carbon/human/verb/suicide() - set hidden = 1 + set hidden = TRUE if(!canSuicide()) return var/oldkey = ckey diff --git a/code/modules/clothing/gloves/_gloves.dm b/code/modules/clothing/gloves/_gloves.dm index 20e557028f..bce61a4adb 100644 --- a/code/modules/clothing/gloves/_gloves.dm +++ b/code/modules/clothing/gloves/_gloves.dm @@ -38,4 +38,4 @@ // Called just before an attack_hand(), in mob/UnarmedAttack() /obj/item/clothing/gloves/proc/Touch(atom/A, proximity) - return 0 // return 1 to cancel attack_hand() + return FALSE // return 1 to cancel attack_hand() diff --git a/code/modules/clothing/head/misc_special.dm b/code/modules/clothing/head/misc_special.dm index 76714b4b90..77e52192d6 100644 --- a/code/modules/clothing/head/misc_special.dm +++ b/code/modules/clothing/head/misc_special.dm @@ -120,7 +120,7 @@ icon_state = "ushankadown" inhand_icon_state = "ushankadown" flags_inv = HIDEEARS|HIDEHAIR - var/earflaps = 1 + var/earflaps = TRUE cold_protection = HEAD min_cold_protection_temperature = FIRE_HELM_MIN_TEMP_PROTECT @@ -128,15 +128,14 @@ /obj/item/clothing/head/ushanka/attack_self(mob/user) if(earflaps) - src.icon_state = "ushankaup" - src.inhand_icon_state = "ushankaup" - earflaps = 0 + icon_state = "ushankaup" + inhand_icon_state = "ushankaup" to_chat(user, "You raise the ear flaps on the ushanka.") else - src.icon_state = "ushankadown" - src.inhand_icon_state = "ushankadown" - earflaps = 1 + icon_state = "ushankadown" + inhand_icon_state = "ushankadown" to_chat(user, "You lower the ear flaps on the ushanka.") + earflaps = !earflaps /* * Pumpkin head diff --git a/code/modules/clothing/head/soft_caps.dm b/code/modules/clothing/head/soft_caps.dm index cfc90174c0..80030e26cf 100644 --- a/code/modules/clothing/head/soft_caps.dm +++ b/code/modules/clothing/head/soft_caps.dm @@ -7,11 +7,11 @@ dog_fashion = /datum/dog_fashion/head/cargo_tech - var/flipped = 0 + var/flipped = FALSE /obj/item/clothing/head/soft/dropped() icon_state = "[soft_type]soft" - flipped=0 + flipped = FALSE ..() /obj/item/clothing/head/soft/verb/flipcap() @@ -32,7 +32,7 @@ /obj/item/clothing/head/soft/proc/flip(mob/user) if(!user.incapacitated()) flipped = !flipped - if(src.flipped) + if(flipped) icon_state = "[soft_type]soft_flipped" to_chat(user, "You flip the hat backwards.") else diff --git a/code/modules/clothing/masks/_masks.dm b/code/modules/clothing/masks/_masks.dm index 4fc0dc41d9..1ccb2c3c17 100644 --- a/code/modules/clothing/masks/_masks.dm +++ b/code/modules/clothing/masks/_masks.dm @@ -6,7 +6,7 @@ strip_delay = 40 equip_delay_other = 40 var/modifies_speech = FALSE - var/mask_adjusted = 0 + var/mask_adjusted = FALSE var/adjusted_flags = null /obj/item/clothing/mask/attack_self(mob/user) diff --git a/code/modules/clothing/shoes/_shoes.dm b/code/modules/clothing/shoes/_shoes.dm index 57d6a49e83..ca8f591308 100644 --- a/code/modules/clothing/shoes/_shoes.dm +++ b/code/modules/clothing/shoes/_shoes.dm @@ -3,7 +3,7 @@ icon = 'icons/obj/clothing/shoes.dmi' desc = "Comfortable-looking shoes." gender = PLURAL //Carn: for grammarically correct text-parsing - var/chained = 0 + var/chained = FALSE body_parts_covered = FEET slot_flags = ITEM_SLOT_FEET diff --git a/code/modules/clothing/shoes/magboots.dm b/code/modules/clothing/shoes/magboots.dm index 15fe1838b0..c3ea63da31 100644 --- a/code/modules/clothing/shoes/magboots.dm +++ b/code/modules/clothing/shoes/magboots.dm @@ -3,7 +3,7 @@ name = "magboots" icon_state = "magboots0" var/magboot_state = "magboots" - var/magpulse = 0 + var/magpulse = FALSE var/slowdown_active = 2 permeability_coefficient = 0.05 actions_types = list(/datum/action/item_action/toggle) diff --git a/code/modules/clothing/spacesuits/chronosuit.dm b/code/modules/clothing/spacesuits/chronosuit.dm index 4a612f9041..383957b531 100644 --- a/code/modules/clothing/spacesuits/chronosuit.dm +++ b/code/modules/clothing/spacesuits/chronosuit.dm @@ -30,10 +30,10 @@ var/obj/item/clothing/head/helmet/space/chronos/helmet var/obj/effect/chronos_cam/camera var/datum/action/innate/chrono_teleport/teleport_now = new - var/activating = 0 - var/activated = 0 + var/activating = FALSE + var/activated = FALSE var/cooldowntime = 50 //deciseconds - var/teleporting = 0 + var/teleporting = FALSE var/phase_timer_id /obj/item/clothing/suit/space/chronos/Initialize() @@ -96,7 +96,7 @@ user.animate_movement = FORWARD_STEPS user.notransform = 0 user.set_anchored(FALSE) - teleporting = 0 + teleporting = FALSE for(var/obj/item/I in user.held_items) REMOVE_TRAIT(I, TRAIT_NODROP, CHRONOSUIT_TRAIT) if(camera) @@ -204,7 +204,7 @@ to_chat(user, "FATAL: Unable to locate /dev/helm. Aborting...") teleport_now.Grant(user) cooldown = world.time + cooldowntime - activating = 0 + activating = FALSE /obj/item/clothing/suit/space/chronos/proc/deactivate(force = 0, silent = FALSE) if(activated && (!teleporting || force)) @@ -213,8 +213,8 @@ var/hard_landing = teleporting && force REMOVE_TRAIT(src, TRAIT_NODROP, CHRONOSUIT_TRAIT) cooldown = world.time + cooldowntime * 1.5 - activated = 0 - activating = 0 + activated = FALSE + activating = FALSE finish_chronowalk() if(user && ishuman(user)) teleport_now.Remove(user) diff --git a/code/modules/clothing/spacesuits/hardsuit.dm b/code/modules/clothing/spacesuits/hardsuit.dm index 3e5be8a626..d9a54c3441 100644 --- a/code/modules/clothing/spacesuits/hardsuit.dm +++ b/code/modules/clothing/spacesuits/hardsuit.dm @@ -751,12 +751,8 @@ owner.visible_message("[owner]'s shield overloads!") shield_state = "broken" owner.update_inv_wear_suit() - return 1 - return 0 - - -/obj/item/clothing/suit/space/hardsuit/shielded/Destroy() - return ..() + return TRUE + return FALSE /obj/item/clothing/suit/space/hardsuit/shielded/process() . = ..() diff --git a/code/modules/clothing/suits/reactive_armour.dm b/code/modules/clothing/suits/reactive_armour.dm index fcd1633b03..1a142c1045 100644 --- a/code/modules/clothing/suits/reactive_armour.dm +++ b/code/modules/clothing/suits/reactive_armour.dm @@ -27,7 +27,7 @@ /obj/item/clothing/suit/armor/reactive name = "reactive armor" desc = "Doesn't seem to do much for some reason." - var/active = 0 + var/active = FALSE var/reactivearmor_cooldown_duration = 0 //cooldown specific to reactive armor var/reactivearmor_cooldown = 0 icon_state = "reactiveoff" @@ -55,7 +55,7 @@ . = ..() if(. & EMP_PROTECT_SELF) return - active = 0 + active = FALSE icon_state = "reactiveoff" inhand_icon_state = "reactiveoff" reactivearmor_cooldown = world.time + 200 @@ -70,12 +70,12 @@ /obj/item/clothing/suit/armor/reactive/teleport/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK) if(!active) - return 0 + return FALSE if(prob(hit_reaction_chance)) var/mob/living/carbon/human/H = owner if(world.time < reactivearmor_cooldown) owner.visible_message("The reactive teleport system is still recharging! It fails to teleport [H]!") - return + return FALSE owner.visible_message("The reactive teleport system flings [H] clear of [attack_text], shutting itself off in the process!") playsound(get_turf(owner),'sound/magic/blink.ogg', 100, TRUE) var/list/turfs = new/list() @@ -95,8 +95,8 @@ H.forceMove(picked) H.rad_act(rad_amount) reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration - return 1 - return 0 + return TRUE + return FALSE //Fire @@ -106,11 +106,11 @@ /obj/item/clothing/suit/armor/reactive/fire/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK) if(!active) - return 0 + return FALSE if(prob(hit_reaction_chance)) if(world.time < reactivearmor_cooldown) owner.visible_message("The reactive incendiary armor on [owner] activates, but fails to send out flames as it is still recharging its flame jets!") - return + return FALSE owner.visible_message("[src] blocks [attack_text], sending out jets of flame!") playsound(get_turf(owner),'sound/magic/fireball.ogg', 100, TRUE) for(var/mob/living/carbon/C in range(6, owner)) @@ -119,8 +119,8 @@ C.IgniteMob() owner.fire_stacks = -20 reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration - return 1 - return 0 + return TRUE + return FALSE //Stealth @@ -130,7 +130,7 @@ /obj/item/clothing/suit/armor/reactive/stealth/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK) if(!active) - return 0 + return FALSE if(prob(hit_reaction_chance)) if(world.time < reactivearmor_cooldown) owner.visible_message("The reactive stealth system on [owner] activates, but is still recharging its holographic emitters!") @@ -143,7 +143,7 @@ owner.visible_message("[owner] is hit by [attack_text] in the chest!") //We pretend to be hit, since blocking it would stop the message otherwise addtimer(VARSET_CALLBACK(owner, alpha, initial(owner.alpha)), 4 SECONDS) reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration - return 1 + return TRUE //Tesla @@ -189,11 +189,11 @@ /obj/item/clothing/suit/armor/reactive/repulse/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK) if(!active) - return 0 + return FALSE if(prob(hit_reaction_chance)) if(world.time < reactivearmor_cooldown) owner.visible_message("The repulse generator is still recharging!") - return 0 + return FALSE playsound(get_turf(owner),'sound/magic/repulse.ogg', 100, TRUE) owner.visible_message("[src] blocks [attack_text], converting the attack into a wave of force!") var/turf/T = get_turf(owner) @@ -206,7 +206,7 @@ thrown_items[A] = A reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration - return 1 + return TRUE /obj/item/clothing/suit/armor/reactive/table name = "reactive table armor" @@ -215,12 +215,12 @@ /obj/item/clothing/suit/armor/reactive/table/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK) if(!active) - return 0 + return FALSE if(prob(hit_reaction_chance)) var/mob/living/carbon/human/H = owner if(world.time < reactivearmor_cooldown) owner.visible_message("The reactive table armor's fabricators are still on cooldown!") - return + return FALSE owner.visible_message("The reactive teleport system flings [H] clear of [attack_text] and slams [H.p_them()] into a fabricated table!") owner.visible_message("[H] GOES ON THE TABLE!!!") owner.Paralyze(40) @@ -241,8 +241,8 @@ H.forceMove(picked) new /obj/structure/table(get_turf(owner)) reactivearmor_cooldown = world.time + reactivearmor_cooldown_duration - return 1 - return 0 + return TRUE + return FALSE /obj/item/clothing/suit/armor/reactive/table/emp_act() return diff --git a/code/modules/clothing/under/_under.dm b/code/modules/clothing/under/_under.dm index 4a8b62cc50..9149e1fd39 100644 --- a/code/modules/clothing/under/_under.dm +++ b/code/modules/clothing/under/_under.dm @@ -204,13 +204,13 @@ return if(has_sensor == LOCKED_SENSORS) to_chat(usr, "The controls are locked.") - return 0 + return if(has_sensor == BROKEN_SENSORS) to_chat(usr, "The sensors have shorted out!") - return 0 + return if(has_sensor <= NO_SENSORS) to_chat(usr, "This suit does not have any sensors.") - return 0 + return var/list/modes = list("Off", "Binary vitals", "Exact vitals", "Tracking beacon") var/switchMode = input("Select a sensor mode:", "Suit Sensor Mode", modes[sensor_mode + 1]) in modes @@ -235,8 +235,9 @@ H.update_suit_sensors() /obj/item/clothing/under/AltClick(mob/user) - if(..()) - return 1 + . = ..() + if(.) + return if(!istype(user) || !user.canUseTopic(src, BE_CLOSE, ismonkey(user))) return diff --git a/code/modules/clothing/under/jobs/Plasmaman/civilian_service.dm b/code/modules/clothing/under/jobs/Plasmaman/civilian_service.dm index c79e4e1d0f..04ee1dd5a8 100644 --- a/code/modules/clothing/under/jobs/Plasmaman/civilian_service.dm +++ b/code/modules/clothing/under/jobs/Plasmaman/civilian_service.dm @@ -79,4 +79,3 @@ H.visible_message("[H]'s suit spews space lube everywhere!","Your suit spews space lube everywhere!") H.ExtinguishMob() new /obj/effect/particle_effect/foam(loc) //Truely terrifying. - return 0 diff --git a/code/modules/clothing/under/miscellaneous.dm b/code/modules/clothing/under/miscellaneous.dm index b9f141cd85..ca6f58a5ab 100644 --- a/code/modules/clothing/under/miscellaneous.dm +++ b/code/modules/clothing/under/miscellaneous.dm @@ -114,7 +114,6 @@ H.visible_message("[H]'s suit automatically extinguishes [H.p_them()]!","Your suit automatically extinguishes you.") H.ExtinguishMob() new /obj/effect/particle_effect/water(get_turf(H)) - return 0 /obj/item/clothing/under/plasmaman/attackby(obj/item/E, mob/user, params) ..() diff --git a/code/modules/detectivework/scanner.dm b/code/modules/detectivework/scanner.dm index c35e5fee7a..a38a5ed31b 100644 --- a/code/modules/detectivework/scanner.dm +++ b/code/modules/detectivework/scanner.dm @@ -15,7 +15,7 @@ flags_1 = CONDUCT_1 item_flags = NOBLUDGEON slot_flags = ITEM_SLOT_BELT - var/scanning = 0 + var/scanning = FALSE var/list/log = list() var/range = 8 var/view_check = TRUE @@ -32,7 +32,7 @@ /obj/item/detective_scanner/attack_self(mob/user) if(log.len && !scanning) - scanning = 1 + scanning = TRUE to_chat(user, "Printing report, please wait...") addtimer(CALLBACK(src, .proc/PrintReport), 100) else @@ -61,7 +61,7 @@ // Clear the logs log = list() - scanning = 0 + scanning = FALSE /obj/item/detective_scanner/afterattack(atom/A, mob/user, params) . = ..() @@ -69,13 +69,13 @@ return FALSE /obj/item/detective_scanner/proc/scan(atom/A, mob/user) - set waitfor = 0 + set waitfor = FALSE if(!scanning) // Can remotely scan objects and mobs. if((get_dist(A, user) > range) || (!(A in view(range, user)) && view_check) || (loc != user)) return - scanning = 1 + scanning = TRUE user.visible_message("\The [user] points the [src.name] at \the [A] and performs a forensic scan.") to_chat(user, "You scan \the [A]. The scanner is now analysing the results...") @@ -120,7 +120,7 @@ // We gathered everything. Create a fork and slowly display the results to the holder of the scanner. - var/found_something = 0 + var/found_something = FALSE add_log("[station_time_timestamp()][get_timestamp()] - [target_name]", 0) // Fingerprints @@ -129,13 +129,13 @@ add_log("Prints:") for(var/finger in fingerprints) add_log("[finger]") - found_something = 1 + found_something = TRUE // Blood if (length(blood)) sleep(30) add_log("Blood:") - found_something = 1 + found_something = TRUE for(var/B in blood) add_log("Type: [blood[B]] DNA (UE): [B]") @@ -145,7 +145,7 @@ add_log("Fibers:") for(var/fiber in fibers) add_log("[fiber]") - found_something = 1 + found_something = TRUE //Reagents if(length(reagents)) @@ -153,7 +153,7 @@ add_log("Reagents:") for(var/R in reagents) add_log("Reagent: [R] Volume: [reagents[R]]") - found_something = 1 + found_something = TRUE // Get a new user var/mob/holder = null @@ -169,7 +169,7 @@ to_chat(holder, "You finish scanning \the [target_name].") add_log("---------------------------------------------------------", 0) - scanning = 0 + scanning = FALSE return /obj/item/detective_scanner/proc/add_log(msg, broadcast = 1) diff --git a/code/modules/events/devil.dm b/code/modules/events/devil.dm index 3760cbe05d..6d9bb3a506 100644 --- a/code/modules/events/devil.dm +++ b/code/modules/events/devil.dm @@ -26,11 +26,11 @@ var/mob/dead/selected_candidate = pick_n_take(candidates) var/key = selected_candidate.key - var/datum/mind/Mind = create_devil_mind(key) - Mind.active = 1 + var/datum/mind/mind = create_devil_mind(key) + mind.active = TRUE var/mob/living/carbon/human/devil = create_event_devil() - Mind.transfer_to(devil) + mind.transfer_to(devil) add_devil(devil, ascendable = FALSE) spawned_mobs += devil diff --git a/code/modules/events/electrical_storm.dm b/code/modules/events/electrical_storm.dm index db0eccf0c5..a769bad158 100644 --- a/code/modules/events/electrical_storm.dm +++ b/code/modules/events/electrical_storm.dm @@ -4,7 +4,7 @@ earliest_start = 10 MINUTES min_players = 5 weight = 20 - alert_observers = 0 + alert_observers = FALSE /datum/round_event/electrical_storm var/lightsoutAmount = 1 diff --git a/code/modules/events/false_alarm.dm b/code/modules/events/false_alarm.dm index 5b032f85f8..e68f5a0e3f 100644 --- a/code/modules/events/false_alarm.dm +++ b/code/modules/events/false_alarm.dm @@ -24,8 +24,8 @@ return ..() && length(gather_false_events()) /datum/round_event/falsealarm - announceWhen = 0 - endWhen = 1 + announceWhen = 0 + endWhen = 1 fakeable = FALSE /datum/round_event/falsealarm/announce(fake) diff --git a/code/modules/events/immovable_rod.dm b/code/modules/events/immovable_rod.dm index 783bc9d9ba..8867157194 100644 --- a/code/modules/events/immovable_rod.dm +++ b/code/modules/events/immovable_rod.dm @@ -120,7 +120,7 @@ In my current plan for it, 'solid' will be defined as anything with density == 1 walk_towards(src, destination, 1) /obj/effect/immovablerod/ex_act(severity, target) - return 0 + return /obj/effect/immovablerod/singularity_act() return diff --git a/code/modules/events/operative.dm b/code/modules/events/operative.dm index 7fca4188b7..9e92364b89 100644 --- a/code/modules/events/operative.dm +++ b/code/modules/events/operative.dm @@ -29,7 +29,7 @@ var/datum/mind/Mind = new /datum/mind(selected.key) Mind.assigned_role = "Lone Operative" Mind.special_role = "Lone Operative" - Mind.active = 1 + Mind.active = TRUE Mind.transfer_to(operative) Mind.add_antag_datum(/datum/antagonist/nukeop/lone) diff --git a/code/modules/events/portal_storm.dm b/code/modules/events/portal_storm.dm index 716fbd13e2..ad9eae0e27 100644 --- a/code/modules/events/portal_storm.dm +++ b/code/modules/events/portal_storm.dm @@ -106,11 +106,12 @@ /datum/round_event/portal_storm/proc/spawn_boss() if(!boss_types || !boss_types.len) - return 0 + return FALSE if(activeFor == next_boss_spawn) next_boss_spawn += CEILING(number_of_hostiles / number_of_bosses, 1) - return 1 + return TRUE + return FALSE /datum/round_event/portal_storm/proc/time_to_end() if(!hostile_types.len && !boss_types.len) diff --git a/code/modules/events/wizard/greentext.dm b/code/modules/events/wizard/greentext.dm index 82e72df3b9..431c249bf1 100644 --- a/code/modules/events/wizard/greentext.dm +++ b/code/modules/events/wizard/greentext.dm @@ -12,7 +12,7 @@ if(!ishuman(M)) holder_canadates -= M if(!holder_canadates) //Very unlikely, but just in case - return 0 + return FALSE var/mob/living/carbon/human/H = pick(holder_canadates) new /obj/item/greentext(H.loc) diff --git a/code/modules/food_and_drinks/food/condiment.dm b/code/modules/food_and_drinks/food/condiment.dm index 4dc24de465..e8177822bf 100644 --- a/code/modules/food_and_drinks/food/condiment.dm +++ b/code/modules/food_and_drinks/food/condiment.dm @@ -72,10 +72,10 @@ if(!reagents || !reagents.total_volume) to_chat(user, "None of [src] left, oh no!") - return 0 + return FALSE if(!canconsume(M, user)) - return 0 + return FALSE if(M == user) user.visible_message("[user] swallows some of the contents of \the [src].", \ @@ -92,7 +92,7 @@ log_combat(user, M, "fed", reagents.log_list()) reagents.trans_to(M, 10, transfered_by = user, methods = INGEST) playsound(M.loc,'sound/items/drink.ogg', rand(10,50), TRUE) - return 1 + return TRUE /obj/item/reagent_containers/food/condiment/afterattack(obj/target, mob/user , proximity) . = ..() diff --git a/code/modules/food_and_drinks/food/snacks.dm b/code/modules/food_and_drinks/food/snacks.dm index c9929b20eb..72e37f6079 100644 --- a/code/modules/food_and_drinks/food/snacks.dm +++ b/code/modules/food_and_drinks/food/snacks.dm @@ -141,14 +141,14 @@ All foods are distributed among various categories. Use common sense. return FALSE if(!do_mob(user, M)) - return + return FALSE log_combat(user, M, "fed", reagents.log_list()) M.visible_message("[user] forces [M] to eat [src]!", \ "[user] forces you to eat [src]!") else to_chat(user, "[M] doesn't seem to have a mouth!") - return + return FALSE if(reagents) //Handle ingestion of the reagent. if(M.satiety > -200) @@ -163,7 +163,7 @@ All foods are distributed among various categories. Use common sense. checkLiked(fraction, M) return TRUE - return 0 + return FALSE /obj/item/reagent_containers/food/snacks/examine(mob/user) . = ..() @@ -179,29 +179,28 @@ All foods are distributed among various categories. Use common sense. . += "[src] was bitten multiple times!" /obj/item/reagent_containers/food/snacks/attackby(obj/item/W, mob/user, params) - if(istype(W, /obj/item/storage)) - ..() // -> item/attackby() - return 0 + if(istype(W, /obj/item/storage))// -> item/attackby() + return ..() if(istype(W, /obj/item/reagent_containers/food/snacks)) var/obj/item/reagent_containers/food/snacks/S = W if(custom_food_type && ispath(custom_food_type)) if(S.w_class > WEIGHT_CLASS_SMALL) to_chat(user, "[S] is too big for [src]!") - return 0 + return FALSE if(!S.customfoodfilling || istype(W, /obj/item/reagent_containers/food/snacks/customizable) || istype(W, /obj/item/reagent_containers/food/snacks/pizzaslice/custom) || istype(W, /obj/item/reagent_containers/food/snacks/cakeslice/custom)) to_chat(user, "[src] can't be filled with [S]!") - return 0 + return FALSE if(contents.len >= 20) to_chat(user, "You can't add more ingredients to [src]!") - return 0 + return FALSE var/obj/item/reagent_containers/food/snacks/customizable/C = new custom_food_type(get_turf(src)) C.initialize_custom_food(src, S, user) - return 0 + return FALSE if(user.a_intent != INTENT_DISARM) var/sharp = W.get_sharpness() return sharp && slice(sharp, W, user) else - ..() + return ..() //Called when you finish tablecrafting a snack. /obj/item/reagent_containers/food/snacks/CheckParts(list/parts_list, datum/crafting_recipe/food/R) diff --git a/code/modules/food_and_drinks/food/snacks_other.dm b/code/modules/food_and_drinks/food/snacks_other.dm index 08e92760dc..652176caa7 100644 --- a/code/modules/food_and_drinks/food/snacks_other.dm +++ b/code/modules/food_and_drinks/food/snacks_other.dm @@ -760,7 +760,7 @@ /obj/item/reagent_containers/food/snacks/canned/attack(mob/living/M, mob/user, def_zone) if (!is_drainable()) to_chat(user, "[src]'s lid hasn't been opened!") - return 0 + return FALSE return ..() /obj/item/reagent_containers/food/snacks/canned/beans diff --git a/code/modules/holiday/holidays.dm b/code/modules/holiday/holidays.dm index 5f431f4cc7..799f5223a4 100644 --- a/code/modules/holiday/holidays.dm +++ b/code/modules/holiday/holidays.dm @@ -322,11 +322,11 @@ if(mm == 9) if(yy/4 == round(yy/4)) //Note: Won't work right on September 12th, 2200 (at least it's a Friday!) if(dd == 12) - return 1 + return TRUE else if(dd == 13) - return 1 - return 0 + return TRUE + return FALSE /datum/holiday/programmers/getStationPrefix() return pick("span>","DEBUG: ","null","/list","EVENT PREFIX NOT FOUND") //Portability diff --git a/code/modules/hydroponics/grown.dm b/code/modules/hydroponics/grown.dm index 14b8cf3bc8..f4d3dd477b 100644 --- a/code/modules/hydroponics/grown.dm +++ b/code/modules/hydroponics/grown.dm @@ -54,8 +54,8 @@ if(reagents) if(bitesize_mod) bitesize = 1 + round(reagents.total_volume / bitesize_mod) - return 1 - return 0 + return TRUE + return FALSE /obj/item/reagent_containers/food/snacks/grown/examine(user) . = ..() diff --git a/code/modules/hydroponics/growninedible.dm b/code/modules/hydroponics/growninedible.dm index fb794db0e7..565f3ac6d1 100644 --- a/code/modules/hydroponics/growninedible.dm +++ b/code/modules/hydroponics/growninedible.dm @@ -44,8 +44,8 @@ /obj/item/grown/proc/add_juice() if(reagents) - return 1 - return 0 + return TRUE + return FALSE /obj/item/grown/throw_impact(atom/hit_atom, datum/thrownthing/throwingdatum) if(!..()) //was it caught by a mob? diff --git a/code/modules/library/lib_items.dm b/code/modules/library/lib_items.dm index ffed7d1748..6c8dfaae8d 100644 --- a/code/modules/library/lib_items.dm +++ b/code/modules/library/lib_items.dm @@ -217,7 +217,7 @@ var/dat //Actual page content var/due_date = 0 //Game time in 1/10th seconds var/author //Who wrote the thing, can be changed by pen or PC. It is not automatically assigned - var/unique = 0 //0 - Normal book, 1 - Should not be treated as normal book, unable to be copied, unable to be modified + var/unique = FALSE //false - Normal book, true - Should not be treated as normal book, unable to be copied, unable to be modified var/title //The real name of the book. var/window_size = null // Specific window size for the book, i.e: "1920x1080", Size x Width diff --git a/code/modules/lighting/lighting_object.dm b/code/modules/lighting/lighting_object.dm index 6c2db404e0..72cc4c20a0 100644 --- a/code/modules/lighting/lighting_object.dm +++ b/code/modules/lighting/lighting_object.dm @@ -130,7 +130,7 @@ // Variety of overrides so the overlays don't get affected by weird things. /atom/movable/lighting_object/ex_act(severity) - return 0 + return /atom/movable/lighting_object/singularity_act() return diff --git a/code/modules/mining/fulton.dm b/code/modules/mining/fulton.dm index f9486a8977..eb464cc0ad 100644 --- a/code/modules/mining/fulton.dm +++ b/code/modules/mining/fulton.dm @@ -181,13 +181,13 @@ GLOBAL_LIST_EMPTY(total_extraction_beacons) if(isliving(A)) var/mob/living/L = A if(L.stat != DEAD) - return 1 + return TRUE for(var/thing in A.GetAllContents()) if(isliving(A)) var/mob/living/L = A if(L.stat != DEAD) - return 1 - return 0 + return TRUE + return FALSE /obj/effect/extraction_holder/singularity_act() return diff --git a/code/modules/mining/lavaland/ash_flora.dm b/code/modules/mining/lavaland/ash_flora.dm index ebf6e1e2c0..4de3dec7bb 100644 --- a/code/modules/mining/lavaland/ash_flora.dm +++ b/code/modules/mining/lavaland/ash_flora.dm @@ -30,7 +30,7 @@ /obj/structure/flora/ash/proc/harvest(user) if(harvested) - return 0 + return FALSE var/rand_harvested = rand(harvest_amount_low, harvest_amount_high) if(rand_harvested) @@ -49,7 +49,7 @@ desc = harvested_desc harvested = TRUE addtimer(CALLBACK(src, .proc/regrow), rand(regrowth_time_low, regrowth_time_high)) - return 1 + return TRUE /obj/structure/flora/ash/proc/regrow() icon_state = base_icon diff --git a/code/modules/mob/dead/new_player/login.dm b/code/modules/mob/dead/new_player/login.dm index 237ce7f9e7..2cc7ae7470 100644 --- a/code/modules/mob/dead/new_player/login.dm +++ b/code/modules/mob/dead/new_player/login.dm @@ -6,7 +6,7 @@ client.set_db_player_flags() if(!mind) mind = new /datum/mind(key) - mind.active = 1 + mind.active = TRUE mind.current = src . = ..() diff --git a/code/modules/mob/dead/new_player/new_player.dm b/code/modules/mob/dead/new_player/new_player.dm index 527f0df3ae..0825bc2be8 100644 --- a/code/modules/mob/dead/new_player/new_player.dm +++ b/code/modules/mob/dead/new_player/new_player.dm @@ -108,10 +108,10 @@ /mob/dead/new_player/Topic(href, href_list[]) if(src != usr) - return 0 + return if(!client) - return 0 + return //Determines Relevent Population Cap var/relevant_cap @@ -124,7 +124,7 @@ if(href_list["show_preferences"]) client.prefs.ShowChoices(src) - return 1 + return TRUE if(href_list["ready"]) var/tready = text2num(href_list["ready"]) @@ -451,7 +451,7 @@ if(mind) if(transfer_after) mind.late_joiner = TRUE - mind.active = 0 //we wish to transfer the key manually + mind.active = FALSE //we wish to transfer the key manually mind.transfer_to(H) //won't transfer key since the mind is not active mind.original_character = H diff --git a/code/modules/mob/living/blood.dm b/code/modules/mob/living/blood.dm index c3af832fe7..79edeb9ff1 100644 --- a/code/modules/mob/living/blood.dm +++ b/code/modules/mob/living/blood.dm @@ -120,16 +120,16 @@ //Gets blood from mob to a container or other mob, preserving all data in it. /mob/living/proc/transfer_blood_to(atom/movable/AM, amount, forced) if(!blood_volume || !AM.reagents) - return 0 + return FALSE if(blood_volume < BLOOD_VOLUME_BAD && !forced) - return 0 + return FALSE if(blood_volume < amount) amount = blood_volume var/blood_id = get_blood_id() if(!blood_id) - return 0 + return FALSE blood_volume -= amount @@ -147,13 +147,13 @@ C.ForceContractDisease(D) if(!(blood_data["blood_type"] in get_safe_blood(C.dna.blood_type))) C.reagents.add_reagent(/datum/reagent/toxin, amount * 0.5) - return 1 + return TRUE C.blood_volume = min(C.blood_volume + round(amount, 0.1), BLOOD_VOLUME_MAX_LETHAL) - return 1 + return TRUE AM.reagents.add_reagent(blood_id, amount, blood_data, bodytemperature) - return 1 + return TRUE /mob/living/proc/get_blood_data(blood_id) diff --git a/code/modules/mob/living/brain/brain.dm b/code/modules/mob/living/brain/brain.dm index 25830066b9..2faa23b800 100644 --- a/code/modules/mob/living/brain/brain.dm +++ b/code/modules/mob/living/brain/brain.dm @@ -56,9 +56,9 @@ return // no eyes, no flashing /mob/living/brain/can_be_revived() - . = 1 if(!container || health <= HEALTH_THRESHOLD_DEAD) - return 0 + return FALSE + return TRUE /mob/living/brain/fully_replace_character_name(oldname,newname) ..() diff --git a/code/modules/mob/living/brain/life.dm b/code/modules/mob/living/brain/life.dm index ff4b85bdcf..4128235e45 100644 --- a/code/modules/mob/living/brain/life.dm +++ b/code/modules/mob/living/brain/life.dm @@ -1,6 +1,5 @@ /mob/living/brain/Life() - set invisibility = 0 if (notransform) return if(!loc) diff --git a/code/modules/mob/living/carbon/alien/alien.dm b/code/modules/mob/living/carbon/alien/alien.dm index 8bc8f9eb40..62c2e35fae 100644 --- a/code/modules/mob/living/carbon/alien/alien.dm +++ b/code/modules/mob/living/carbon/alien/alien.dm @@ -19,9 +19,9 @@ heat_protection = 0.5 // minor heat insulation - var/leaping = 0 + var/leaping = FALSE gib_type = /obj/effect/decal/cleanable/xenoblood/xgibs - unique_name = 1 + unique_name = TRUE var/static/regex/alien_name_regex = new("alien (larva|sentinel|drone|hunter|praetorian|queen)( \\(\\d+\\))?") diff --git a/code/modules/mob/living/carbon/alien/alien_defense.dm b/code/modules/mob/living/carbon/alien/alien_defense.dm index be92b6d708..9a98d00a89 100644 --- a/code/modules/mob/living/carbon/alien/alien_defense.dm +++ b/code/modules/mob/living/carbon/alien/alien_defense.dm @@ -54,8 +54,9 @@ In all, this is a lot like the monkey code. /N /mob/living/carbon/alien/attack_hand(mob/living/carbon/human/M) - if(..()) //to allow surgery to return properly. - return 0 + . = ..() + if(.) //to allow surgery to return properly. + return FALSE switch(M.a_intent) if("help") @@ -64,11 +65,11 @@ In all, this is a lot like the monkey code. /N grabbedby(M) if ("harm") M.do_attack_animation(src, ATTACK_EFFECT_PUNCH) - return 1 + return TRUE if("disarm") M.do_attack_animation(src, ATTACK_EFFECT_DISARM) - return 1 - return 0 + return TRUE + return FALSE /mob/living/carbon/alien/attack_paw(mob/living/carbon/monkey/M) @@ -133,4 +134,4 @@ In all, this is a lot like the monkey code. /N return 0 /mob/living/carbon/alien/acid_act(acidpwr, acid_volume) - return 0//aliens are immune to acid. + return FALSE//aliens are immune to acid. diff --git a/code/modules/mob/living/carbon/alien/humanoid/alien_powers.dm b/code/modules/mob/living/carbon/alien/humanoid/alien_powers.dm index 1fc9e2853e..4b175560a2 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/alien_powers.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/alien_powers.dm @@ -77,10 +77,10 @@ Doesn't work on other aliens/AI.*/ /obj/effect/proc_holder/alien/plant/fire(mob/living/carbon/user) if(locate(/obj/structure/alien/weeds/node) in get_turf(user)) to_chat(user, "There's already a weed node here!") - return 0 + return FALSE user.visible_message("[user] plants some alien weeds!") new/obj/structure/alien/weeds/node(user.loc) - return 1 + return TRUE /obj/effect/proc_holder/alien/whisper name = "Whisper" @@ -94,7 +94,7 @@ Doesn't work on other aliens/AI.*/ options += Ms var/mob/living/M = input("Select who to whisper to:","Whisper to?",null) as null|mob in sortNames(options) if(!M) - return 0 + return FALSE if(M.anti_magic_check(FALSE, FALSE, TRUE, 0)) to_chat(user, "As you try to communicate with [M], you're suddenly stopped by a vision of a massive tinfoil wall that streches beyond visible range. It seems you've been foiled.") return FALSE @@ -113,8 +113,8 @@ Doesn't work on other aliens/AI.*/ var/follow_link_whispee = FOLLOW_LINK(ded, M) to_chat(ded, "[follow_link_user] [user] Alien Whisper --> [follow_link_whispee] [M] [msg]") else - return 0 - return 1 + return FALSE + return TRUE /obj/effect/proc_holder/alien/transfer name = "Transfer Plasma" @@ -129,7 +129,7 @@ Doesn't work on other aliens/AI.*/ aliens_around.Add(A) var/mob/living/carbon/M = input("Select who to transfer to:","Transfer plasma to?",null) as mob in sortNames(aliens_around) if(!M) - return 0 + return var/amount = input("Amount:", "Transfer Plasma to [M]") as num|null if (amount) amount = min(abs(round(amount)), user.getPlasma()) @@ -158,21 +158,19 @@ Doesn't work on other aliens/AI.*/ if(target in oview(1,user)) if(target.acid_act(200, 100)) user.visible_message("[user] vomits globs of vile stuff all over [target]. It begins to sizzle and melt under the bubbling mess of acid!") - return 1 + return TRUE else to_chat(user, "You cannot dissolve this object.") + return FALSE - - return 0 - else - to_chat(src, "[target] is too far away.") - return 0 + to_chat(src, "[target] is too far away.") + return FALSE /obj/effect/proc_holder/alien/acid/fire(mob/living/carbon/alien/user) var/O = input("Select what to dissolve:","Dissolve",null) as obj|turf in oview(1,user) if(!O || user.incapacitated()) - return 0 + return FALSE else return corrode(O,user) @@ -208,19 +206,20 @@ Doesn't work on other aliens/AI.*/ action.UpdateButtonIcon() /obj/effect/proc_holder/alien/neurotoxin/InterceptClickOn(mob/living/caller, params, atom/target) - if(..()) + . = ..() + if(.) return var/p_cost = 50 if(!iscarbon(ranged_ability_user) || ranged_ability_user.stat) remove_ranged_ability() - return + return FALSE var/mob/living/carbon/user = ranged_ability_user if(user.getPlasma() < p_cost) to_chat(user, "You need at least [p_cost] plasma to spit.") remove_ranged_ability() - return + return FALSE var/turf/T = user.loc var/turf/U = get_step(user, user.dir) // Get the tile infront of the move, based on their direction @@ -315,14 +314,14 @@ Doesn't work on other aliens/AI.*/ /mob/living/carbon/proc/adjustPlasma(amount) var/obj/item/organ/alien/plasmavessel/vessel = getorgan(/obj/item/organ/alien/plasmavessel) if(!vessel) - return 0 + return FALSE vessel.storedPlasma = max(vessel.storedPlasma + amount,0) vessel.storedPlasma = min(vessel.storedPlasma, vessel.max_plasma) //upper limit of max_plasma, lower limit of 0 for(var/X in abilities) var/obj/effect/proc_holder/alien/APH = X if(APH.has_action) APH.action.UpdateButtonIcon() - return 1 + return TRUE /mob/living/carbon/alien/adjustPlasma(amount) . = ..() @@ -331,6 +330,5 @@ Doesn't work on other aliens/AI.*/ /mob/living/carbon/proc/usePlasma(amount) if(getPlasma() >= amount) adjustPlasma(-amount) - return 1 - - return 0 + return TRUE + return FALSE diff --git a/code/modules/mob/living/carbon/alien/humanoid/caste/drone.dm b/code/modules/mob/living/carbon/alien/humanoid/caste/drone.dm index d9ae677ab4..5b6f36c2f3 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/caste/drone.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/caste/drone.dm @@ -26,18 +26,18 @@ var/obj/item/organ/alien/hivenode/node = user.getorgan(/obj/item/organ/alien/hivenode) if(!node) //Players are Murphy's Law. We may not expect there to ever be a living xeno with no hivenode, but they _WILL_ make it happen. to_chat(user, "Without the hivemind, you can't possibly hold the responsibility of leadership!") - return 0 + return FALSE if(node.recent_queen_death) to_chat(user, "Your thoughts are still too scattered to take up the position of leadership.") - return 0 + return FALSE if(!isturf(user.loc)) to_chat(user, "You can't evolve here!") - return 0 + return FALSE if(!get_alien_type(/mob/living/carbon/alien/humanoid/royal)) var/mob/living/carbon/alien/humanoid/royal/praetorian/new_xeno = new (user.loc) user.alien_evolve(new_xeno) - return 1 + return TRUE else to_chat(user, "We already have a living royal!") - return 0 + return FALSE diff --git a/code/modules/mob/living/carbon/alien/humanoid/caste/praetorian.dm b/code/modules/mob/living/carbon/alien/humanoid/caste/praetorian.dm index bb6e22d719..86038c84f5 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/caste/praetorian.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/caste/praetorian.dm @@ -29,14 +29,14 @@ var/obj/item/organ/alien/hivenode/node = user.getorgan(/obj/item/organ/alien/hivenode) if(!node) //Just in case this particular Praetorian gets violated and kept by the RD as a replacement for Lamarr. to_chat(user, "Without the hivemind, you would be unfit to rule as queen!") - return 0 + return FALSE if(node.recent_queen_death) to_chat(user, "You are still too burdened with guilt to evolve into a queen.") - return 0 + return FALSE if(!get_alien_type(/mob/living/carbon/alien/humanoid/royal/queen)) var/mob/living/carbon/alien/humanoid/royal/queen/new_xeno = new (user.loc) user.alien_evolve(new_xeno) - return 1 + return TRUE else to_chat(user, "We already have an alive queen!") - return 0 + return FALSE diff --git a/code/modules/mob/living/carbon/alien/humanoid/queen.dm b/code/modules/mob/living/carbon/alien/humanoid/queen.dm index acc833f89f..2ae3f7fbf0 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/queen.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/queen.dm @@ -13,7 +13,7 @@ var/alt_inhands_file = 'icons/mob/alienqueen.dmi' /mob/living/carbon/alien/humanoid/royal/can_inject() - return 0 + return FALSE /mob/living/carbon/alien/humanoid/royal/queen name = "alien queen" @@ -83,20 +83,20 @@ var/obj/item/queenpromote/prom if(get_alien_type(/mob/living/carbon/alien/humanoid/royal/praetorian/)) to_chat(user, "You already have a Praetorian!") - return 0 + return else for(prom in user) to_chat(user, "You discard [prom].") qdel(prom) - return 0 + return prom = new (user.loc) if(!user.put_in_active_hand(prom, 1)) to_chat(user, "You must empty your hands before preparing the parasite.") - return 0 + return else //Just in case telling the player only once is not enough! to_chat(user, "Use the royal parasite on one of your children to promote her to Praetorian!") - return 0 + return /obj/item/queenpromote name = "\improper royal parasite" diff --git a/code/modules/mob/living/carbon/alien/larva/life.dm b/code/modules/mob/living/carbon/alien/larva/life.dm index fe53dfa717..4b7bd67677 100644 --- a/code/modules/mob/living/carbon/alien/larva/life.dm +++ b/code/modules/mob/living/carbon/alien/larva/life.dm @@ -1,7 +1,6 @@ /mob/living/carbon/alien/larva/Life() - set invisibility = 0 if (notransform) return if(..() && !IS_IN_STASIS(src)) //not dead and not in stasis diff --git a/code/modules/mob/living/carbon/alien/larva/powers.dm b/code/modules/mob/living/carbon/alien/larva/powers.dm index f7a4e2133c..85a9b7746b 100644 --- a/code/modules/mob/living/carbon/alien/larva/powers.dm +++ b/code/modules/mob/living/carbon/alien/larva/powers.dm @@ -57,7 +57,7 @@ new_xeno = new /mob/living/carbon/alien/humanoid/drone(L.loc) L.alien_evolve(new_xeno) - return 0 + return else to_chat(user, "You are not fully grown!") - return 0 + return diff --git a/code/modules/mob/living/carbon/alien/organs.dm b/code/modules/mob/living/carbon/alien/organs.dm index d89945195b..3e9becdddb 100644 --- a/code/modules/mob/living/carbon/alien/organs.dm +++ b/code/modules/mob/living/carbon/alien/organs.dm @@ -103,7 +103,8 @@ zone = BODY_ZONE_HEAD slot = "hivenode" w_class = WEIGHT_CLASS_TINY - var/recent_queen_death = 0 //Indicates if the queen died recently, aliens are heavily weakened while this is active. + ///Indicates if the queen died recently, aliens are heavily weakened while this is active. + var/recent_queen_death = FALSE alien_powers = list(/obj/effect/proc_holder/alien/whisper) /obj/item/organ/alien/hivenode/Insert(mob/living/carbon/M, special = 0) @@ -135,7 +136,7 @@ owner.add_confusion(30) owner.stuttering += 30 - recent_queen_death = 1 + recent_queen_death = TRUE owner.throw_alert("alien_noqueen", /obj/screen/alert/alien_vulnerable) addtimer(CALLBACK(src, .proc/clear_queen_death), QUEEN_DEATH_DEBUFF_DURATION) @@ -143,7 +144,7 @@ /obj/item/organ/alien/hivenode/proc/clear_queen_death() if(QDELETED(src)) //In case the node is deleted return - recent_queen_death = 0 + recent_queen_death = FALSE if(!owner) //In case the xeno is butchered or subjected to surgery after death. return to_chat(owner, "The pain of the queen's death is easing. You begin to hear the hivemind again.") diff --git a/code/modules/mob/living/carbon/alien/special/facehugger.dm b/code/modules/mob/living/carbon/alien/special/facehugger.dm index c636427ef9..444c3156ba 100644 --- a/code/modules/mob/living/carbon/alien/special/facehugger.dm +++ b/code/modules/mob/living/carbon/alien/special/facehugger.dm @@ -96,15 +96,14 @@ /obj/item/clothing/mask/facehugger/on_found(mob/finder) if(stat == CONSCIOUS) return HasProximity(finder) - return 0 /obj/item/clothing/mask/facehugger/HasProximity(atom/movable/AM as mob|obj) if(CanHug(AM) && Adjacent(AM)) return Leap(AM) - return 0 /obj/item/clothing/mask/facehugger/throw_at(atom/target, range, speed, mob/thrower, spin=1, diagonals_first = 0, datum/callback/callback, quickstart = TRUE) - if(!..()) + . = ..() + if(!.) return if(stat == CONSCIOUS) icon_state = "[initial(icon_state)]_thrown" @@ -248,22 +247,22 @@ /proc/CanHug(mob/living/M) if(!istype(M)) - return 0 + return FALSE if(M.stat == DEAD) - return 0 + return FALSE if(M.getorgan(/obj/item/organ/alien/hivenode)) - return 0 + return FALSE if(ismonkey(M)) - return 1 + return TRUE var/mob/living/carbon/C = M if(ishuman(C) && !(ITEM_SLOT_MASK in C.dna.species.no_equip)) var/mob/living/carbon/human/H = C if(H.is_mouth_covered(head_only = 1)) - return 0 - return 1 - return 0 + return FALSE + return TRUE + return FALSE #undef MIN_ACTIVE_TIME #undef MAX_ACTIVE_TIME diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index 444746b647..9d2a67c94f 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -871,7 +871,7 @@ /mob/living/carbon/can_be_revived() . = ..() if(!getorgan(/obj/item/organ/brain) && (!mind || !mind.has_antag_datum(/datum/antagonist/changeling))) - return 0 + return FALSE /mob/living/carbon/proc/can_defib() if (suiciding) diff --git a/code/modules/mob/living/carbon/examine.dm b/code/modules/mob/living/carbon/examine.dm index e4d04473bf..5d6074bd20 100644 --- a/code/modules/mob/living/carbon/examine.dm +++ b/code/modules/mob/living/carbon/examine.dm @@ -24,9 +24,9 @@ if (back) . += "[t_He] [t_has] [back.get_examine_string(user)] on [t_his] back." - var/appears_dead = 0 + var/appears_dead = FALSE if (stat == DEAD) - appears_dead = 1 + appears_dead = TRUE if(getorgan(/obj/item/organ/brain)) . += "[t_He] [t_is] limp and unresponsive, with no signs of life." else if(get_bodypart(BODY_ZONE_HEAD)) diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm index 13c8f37e92..acd8cffddd 100644 --- a/code/modules/mob/living/carbon/human/human_defense.dm +++ b/code/modules/mob/living/carbon/human/human_defense.dm @@ -167,7 +167,7 @@ /mob/living/carbon/human/attacked_by(obj/item/I, mob/living/user) if(!I || !user) - return 0 + return FALSE var/obj/item/bodypart/affecting if(user == src) @@ -212,7 +212,7 @@ affecting = get_bodypart(BODY_ZONE_CHEST) if(M.a_intent == INTENT_HELP) ..() //shaking - return 0 + return FALSE if(M.a_intent == INTENT_DISARM) //Always drop item in hand, if no item, get stunned instead. var/obj/item/I = get_active_held_item() @@ -243,110 +243,115 @@ if(..()) //successful monkey bite, this handles disease contraction. var/damage = rand(1, 3) if(check_shields(M, damage, "the [M.name]")) - return 0 + return FALSE if(stat != DEAD) apply_damage(damage, BRUTE, affecting, run_armor_check(affecting, MELEE)) - return 1 + return TRUE /mob/living/carbon/human/attack_alien(mob/living/carbon/alien/humanoid/M) if(check_shields(M, 0, "the M.name")) visible_message("[M] attempts to touch [src]!", \ "[M] attempts to touch you!", "You hear a swoosh!", null, M) to_chat(M, "You attempt to touch [src]!") - return 0 + return FALSE + . = ..() + if(!.) + return + if(M.a_intent == INTENT_HARM) + if (w_uniform) + w_uniform.add_fingerprint(M) + var/damage = prob(90) ? 20 : 0 + if(!damage) + playsound(loc, 'sound/weapons/slashmiss.ogg', 50, TRUE, -1) + visible_message("[M] lunges at [src]!", \ + "[M] lunges at you!", "You hear a swoosh!", null, M) + to_chat(M, "You lunge at [src]!") + return FALSE + var/obj/item/bodypart/affecting = get_bodypart(ran_zone(M.zone_selected)) + if(!affecting) + affecting = get_bodypart(BODY_ZONE_CHEST) + var/armor_block = run_armor_check(affecting, MELEE,"","",10) - if(..()) - if(M.a_intent == INTENT_HARM) - if (w_uniform) - w_uniform.add_fingerprint(M) - var/damage = prob(90) ? 20 : 0 - if(!damage) - playsound(loc, 'sound/weapons/slashmiss.ogg', 50, TRUE, -1) - visible_message("[M] lunges at [src]!", \ - "[M] lunges at you!", "You hear a swoosh!", null, M) - to_chat(M, "You lunge at [src]!") - return 0 - var/obj/item/bodypart/affecting = get_bodypart(ran_zone(M.zone_selected)) - if(!affecting) - affecting = get_bodypart(BODY_ZONE_CHEST) - var/armor_block = run_armor_check(affecting, MELEE,"","",10) + playsound(loc, 'sound/weapons/slice.ogg', 25, TRUE, -1) + visible_message("[M] slashes at [src]!", \ + "[M] slashes at you!", "You hear a sickening sound of a slice!", null, M) + to_chat(M, "You slash at [src]!") + log_combat(M, src, "attacked") + if(!dismembering_strike(M, M.zone_selected)) //Dismemberment successful + return TRUE + apply_damage(damage, BRUTE, affecting, armor_block) - playsound(loc, 'sound/weapons/slice.ogg', 25, TRUE, -1) - visible_message("[M] slashes at [src]!", \ - "[M] slashes at you!", "You hear a sickening sound of a slice!", null, M) - to_chat(M, "You slash at [src]!") - log_combat(M, src, "attacked") - if(!dismembering_strike(M, M.zone_selected)) //Dismemberment successful - return 1 - apply_damage(damage, BRUTE, affecting, armor_block) - - if(M.a_intent == INTENT_DISARM) //Always drop item in hand, if no item, get stun instead. - var/obj/item/I = get_active_held_item() - if(I && dropItemToGround(I)) - playsound(loc, 'sound/weapons/slash.ogg', 25, TRUE, -1) - visible_message("[M] disarms [src]!", \ - "[M] disarms you!", "You hear aggressive shuffling!", null, M) - to_chat(M, "You disarm [src]!") - else - playsound(loc, 'sound/weapons/pierce.ogg', 25, TRUE, -1) - Paralyze(100) - log_combat(M, src, "tackled") - visible_message("[M] tackles [src] down!", \ - "[M] tackles you down!", "You hear aggressive shuffling followed by a loud thud!", null, M) - to_chat(M, "You tackle [src] down!") + if(M.a_intent == INTENT_DISARM) //Always drop item in hand, if no item, get stun instead. + var/obj/item/I = get_active_held_item() + if(I && dropItemToGround(I)) + playsound(loc, 'sound/weapons/slash.ogg', 25, TRUE, -1) + visible_message("[M] disarms [src]!", \ + "[M] disarms you!", "You hear aggressive shuffling!", null, M) + to_chat(M, "You disarm [src]!") + else + playsound(loc, 'sound/weapons/pierce.ogg', 25, TRUE, -1) + Paralyze(100) + log_combat(M, src, "tackled") + visible_message("[M] tackles [src] down!", \ + "[M] tackles you down!", "You hear aggressive shuffling followed by a loud thud!", null, M) + to_chat(M, "You tackle [src] down!") /mob/living/carbon/human/attack_larva(mob/living/carbon/alien/larva/L) - - if(..()) //successful larva bite. - var/damage = rand(1, 3) - if(check_shields(L, damage, "the [L.name]")) - return 0 - if(stat != DEAD) - L.amount_grown = min(L.amount_grown + damage, L.max_grown) - var/obj/item/bodypart/affecting = get_bodypart(ran_zone(L.zone_selected)) - if(!affecting) - affecting = get_bodypart(BODY_ZONE_CHEST) - var/armor_block = run_armor_check(affecting, MELEE) - apply_damage(damage, BRUTE, affecting, armor_block) + . = ..() + if(!.) + return //successful larva bite. + var/damage = rand(1, 3) + if(check_shields(L, damage, "the [L.name]")) + return FALSE + if(stat != DEAD) + L.amount_grown = min(L.amount_grown + damage, L.max_grown) + var/obj/item/bodypart/affecting = get_bodypart(ran_zone(L.zone_selected)) + if(!affecting) + affecting = get_bodypart(BODY_ZONE_CHEST) + var/armor_block = run_armor_check(affecting, MELEE) + apply_damage(damage, BRUTE, affecting, armor_block) /mob/living/carbon/human/attack_animal(mob/living/simple_animal/M) . = ..() - if(.) - var/damage = rand(M.melee_damage_lower, M.melee_damage_upper) - if(check_shields(M, damage, "the [M.name]", MELEE_ATTACK, M.armour_penetration)) - return FALSE - var/dam_zone = dismembering_strike(M, pick(BODY_ZONE_CHEST, BODY_ZONE_PRECISE_L_HAND, BODY_ZONE_PRECISE_R_HAND, BODY_ZONE_L_LEG, BODY_ZONE_R_LEG)) - if(!dam_zone) //Dismemberment successful - return TRUE - var/obj/item/bodypart/affecting = get_bodypart(ran_zone(dam_zone)) - if(!affecting) - affecting = get_bodypart(BODY_ZONE_CHEST) - var/armor = run_armor_check(affecting, MELEE, armour_penetration = M.armour_penetration) - apply_damage(damage, M.melee_damage_type, affecting, armor, wound_bonus = M.wound_bonus, bare_wound_bonus = M.bare_wound_bonus, sharpness = M.sharpness) + if(!.) + return + var/damage = rand(M.melee_damage_lower, M.melee_damage_upper) + if(check_shields(M, damage, "the [M.name]", MELEE_ATTACK, M.armour_penetration)) + return FALSE + var/dam_zone = dismembering_strike(M, pick(BODY_ZONE_CHEST, BODY_ZONE_PRECISE_L_HAND, BODY_ZONE_PRECISE_R_HAND, BODY_ZONE_L_LEG, BODY_ZONE_R_LEG)) + if(!dam_zone) //Dismemberment successful + return TRUE + var/obj/item/bodypart/affecting = get_bodypart(ran_zone(dam_zone)) + if(!affecting) + affecting = get_bodypart(BODY_ZONE_CHEST) + var/armor = run_armor_check(affecting, MELEE, armour_penetration = M.armour_penetration) + apply_damage(damage, M.melee_damage_type, affecting, armor, wound_bonus = M.wound_bonus, bare_wound_bonus = M.bare_wound_bonus, sharpness = M.sharpness) /mob/living/carbon/human/attack_slime(mob/living/simple_animal/slime/M) - if(..()) //successful slime attack - var/damage = rand(5, 25) - var/wound_mod = -45 // 25^1.4=90, 90-45=45 - if(M.is_adult) - damage = rand(10, 35) - wound_mod = -90 // 35^1.4=145, 145-90=55 + . = ..() + if(!.) // slime attack failed + return + var/damage = rand(5, 25) + var/wound_mod = -45 // 25^1.4=90, 90-45=45 + if(M.is_adult) + damage = rand(10, 35) + wound_mod = -90 // 35^1.4=145, 145-90=55 - if(check_shields(M, damage, "the [M.name]")) - return 0 + if(check_shields(M, damage, "the [M.name]")) + return FALSE - var/dam_zone = dismembering_strike(M, pick(BODY_ZONE_HEAD, BODY_ZONE_CHEST, BODY_ZONE_L_ARM, BODY_ZONE_R_ARM, BODY_ZONE_L_LEG, BODY_ZONE_R_LEG)) - if(!dam_zone) //Dismemberment successful - return 1 + var/dam_zone = dismembering_strike(M, pick(BODY_ZONE_HEAD, BODY_ZONE_CHEST, BODY_ZONE_L_ARM, BODY_ZONE_R_ARM, BODY_ZONE_L_LEG, BODY_ZONE_R_LEG)) + if(!dam_zone) //Dismemberment successful + return TRUE - var/obj/item/bodypart/affecting = get_bodypart(ran_zone(dam_zone)) - if(!affecting) - affecting = get_bodypart(BODY_ZONE_CHEST) - var/armor_block = run_armor_check(affecting, MELEE) - apply_damage(damage, BRUTE, affecting, armor_block, wound_bonus=wound_mod) + var/obj/item/bodypart/affecting = get_bodypart(ran_zone(dam_zone)) + if(!affecting) + affecting = get_bodypart(BODY_ZONE_CHEST) + var/armor_block = run_armor_check(affecting, MELEE) + apply_damage(damage, BRUTE, affecting, armor_block, wound_bonus=wound_mod) /mob/living/carbon/human/mech_melee_attack(obj/mecha/M) diff --git a/code/modules/mob/living/carbon/human/human_defines.dm b/code/modules/mob/living/carbon/human/human_defines.dm index 9ae1c576ae..3c197bb32f 100644 --- a/code/modules/mob/living/carbon/human/human_defines.dm +++ b/code/modules/mob/living/carbon/human/human_defines.dm @@ -9,7 +9,7 @@ possible_a_intents = list(INTENT_HELP, INTENT_DISARM, INTENT_GRAB, INTENT_HARM) pressure_resistance = 25 can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 mob_biotypes = MOB_ORGANIC|MOB_HUMANOID blocks_emissive = EMISSIVE_BLOCK_UNIQUE can_be_shoved_into = TRUE diff --git a/code/modules/mob/living/carbon/human/human_movement.dm b/code/modules/mob/living/carbon/human/human_movement.dm index a5a6f432f8..5948b7fa93 100644 --- a/code/modules/mob/living/carbon/human/human_movement.dm +++ b/code/modules/mob/living/carbon/human/human_movement.dm @@ -11,14 +11,14 @@ /mob/living/carbon/human/slip(knockdown_amount, obj/O, lube, paralyze, forcedrop) if(HAS_TRAIT(src, TRAIT_NOSLIPALL)) - return 0 + return FALSE if (!(lube & GALOSHES_DONT_HELP)) if(HAS_TRAIT(src, TRAIT_NOSLIPWATER)) - return 0 + return FALSE if(shoes && istype(shoes, /obj/item/clothing)) var/obj/item/clothing/CS = shoes if (CS.clothing_flags & NOSLIP) - return 0 + return FALSE if (lube & SLIDE_ICE) if(shoes && istype(shoes, /obj/item/clothing)) var/obj/item/clothing/CS = shoes diff --git a/code/modules/mob/living/carbon/human/human_say.dm b/code/modules/mob/living/carbon/human/human_say.dm index 2ff1204844..8d54ed84e9 100644 --- a/code/modules/mob/living/carbon/human/human_say.dm +++ b/code/modules/mob/living/carbon/human/human_say.dm @@ -60,8 +60,8 @@ /mob/living/carbon/human/radio(message, list/message_mods = list(), list/spans, language) //Poly has a copy of this, lazy bastard . = ..() - if(. != FALSE) - return . + if(.) + return if(message_mods[MODE_HEADSET]) if(ears) @@ -76,7 +76,7 @@ ears.talk_into(src, message, message_mods[RADIO_EXTENSION], spans, language, message_mods) return ITALICS | REDUCE_RANGE - return 0 + return FALSE /mob/living/carbon/human/get_alt_name() if(name != GetVoice()) diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm index 70bf9cce8f..bc9a69097c 100644 --- a/code/modules/mob/living/carbon/human/life.dm +++ b/code/modules/mob/living/carbon/human/life.dm @@ -19,14 +19,13 @@ #define THERMAL_PROTECTION_HAND_RIGHT 0.025 /mob/living/carbon/human/Life() - set invisibility = 0 if (notransform) return . = ..() if (QDELETED(src)) - return 0 + return FALSE if(!IS_IN_STASIS(src)) if(.) //not dead @@ -49,7 +48,7 @@ name = get_visible_name() if(stat != DEAD) - return 1 + return TRUE /mob/living/carbon/human/calculate_affecting_pressure(pressure) diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm index 1a235723b7..9abdbf353e 100644 --- a/code/modules/mob/living/carbon/human/species.dm +++ b/code/modules/mob/living/carbon/human/species.dm @@ -240,20 +240,6 @@ GLOBAL_LIST_EMPTY(roundstart_races) /datum/species/proc/copy_properties_from(datum/species/old_species) return -/** - * Checks if this carbon is allowed to be a certain job or rank. - * - * Override this locally if you want to define when this species qualifies for what rank if human authority is enforced. - * Arguments: - * * rank - Rank to be tested. - * * features - Features of a species that factors into rank qualifications, like a human with cat ears being unable to join command positions. - */ -/datum/species/proc/qualifies_for_rank(rank, list/features) - if(rank in GLOB.command_positions) - return 0 - return 1 - - /** regenerate_organs * Corrects organs in a carbon, removing ones it doesn't need and adding ones it does * @@ -1185,7 +1171,7 @@ GLOBAL_LIST_EMPTY(roundstart_races) H.throw_alert("nutrition", /obj/screen/alert/starving) /datum/species/proc/update_health_hud(mob/living/carbon/human/H) - return 0 + return FALSE /datum/species/proc/handle_mutations_and_radiation(mob/living/carbon/human/H) if(HAS_TRAIT(H, TRAIT_RADIMMUNE)) @@ -1382,7 +1368,7 @@ GLOBAL_LIST_EMPTY(roundstart_races) H.visible_message("[M] attempts to touch [H]!", \ "[M] attempts to touch you!", "You hear a swoosh!", COMBAT_MESSAGE_RANGE, M) to_chat(M, "You attempt to touch [H]!") - return 0 + return SEND_SIGNAL(M, COMSIG_MOB_ATTACK_HAND, M, H, attacker_style) switch(M.a_intent) if("help") @@ -1401,11 +1387,11 @@ GLOBAL_LIST_EMPTY(roundstart_races) // Allows you to put in item-specific reactions based on species if(user != H) if(H.check_shields(I, I.force, "the [I.name]", MELEE_ATTACK, I.armour_penetration)) - return 0 + return FALSE if(H.check_block()) H.visible_message("[H] blocks [I]!", \ "You block [I]!") - return 0 + return FALSE var/hit_area if(!affecting) //Something went wrong. Maybe the limb is missing? @@ -1428,14 +1414,14 @@ GLOBAL_LIST_EMPTY(roundstart_races) H.send_item_attack_message(I, user, hit_area, affecting) if(!I.force) - return 0 //item force is zero + return FALSE //item force is zero - var/bloody = 0 + var/bloody = FALSE if(((I.damtype == BRUTE) && I.force && prob(25 + (I.force * 2)))) if(affecting.status == BODYPART_ORGANIC) I.add_mob_blood(H) //Make the weapon bloody, not the person. if(prob(I.force * 2)) //blood spatter! - bloody = 1 + bloody = TRUE var/turf/location = H.loc if(istype(location)) H.add_splatter_floor(location) diff --git a/code/modules/mob/living/carbon/human/species_types/felinid.dm b/code/modules/mob/living/carbon/human/species_types/felinid.dm index 39a014c667..15a76493df 100644 --- a/code/modules/mob/living/carbon/human/species_types/felinid.dm +++ b/code/modules/mob/living/carbon/human/species_types/felinid.dm @@ -15,9 +15,6 @@ var/original_felinid = TRUE //set to false for felinids created by mass-purrbation payday_modifier = 0.75 -/datum/species/human/felinid/qualifies_for_rank(rank, list/features) - return TRUE - //Curiosity killed the cat's wagging tail. /datum/species/human/felinid/spec_death(gibbed, mob/living/carbon/human/H) if(H) diff --git a/code/modules/mob/living/carbon/human/species_types/golems.dm b/code/modules/mob/living/carbon/human/species_types/golems.dm index 339e50de20..b1d3c9a595 100644 --- a/code/modules/mob/living/carbon/human/species_types/golems.dm +++ b/code/modules/mob/living/carbon/human/species_types/golems.dm @@ -471,10 +471,12 @@ var/last_teleport = 0 /datum/action/innate/unstable_teleport/IsAvailable() - if(..()) - if(world.time > last_teleport + cooldown) - return 1 - return 0 + . = ..() + if(!.) + return + if(world.time > last_teleport + cooldown) + return TRUE + return FALSE /datum/action/innate/unstable_teleport/Activate() var/mob/living/carbon/human/H = owner diff --git a/code/modules/mob/living/carbon/human/species_types/humans.dm b/code/modules/mob/living/carbon/human/species_types/humans.dm index 2c80700c58..fce8d234aa 100644 --- a/code/modules/mob/living/carbon/human/species_types/humans.dm +++ b/code/modules/mob/living/carbon/human/species_types/humans.dm @@ -10,6 +10,3 @@ liked_food = JUNKFOOD | FRIED changesource_flags = MIRROR_BADMIN | WABBAJACK | MIRROR_MAGIC | MIRROR_PRIDE | ERT_SPAWN | RACE_SWAP | SLIME_EXTRACT payday_modifier = 1 - -/datum/species/human/qualifies_for_rank(rank, list/features) - return TRUE //Pure humans are always allowed in all roles. diff --git a/code/modules/mob/living/carbon/human/species_types/jellypeople.dm b/code/modules/mob/living/carbon/human/species_types/jellypeople.dm index e51f0a1658..1f4f8ca1f6 100644 --- a/code/modules/mob/living/carbon/human/species_types/jellypeople.dm +++ b/code/modules/mob/living/carbon/human/species_types/jellypeople.dm @@ -73,14 +73,15 @@ background_icon_state = "bg_alien" /datum/action/innate/regenerate_limbs/IsAvailable() - if(..()) - var/mob/living/carbon/human/H = owner - var/list/limbs_to_heal = H.get_missing_limbs() - if(limbs_to_heal.len < 1) - return 0 - if(H.blood_volume >= BLOOD_VOLUME_OKAY+40) - return 1 - return 0 + . = ..() + if(!.) + return + var/mob/living/carbon/human/H = owner + var/list/limbs_to_heal = H.get_missing_limbs() + if(limbs_to_heal.len < 1) + return FALSE + if(H.blood_volume >= BLOOD_VOLUME_OKAY+40) + return TRUE /datum/action/innate/regenerate_limbs/Activate() var/mob/living/carbon/human/H = owner @@ -182,11 +183,13 @@ background_icon_state = "bg_alien" /datum/action/innate/split_body/IsAvailable() - if(..()) - var/mob/living/carbon/human/H = owner - if(H.blood_volume >= BLOOD_VOLUME_SLIME_SPLIT) - return 1 - return 0 + . = ..() + if(!.) + return + var/mob/living/carbon/human/H = owner + if(H.blood_volume >= BLOOD_VOLUME_SLIME_SPLIT) + return TRUE + return FALSE /datum/action/innate/split_body/Activate() var/mob/living/carbon/human/H = owner diff --git a/code/modules/mob/living/carbon/human/species_types/plasmamen.dm b/code/modules/mob/living/carbon/human/species_types/plasmamen.dm index bea6545a86..b70c3b6c90 100644 --- a/code/modules/mob/living/carbon/human/species_types/plasmamen.dm +++ b/code/modules/mob/living/carbon/human/species_types/plasmamen.dm @@ -158,7 +158,6 @@ H.equipOutfit(O, visualsOnly) H.internal = H.get_item_for_held_index(2) H.update_internals_hud_icon(1) - return 0 /datum/species/plasmaman/random_name(gender,unique,lastname) if(unique) diff --git a/code/modules/mob/living/carbon/life.dm b/code/modules/mob/living/carbon/life.dm index 23677909bb..82fee6cbab 100644 --- a/code/modules/mob/living/carbon/life.dm +++ b/code/modules/mob/living/carbon/life.dm @@ -1,5 +1,4 @@ /mob/living/carbon/Life() - set invisibility = 0 if(notransform) return @@ -137,9 +136,9 @@ //Third link in a breath chain, calls handle_breath_temperature() /mob/living/carbon/proc/check_breath(datum/gas_mixture/breath) if(status_flags & GODMODE) - return + return FALSE if(HAS_TRAIT(src, TRAIT_NOBREATH)) - return + return FALSE var/obj/item/organ/lungs = getorganslot(ORGAN_SLOT_LUNGS) if(!lungs) @@ -148,12 +147,12 @@ //CRIT if(!breath || (breath.total_moles() == 0) || !lungs) if(reagents.has_reagent(/datum/reagent/medicine/epinephrine, needs_metabolizing = TRUE) && lungs) - return + return FALSE adjustOxyLoss(1) failed_last_breath = 1 throw_alert("not_enough_oxy", /obj/screen/alert/not_enough_oxy) - return 0 + return FALSE var/safe_oxy_min = 16 var/safe_co2_max = 10 @@ -305,7 +304,7 @@ //BREATH TEMPERATURE handle_breath_temperature(breath) - return 1 + return TRUE //Fourth and final link in a breath chain /mob/living/carbon/proc/handle_breath_temperature(datum/gas_mixture/breath) diff --git a/code/modules/mob/living/carbon/monkey/combat.dm b/code/modules/mob/living/carbon/monkey/combat.dm index f31bbd45cf..cafc5ab2d5 100644 --- a/code/modules/mob/living/carbon/monkey/combat.dm +++ b/code/modules/mob/living/carbon/monkey/combat.dm @@ -27,7 +27,7 @@ // taken from /mob/living/carbon/human/interactive/ /mob/living/carbon/monkey/proc/walk2derpless(target) if(!target || IsStandingStill()) - return 0 + return FALSE if(myPath.len <= 0) myPath = get_path_to(src, get_turf(target), /turf/proc/Distance, MAX_RANGE_FIND + 1, 250,1) @@ -39,26 +39,26 @@ if(myPath.len >= 1) walk_to(src,myPath[1],0,5) myPath -= myPath[1] - return 1 + return TRUE // failed to path correctly so just try to head straight for a bit walk_to(src,get_turf(target),0,5) sleep(1) walk_to(src,0) - return 0 + return FALSE // taken from /mob/living/carbon/human/interactive/ /mob/living/carbon/monkey/proc/IsDeadOrIncap(checkDead = TRUE) if(!(mobility_flags & MOBILITY_FLAGS_INTERACTION)) - return 1 + return TRUE if(health <= 0 && checkDead) - return 1 + return TRUE if(IsStun() || IsParalyzed()) - return 1 + return TRUE if(stat) - return 1 - return 0 + return TRUE + return FALSE /mob/living/carbon/monkey/proc/battle_screech() if(next_battle_screech < world.time) diff --git a/code/modules/mob/living/carbon/monkey/life.dm b/code/modules/mob/living/carbon/monkey/life.dm index f156aa27f3..a52fa0bb75 100644 --- a/code/modules/mob/living/carbon/monkey/life.dm +++ b/code/modules/mob/living/carbon/monkey/life.dm @@ -4,8 +4,6 @@ /mob/living/carbon/monkey/Life() - set invisibility = 0 - if (notransform) return diff --git a/code/modules/mob/living/life.dm b/code/modules/mob/living/life.dm index 052a94f289..7cce89593b 100644 --- a/code/modules/mob/living/life.dm +++ b/code/modules/mob/living/life.dm @@ -3,7 +3,6 @@ /mob/living/proc/Life(seconds, times_fired) set waitfor = FALSE - set invisibility = 0 if((movement_type & FLYING) && !(movement_type & FLOATING)) //TODO: Better floating float(on = TRUE) diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 48cb75d14a..644a6a6de4 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -140,7 +140,7 @@ //switch our position with M if(loc && !loc.Adjacent(M.loc)) return TRUE - now_pushing = 1 + now_pushing = TRUE var/oldloc = loc var/oldMloc = M.loc @@ -160,7 +160,7 @@ if(!M_passmob) M.pass_flags &= ~PASSMOB - now_pushing = 0 + now_pushing = FALSE if(!move_failed) return TRUE @@ -1132,7 +1132,7 @@ /mob/living/proc/ExtinguishMob() if(on_fire) - on_fire = 0 + on_fire = FALSE fire_stacks = 0 for(var/obj/effect/dummy/lighting_obj/moblight/fire/F in src) qdel(F) diff --git a/code/modules/mob/living/living_defense.dm b/code/modules/mob/living/living_defense.dm index 68981a88f5..f18eba989b 100644 --- a/code/modules/mob/living/living_defense.dm +++ b/code/modules/mob/living/living_defense.dm @@ -174,12 +174,12 @@ if(GRAB_NECK) log_combat(user, src, "attempted to strangle", addition="kill grab") if(!do_mob(user, src, grab_upgrade_time)) - return 0 + return FALSE if(!user.pulling || user.pulling != src || user.grab_state != old_grab_state) - return 0 + return FALSE if(user.a_intent != INTENT_GRAB) to_chat(user, "You must be on grab intent to upgrade your grab further!") - return 0 + return FALSE user.setGrabState(user.grab_state + 1) switch(user.grab_state) if(GRAB_AGGRESSIVE) @@ -213,7 +213,7 @@ if(!buckled && !density) Move(user.loc) user.set_pull_offsets(src, grab_state) - return 1 + return TRUE /mob/living/attack_slime(mob/living/simple_animal/slime/M) @@ -425,7 +425,7 @@ //called when the mob receives a loud bang /mob/living/proc/soundbang_act() - return 0 + return FALSE //to damage the clothes worn by a mob /mob/living/proc/damage_clothes(damage_amount, damage_type = BRUTE, damage_flag = 0, def_zone) diff --git a/code/modules/mob/living/logout.dm b/code/modules/mob/living/logout.dm index 12dd07ae98..ca5296cdff 100644 --- a/code/modules/mob/living/logout.dm +++ b/code/modules/mob/living/logout.dm @@ -2,5 +2,5 @@ update_z(null) ..() if(!key && mind) //key and mind have become separated. - mind.active = 0 //This is to stop say, a mind.transfer_to call on a corpse causing a ghost to re-enter its body. + mind.active = FALSE //This is to stop say, a mind.transfer_to call on a corpse causing a ghost to re-enter its body. med_hud_set_status() diff --git a/code/modules/mob/living/silicon/ai/ai.dm b/code/modules/mob/living/silicon/ai/ai.dm index 5dfdc397ca..3f436e3670 100644 --- a/code/modules/mob/living/silicon/ai/ai.dm +++ b/code/modules/mob/living/silicon/ai/ai.dm @@ -789,7 +789,7 @@ to_chat(user, "Transfer successful: [name] ([rand(1000,9999)].exe) removed from host terminal and stored within local memory.") /mob/living/silicon/ai/can_buckle() - return 0 + return FALSE /mob/living/silicon/ai/incapacitated(ignore_restraints = FALSE, ignore_grab = FALSE, ignore_stasis = FALSE) if(aiRestorePowerRoutine) diff --git a/code/modules/mob/living/silicon/ai/ai_defense.dm b/code/modules/mob/living/silicon/ai/ai_defense.dm index 1714bc5f86..2c53448f09 100644 --- a/code/modules/mob/living/silicon/ai/ai_defense.dm +++ b/code/modules/mob/living/silicon/ai/ai_defense.dm @@ -24,8 +24,8 @@ if (stat != DEAD) adjustBruteLoss(60) updatehealth() - return 1 - return 0 + return TRUE + return FALSE /mob/living/silicon/ai/emp_act(severity) . = ..() diff --git a/code/modules/mob/living/silicon/ai/ai_say.dm b/code/modules/mob/living/silicon/ai/ai_say.dm index 82444a8e4e..1b1f4e400b 100644 --- a/code/modules/mob/living/silicon/ai/ai_say.dm +++ b/code/modules/mob/living/silicon/ai/ai_say.dm @@ -148,8 +148,8 @@ SEND_SOUND(M, voice) else SEND_SOUND(only_listener, voice) - return 1 - return 0 + return TRUE + return FALSE #undef VOX_DELAY #endif diff --git a/code/modules/mob/living/silicon/ai/freelook/eye.dm b/code/modules/mob/living/silicon/ai/freelook/eye.dm index 4cc0fb92c5..a54f825925 100644 --- a/code/modules/mob/living/silicon/ai/freelook/eye.dm +++ b/code/modules/mob/living/silicon/ai/freelook/eye.dm @@ -114,7 +114,7 @@ return TRUE /mob/camera/ai_eye/Move() - return 0 + return /mob/camera/ai_eye/proc/GetViewerClient() if(ai) diff --git a/code/modules/mob/living/silicon/pai/personality.dm b/code/modules/mob/living/silicon/pai/personality.dm index 35d4f2d960..acf766c342 100644 --- a/code/modules/mob/living/silicon/pai/personality.dm +++ b/code/modules/mob/living/silicon/pai/personality.dm @@ -12,7 +12,7 @@ /datum/pai_candidate/proc/savefile_save(mob/user) if(IsGuestKey(user.key)) - return 0 + return FALSE var/savefile/F = new /savefile(src.savefile_path(user)) @@ -24,7 +24,7 @@ WRITE_FILE(F["version"], 1) - return 1 + return TRUE // loads the savefile corresponding to the mob's ckey // if silent=true, report incompatible savefiles diff --git a/code/modules/mob/living/silicon/robot/laws.dm b/code/modules/mob/living/silicon/robot/laws.dm index b4362d0137..cd9bbf3792 100644 --- a/code/modules/mob/living/silicon/robot/laws.dm +++ b/code/modules/mob/living/silicon/robot/laws.dm @@ -11,7 +11,7 @@ return ..() -/mob/living/silicon/robot/show_laws(everyone = 0) +/mob/living/silicon/robot/show_laws(everyone = FALSE) laws_sanity_check() var/who @@ -29,7 +29,7 @@ to_chat(src, "Laws synced with AI, be sure to note any changes.") else to_chat(src, "No AI selected to sync laws with, disabling lawsync protocol.") - lawupdate = 0 + lawupdate = FALSE to_chat(who, "Obey these laws:") laws.show_laws(who) diff --git a/code/modules/mob/living/silicon/robot/life.dm b/code/modules/mob/living/silicon/robot/life.dm index d51a332655..8cf67247ba 100644 --- a/code/modules/mob/living/silicon/robot/life.dm +++ b/code/modules/mob/living/silicon/robot/life.dm @@ -1,5 +1,4 @@ /mob/living/silicon/robot/Life() - set invisibility = 0 if (src.notransform) return @@ -11,7 +10,7 @@ if(stat != DEAD) if(low_power_mode) if(cell && cell.charge) - low_power_mode = 0 + low_power_mode = FALSE update_headlamp() else if(stat == CONSCIOUS) use_power() @@ -24,7 +23,7 @@ cell.use(amt) //Usage table: 1/tick if off/lowest setting, 4 = 4/tick, 6 = 8/tick, 8 = 12/tick, 10 = 16/tick else uneq_all() - low_power_mode = 1 + low_power_mode = TRUE update_headlamp() diag_hud_set_borgcell() diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm index 36225bdedf..c767ba88aa 100644 --- a/code/modules/mob/living/silicon/robot/robot.dm +++ b/code/modules/mob/living/silicon/robot/robot.dm @@ -53,10 +53,10 @@ var/mob/living/silicon/ai/connected_ai = null var/obj/item/stock_parts/cell/cell = /obj/item/stock_parts/cell/high ///If this is a path, this gets created as an object in Initialize. - var/opened = 0 + var/opened = FALSE var/emagged = FALSE var/emag_cooldown = 0 - var/wiresexposed = 0 + var/wiresexposed = FALSE /// Random serial number generated for each cyborg upon its initialization var/ident = 0 @@ -74,7 +74,7 @@ var/datum/effect_system/spark_spread/spark_system // So they can initialize sparks whenever/N var/lawupdate = 1 //Cyborgs will sync their laws with their AI by default - var/scrambledcodes = 0 // Used to determine if a borg shows up on the robotics console. Setting to one hides them. + var/scrambledcodes = FALSE // Used to determine if a borg shows up on the robotics console. Setting to TRUE hides them. var/lockcharge //Boolean of whether the borg is locked down or not var/toner = 0 @@ -94,7 +94,7 @@ var/hat_offset = -3 can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 var/static/list/can_ride_typecache = typecacheof(/mob/living/carbon/human) /mob/living/silicon/robot/get_cell() @@ -324,13 +324,13 @@ . += "Master AI: [connected_ai.name]" /mob/living/silicon/robot/restrained(ignore_grab) - . = 0 + return /mob/living/silicon/robot/triggerAlarm(class, area/A, O, obj/alarmsource) if(alarmsource.z != z) return if(stat == DEAD) - return 1 + return TRUE var/list/L = alarms[class] for (var/I in L) if (I == A.name) @@ -338,7 +338,7 @@ var/list/sources = alarm[3] if (!(alarmsource in sources)) sources += alarmsource - return 1 + return TRUE var/obj/machinery/camera/C = null var/list/CL = null if (O && istype(O, /list)) @@ -349,11 +349,11 @@ C = O L[A.name] = list(A, (C) ? C : O, list(alarmsource)) queueAlarm(text("--- [class] alarm detected in [A.name]!"), class) - return 1 + return TRUE /mob/living/silicon/robot/cancelAlarm(class, area/A, obj/origin) var/list/L = alarms[class] - var/cleared = 0 + var/cleared = FALSE for (var/I in L) if (I == A.name) var/list/alarm = L[I] @@ -361,7 +361,7 @@ if (origin in srcs) srcs -= origin if (srcs.len == 0) - cleared = 1 + cleared = TRUE L -= I if (cleared) queueAlarm("--- [class] alarm in [A.name] has been cleared.", class, 0) @@ -392,36 +392,36 @@ /mob/living/silicon/robot/proc/allowed(mob/M) //check if it doesn't require any access at all if(check_access(null)) - return 1 + return TRUE if(ishuman(M)) var/mob/living/carbon/human/H = M //if they are holding or wearing a card that has access, that works if(check_access(H.get_active_held_item()) || check_access(H.wear_id)) - return 1 + return TRUE else if(ismonkey(M)) var/mob/living/carbon/monkey/george = M //they can only hold things :( if(isitem(george.get_active_held_item())) return check_access(george.get_active_held_item()) - return 0 + return FALSE /mob/living/silicon/robot/proc/check_access(obj/item/card/id/I) if(!istype(req_access, /list)) //something's very wrong - return 1 + return TRUE var/list/L = req_access if(!L.len) //no requirements - return 1 + return TRUE if(!istype(I, /obj/item/card/id) && isitem(I)) I = I.GetID() if(!I || !I.access) //not ID or no access - return 0 + return FALSE for(var/req in req_access) if(!(req in I.access)) //doesn't have this access - return 0 - return 1 + return FALSE + return TRUE /mob/living/silicon/robot/regenerate_icons() return update_icons() @@ -582,7 +582,7 @@ robot_suit.r_leg = null new /obj/item/stack/cable_coil(T, robot_suit.chest.wired) robot_suit.chest.forceMove(T) - robot_suit.chest.wired = 0 + robot_suit.chest.wired = FALSE robot_suit.chest = null robot_suit.l_arm.forceMove(T) robot_suit.l_arm = null @@ -1049,7 +1049,7 @@ else M.visible_message("[M] can't climb onto [src] because [M.p_their()] hands are full!") return - . = ..(M, force, check_loc) + return ..() /mob/living/silicon/robot/unbuckle_mob(mob/user, force=FALSE) if(iscarbon(user)) @@ -1057,7 +1057,7 @@ if(istype(riding_datum)) riding_datum.unequip_buckle_inhands(user) riding_datum.restore_position(user) - . = ..(user) + return ..() /mob/living/silicon/robot/resist() . = ..() @@ -1073,7 +1073,7 @@ if(connected_ai) connected_ai.connected_robots += src lawsync() - lawupdate = 1 + lawupdate = TRUE return TRUE picturesync() return FALSE diff --git a/code/modules/mob/living/silicon/robot/robot_defense.dm b/code/modules/mob/living/silicon/robot/robot_defense.dm index bc872ba060..952514adda 100644 --- a/code/modules/mob/living/silicon/robot/robot_defense.dm +++ b/code/modules/mob/living/silicon/robot/robot_defense.dm @@ -42,14 +42,14 @@ GLOBAL_LIST_INIT(blacklisted_borg_hats, typecacheof(list( //Hats that don't real if(W.tool_behaviour == TOOL_CROWBAR) // crowbar means open or close the cover if(opened) to_chat(user, "You close the cover.") - opened = 0 + opened = FALSE update_icons() else if(locked) to_chat(user, "The cover is locked and cannot be opened!") else to_chat(user, "You open the cover.") - opened = 1 + opened = TRUE update_icons() return @@ -340,7 +340,7 @@ GLOBAL_LIST_INIT(blacklisted_borg_hats, typecacheof(list( //Hats that don't real SetEmagged(1) SetStun(60) //Borgs were getting into trouble because they would attack the emagger before the new laws were shown - lawupdate = 0 + lawupdate = FALSE connected_ai = null message_admins("[ADMIN_LOOKUPFLW(user)] emagged cyborg [ADMIN_LOOKUPFLW(src)]. Laws overridden.") log_game("[key_name(user)] emagged cyborg [key_name(src)]. Laws overridden.") diff --git a/code/modules/mob/living/silicon/silicon.dm b/code/modules/mob/living/silicon/silicon.dm index de8ea801b8..b7fd16ea80 100644 --- a/code/modules/mob/living/silicon/silicon.dm +++ b/code/modules/mob/living/silicon/silicon.dm @@ -371,12 +371,12 @@ to_chat(src, "Automatic announcements [Autochan == "None" ? "will not use the radio." : "set to [Autochan]."]") /mob/living/silicon/put_in_hand_check() // This check is for borgs being able to receive items, not put them in others' hands. - return 0 + return FALSE // The src mob is trying to place an item on someone // But the src mob is a silicon!! Disable. /mob/living/silicon/stripPanelEquip(obj/item/what, mob/who, slot) - return 0 + return FALSE /mob/living/silicon/assess_threat(judgement_criteria, lasercolor = "", datum/callback/weaponcheck=null) //Secbots won't hunt silicon units diff --git a/code/modules/mob/living/silicon/silicon_say.dm b/code/modules/mob/living/silicon/silicon_say.dm index 48062a69f5..1401c21e42 100644 --- a/code/modules/mob/living/silicon/silicon_say.dm +++ b/code/modules/mob/living/silicon/silicon_say.dm @@ -24,15 +24,15 @@ to_chat(M, "[link] [rendered]") /mob/living/silicon/binarycheck() - return 1 + return TRUE /mob/living/silicon/lingcheck() - return 0 //Borged or AI'd lings can't speak on the ling channel. + return FALSE //Borged or AI'd lings can't speak on the ling channel. /mob/living/silicon/radio(message, list/message_mods = list(), list/spans, language) . = ..() - if(. != 0) - return . + if(!.) + return if(message_mods[MODE_HEADSET]) if(radio) radio.talk_into(src, message, , spans, language, message_mods) @@ -42,4 +42,4 @@ radio.talk_into(src, message, message_mods[RADIO_EXTENSION], spans, language, message_mods) return ITALICS | REDUCE_RANGE - return 0 + return FALSE diff --git a/code/modules/mob/living/simple_animal/bot/bot.dm b/code/modules/mob/living/simple_animal/bot/bot.dm index 9beae1714f..5fded700f2 100644 --- a/code/modules/mob/living/simple_animal/bot/bot.dm +++ b/code/modules/mob/living/simple_animal/bot/bot.dm @@ -404,7 +404,7 @@ /mob/living/simple_animal/bot/radio(message, list/message_mods = list(), list/spans, language) . = ..() - if(. != 0) + if(!.) return if(message_mods[MODE_HEADSET]) @@ -693,7 +693,7 @@ Pass a positive integer as an argument to override a bot's default speed. patrol_target = nearest_beacon_loc destination = next_destination else - auto_patrol = 0 + auto_patrol = FALSE mode = BOT_IDLE speak("Disengaging patrol mode.") @@ -732,11 +732,11 @@ Pass a positive integer as an argument to override a bot's default speed. // process control input switch(command) if("patroloff") - bot_reset() //HOLD IT!! - auto_patrol = 0 + bot_reset() //HOLD IT!! //OBJECTION!! + auto_patrol = FALSE if("patrolon") - auto_patrol = 1 + auto_patrol = TRUE if("summon") bot_reset() @@ -751,7 +751,7 @@ Pass a positive integer as an argument to override a bot's default speed. ejectpairemote(user) return -// + /mob/living/simple_animal/bot/proc/bot_control_message(command, user) switch(command) if("patroloff") @@ -831,7 +831,7 @@ Pass a positive integer as an argument to override a bot's default speed. dat = get_controls(M) var/datum/browser/popup = new(M,window_id,window_name,350,600) popup.set_content(dat) - popup.open(use_onclose = 0) + popup.open(use_onclose = FALSE) onclose(M,window_id,ref=src) return diff --git a/code/modules/mob/living/simple_animal/bot/construction.dm b/code/modules/mob/living/simple_animal/bot/construction.dm index cf5ce1f77b..dee1fa482c 100644 --- a/code/modules/mob/living/simple_animal/bot/construction.dm +++ b/code/modules/mob/living/simple_animal/bot/construction.dm @@ -287,7 +287,7 @@ to_chat(user, "You add the [I] to [src]! Honk!") var/mob/living/simple_animal/bot/honkbot/S = new(drop_location()) S.name = created_name - S.spam_flag = TRUE // only long enough to hear the first ping. + S.limiting_spam = TRUE // only long enough to hear the first ping. addtimer(CALLBACK (S, .mob/living/simple_animal/bot/honkbot/proc/react_ping), 5) S.bikehorn = I.type qdel(I) diff --git a/code/modules/mob/living/simple_animal/bot/honkbot.dm b/code/modules/mob/living/simple_animal/bot/honkbot.dm index 41d78292fd..6e4b6dba89 100644 --- a/code/modules/mob/living/simple_animal/bot/honkbot.dm +++ b/code/modules/mob/living/simple_animal/bot/honkbot.dm @@ -21,7 +21,7 @@ path_image_color = "#FF69B4" var/honksound = 'sound/items/bikehorn.ogg' //customizable sound - var/spam_flag = FALSE + var/limiting_spam = FALSE var/cooldowntime = 30 var/cooldowntimehorn = 10 var/mob/living/carbon/target @@ -45,8 +45,8 @@ access_card.access += J.get_access() prev_access = access_card.access -/mob/living/simple_animal/bot/honkbot/proc/spam_flag_false() //used for addtimer - spam_flag = FALSE +/mob/living/simple_animal/bot/honkbot/proc/limiting_spam_false() //used for addtimer + limiting_spam = FALSE /mob/living/simple_animal/bot/honkbot/proc/sensor_blink() icon_state = "honkbot-c" @@ -55,9 +55,9 @@ //honkbots react with sounds. /mob/living/simple_animal/bot/honkbot/proc/react_ping() playsound(src, 'sound/machines/ping.ogg', 50, TRUE, -1) //the first sound upon creation! - spam_flag = TRUE + limiting_spam = TRUE sensor_blink() - addtimer(CALLBACK(src, .proc/spam_flag_false), 18) // calibrates before starting the honk + addtimer(CALLBACK(src, .proc/limiting_spam_false), 18) // calibrates before starting the honk /mob/living/simple_animal/bot/honkbot/proc/react_buzz() playsound(src, 'sound/machines/buzz-sigh.ogg', 50, TRUE, -1) @@ -70,7 +70,7 @@ anchored = FALSE walk_to(src,0) last_found = world.time - spam_flag = FALSE + limiting_spam = FALSE /mob/living/simple_animal/bot/honkbot/set_custom_texts() @@ -151,7 +151,7 @@ Maintenance panel panel is [open ? "opened" : "closed"]"}, if(!C.IsParalyzed() || arrest_type) stun_attack(A) ..() - else if (!spam_flag) //honking at the ground + else if (!limiting_spam) //honking at the ground bike_horn(A) @@ -166,31 +166,31 @@ Maintenance panel panel is [open ? "opened" : "closed"]"}, /mob/living/simple_animal/bot/honkbot/proc/bike_horn() //use bike_horn if (emagged <= 1) - if (!spam_flag) + if (!limiting_spam) playsound(src, honksound, 50, TRUE, -1) - spam_flag = TRUE //prevent spam + limiting_spam = TRUE //prevent spam sensor_blink() - addtimer(CALLBACK(src, .proc/spam_flag_false), cooldowntimehorn) + addtimer(CALLBACK(src, .proc/limiting_spam_false), cooldowntimehorn) else if (emagged == 2) //emagged honkbots will spam short and memorable sounds. - if (!spam_flag) + if (!limiting_spam) playsound(src, "honkbot_e", 50, FALSE) - spam_flag = TRUE // prevent spam + limiting_spam = TRUE // prevent spam icon_state = "honkbot-e" addtimer(CALLBACK(src, /atom/.proc/update_icon), 30, TIMER_OVERRIDE|TIMER_UNIQUE) - addtimer(CALLBACK(src, .proc/spam_flag_false), cooldowntimehorn) + addtimer(CALLBACK(src, .proc/limiting_spam_false), cooldowntimehorn) /mob/living/simple_animal/bot/honkbot/proc/honk_attack(mob/living/carbon/C) // horn attack - if(!spam_flag) + if(!limiting_spam) playsound(loc, honksound, 50, TRUE, -1) - spam_flag = TRUE // prevent spam + limiting_spam = TRUE // prevent spam sensor_blink() - addtimer(CALLBACK(src, .proc/spam_flag_false), cooldowntimehorn) + addtimer(CALLBACK(src, .proc/limiting_spam_false), cooldowntimehorn) /mob/living/simple_animal/bot/honkbot/proc/stun_attack(mob/living/carbon/C) // airhorn stun - if(!spam_flag) + if(!limiting_spam) playsound(src, 'sound/items/AirHorn.ogg', 100, TRUE, -1) //HEEEEEEEEEEEENK!! sensor_blink() - if(spam_flag == 0) + if(limiting_spam == 0) if(ishuman(C)) C.stuttering = 20 var/obj/item/organ/ears/ears = C.getorganslot(ORGAN_SLOT_EARS) @@ -200,7 +200,7 @@ Maintenance panel panel is [open ? "opened" : "closed"]"}, C.Paralyze(60) var/mob/living/carbon/human/H = C if(client) //prevent spam from players.. - spam_flag = TRUE + limiting_spam = TRUE if (emagged <= 1) //HONK once, then leave var/judgement_criteria = judgement_criteria() threatlevel = H.assess_threat(judgement_criteria) @@ -208,7 +208,7 @@ Maintenance panel panel is [open ? "opened" : "closed"]"}, target = oldtarget_name else // you really don't want to hit an emagged honkbot threatlevel = 6 // will never let you go - addtimer(CALLBACK(src, .proc/spam_flag_false), cooldowntime) + addtimer(CALLBACK(src, .proc/limiting_spam_false), cooldowntime) log_combat(src,C,"honked") @@ -217,7 +217,7 @@ Maintenance panel panel is [open ? "opened" : "closed"]"}, else C.stuttering = 20 C.Paralyze(80) - addtimer(CALLBACK(src, .proc/spam_flag_false), cooldowntime) + addtimer(CALLBACK(src, .proc/limiting_spam_false), cooldowntime) /mob/living/simple_animal/bot/honkbot/handle_automated_action() @@ -303,14 +303,14 @@ Maintenance panel panel is [open ? "opened" : "closed"]"}, if(threatlevel <= 3) if(C in view(4,src)) //keep the range short for patrolling - if(!spam_flag) + if(!limiting_spam) bike_horn() else if(threatlevel >= 10) bike_horn() //just spam the shit outta this else if(threatlevel >= 4) - if(!spam_flag) + if(!limiting_spam) target = C oldtarget_name = C.name bike_horn() diff --git a/code/modules/mob/living/simple_animal/constructs.dm b/code/modules/mob/living/simple_animal/constructs.dm index 4972a860db..390db50ed3 100644 --- a/code/modules/mob/living/simple_animal/constructs.dm +++ b/code/modules/mob/living/simple_animal/constructs.dm @@ -281,17 +281,15 @@ if(isconstruct(A)) //is it a construct? var/mob/living/simple_animal/hostile/construct/C = A if(C.health < C.maxHealth) //is it hurt? let's go heal it if it is - return 1 - else - return 0 - else - return 0 + return TRUE + return FALSE /mob/living/simple_animal/hostile/construct/artificer/CanAttack(atom/the_target) if(see_invisible < the_target.invisibility)//Target's invisible to us, forget it - return 0 + return FALSE if(Found(the_target) || ..()) //If we Found it or Can_Attack it normally, we Can_Attack it as long as it wasn't invisible - return 1 //as a note this shouldn't be added to base hostile mobs because it'll mess up retaliate hostile mobs + return TRUE //as a note this shouldn't be added to base hostile mobs because it'll mess up retaliate hostile mobs + return FALSE /mob/living/simple_animal/hostile/construct/artificer/MoveToTarget(list/possible_targets) ..() @@ -299,7 +297,7 @@ var/mob/living/L = target if(isconstruct(L) && L.health >= L.maxHealth) //is this target an unhurt construct? stop trying to heal it LoseTarget() - return 0 + return if(L.health <= melee_damage_lower+melee_damage_upper) //ey bucko you're hurt as fuck let's go hit you retreat_distance = null minimum_distance = 1 diff --git a/code/modules/mob/living/simple_animal/friendly/dog.dm b/code/modules/mob/living/simple_animal/friendly/dog.dm index 8c74ec337f..4543568889 100644 --- a/code/modules/mob/living/simple_animal/friendly/dog.dm +++ b/code/modules/mob/living/simple_animal/friendly/dog.dm @@ -38,16 +38,16 @@ turns_since_scan = 0 if((movement_target) && !(isturf(movement_target.loc) || ishuman(movement_target.loc) )) movement_target = null - stop_automated_movement = 0 + stop_automated_movement = FALSE if( !movement_target || !(movement_target.loc in oview(src, 3)) ) movement_target = null - stop_automated_movement = 0 + stop_automated_movement = FALSE for(var/obj/item/reagent_containers/food/snacks/S in oview(src,3)) if(isturf(S.loc) || ishuman(S.loc)) movement_target = S break if(movement_target) - stop_automated_movement = 1 + stop_automated_movement = TRUE step_to(src,movement_target,1) sleep(3) step_to(src,movement_target,1) @@ -359,7 +359,7 @@ if(user && !user.temporarilyRemoveItemFromInventory(item_to_add)) to_chat(user, "\The [item_to_add] is stuck to your hand, you cannot put it on [src]'s head!") - return 0 + return var/valid = FALSE if(ispath(item_to_add.dog_fashion, /datum/dog_fashion/head)) diff --git a/code/modules/mob/living/simple_animal/friendly/drone/_drone.dm b/code/modules/mob/living/simple_animal/friendly/drone/_drone.dm index 06545473b0..3738354f54 100644 --- a/code/modules/mob/living/simple_animal/friendly/drone/_drone.dm +++ b/code/modules/mob/living/simple_animal/friendly/drone/_drone.dm @@ -308,7 +308,7 @@ return ..() /mob/living/simple_animal/drone/mob_negates_gravity() - return 1 + return TRUE /mob/living/simple_animal/drone/mob_has_gravity() return ..() || mob_negates_gravity() @@ -318,7 +318,7 @@ /mob/living/simple_animal/drone/bee_friendly() // Why would bees pay attention to drones? - return 1 + return TRUE /mob/living/simple_animal/drone/electrocute_act(shock_damage, source, siemens_coeff, flags = NONE) - return 0 //So they don't die trying to fix wiring + return FALSE //So they don't die trying to fix wiring diff --git a/code/modules/mob/living/simple_animal/friendly/farm_animals.dm b/code/modules/mob/living/simple_animal/friendly/farm_animals.dm index f78ad951e6..f96b894be1 100644 --- a/code/modules/mob/living/simple_animal/friendly/farm_animals.dm +++ b/code/modules/mob/living/simple_animal/friendly/farm_animals.dm @@ -170,7 +170,7 @@ /mob/living/simple_animal/cow/tamed() . = ..() can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 var/datum/component/riding/D = LoadComponent(/datum/component/riding) D.set_riding_offsets(RIDING_OFFSET_ALL, list(TEXT_NORTH = list(0, 8), TEXT_SOUTH = list(0, 8), TEXT_EAST = list(-2, 8), TEXT_WEST = list(2, 8))) D.set_vehicle_dir_layer(SOUTH, ABOVE_MOB_LAYER) diff --git a/code/modules/mob/living/simple_animal/hostile/bear.dm b/code/modules/mob/living/simple_animal/hostile/bear.dm index 19633468a3..9a5e7c9418 100644 --- a/code/modules/mob/living/simple_animal/hostile/bear.dm +++ b/code/modules/mob/living/simple_animal/hostile/bear.dm @@ -60,7 +60,7 @@ . = ..() if(!rideable && mind) can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 var/datum/component/riding/D = LoadComponent(/datum/component/riding) D.set_riding_offsets(RIDING_OFFSET_ALL, list(TEXT_NORTH = list(1, 8), TEXT_SOUTH = list(1, 8), TEXT_EAST = list(-3, 6), TEXT_WEST = list(3, 6))) D.set_vehicle_dir_layer(SOUTH, ABOVE_MOB_LAYER) diff --git a/code/modules/mob/living/simple_animal/hostile/bosses/boss.dm b/code/modules/mob/living/simple_animal/hostile/bosses/boss.dm index 441c306243..0fc0b43596 100644 --- a/code/modules/mob/living/simple_animal/hostile/bosses/boss.dm +++ b/code/modules/mob/living/simple_animal/hostile/bosses/boss.dm @@ -54,21 +54,22 @@ /datum/action/boss/Trigger() . = ..() - if(.) - if(!istype(boss, boss_type)) - return 0 - if(!boss.atb) - return 0 - if(boss.atb.points < boss_cost) - return 0 - if(!boss.client) - if(needs_target && !boss.target) - return 0 - if(boss) - if(say_when_triggered) - boss.say(say_when_triggered, forced = "boss action") - if(!boss.atb.spend(boss_cost)) - return 0 + if(!.) + return + if(!istype(boss, boss_type)) + return + if(!boss.atb) + return + if(boss.atb.points < boss_cost) + return + if(!boss.client) + if(needs_target && !boss.target) + return + if(boss) + if(say_when_triggered) + boss.say(say_when_triggered, forced = "boss action") + if(!boss.atb.spend(boss_cost)) + return //Example: /* diff --git a/code/modules/mob/living/simple_animal/hostile/carp.dm b/code/modules/mob/living/simple_animal/hostile/carp.dm index ff5f58e391..94df42c353 100644 --- a/code/modules/mob/living/simple_animal/hostile/carp.dm +++ b/code/modules/mob/living/simple_animal/hostile/carp.dm @@ -146,7 +146,7 @@ /mob/living/simple_animal/hostile/carp/tamed() . = ..() can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 var/datum/component/riding/D = LoadComponent(/datum/component/riding) D.set_riding_offsets(RIDING_OFFSET_ALL, list(TEXT_NORTH = list(0, 13), TEXT_SOUTH = list(0, 15), TEXT_EAST = list(-2, 12), TEXT_WEST = list(2, 12))) D.set_vehicle_dir_layer(SOUTH, ABOVE_MOB_LAYER) @@ -218,7 +218,7 @@ heal_overall_damage(4) if(!rideable && src.mind) can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 var/datum/component/riding/D = LoadComponent(/datum/component/riding) D.set_riding_offsets(RIDING_OFFSET_ALL, list(TEXT_NORTH = list(1, 8), TEXT_SOUTH = list(1, 8), TEXT_EAST = list(-3, 6), TEXT_WEST = list(3, 6))) D.set_vehicle_dir_offsets(SOUTH, pixel_x, 0) diff --git a/code/modules/mob/living/simple_animal/hostile/giant_spider.dm b/code/modules/mob/living/simple_animal/hostile/giant_spider.dm index 5a7290c778..e48862f9e8 100644 --- a/code/modules/mob/living/simple_animal/hostile/giant_spider.dm +++ b/code/modules/mob/living/simple_animal/hostile/giant_spider.dm @@ -90,17 +90,17 @@ /mob/living/simple_animal/hostile/poison/giant_spider/proc/humanize_spider(mob/user) if(key || !playable_spider || stat)//Someone is in it, it's dead, or the fun police are shutting it down - return 0 + return FALSE var/spider_ask = alert("Become a spider?", "Are you australian?", "Yes", "No") if(spider_ask == "No" || !src || QDELETED(src)) - return 1 + return TRUE if(key) to_chat(user, "Someone else already took this spider!") - return 1 + return TRUE key = user.key if(directive) log_game("[key_name(src)] took control of [name] with the objective: '[directive]'.") - return 1 + return TRUE //nursemaids - these create webs and eggs /mob/living/simple_animal/hostile/poison/giant_spider/nurse @@ -244,15 +244,16 @@ gold_core_spawnable = NO_SPAWN /mob/living/simple_animal/hostile/poison/giant_spider/handle_automated_action() - if(!..()) //AIStatus is off - return 0 + . = ..() + if(!.)//AIStatus is off + return FALSE if(AIStatus == AI_IDLE) //1% chance to skitter madly away if(!busy && prob(1)) stop_automated_movement = TRUE Goto(pick(urange(20, src, 1)), move_to_delay) addtimer(CALLBACK(src, .proc/do_action), 5 SECONDS) - return 1 + return TRUE /mob/living/simple_animal/hostile/poison/giant_spider/proc/do_action() stop_automated_movement = FALSE @@ -449,13 +450,14 @@ button_icon_state = "lay_eggs" /datum/action/innate/spider/lay_eggs/IsAvailable() - if(..()) - if(!istype(owner, /mob/living/simple_animal/hostile/poison/giant_spider/nurse)) - return 0 - var/mob/living/simple_animal/hostile/poison/giant_spider/nurse/S = owner - if(S.fed) - return 1 - return 0 + . = ..() + if(!.) + return + if(!istype(owner, /mob/living/simple_animal/hostile/poison/giant_spider/nurse)) + return FALSE + var/mob/living/simple_animal/hostile/poison/giant_spider/nurse/S = owner + if(S.fed) + return TRUE /datum/action/innate/spider/lay_eggs/Activate() if(!istype(owner, /mob/living/simple_animal/hostile/poison/giant_spider/nurse)) diff --git a/code/modules/mob/living/simple_animal/hostile/hostile.dm b/code/modules/mob/living/simple_animal/hostile/hostile.dm index 52c99698d1..06a1978945 100644 --- a/code/modules/mob/living/simple_animal/hostile/hostile.dm +++ b/code/modules/mob/living/simple_animal/hostile/hostile.dm @@ -68,11 +68,10 @@ . = ..() if(!.) //dead walk(src, 0) //stops walking - return 0 /mob/living/simple_animal/hostile/handle_automated_action() if(AIStatus == AI_OFF) - return 0 + return FALSE var/list/possible_targets = ListTargets() //we look around for potential targets and make it a list for later use. if(environment_smash) diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/drake.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/drake.dm index ce66bb1e7f..33f7786860 100644 --- a/code/modules/mob/living/simple_animal/hostile/megafauna/drake.dm +++ b/code/modules/mob/living/simple_animal/hostile/megafauna/drake.dm @@ -221,7 +221,7 @@ Difficulty: Medium if(!any_attack) for(var/obj/effect/temp_visual/drakewall/D in drakewalls) qdel(D) - return 0 // nothing to attack in the arena time for enraged attack if we still have a target + return FALSE // nothing to attack in the arena time for enraged attack if we still have a target for(var/turf/T in turfs) if(!(T in empty)) new /obj/effect/temp_visual/lava_warning(T) @@ -229,7 +229,7 @@ Difficulty: Medium new /obj/effect/temp_visual/lava_safe(T) amount-- SLEEP_CHECK_DEATH(24) - return 1 // attack finished completely + return TRUE // attack finished completely /mob/living/simple_animal/hostile/megafauna/dragon/proc/arena_escape_enrage() // you ran somehow / teleported away from my arena attack now i'm mad fucker SLEEP_CHECK_DEATH(0) diff --git a/code/modules/mob/living/simple_animal/hostile/mimic.dm b/code/modules/mob/living/simple_animal/hostile/mimic.dm index b786de7022..a976a6c38d 100644 --- a/code/modules/mob/living/simple_animal/hostile/mimic.dm +++ b/code/modules/mob/living/simple_animal/hostile/mimic.dm @@ -135,8 +135,8 @@ GLOBAL_LIST_INIT(protected_objects, list(/obj/structure/table, /obj/structure/ca /mob/living/simple_animal/hostile/mimic/copy/proc/CheckObject(obj/O) if((isitem(O) || isstructure(O)) && !is_type_in_list(O, GLOB.protected_objects)) - return 1 - return 0 + return TRUE + return FALSE /mob/living/simple_animal/hostile/mimic/copy/proc/CopyObject(obj/O, mob/living/user, destroy_original = 0) if(destroy_original || CheckObject(O)) diff --git a/code/modules/mob/living/simple_animal/hostile/mining_mobs/goliath.dm b/code/modules/mob/living/simple_animal/hostile/mining_mobs/goliath.dm index bf479c56e5..1277f2d75e 100644 --- a/code/modules/mob/living/simple_animal/hostile/mining_mobs/goliath.dm +++ b/code/modules/mob/living/simple_animal/hostile/mining_mobs/goliath.dm @@ -114,7 +114,7 @@ qdel(O) saddled = TRUE can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 add_overlay("goliath_saddled") var/datum/component/riding/D = LoadComponent(/datum/component/riding) D.set_riding_offsets(RIDING_OFFSET_ALL, list(TEXT_NORTH = list(0, 8), TEXT_SOUTH = list(0, 8), TEXT_EAST = list(-2, 8), TEXT_WEST = list(2, 8))) diff --git a/code/modules/mob/living/simple_animal/hostile/retaliate/retaliate.dm b/code/modules/mob/living/simple_animal/hostile/retaliate/retaliate.dm index 63a796a809..3a80e32d45 100644 --- a/code/modules/mob/living/simple_animal/hostile/retaliate/retaliate.dm +++ b/code/modules/mob/living/simple_animal/hostile/retaliate/retaliate.dm @@ -39,7 +39,6 @@ for(var/mob/living/simple_animal/hostile/retaliate/H in around) if(faction_check_mob(H) && !attack_same && !H.attack_same) H.enemies |= enemies - return 0 /mob/living/simple_animal/hostile/retaliate/adjustHealth(amount, updating_health = TRUE, forced = FALSE) . = ..() diff --git a/code/modules/mob/living/simple_animal/hostile/statue.dm b/code/modules/mob/living/simple_animal/hostile/statue.dm index 7d2ff1ad64..cc3f994940 100644 --- a/code/modules/mob/living/simple_animal/hostile/statue.dm +++ b/code/modules/mob/living/simple_animal/hostile/statue.dm @@ -79,7 +79,7 @@ if(can_be_seen(NewLoc)) if(client) to_chat(src, "You cannot move, there are eyes on you!") - return 0 + return return ..() /mob/living/simple_animal/hostile/statue/Life() @@ -143,7 +143,7 @@ // Cannot talk /mob/living/simple_animal/hostile/statue/say(message, bubble_type, list/spans = list(), sanitize = TRUE, datum/language/language = null, ignore_spam = FALSE, forced = null) - return 0 + return // Turn to dust when gibbed @@ -157,7 +157,7 @@ if(isliving(the_target)) var/mob/living/L = the_target if(!L.client && !L.ckey) - return 0 + return FALSE return ..() // Don't attack your creator if there is one diff --git a/code/modules/mob/living/simple_animal/hostile/vatbeast.dm b/code/modules/mob/living/simple_animal/hostile/vatbeast.dm index 4ec6f63cd2..68b953acfa 100644 --- a/code/modules/mob/living/simple_animal/hostile/vatbeast.dm +++ b/code/modules/mob/living/simple_animal/hostile/vatbeast.dm @@ -39,7 +39,7 @@ /mob/living/simple_animal/hostile/vatbeast/tamed() . = ..() can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 var/datum/component/riding/riding = LoadComponent(/datum/component/riding) riding.set_riding_offsets(RIDING_OFFSET_ALL, list(TEXT_NORTH = list(0, 15), TEXT_SOUTH = list(0, 15), TEXT_EAST = list(-10, 15), TEXT_WEST = list(10, 15))) riding.set_vehicle_dir_layer(SOUTH, ABOVE_MOB_LAYER) diff --git a/code/modules/mob/living/simple_animal/parrot.dm b/code/modules/mob/living/simple_animal/parrot.dm index 940faac790..5212414999 100644 --- a/code/modules/mob/living/simple_animal/parrot.dm +++ b/code/modules/mob/living/simple_animal/parrot.dm @@ -159,8 +159,8 @@ /mob/living/simple_animal/parrot/radio(message, list/message_mods = list(), list/spans, language) //literally copied from human/radio(), but there's no other way to do this. at least it's better than it used to be. . = ..() - if(. != 0) - return . + if(!.) + return if(message_mods[MODE_HEADSET]) if(ears) @@ -175,7 +175,7 @@ ears.talk_into(src, message, message_mods[RADIO_EXTENSION], spans, language, message_mods) return ITALICS | REDUCE_RANGE - return 0 + return FALSE /* * Inventory @@ -605,12 +605,12 @@ parrot_state = PARROT_WANDER parrot_stuck = 0 parrot_lastmove = null - return 1 + return TRUE else parrot_lastmove = null else parrot_lastmove = src.loc - return 0 + return FALSE /mob/living/simple_animal/parrot/proc/search_for_item() var/item @@ -634,8 +634,6 @@ continue return item - return null - /mob/living/simple_animal/parrot/proc/search_for_perch() for(var/obj/O in view(src)) for(var/path in desired_perches) diff --git a/code/modules/mob/living/simple_animal/shade.dm b/code/modules/mob/living/simple_animal/shade.dm index aaf7411d63..abed275d97 100644 --- a/code/modules/mob/living/simple_animal/shade.dm +++ b/code/modules/mob/living/simple_animal/shade.dm @@ -44,7 +44,7 @@ /mob/living/simple_animal/shade/canSuicide() if(istype(loc, /obj/item/soulstone)) //do not suicide inside the soulstone - return 0 + return FALSE return ..() /mob/living/simple_animal/shade/attack_animal(mob/living/simple_animal/M) diff --git a/code/modules/mob/living/simple_animal/slime/life.dm b/code/modules/mob/living/simple_animal/slime/life.dm index acb6fcc957..539787a682 100644 --- a/code/modules/mob/living/simple_animal/slime/life.dm +++ b/code/modules/mob/living/simple_animal/slime/life.dm @@ -8,7 +8,6 @@ /mob/living/simple_animal/slime/Life() - set invisibility = 0 if (notransform) return if(..()) @@ -614,11 +613,11 @@ /mob/living/simple_animal/slime/proc/will_hunt(hunger = -1) // Check for being stopped from feeding and chasing if (docile) - return 0 + return FALSE if (hunger == 2 || rabid || attacked) - return 1 + return TRUE if (Leader) - return 0 + return FALSE if (holding_still) - return 0 - return 1 + return FALSE + return TRUE diff --git a/code/modules/mob/living/simple_animal/slime/powers.dm b/code/modules/mob/living/simple_animal/slime/powers.dm index f1caf2e4f4..2c8fbe447a 100644 --- a/code/modules/mob/living/simple_animal/slime/powers.dm +++ b/code/modules/mob/living/simple_animal/slime/powers.dm @@ -12,20 +12,22 @@ var/needs_growth = NO_GROWTH_NEEDED /datum/action/innate/slime/IsAvailable() - if(..()) - var/mob/living/simple_animal/slime/S = owner - if(needs_growth == GROWTH_NEEDED) - if(S.amount_grown >= SLIME_EVOLUTION_THRESHOLD) - return 1 - return 0 - return 1 + . = ..() + if(!.) + return + var/mob/living/simple_animal/slime/S = owner + if(needs_growth == GROWTH_NEEDED) + if(S.amount_grown >= SLIME_EVOLUTION_THRESHOLD) + return TRUE + return FALSE + return TRUE /mob/living/simple_animal/slime/verb/Feed() set category = "Slime" set desc = "This will let you feed on any valid creature in the surrounding area. This should also be used to halt the feeding process." if(stat) - return 0 + return FALSE var/list/choices = list() for(var/mob/living/C in view(1,src)) @@ -34,10 +36,11 @@ var/mob/living/M = input(src,"Who do you wish to feed on?") in null|sortNames(choices) if(!M) - return 0 + return FALSE if(CanFeedon(M)) Feedon(M) - return 1 + return TRUE + return FALSE /datum/action/innate/slime/feed name = "Feed" diff --git a/code/modules/mob/living/simple_animal/slime/slime.dm b/code/modules/mob/living/simple_animal/slime/slime.dm index 97fba14652..bb0546606a 100644 --- a/code/modules/mob/living/simple_animal/slime/slime.dm +++ b/code/modules/mob/living/simple_animal/slime/slime.dm @@ -479,10 +479,10 @@ docile = 1 /mob/living/simple_animal/slime/can_unbuckle() - return 0 + return FALSE /mob/living/simple_animal/slime/can_buckle() - return 0 + return FALSE /mob/living/simple_animal/slime/get_mob_buckling_height(mob/seat) if(..()) diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm index 225d84a722..545f2c1070 100644 --- a/code/modules/mob/mob.dm +++ b/code/modules/mob/mob.dm @@ -109,10 +109,10 @@ */ /mob/proc/Cell() set category = "Admin" - set hidden = 1 + set hidden = TRUE if(!loc) - return 0 + return var/datum/gas_mixture/environment = loc.return_air() @@ -302,7 +302,7 @@ if(istype(W)) if(equip_to_slot_if_possible(W, slot,0,0,0)) - return 1 + return TRUE if(!W) // Activate the item @@ -310,7 +310,7 @@ if(istype(I)) I.attack_hand(src) - return 0 + return FALSE /** * Try to equip an item to a slot on the mob @@ -369,7 +369,7 @@ */ /mob/proc/equip_to_appropriate_slot(obj/item/W, swap=FALSE) if(!istype(W)) - return 0 + return FALSE var/slot_priority = W.slot_equipment_priority if(!slot_priority) @@ -386,9 +386,9 @@ for(var/slot in slot_priority) if(equip_to_slot_if_possible(W, slot, FALSE, TRUE, TRUE, FALSE, FALSE, swap)) //qdel_on_fail = FALSE; disable_warning = TRUE; redraw_mob = TRUE; - return 1 + return TRUE - return 0 + return FALSE /** * Reset the attached clients perspective (viewpoint) * @@ -801,7 +801,7 @@ ///Is the mob muzzled (default false) /mob/proc/is_muzzled() - return 0 + return FALSE /// Adds this list to the output to the stat browser /mob/proc/get_status_tab_items() @@ -1008,11 +1008,11 @@ ///can the mob be buckled to something by default? /mob/proc/can_buckle() - return 1 + return TRUE ///can the mob be unbuckled from something by default? /mob/proc/can_unbuckle() - return 1 + return TRUE ///Can the mob interact() with an atom? /mob/proc/can_interact_with(atom/A) @@ -1072,7 +1072,7 @@ /mob/proc/fully_replace_character_name(oldname,newname) log_message("[src] name changed from [oldname] to [newname]", LOG_OWNERSHIP) if(!newname) - return 0 + return FALSE log_played_names(ckey,newname) @@ -1095,7 +1095,7 @@ // Only update if this player is a target if(obj.target && obj.target.current && obj.target.current.real_name == name) obj.update_explanation_text() - return 1 + return TRUE ///Updates GLOB.data_core records with new name , see mob/living/carbon/human /mob/proc/replace_records_name(oldname,newname) diff --git a/code/modules/mob/mob_helpers.dm b/code/modules/mob/mob_helpers.dm index e313038db6..5122043652 100644 --- a/code/modules/mob/mob_helpers.dm +++ b/code/modules/mob/mob_helpers.dm @@ -45,9 +45,9 @@ /proc/above_neck(zone) var/list/zones = list(BODY_ZONE_HEAD, BODY_ZONE_PRECISE_MOUTH, BODY_ZONE_PRECISE_EYES) if(zones.Find(zone)) - return 1 + return TRUE else - return 0 + return FALSE /** * Convert random parts of a passed in message to stars diff --git a/code/modules/mob/mob_say.dm b/code/modules/mob/mob_say.dm index aacc44e60d..56749f3037 100644 --- a/code/modules/mob/mob_say.dm +++ b/code/modules/mob/mob_say.dm @@ -93,7 +93,7 @@ ///Check if the mob has a hivemind channel /mob/proc/hivecheck() - return 0 + return FALSE ///Check if the mob has a ling hivemind /mob/proc/lingcheck() diff --git a/code/modules/mob/transform_procs.dm b/code/modules/mob/transform_procs.dm index b45e861719..4c5dae12b6 100644 --- a/code/modules/mob/transform_procs.dm +++ b/code/modules/mob/transform_procs.dm @@ -619,34 +619,34 @@ //Bad mobs! - Remember to add a comment explaining what's wrong with the mob if(!MP) - return 0 //Sanity, this should never happen. + return FALSE //Sanity, this should never happen. if(ispath(MP, /mob/living/simple_animal/hostile/construct)) - return 0 //Verbs do not appear for players. + return FALSE //Verbs do not appear for players. //Good mobs! if(ispath(MP, /mob/living/simple_animal/pet/cat)) - return 1 + return TRUE if(ispath(MP, /mob/living/simple_animal/pet/dog/corgi)) - return 1 + return TRUE if(ispath(MP, /mob/living/simple_animal/crab)) - return 1 + return TRUE if(ispath(MP, /mob/living/simple_animal/hostile/carp)) - return 1 + return TRUE if(ispath(MP, /mob/living/simple_animal/hostile/mushroom)) - return 1 + return TRUE if(ispath(MP, /mob/living/simple_animal/shade)) - return 1 + return TRUE if(ispath(MP, /mob/living/simple_animal/hostile/killertomato)) - return 1 + return TRUE if(ispath(MP, /mob/living/simple_animal/mouse)) - return 1 //It is impossible to pull up the player panel for mice (Fixed! - Nodrak) + return TRUE if(ispath(MP, /mob/living/simple_animal/hostile/bear)) - return 1 //Bears will auto-attack mobs, even if they're player controlled (Fixed! - Nodrak) + return TRUE if(ispath(MP, /mob/living/simple_animal/parrot)) - return 1 //Parrots are no longer unfinished! -Nodrak + return TRUE //Parrots are no longer unfinished! -Nodrak //Not in here? Must be untested! - return 0 + return FALSE #undef TRANSFORMATION_DURATION diff --git a/code/modules/modular_computers/computers/item/computer.dm b/code/modules/modular_computers/computers/item/computer.dm index bb33a23039..5a5de49845 100644 --- a/code/modules/modular_computers/computers/item/computer.dm +++ b/code/modules/modular_computers/computers/item/computer.dm @@ -222,11 +222,11 @@ /obj/item/modular_computer/process() if(!enabled) // The computer is turned off last_power_usage = 0 - return 0 + return if(obj_integrity <= integrity_failure * max_integrity) shutdown_computer() - return 0 + return if(active_program && active_program.requires_ntnet && !get_ntnet_status(active_program.requires_ntnet_feature)) active_program.event_networkfailure(0) // Active program requires NTNet to run but we've just lost connection. Crash. diff --git a/code/modules/modular_computers/computers/item/computer_ui.dm b/code/modules/modular_computers/computers/item/computer_ui.dm index 80c0811d66..f891ef4099 100644 --- a/code/modules/modular_computers/computers/item/computer_ui.dm +++ b/code/modules/modular_computers/computers/item/computer_ui.dm @@ -7,17 +7,17 @@ if(!enabled) if(ui) ui.close() - return 0 + return if(!use_power()) if(ui) ui.close() - return 0 + return // Robots don't really need to see the screen, their wireless connection works as long as computer is on. if(!screen_on && !issilicon(user)) if(ui) ui.close() - return 0 + return // If we have an active program switch to it now. if(active_program) @@ -74,9 +74,9 @@ data["programs"] = list() var/obj/item/computer_hardware/hard_drive/hard_drive = all_components[MC_HDD] for(var/datum/computer_file/program/P in hard_drive.stored_files) - var/running = 0 + var/running = FALSE if(P in idle_threads) - running = 1 + running = TRUE data["programs"] += list(list("name" = P.filename, "desc" = P.filedesc, "running" = running)) diff --git a/code/modules/modular_computers/computers/item/laptop.dm b/code/modules/modular_computers/computers/item/laptop.dm index 73007c1a9c..a5d2a7ed17 100644 --- a/code/modules/modular_computers/computers/item/laptop.dm +++ b/code/modules/modular_computers/computers/item/laptop.dm @@ -17,7 +17,7 @@ // No running around with open laptops in hands. item_flags = SLOWS_WHILE_IN_HAND - screen_on = 0 // Starts closed + screen_on = FALSE // Starts closed var/start_open = TRUE // unless this var is set to 1 var/icon_state_closed = "laptop-closed" var/w_class_open = WEIGHT_CLASS_BULKY diff --git a/code/modules/modular_computers/computers/item/processor.dm b/code/modules/modular_computers/computers/item/processor.dm index 0d7b567877..a8e4a8a654 100644 --- a/code/modules/modular_computers/computers/item/processor.dm +++ b/code/modules/modular_computers/computers/item/processor.dm @@ -43,13 +43,6 @@ /obj/item/modular_computer/processor/relay_qdel() qdel(machinery_computer) -// This thing is not meant to be used on it's own, get topic data from our machinery owner. -//obj/item/modular_computer/processor/canUseTopic(atom/movable/M, be_close=FALSE, no_dexterity=FALSE, no_tk=FALSE) -// if(!machinery_computer) -// return 0 - -// return machinery_computer.canUseTopic(user, state) - /obj/item/modular_computer/processor/shutdown_computer() if(!machinery_computer) return diff --git a/code/modules/modular_computers/file_system/program.dm b/code/modules/modular_computers/file_system/program.dm index f65f0e36f6..d16d6f8a25 100644 --- a/code/modules/modular_computers/file_system/program.dm +++ b/code/modules/modular_computers/file_system/program.dm @@ -68,8 +68,8 @@ if(!(hardware_flag & usage_flags)) if(loud && computer && user) to_chat(user, "\The [computer] flashes a \"Hardware Error - Incompatible software\" warning.") - return 0 - return 1 + return FALSE + return TRUE /datum/computer_file/program/proc/get_signal(specific_action = 0) if(computer) @@ -78,7 +78,7 @@ // Called by Process() on device that runs us, once every tick. /datum/computer_file/program/proc/process_tick() - return 1 + return TRUE /** *Check if the user can run program. Only humans can operate computer. Automatically called in run_program() @@ -147,8 +147,8 @@ ID = card_holder.GetID() generate_network_log("Connection opened -- Program ID: [filename] User:[ID?"[ID.registered_name]":"None"]") program_state = PROGRAM_STATE_ACTIVE - return 1 - return 0 + return TRUE + return FALSE /** * diff --git a/code/modules/modular_computers/file_system/programs/ntdownloader.dm b/code/modules/modular_computers/file_system/programs/ntdownloader.dm index 8fbcfd0b01..c368b6408c 100644 --- a/code/modules/modular_computers/file_system/programs/ntdownloader.dm +++ b/code/modules/modular_computers/file_system/programs/ntdownloader.dm @@ -13,8 +13,8 @@ tgui_id = "NtosNetDownloader" var/datum/computer_file/program/downloaded_file = null - var/hacked_download = 0 - var/download_completion = 0 //GQ of downloaded data. + var/hacked_download = FALSE + var/download_completion = FALSE //GQ of downloaded data. var/download_netspeed = 0 var/downloaderror = "" var/obj/item/modular_computer/my_computer = null @@ -36,33 +36,33 @@ /datum/computer_file/program/ntnetdownload/proc/begin_file_download(filename) if(downloaded_file) - return 0 + return FALSE var/datum/computer_file/program/PRG = SSnetworks.station_network.find_ntnet_file_by_name(filename) if(!PRG || !istype(PRG)) - return 0 + return FALSE // Attempting to download antag only program, but without having emagged/syndicate computer. No. if(PRG.available_on_syndinet && !emagged) - return 0 + return FALSE var/obj/item/computer_hardware/hard_drive/hard_drive = computer.all_components[MC_HDD] if(!computer || !hard_drive || !hard_drive.can_store_file(PRG)) - return 0 + return FALSE ui_header = "downloader_running.gif" if(PRG in main_repo) generate_network_log("Began downloading file [PRG.filename].[PRG.filetype] from NTNet Software Repository.") - hacked_download = 0 + hacked_download = FALSE else if(PRG in antag_repo) generate_network_log("Began downloading file **ENCRYPTED**.[PRG.filetype] from unspecified server.") - hacked_download = 1 + hacked_download = TRUE else generate_network_log("Began downloading file [PRG.filename].[PRG.filetype] from unspecified server.") - hacked_download = 0 + hacked_download = FALSE downloaded_file = PRG.clone() @@ -71,7 +71,7 @@ return generate_network_log("Aborted download of file [hacked_download ? "**ENCRYPTED**" : "[downloaded_file.filename].[downloaded_file.filetype]"].") downloaded_file = null - download_completion = 0 + download_completion = FALSE ui_header = "downloader_finished.gif" /datum/computer_file/program/ntnetdownload/proc/complete_file_download() @@ -83,7 +83,7 @@ // The download failed downloaderror = "I/O ERROR - Unable to save file. Check whether you have enough free space on your hard drive and whether your hard drive is properly connected. If the issue persists contact your system administrator for assistance." downloaded_file = null - download_completion = 0 + download_completion = FALSE ui_header = "downloader_finished.gif" /datum/computer_file/program/ntnetdownload/process_tick() @@ -105,20 +105,20 @@ /datum/computer_file/program/ntnetdownload/ui_act(action, params) if(..()) - return 1 + return TRUE switch(action) if("PRG_downloadfile") if(!downloaded_file) begin_file_download(params["filename"]) - return 1 + return TRUE if("PRG_reseterror") if(downloaderror) - download_completion = 0 - download_netspeed = 0 + download_completion = FALSE + download_netspeed = FALSE downloaded_file = null downloaderror = "" - return 1 - return 0 + return TRUE + return FALSE /datum/computer_file/program/ntnetdownload/ui_data(mob/user) my_computer = computer @@ -186,7 +186,7 @@ /datum/computer_file/program/ntnetdownload/kill_program(forced) abort_file_download() - return ..(forced) + return ..() //////////////////////// //Syndicate Downloader// @@ -199,7 +199,7 @@ filedesc = "Software Download Tool" program_icon_state = "generic" extended_desc = "This program allows downloads of software from shared Syndicate repositories" - requires_ntnet = 0 + requires_ntnet = FALSE ui_header = "downloader_finished.gif" tgui_id = "NtosNetDownloader" emagged = TRUE diff --git a/code/modules/modular_computers/hardware/hard_drive.dm b/code/modules/modular_computers/hardware/hard_drive.dm index e5c133de20..857eed5f1b 100644 --- a/code/modules/modular_computers/hardware/hard_drive.dm +++ b/code/modules/modular_computers/hardware/hard_drive.dm @@ -31,43 +31,43 @@ // Use this proc to add file to the drive. Returns 1 on success and 0 on failure. Contains necessary sanity checks. /obj/item/computer_hardware/hard_drive/proc/store_file(datum/computer_file/F) if(!F || !istype(F)) - return 0 + return FALSE if(!can_store_file(F)) - return 0 + return FALSE if(!check_functionality()) - return 0 + return FALSE if(!stored_files) - return 0 + return FALSE // This file is already stored. Don't store it again. if(F in stored_files) - return 0 + return FALSE F.holder = src stored_files.Add(F) recalculate_size() - return 1 + return TRUE // Use this proc to remove file from the drive. Returns 1 on success and 0 on failure. Contains necessary sanity checks. /obj/item/computer_hardware/hard_drive/proc/remove_file(datum/computer_file/F) if(!F || !istype(F)) - return 0 + return FALSE if(!stored_files) - return 0 + return FALSE if(!check_functionality()) - return 0 + return FALSE if(F in stored_files) stored_files -= F recalculate_size() - return 1 + return TRUE else - return 0 + return FALSE // Loops through all stored files and recalculates used_capacity of this drive /obj/item/computer_hardware/hard_drive/proc/recalculate_size() @@ -80,24 +80,24 @@ // Checks whether file can be stored on the hard drive. We can only store unique files, so this checks whether we wouldn't get a duplicity by adding a file. /obj/item/computer_hardware/hard_drive/proc/can_store_file(datum/computer_file/F) if(!F || !istype(F)) - return 0 + return FALSE if(F in stored_files) - return 0 + return FALSE var/name = F.filename + "." + F.filetype for(var/datum/computer_file/file in stored_files) if((file.filename + "." + file.filetype) == name) - return 0 + return FALSE // In the unlikely event someone manages to create that many files. // BYOND is acting weird with numbers above 999 in loops (infinite loop prevention) if(stored_files.len >= 999) - return 0 + return FALSE if((used_capacity + F.size) > max_capacity) - return 0 + return FALSE else - return 1 + return TRUE // Tries to find the file by filename. Returns null on failure diff --git a/code/modules/modular_computers/hardware/portable_disk.dm b/code/modules/modular_computers/hardware/portable_disk.dm index 89b0382e86..f1c565188f 100644 --- a/code/modules/modular_computers/hardware/portable_disk.dm +++ b/code/modules/modular_computers/hardware/portable_disk.dm @@ -4,7 +4,7 @@ power_usage = 10 icon_state = "datadisk6" w_class = WEIGHT_CLASS_TINY - critical = 0 + critical = FALSE max_capacity = 16 device_type = MC_SDD diff --git a/code/modules/modular_computers/hardware/recharger.dm b/code/modules/modular_computers/hardware/recharger.dm index b58ea92978..38e406bc5b 100644 --- a/code/modules/modular_computers/hardware/recharger.dm +++ b/code/modules/modular_computers/hardware/recharger.dm @@ -6,8 +6,8 @@ /obj/item/computer_hardware/recharger/proc/use_power(amount, charging=0) if(charging) - return 1 - return 0 + return TRUE + return FALSE /obj/item/computer_hardware/recharger/process() ..() @@ -34,17 +34,17 @@ var/obj/machinery/M = holder.physical if(M.powered()) M.use_power(amount) - return 1 + return TRUE else var/area/A = get_area(src) if(!istype(A)) - return 0 + return FALSE if(A.powered(AREA_USAGE_EQUIP)) A.use_power(amount, AREA_USAGE_EQUIP) - return 1 - return 0 + return TRUE + return FALSE /obj/item/computer_hardware/recharger/wired name = "wired power connector" @@ -56,26 +56,25 @@ if(ismachinery(M.physical) && M.physical.anchored) return ..() to_chat(user, "\The [src] is incompatible with portable computers!") - return 0 + return FALSE /obj/item/computer_hardware/recharger/wired/use_power(amount, charging=0) if(ismachinery(holder.physical) && holder.physical.anchored) var/obj/machinery/M = holder.physical var/turf/T = M.loc if(!T || !istype(T)) - return 0 + return FALSE var/obj/structure/cable/C = T.get_cable_node() if(!C || !C.powernet) - return 0 + return FALSE var/power_in_net = C.powernet.avail-C.powernet.load if(power_in_net && power_in_net > amount) C.powernet.load += amount - return 1 - - return 0 + return TRUE + return FALSE diff --git a/code/modules/ninja/ninja_event.dm b/code/modules/ninja/ninja_event.dm index c60d6b93fd..beec8aa88c 100644 --- a/code/modules/ninja/ninja_event.dm +++ b/code/modules/ninja/ninja_event.dm @@ -59,7 +59,7 @@ Contents: var/datum/mind/Mind = new /datum/mind(key) Mind.assigned_role = ROLE_NINJA Mind.special_role = ROLE_NINJA - Mind.active = 1 + Mind.active = TRUE //spawn the ninja and assign the candidate var/mob/living/carbon/human/Ninja = create_space_ninja(spawn_loc) diff --git a/code/modules/ninja/suit/gloves.dm b/code/modules/ninja/suit/gloves.dm index 652b3f54d7..839bdcfb0e 100644 --- a/code/modules/ninja/suit/gloves.dm +++ b/code/modules/ninja/suit/gloves.dm @@ -32,8 +32,8 @@ max_heat_protection_temperature = GLOVES_MAX_TEMP_PROTECT strip_delay = 120 resistance_flags = LAVA_PROOF | FIRE_PROOF | ACID_PROOF - var/draining = 0 - var/candrain = 0 + var/draining = FALSE + var/candrain = FALSE var/mindrain = 200 var/maxdrain = 400 diff --git a/code/modules/ninja/suit/n_suit_verbs/ninja_net.dm b/code/modules/ninja/suit/n_suit_verbs/ninja_net.dm index 333061814d..629b2f1d67 100644 --- a/code/modules/ninja/suit/n_suit_verbs/ninja_net.dm +++ b/code/modules/ninja/suit/n_suit_verbs/ninja_net.dm @@ -5,7 +5,7 @@ var/mob/living/carbon/C = input("Select who to capture:","Capture who?",null) as null|mob in sortNames(oview(H)) if(QDELETED(C)||!(C in oview(H))) - return 0 + return if(!C.client)//Monkeys without a client can still step_to() and bypass the net. Also, netting inactive people is lame. to_chat(H, "[C.p_they(TRUE)] will bring no honor to your Clan!") diff --git a/code/modules/ninja/suit/n_suit_verbs/ninja_stealth.dm b/code/modules/ninja/suit/n_suit_verbs/ninja_stealth.dm index 1c3fbd8147..4d9b97d8cf 100644 --- a/code/modules/ninja/suit/n_suit_verbs/ninja_stealth.dm +++ b/code/modules/ninja/suit/n_suit_verbs/ninja_stealth.dm @@ -26,14 +26,14 @@ Contents: /obj/item/clothing/suit/space/space_ninja/proc/cancel_stealth() var/mob/living/carbon/human/U = affecting if(!U) - return 0 + return FALSE if(stealth) stealth = !stealth animate(U, alpha = 255, time = 15) U.visible_message("[U.name] appears from thin air!", \ "You are now visible.") - return 1 - return 0 + return TRUE + return FALSE /obj/item/clothing/suit/space/space_ninja/proc/stealth() diff --git a/code/modules/paperwork/contract.dm b/code/modules/paperwork/contract.dm index 44d1d48acb..f68b30b108 100644 --- a/code/modules/paperwork/contract.dm +++ b/code/modules/paperwork/contract.dm @@ -189,31 +189,30 @@ /obj/item/paper/contract/infernal/proc/attempt_signature(mob/living/carbon/human/user, blood = 0) if(!user.IsAdvancedToolUser() || !user.is_literate()) to_chat(user, "You don't know how to read or write!") - return 0 + return FALSE if(user.mind != target) to_chat(user, "Your signature simply slides off the sheet, it seems this contract is not meant for you to sign!") - return 0 + return FALSE if(user.mind.soulOwner == owner) to_chat(user, "This devil already owns your soul, you may not sell it to [owner.p_them()] again!") - return 0 + return FALSE if(signed) to_chat(user, "This contract has already been signed! It may not be signed again.") - return 0 + return FALSE if(!user.mind.hasSoul) to_chat(user, "You do not possess a soul.") - return 0 + return FALSE if(HAS_TRAIT(user, TRAIT_DUMB)) to_chat(user, "You quickly scrawl 'your name' on the contract.") signIncorrectly() - return 0 + return FALSE if (contractType == CONTRACT_REVIVE) to_chat(user, "You are already alive, this contract would do nothing.") - return 0 - else - to_chat(user, "You quickly scrawl your name on the contract.") - if(fulfillContract(target.current, blood)<=0) - to_chat(user, "But it seemed to have no effect, perhaps even Hell itself cannot grant this boon?") - return 1 + return FALSE + to_chat(user, "You quickly scrawl your name on the contract.") + if(!fulfillContract(target.current, blood)) + to_chat(user, "But it seemed to have no effect, perhaps even Hell itself cannot grant this boon?") + return TRUE @@ -221,7 +220,7 @@ if (target == M.mind && M.stat == DEAD && M.mind.soulOwner == M.mind) if (cooldown) to_chat(user, "Give [M] a chance to think through the contract, don't rush [M.p_them()]!") - return 0 + return cooldown = TRUE var/mob/living/carbon/human/H = M var/mob/dead/observer/ghost = H.get_ghost() @@ -265,12 +264,12 @@ return TRUE /obj/item/paper/contract/infernal/proc/signIncorrectly(mob/living/carbon/human/user = target.current, blood = FALSE) - signed = 1 + signed = TRUE update_text("your name", blood) /obj/item/paper/contract/infernal/power/fulfillContract(mob/living/carbon/human/user = target.current, blood = FALSE) if(!user.dna) - return -1 + return FALSE user.dna.add_mutation(HULK) var/obj/item/organ/regenerative_core/organ = new /obj/item/organ/regenerative_core organ.Insert(user) @@ -278,7 +277,7 @@ /obj/item/paper/contract/infernal/wealth/fulfillContract(mob/living/carbon/human/user = target.current, blood = 0) if(!istype(user) || !user.mind) // How in the hell could that happen? - return -1 + return FALSE user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/summon_wealth(null)) return ..() @@ -318,20 +317,20 @@ /obj/item/paper/contract/infernal/magic/fulfillContract(mob/living/carbon/human/user = target.current, blood = 0) if(!istype(user) || !user.mind) - return -1 + return FALSE user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/spellpacket/robeless(null)) user.mind.AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/knock(null)) return ..() /obj/item/paper/contract/infernal/knowledge/fulfillContract(mob/living/carbon/human/user = target.current, blood = 0) if(!istype(user) || !user.mind) - return -1 + return FALSE user.dna.add_mutation(XRAY) user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/view_range(null)) return ..() /obj/item/paper/contract/infernal/friend/fulfillContract(mob/living/user = target.current, blood = 0) if(!istype(user) || !user.mind) - return -1 + return FALSE user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/summon_friend(null)) return ..() diff --git a/code/modules/power/apc.dm b/code/modules/power/apc.dm index fea40b36e1..b6ea91f292 100644 --- a/code/modules/power/apc.dm +++ b/code/modules/power/apc.dm @@ -65,7 +65,7 @@ var/start_charge = 90 // initial cell charge % var/cell_type = /obj/item/stock_parts/cell/upgraded //Base cell has 2500 capacity. Enter the path of a different cell you want to use. cell determines charge rates, max capacity, ect. These can also be changed with other APC vars, but isn't recommended to minimize the risk of accidental usage of dirty editted APCs var/opened = APC_COVER_CLOSED - var/shorted = 0 + var/shorted = FALSE var/lighting = 3 var/equipment = 3 var/environ = 3 @@ -75,7 +75,7 @@ var/chargecount = 0 var/locked = TRUE var/coverlocked = TRUE - var/aidisabled = 0 + var/aidisabled = FALSE var/tdir = null var/obj/machinery/power/terminal/terminal = null var/lastused_light = 0 @@ -83,8 +83,8 @@ var/lastused_environ = 0 var/lastused_total = 0 var/main_status = 0 - powernet = 0 // set so that APCs aren't found as powernet nodes //Hackish, Horrible, was like this before I changed it :( - var/malfhack = 0 //New var for my changes to AI malf. --NeoFite + powernet = FALSE // set so that APCs aren't found as powernet nodes //Hackish, Horrible, was like this before I changed it :( + var/malfhack = FALSE //New var for my changes to AI malf. --NeoFite var/mob/living/silicon/ai/malfai = null //See above --NeoFite var/has_electronics = APC_ELECTRONICS_MISSING // 0 - none, 1 - plugged in, 2 - secured by screwdriver var/overload = 1 //used for the Blackout malf module @@ -94,7 +94,7 @@ var/longtermpower = 10 var/auto_name = FALSE var/failure_timer = 0 - var/force_update = 0 + var/force_update = FALSE var/emergency_lights = FALSE var/nightshift_lights = FALSE var/last_nightshift_switch = 0 @@ -1027,7 +1027,7 @@ L.no_emergency = emergency_lights INVOKE_ASYNC(L, /obj/machinery/light/.proc/update, FALSE) CHECK_TICK - return 1 + return TRUE /obj/machinery/power/apc/proc/toggle_breaker(mob/user) if(!is_operational || failure_timer) @@ -1182,7 +1182,7 @@ update() queue_icon_update() failure_timer-- - force_update = 1 + force_update = TRUE return lastused_light = area.power_usage[AREA_USAGE_LIGHT] + area.power_usage[AREA_USAGE_STATIC_LIGHT] @@ -1400,22 +1400,22 @@ /obj/machinery/power/apc/proc/shock(mob/user, prb) if(!prob(prb)) - return 0 + return FALSE do_sparks(5, TRUE, src) if(isalien(user)) - return 0 + return FALSE if(electrocute_mob(user, src, src, 1, TRUE)) - return 1 + return TRUE else - return 0 + return FALSE /obj/machinery/power/apc/proc/setsubsystem(val) if(cell && cell.charge > 0) return (val==1) ? 0 : val else if(val == 3) - return 1 + return TRUE else - return 0 + return FALSE /obj/machinery/power/apc/proc/energy_fail(duration) diff --git a/code/modules/power/cell.dm b/code/modules/power/cell.dm index 9e041b82a2..4ad1ee6a27 100644 --- a/code/modules/power/cell.dm +++ b/code/modules/power/cell.dm @@ -73,13 +73,13 @@ /obj/item/stock_parts/cell/use(amount) if(rigged && amount > 0) explode() - return 0 + return FALSE if(charge < amount) - return 0 + return FALSE charge = (charge - amount) if(!istype(loc, /obj/machinery/power/apc)) SSblackbox.record_feedback("tally", "cell_used", 1, type) - return 1 + return TRUE // recharge the cell /obj/item/stock_parts/cell/proc/give(amount) diff --git a/code/modules/power/lighting.dm b/code/modules/power/lighting.dm index c157f04e36..b923b4b1c9 100644 --- a/code/modules/power/lighting.dm +++ b/code/modules/power/lighting.dm @@ -605,10 +605,10 @@ /obj/machinery/light/proc/flicker(amount = rand(10, 20)) - set waitfor = 0 + set waitfor = FALSE if(flickering) return - flickering = 1 + flickering = TRUE if(on && status == LIGHT_OK) for(var/i = 0; i < amount; i++) if(status != LIGHT_OK) @@ -618,7 +618,7 @@ sleep(rand(5, 15)) on = (status == LIGHT_OK) update(0) - flickering = 0 + flickering = FALSE // ai attack - make lights flicker, because why not @@ -759,7 +759,7 @@ // called when area power state changes /obj/machinery/light/power_change() - SHOULD_CALL_PARENT(0) + SHOULD_CALL_PARENT(FALSE) var/area/A = get_area(src) seton(A.lightswitch && A.power_light) diff --git a/code/modules/power/power.dm b/code/modules/power/power.dm index a1bf54d61e..fdfb77b09d 100644 --- a/code/modules/power/power.dm +++ b/code/modules/power/power.dm @@ -119,7 +119,7 @@ */ /obj/machinery/proc/power_change() SIGNAL_HANDLER - SHOULD_CALL_PARENT(1) + SHOULD_CALL_PARENT(TRUE) if(machine_stat & BROKEN) return diff --git a/code/modules/power/rtg.dm b/code/modules/power/rtg.dm index 7cd8717920..9eff3ce3f8 100644 --- a/code/modules/power/rtg.dm +++ b/code/modules/power/rtg.dm @@ -12,7 +12,7 @@ // You can buckle someone to RTG, then open its panel. Fun stuff. can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 buckle_requires_restraints = TRUE var/power_gen = 1000 // Enough to power a single APC. 4000 output with T4 capacitor. diff --git a/code/modules/power/singularity/field_generator.dm b/code/modules/power/singularity/field_generator.dm index 6e64e1af6b..836a507b41 100644 --- a/code/modules/power/singularity/field_generator.dm +++ b/code/modules/power/singularity/field_generator.dm @@ -158,9 +158,9 @@ field_generator power level display /obj/machinery/field/generator/blob_act(obj/structure/blob/B) if(active) - return 0 + return FALSE else - ..() + return ..() /obj/machinery/field/generator/bullet_act(obj/projectile/Proj) if(Proj.flag != BULLET) @@ -221,25 +221,25 @@ field_generator power level display if(draw_power(round(power_draw/2,1))) check_power_level() - return 1 + return TRUE else visible_message("The [name] shuts down!", "You hear something shutting down.") turn_off() investigate_log("ran out of power and deactivated", INVESTIGATE_SINGULO) power = 0 check_power_level() - return 0 + return FALSE //This could likely be better, it tends to start loopin if you have a complex generator loop setup. Still works well enough to run the engine fields will likely recode the field gens and fields sometime -Mport /obj/machinery/field/generator/proc/draw_power(draw = 0, failsafe = FALSE, obj/machinery/field/generator/G = null, obj/machinery/field/generator/last = null) if((G && (G == src)) || (failsafe >= 8))//Loopin, set fail - return 0 + return FALSE else failsafe++ if(power >= draw)//We have enough power power -= draw - return 1 + return TRUE else//Need more power draw -= power @@ -250,14 +250,14 @@ field_generator power level display continue if(G)//Another gen is askin for power and we dont have it if(FG.draw_power(draw,failsafe,G,src))//Can you take the load - return 1 + return TRUE else - return 0 + return FALSE else//We are askin another for power if(FG.draw_power(draw,failsafe,src,src)) - return 1 + return TRUE else - return 0 + return FALSE /obj/machinery/field/generator/proc/start_fields() @@ -276,22 +276,22 @@ field_generator power level display /obj/machinery/field/generator/proc/setup_field(NSEW) var/turf/T = loc if(!istype(T)) - return 0 + return FALSE var/obj/machinery/field/generator/G = null var/steps = 0 if(!NSEW)//Make sure its ran right - return 0 + return FALSE for(var/dist in 0 to 7) // checks out to 8 tiles away for another generator T = get_step(T, NSEW) if(T.density)//We cant shoot a field though this - return 0 + return FALSE G = locate(/obj/machinery/field/generator) in T if(G) steps -= 1 if(!G.active) - return 0 + return FALSE break for(var/TC in T.contents) @@ -299,12 +299,12 @@ field_generator power level display if(ismob(A)) continue if(A.density) - return 0 + return FALSE steps++ if(!G) - return 0 + return FALSE T = loc for(var/dist in 0 to steps) // creates each field tile diff --git a/code/modules/power/singularity/generator.dm b/code/modules/power/singularity/generator.dm index f5e3bbc141..2a191cff00 100644 --- a/code/modules/power/singularity/generator.dm +++ b/code/modules/power/singularity/generator.dm @@ -11,7 +11,7 @@ // You can buckle someone to the singularity generator, then start the engine. Fun! can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 buckle_requires_restraints = TRUE var/energy = 0 diff --git a/code/modules/power/singularity/singularity.dm b/code/modules/power/singularity/singularity.dm index d73c0e63e6..4c0cf0af3e 100644 --- a/code/modules/power/singularity/singularity.dm +++ b/code/modules/power/singularity/singularity.dm @@ -70,7 +70,7 @@ return ..() else last_failed_movement = direct - return 0 + return FALSE /obj/singularity/attack_hand(mob/user) consume(user) @@ -87,10 +87,10 @@ /obj/singularity/attackby(obj/item/W, mob/user, params) consume(user) - return 1 + return TRUE /obj/singularity/Process_Spacemove() //The singularity stops drifting for no man! - return 0 + return FALSE /obj/singularity/blob_act(obj/structure/blob/B) return @@ -252,18 +252,18 @@ dissipate = 0 if(current_size == allowed_size) investigate_log("grew to size [current_size]", INVESTIGATE_SINGULO) - return 1 + return TRUE else if(current_size < (--temp_allowed_size)) expand(temp_allowed_size) else - return 0 + return FALSE /obj/singularity/proc/check_energy() if(energy <= 0) investigate_log("collapsed.", INVESTIGATE_SINGULO) qdel(src) - return 0 + return FALSE switch(energy)//Some of these numbers might need to be changed up later -Mport if(1 to 199) allowed_size = STAGE_ONE @@ -280,7 +280,7 @@ allowed_size = STAGE_FIVE if(current_size != allowed_size) expand() - return 1 + return TRUE /obj/singularity/proc/eat() @@ -316,7 +316,7 @@ /obj/singularity/proc/move(force_move = 0) if(!move_self) - return 0 + return FALSE var/drifting_dir = pick(GLOB.alldirs - last_failed_movement) @@ -337,11 +337,11 @@ if(step(src, i)) //Move in each direction. if(check_cardinals_range(steps, FALSE)) //New location passes, return true. return TRUE - . = !. + return !. /obj/singularity/proc/check_turfs_in(direction = 0, step = 0) if(!direction) - return 0 + return FALSE var/steps = 0 if(!step) switch(current_size) @@ -362,7 +362,7 @@ for(var/i = 1 to steps) T = get_step(T,direction) if(!isturf(T)) - return 0 + return FALSE turfs.Add(T) var/dir2 = 0 var/dir3 = 0 @@ -377,35 +377,35 @@ for(var/j = 1 to steps-1) T2 = get_step(T2,dir2) if(!isturf(T2)) - return 0 + return FALSE turfs.Add(T2) for(var/k = 1 to steps-1) T = get_step(T,dir3) if(!isturf(T)) - return 0 + return FALSE turfs.Add(T) for(var/turf/T3 in turfs) if(isnull(T3)) continue if(!can_move(T3)) - return 0 - return 1 + return FALSE + return TRUE /obj/singularity/proc/can_move(turf/T) if(!T) - return 0 + return FALSE if((locate(/obj/machinery/field/containment) in T)||(locate(/obj/machinery/shieldwall) in T)) - return 0 + return FALSE else if(locate(/obj/machinery/field/generator) in T) var/obj/machinery/field/generator/G = locate(/obj/machinery/field/generator) in T if(G && G.active) - return 0 + return FALSE else if(locate(/obj/machinery/power/shieldwallgen) in T) var/obj/machinery/power/shieldwallgen/S = locate(/obj/machinery/power/shieldwallgen) in T if(S && S.active) - return 0 - return 1 + return FALSE + return TRUE /obj/singularity/proc/event() @@ -417,11 +417,11 @@ mezzer() if(3,4) //Sets all nearby mobs on fire if(current_size < STAGE_SIX) - return 0 + return FALSE combust_mobs() else - return 0 - return 1 + return FALSE + return TRUE /obj/singularity/proc/combust_mobs() diff --git a/code/modules/power/solar.dm b/code/modules/power/solar.dm index 48e39202a1..aea8321db0 100644 --- a/code/modules/power/solar.dm +++ b/code/modules/power/solar.dm @@ -15,12 +15,16 @@ var/id var/obscured = FALSE - var/sunfrac = 0 //[0-1] measure of obscuration -- multipllier against power generation - var/azimuth_current = 0 //[0-360) degrees, which direction are we facing? + ///[0-1] measure of obscuration -- multipllier against power generation + var/sunfrac = 0 + ///[0-360) degrees, which direction are we facing? + var/azimuth_current = 0 var/azimuth_target = 0 //same but what way we're going to face next time we turn var/obj/machinery/power/solar_control/control - var/needs_to_turn = TRUE //do we need to turn next tick? - var/needs_to_update_solar_exposure = TRUE //do we need to call update_solar_exposure() next tick? + ///do we need to turn next tick? + var/needs_to_turn = TRUE + ///do we need to call update_solar_exposure() next tick? + var/needs_to_update_solar_exposure = TRUE var/obj/effect/overlay/panel /obj/machinery/power/solar/Initialize(mapload, obj/item/solar_assembly/S) diff --git a/code/modules/power/tesla/coil.dm b/code/modules/power/tesla/coil.dm index 5ec1b412ea..74502cfe07 100644 --- a/code/modules/power/tesla/coil.dm +++ b/code/modules/power/tesla/coil.dm @@ -8,7 +8,7 @@ // Executing a traitor caught releasing tesla was never this fun! can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 buckle_requires_restraints = TRUE circuit = /obj/item/circuitboard/machine/tesla_coil @@ -109,7 +109,7 @@ density = TRUE can_buckle = TRUE - buckle_lying = FALSE + buckle_lying = 0 buckle_requires_restraints = TRUE /obj/machinery/power/grounding_rod/default_unfasten_wrench(mob/user, obj/item/I, time = 20) diff --git a/code/modules/procedural_mapping/mapGenerator.dm b/code/modules/procedural_mapping/mapGenerator.dm index 5b70fee96f..9e6767dc64 100644 --- a/code/modules/procedural_mapping/mapGenerator.dm +++ b/code/modules/procedural_mapping/mapGenerator.dm @@ -89,17 +89,16 @@ //Checks for and Rejects bad region coordinates //Returns 1/0 /datum/map_generator/proc/checkRegion(turf/Start, turf/End) - . = 1 - if(!Start || !End) - return 0 //Just bail + return FALSE //Just bail if(Start.x > world.maxx || End.x > world.maxx) - . = 0 + return FALSE if(Start.y > world.maxy || End.y > world.maxy) - . = 0 + return FALSE if(Start.z > world.maxz || End.z > world.maxz) - . = 0 + return FALSE + return TRUE //Requests the mapGeneratorModule(s) to (re)generate @@ -153,10 +152,10 @@ return var/endInput = input(usr,"End turf of Map (X;Y;Z)", "Map Gen Settings", "[world.maxx];[world.maxy];[mob ? mob.z : 1]") as text|null - + if (isnull(endInput)) return - + //maxx maxy and current z so that if you fuck up, you only fuck up one entire z level instead of the entire universe if(!startInput || !endInput) to_chat(src, "Missing Input") diff --git a/code/modules/procedural_mapping/mapGeneratorModule.dm b/code/modules/procedural_mapping/mapGeneratorModule.dm index 412a439a0a..d5742fdb85 100644 --- a/code/modules/procedural_mapping/mapGeneratorModule.dm +++ b/code/modules/procedural_mapping/mapGeneratorModule.dm @@ -105,17 +105,16 @@ //Checks and Rejects dense turfs /datum/map_generator_module/proc/checkPlaceAtom(turf/T) - . = 1 if(!T) - return 0 + return FALSE if(T.density) - . = 0 + return FALSE for(var/atom/A in T) if(A.density) - . = 0 - break + return FALSE if(!allowAtomsOnSpace && (isspaceturf(T))) - . = 0 + return FALSE + return TRUE /////////////////////////////////////////////////////////// diff --git a/code/modules/projectiles/boxes_magazines/internal/revolver.dm b/code/modules/projectiles/boxes_magazines/internal/revolver.dm index 982d22493f..62d6731f21 100644 --- a/code/modules/projectiles/boxes_magazines/internal/revolver.dm +++ b/code/modules/projectiles/boxes_magazines/internal/revolver.dm @@ -15,7 +15,7 @@ ammo_type = /obj/item/ammo_casing/a357 caliber = "357" max_ammo = 6 - multiload = 0 + multiload = FALSE /obj/item/ammo_box/magazine/internal/rus357/Initialize() stored_ammo += new ammo_type(src) diff --git a/code/modules/projectiles/boxes_magazines/internal/rifle.dm b/code/modules/projectiles/boxes_magazines/internal/rifle.dm index a7469284a5..d4df54f75c 100644 --- a/code/modules/projectiles/boxes_magazines/internal/rifle.dm +++ b/code/modules/projectiles/boxes_magazines/internal/rifle.dm @@ -4,7 +4,7 @@ ammo_type = /obj/item/ammo_casing/a762 caliber = "a762" max_ammo = 5 - multiload = 1 + multiload = TRUE /obj/item/ammo_box/magazine/internal/boltaction/enchanted max_ammo = 1 diff --git a/code/modules/projectiles/boxes_magazines/internal/shotgun.dm b/code/modules/projectiles/boxes_magazines/internal/shotgun.dm index a8dabe744f..2f215e7d6b 100644 --- a/code/modules/projectiles/boxes_magazines/internal/shotgun.dm +++ b/code/modules/projectiles/boxes_magazines/internal/shotgun.dm @@ -3,7 +3,7 @@ ammo_type = /obj/item/ammo_casing/shotgun/beanbag caliber = "shotgun" max_ammo = 4 - multiload = 0 + multiload = FALSE /obj/item/ammo_box/magazine/internal/shot/tube name = "dual feed shotgun internal tube" @@ -17,7 +17,7 @@ name = "combat shotgun internal magazine" ammo_type = /obj/item/ammo_casing/shotgun/buckshot max_ammo = 6 - + /obj/item/ammo_box/magazine/internal/shot/dual name = "double-barrel shotgun internal magazine" max_ammo = 2 diff --git a/code/modules/projectiles/guns/ballistic/laser_gatling.dm b/code/modules/projectiles/guns/ballistic/laser_gatling.dm index 9d06483d06..e383c692da 100644 --- a/code/modules/projectiles/guns/ballistic/laser_gatling.dm +++ b/code/modules/projectiles/guns/ballistic/laser_gatling.dm @@ -12,7 +12,7 @@ slot_flags = ITEM_SLOT_BACK w_class = WEIGHT_CLASS_HUGE var/obj/item/gun/ballistic/minigun/gun - var/armed = 0 //whether the gun is attached, 0 is attached, 1 is the gun is wielded. + var/armed = FALSE //whether the gun is attached, FALSE is attached, TRUE is the gun is wielded. var/overheat = 0 var/overheat_max = 40 var/heat_diffusion = 1 @@ -34,9 +34,9 @@ if(src.loc == user) if(!armed) if(user.get_item_by_slot(ITEM_SLOT_BACK) == src) - armed = 1 + armed = TRUE if(!user.put_in_hands(gun)) - armed = 0 + armed = FALSE to_chat(user, "You need a free hand to hold the gun!") return update_icon() @@ -84,7 +84,7 @@ if(!gun) gun = new(src) gun.forceMove(src) - armed = 0 + armed = FALSE if(user) to_chat(user, "You attach the [gun.name] to the [name].") else @@ -127,7 +127,7 @@ return /obj/item/gun/ballistic/minigun/dropped(mob/user) - SHOULD_CALL_PARENT(0) + SHOULD_CALL_PARENT(FALSE) if(ammo_pack) ammo_pack.attach_gun(user) else diff --git a/code/modules/projectiles/guns/ballistic/pistol.dm b/code/modules/projectiles/guns/ballistic/pistol.dm index 07c8699cf3..6c981212cb 100644 --- a/code/modules/projectiles/guns/ballistic/pistol.dm +++ b/code/modules/projectiles/guns/ballistic/pistol.dm @@ -87,7 +87,7 @@ icon_state = "flatgun" /obj/item/gun/ballistic/automatic/pistol/stickman/pickup(mob/living/user) - SHOULD_CALL_PARENT(0) + SHOULD_CALL_PARENT(FALSE) to_chat(user, "As you try to pick up [src], it slips out of your grip..") if(prob(50)) to_chat(user, "..and vanishes from your vision! Where the hell did it go?") diff --git a/code/modules/projectiles/guns/ballistic/revolver.dm b/code/modules/projectiles/guns/ballistic/revolver.dm index 8b25b0a64a..7c0eef63b7 100644 --- a/code/modules/projectiles/guns/ballistic/revolver.dm +++ b/code/modules/projectiles/guns/ballistic/revolver.dm @@ -91,7 +91,7 @@ "The Peacemaker" = "detective_peacemaker", "Black Panther" = "detective_panther" ) - + /// Used to avoid some redundancy on a revolver loaded with 357 regarding misfiring while being wrenched. var/skip_357_missfire_check = FALSE @@ -250,7 +250,7 @@ user.visible_message("[user.name]'s soul is captured by \the [src]!", "You've lost the gamble! Your soul is forfeit!") /obj/item/gun/ballistic/revolver/reverse //Fires directly at its user... unless the user is a clown, of course. - clumsy_check = 0 + clumsy_check = FALSE /obj/item/gun/ballistic/revolver/reverse/can_trigger_gun(mob/living/user) if((HAS_TRAIT(user, TRAIT_CLUMSY)) || (user.mind && user.mind.assigned_role == "Clown")) diff --git a/code/modules/projectiles/guns/ballistic/shotgun.dm b/code/modules/projectiles/guns/ballistic/shotgun.dm index d19f3b534f..4f77d37f68 100644 --- a/code/modules/projectiles/guns/ballistic/shotgun.dm +++ b/code/modules/projectiles/guns/ballistic/shotgun.dm @@ -227,7 +227,7 @@ . = ..() if(. && slung) //sawing off the gun removes the sling new /obj/item/stack/cable_coil(get_turf(src), 10) - slung = 0 + slung = FALSE update_icon() lefthand_file = 'icons/mob/inhands/weapons/64x_guns_left.dmi' righthand_file = 'icons/mob/inhands/weapons/64x_guns_right.dmi' diff --git a/code/modules/projectiles/guns/ballistic/toy.dm b/code/modules/projectiles/guns/ballistic/toy.dm index feb29e8cf7..ffdad6d584 100644 --- a/code/modules/projectiles/guns/ballistic/toy.dm +++ b/code/modules/projectiles/guns/ballistic/toy.dm @@ -10,7 +10,7 @@ throwforce = 0 burst_size = 3 can_suppress = TRUE - clumsy_check = 0 + clumsy_check = FALSE item_flags = NONE casing_ejector = FALSE diff --git a/code/modules/projectiles/guns/energy/laser.dm b/code/modules/projectiles/guns/energy/laser.dm index f383c07789..397f8b8c51 100644 --- a/code/modules/projectiles/guns/energy/laser.dm +++ b/code/modules/projectiles/guns/energy/laser.dm @@ -13,7 +13,7 @@ name = "practice laser gun" desc = "A modified version of the basic laser gun, this one fires less concentrated energy bolts designed for target practice." ammo_type = list(/obj/item/ammo_casing/energy/laser/practice) - clumsy_check = 0 + clumsy_check = FALSE item_flags = NONE /obj/item/gun/energy/laser/retro diff --git a/code/modules/projectiles/guns/misc/medbeam.dm b/code/modules/projectiles/guns/misc/medbeam.dm index 0e9658bcba..ef7bef4b20 100644 --- a/code/modules/projectiles/guns/misc/medbeam.dm +++ b/code/modules/projectiles/guns/misc/medbeam.dm @@ -10,7 +10,7 @@ var/last_check = 0 var/check_delay = 10 //Check los as often as possible, max resolution is SSobj tick though var/max_range = 8 - var/active = 0 + var/active = FALSE var/datum/beam/current_beam = null var/mounted = 0 //Denotes if this is a handheld or mounted version @@ -37,7 +37,7 @@ if(active) qdel(current_beam) current_beam = null - active = 0 + active = FALSE on_beam_release(current_target) current_target = null @@ -87,7 +87,7 @@ if(mounted) user_turf = get_turf(user) else if(!istype(user_turf)) - return 0 + return FALSE var/obj/dummy = new(user_turf) dummy.pass_flags |= PASSTABLE|PASSGLASS|PASSGRILLE //Grille/Glass so it can be used through common windows for(var/turf/turf in getline(user_turf,target)) @@ -95,18 +95,18 @@ continue //Mechs are dense and thus fail the check if(turf.density) qdel(dummy) - return 0 + return FALSE for(var/atom/movable/AM in turf) if(!AM.CanPass(dummy,turf,1)) qdel(dummy) - return 0 + return FALSE for(var/obj/effect/ebeam/medical/B in turf)// Don't cross the str-beams! if(B.owner.origin != current_beam.origin) explosion(B.loc,0,3,5,8) qdel(dummy) - return 0 + return FALSE qdel(dummy) - return 1 + return TRUE /obj/item/gun/medbeam/proc/on_beam_hit(mob/living/target) return @@ -128,7 +128,7 @@ //////////////////////////////Mech Version/////////////////////////////// /obj/item/gun/medbeam/mech - mounted = 1 + mounted = TRUE /obj/item/gun/medbeam/mech/Initialize() . = ..() diff --git a/code/modules/projectiles/guns/misc/syringe_gun.dm b/code/modules/projectiles/guns/misc/syringe_gun.dm index 2503b01d96..56b846034b 100644 --- a/code/modules/projectiles/guns/misc/syringe_gun.dm +++ b/code/modules/projectiles/guns/misc/syringe_gun.dm @@ -8,7 +8,7 @@ throw_range = 7 force = 4 custom_materials = list(/datum/material/iron=2000) - clumsy_check = 0 + clumsy_check = FALSE fire_sound = 'sound/items/syringeproj.ogg' var/load_sound = 'sound/weapons/gun/shotgun/insert_shell.ogg' var/list/syringes = list() @@ -44,7 +44,7 @@ /obj/item/gun/syringe/attack_self(mob/living/user) if(!syringes.len) to_chat(user, "[src] is empty!") - return 0 + return FALSE var/obj/item/reagent_containers/syringe/S = syringes[syringes.len] diff --git a/code/modules/projectiles/pins.dm b/code/modules/projectiles/pins.dm index e0fe135dda..1876763e2c 100644 --- a/code/modules/projectiles/pins.dm +++ b/code/modules/projectiles/pins.dm @@ -10,9 +10,9 @@ attack_verb_continuous = list("pokes") attack_verb_simple = list("poke") var/fail_message = "INVALID USER." - var/selfdestruct = 0 // Explode when user check is failed. - var/force_replace = 0 // Can forcefully replace other pins. - var/pin_removeable = 0 // Can be replaced by any pin. + var/selfdestruct = FALSE // Explode when user check is failed. + var/force_replace = FALSE // Can forcefully replace other pins. + var/pin_removeable = FALSE // Can be replaced by any pin. var/obj/item/gun/gun /obj/item/firing_pin/New(newloc) diff --git a/code/modules/reagents/chemistry/holder.dm b/code/modules/reagents/chemistry/holder.dm index 07793fe5c4..ef4a424ee2 100644 --- a/code/modules/reagents/chemistry/holder.dm +++ b/code/modules/reagents/chemistry/holder.dm @@ -371,7 +371,7 @@ if(can_overdose) if(R.overdose_threshold) if(R.volume >= R.overdose_threshold && !R.overdosed) - R.overdosed = 1 + R.overdosed = TRUE need_mob_update += R.overdose_start(C) log_game("[key_name(C)] has started overdosing on [R.name] at [R.volume] units.") if(R.addiction_threshold) @@ -582,7 +582,6 @@ while(reaction_occurred) update_total() - return 0 /// Remove every reagent except this one /datum/reagents/proc/isolate_reagent(reagent) @@ -625,7 +624,6 @@ else total_volume += R.volume - return 0 /// Removes all reagents /datum/reagents/proc/clear_reagents() @@ -635,7 +633,6 @@ del_reagent(R.type) if(my_atom) my_atom.on_reagent_change(CLEAR_REAGENTS) - return 0 /** * Applies the relevant expose_ proc for every reagent in this holder @@ -817,17 +814,14 @@ Needs matabolizing takes into consideration if the chemical is matabolizing when if (R.type == reagent) if(!amount) if(needs_metabolizing && !R.metabolizing) - return 0 + return FALSE return R else if(round(R.volume, CHEMICAL_QUANTISATION_LEVEL) >= amount) if(needs_metabolizing && !R.metabolizing) - return 0 + return FALSE return R - else - return 0 - - return 0 + return FALSE /// Get the amount of this reagent /datum/reagents/proc/get_reagent_amount(reagent) @@ -836,7 +830,6 @@ Needs matabolizing takes into consideration if the chemical is matabolizing when var/datum/reagent/R = _reagent if (R.type == reagent) return round(R.volume, CHEMICAL_QUANTISATION_LEVEL) - return 0 /// Get a comma separated string of every reagent name in this holder diff --git a/code/modules/reagents/chemistry/reagents.dm b/code/modules/reagents/chemistry/reagents.dm index 3f25609be1..7f722b9eae 100644 --- a/code/modules/reagents/chemistry/reagents.dm +++ b/code/modules/reagents/chemistry/reagents.dm @@ -61,7 +61,7 @@ GLOBAL_LIST_INIT(name2reagent, build_name2reagent()) /// increases as addiction gets worse var/addiction_stage = 0 /// You fucked up and this is now triggering its overdose effects, purge that shit quick. - var/overdosed = 0 + var/overdosed = FALSE ///if false stops metab in liverless mobs var/self_consuming = FALSE ///affects how far it travels when sprayed @@ -96,14 +96,14 @@ GLOBAL_LIST_INIT(name2reagent, build_name2reagent()) /// Applies this reagent to a [/mob/living] /datum/reagent/proc/expose_mob(mob/living/M, methods=TOUCH, reac_volume, show_message = 1, touch_protection = 0) if(!istype(M)) - return 0 + return FALSE if(methods & VAPOR) //smoke, foam, spray if(M.reagents) var/modifier = clamp((1 - touch_protection), 0, 1) var/amount = round(reac_volume*modifier, 0.1) if(amount >= 0.5) M.reagents.add_reagent(type, amount) - return 1 + return TRUE /// Applies this reagent to an [/obj] /datum/reagent/proc/expose_obj(obj/O, volume) diff --git a/code/modules/reagents/reagent_containers.dm b/code/modules/reagents/reagent_containers.dm index 3afae78b53..295a1da9dc 100644 --- a/code/modules/reagents/reagent_containers.dm +++ b/code/modules/reagents/reagent_containers.dm @@ -50,7 +50,7 @@ /obj/item/reagent_containers/proc/canconsume(mob/eater, mob/user) if(!iscarbon(eater)) - return 0 + return FALSE var/mob/living/carbon/C = eater var/covered = "" if(C.is_mouth_covered(head_only = 1)) @@ -60,8 +60,8 @@ if(covered) var/who = (isnull(user) || eater == user) ? "your" : "[eater.p_their()]" to_chat(user, "You have to remove [who] [covered] first!") - return 0 - return 1 + return FALSE + return TRUE /* * On accidental consumption, transfer a portion of the reagents to the eater and the item it's in, then continue to the base proc (to deal with shattering glass containers) diff --git a/code/modules/reagents/reagent_containers/hypospray.dm b/code/modules/reagents/reagent_containers/hypospray.dm index 4a9d8b9765..e6290be99e 100644 --- a/code/modules/reagents/reagent_containers/hypospray.dm +++ b/code/modules/reagents/reagent_containers/hypospray.dm @@ -12,7 +12,7 @@ resistance_flags = ACID_PROOF reagent_flags = OPENCONTAINER slot_flags = ITEM_SLOT_BELT - var/ignore_flags = 0 + var/ignore_flags = NONE var/infinite = FALSE /obj/item/reagent_containers/hypospray/attack_paw(mob/user) diff --git a/code/modules/reagents/reagent_containers/patch.dm b/code/modules/reagents/reagent_containers/patch.dm index 0642313f5b..d04dd3ad0d 100644 --- a/code/modules/reagents/reagent_containers/patch.dm +++ b/code/modules/reagents/reagent_containers/patch.dm @@ -24,8 +24,8 @@ /obj/item/reagent_containers/pill/patch/canconsume(mob/eater, mob/user) if(!iscarbon(eater)) - return 0 - return 1 // Masks were stopping people from "eating" patches. Thanks, inheritance. + return FALSE + return TRUE // Masks were stopping people from "eating" patches. Thanks, inheritance. /obj/item/reagent_containers/pill/patch/libital name = "libital patch (brute)" diff --git a/code/modules/research/xenobiology/crossbreeding/_weapons.dm b/code/modules/research/xenobiology/crossbreeding/_weapons.dm index 0c09186a29..e67a36b326 100644 --- a/code/modules/research/xenobiology/crossbreeding/_weapons.dm +++ b/code/modules/research/xenobiology/crossbreeding/_weapons.dm @@ -100,7 +100,7 @@ Slimecrossing Weapons /obj/item/gun/magic/bloodchill/process() charge_tick++ if(charge_tick < recharge_rate || charges >= max_charges) - return 0 + return FALSE charge_tick = 0 var/mob/living/M = loc if(istype(M) && M.blood_volume >= 20) @@ -108,7 +108,7 @@ Slimecrossing Weapons M.blood_volume -= 20 if(charges == 1) recharge_newshot() - return 1 + return TRUE /obj/item/ammo_casing/magic/bloodchill projectile_type = /obj/projectile/magic/bloodchill diff --git a/code/modules/research/xenobiology/xenobiology.dm b/code/modules/research/xenobiology/xenobiology.dm index 4bb11af900..43ec37a5d4 100644 --- a/code/modules/research/xenobiology/xenobiology.dm +++ b/code/modules/research/xenobiology/xenobiology.dm @@ -56,7 +56,7 @@ */ /obj/item/slime_extract/proc/activate(mob/living/carbon/human/user, datum/species/jelly/luminescent/species, activation_type) to_chat(user, "Nothing happened... This slime extract cannot be activated this way.") - return 0 + return FALSE /** * Core-crossing: Feeding adult slimes extracts to obtain a much more powerful, single extract. diff --git a/code/modules/security_levels/keycard_authentication.dm b/code/modules/security_levels/keycard_authentication.dm index bd424474a9..1c17412d27 100644 --- a/code/modules/security_levels/keycard_authentication.dm +++ b/code/modules/security_levels/keycard_authentication.dm @@ -20,7 +20,7 @@ GLOBAL_DATUM_INIT(keycard_events, /datum/events, new) var/event = "" var/obj/machinery/keycard_auth/event_source var/mob/triggerer = null - var/waiting = 0 + var/waiting = FALSE /obj/machinery/keycard_auth/Initialize() . = ..() @@ -82,14 +82,14 @@ GLOBAL_DATUM_INIT(keycard_events, /datum/events, new) /obj/machinery/keycard_auth/proc/sendEvent(event_type) triggerer = usr event = event_type - waiting = 1 + waiting = TRUE GLOB.keycard_events.fireEvent("triggerEvent", src) addtimer(CALLBACK(src, .proc/eventSent), 20) /obj/machinery/keycard_auth/proc/eventSent() triggerer = null event = "" - waiting = 0 + waiting = FALSE /obj/machinery/keycard_auth/proc/triggerEvent(source) icon_state = "auth_on" diff --git a/code/modules/spells/spell.dm b/code/modules/spells/spell.dm index be258176dc..2880d3cd9d 100644 --- a/code/modules/spells/spell.dm +++ b/code/modules/spells/spell.dm @@ -506,8 +506,8 @@ GLOBAL_LIST_INIT(spells, typesof(/obj/effect/proc_holder/spell)) //needed for th /obj/effect/proc_holder/spell/proc/can_be_cast_by(mob/caster) if((human_req || clothes_req) && !ishuman(caster)) - return 0 - return 1 + return FALSE + return TRUE /obj/effect/proc_holder/spell/targeted/proc/los_check(mob/A,mob/B) //Checks for obstacles from A to B @@ -517,9 +517,9 @@ GLOBAL_LIST_INIT(spells, typesof(/obj/effect/proc_holder/spell)) //needed for th for(var/atom/movable/AM in turf) if(!AM.CanPass(dummy,turf,1)) qdel(dummy) - return 0 + return FALSE qdel(dummy) - return 1 + return TRUE /obj/effect/proc_holder/spell/proc/can_cast(mob/user = usr) if(((!user.mind) || !(src in user.mind.spell_list)) && !(src in user.mob_spell_list)) diff --git a/code/modules/surgery/cavity_implant.dm b/code/modules/surgery/cavity_implant.dm index e81dea83bb..a65297a5f9 100644 --- a/code/modules/surgery/cavity_implant.dm +++ b/code/modules/surgery/cavity_implant.dm @@ -36,7 +36,7 @@ if(tool) if(IC || tool.w_class > WEIGHT_CLASS_NORMAL || HAS_TRAIT(tool, TRAIT_NODROP) || istype(tool, /obj/item/organ)) to_chat(user, "You can't seem to fit [tool] in [target]'s [target_zone]!") - return 0 + return FALSE else display_results(user, target, "You stuff [tool] into [target]'s [target_zone].", "[user] stuffs [tool] into [target]'s [target_zone]!", @@ -54,4 +54,4 @@ return ..() else to_chat(user, "You don't find anything in [target]'s [target_zone].") - return 0 + return FALSE diff --git a/code/modules/surgery/organ_manipulation.dm b/code/modules/surgery/organ_manipulation.dm index 47820c366a..829a74b622 100644 --- a/code/modules/surgery/organ_manipulation.dm +++ b/code/modules/surgery/organ_manipulation.dm @@ -153,4 +153,4 @@ display_results(user, target, "You can't extract anything from [target]'s [parse_zone(target_zone)]!", "[user] can't seem to extract anything from [target]'s [parse_zone(target_zone)]!", "[user] can't seem to extract anything from [target]'s [parse_zone(target_zone)]!") - return 0 + return FALSE diff --git a/code/modules/surgery/organs/augments_chest.dm b/code/modules/surgery/organs/augments_chest.dm index b7edd798ca..f2f2b1ec6e 100644 --- a/code/modules/surgery/organs/augments_chest.dm +++ b/code/modules/surgery/organs/augments_chest.dm @@ -149,7 +149,7 @@ if((organ_flags & ORGAN_FAILING)) if(!silent) to_chat(owner, "Your thrusters set seems to be broken!") - return 0 + return FALSE if(allow_thrust(0.01)) on = TRUE ion_trail.start() diff --git a/code/modules/surgery/organs/organ_internal.dm b/code/modules/surgery/organs/organ_internal.dm index fb4f80f0d1..cadd8e2d98 100644 --- a/code/modules/surgery/organs/organ_internal.dm +++ b/code/modules/surgery/organs/organ_internal.dm @@ -35,13 +35,13 @@ if(organ_flags & ORGAN_EDIBLE) AddComponent(/datum/component/edible, food_reagents, null, RAW | MEAT | GROSS, null, 10, null, null, null, CALLBACK(src, .proc/OnEatFrom)) -/obj/item/organ/proc/Insert(mob/living/carbon/M, special = 0, drop_if_replaced = TRUE) +/obj/item/organ/proc/Insert(mob/living/carbon/M, special = FALSE, drop_if_replaced = TRUE) if(!iscarbon(M) || owner == M) return var/obj/item/organ/replaced = M.getorganslot(slot) if(replaced) - replaced.Remove(M, special = 1) + replaced.Remove(M, special = TRUE) if(drop_if_replaced) replaced.forceMove(get_turf(M)) else diff --git a/code/modules/surgery/prosthetic_replacement.dm b/code/modules/surgery/prosthetic_replacement.dm index 97c1e983db..951ad2fae1 100644 --- a/code/modules/surgery/prosthetic_replacement.dm +++ b/code/modules/surgery/prosthetic_replacement.dm @@ -8,10 +8,11 @@ /datum/surgery/prosthetic_replacement/can_start(mob/user, mob/living/carbon/target) if(!iscarbon(target)) - return 0 + return FALSE var/mob/living/carbon/C = target if(!C.get_bodypart(user.zone_selected)) //can only start if limb is missing - return 1 + return TRUE + return FALSE diff --git a/code/modules/surgery/surgery_helpers.dm b/code/modules/surgery/surgery_helpers.dm index 71106d66dd..881dd89e0f 100644 --- a/code/modules/surgery/surgery_helpers.dm +++ b/code/modules/surgery/surgery_helpers.dm @@ -32,42 +32,42 @@ switch(location) if(BODY_ZONE_HEAD) if(covered_locations & HEAD) - return 0 + return FALSE if(BODY_ZONE_PRECISE_EYES) if(covered_locations & HEAD || face_covered & HIDEEYES || eyesmouth_covered & GLASSESCOVERSEYES) - return 0 + return FALSE if(BODY_ZONE_PRECISE_MOUTH) if(covered_locations & HEAD || face_covered & HIDEFACE || eyesmouth_covered & MASKCOVERSMOUTH || eyesmouth_covered & HEADCOVERSMOUTH) - return 0 + return FALSE if(BODY_ZONE_CHEST) if(covered_locations & CHEST) - return 0 + return FALSE if(BODY_ZONE_PRECISE_GROIN) if(covered_locations & GROIN) - return 0 + return FALSE if(BODY_ZONE_L_ARM) if(covered_locations & ARM_LEFT) - return 0 + return FALSE if(BODY_ZONE_R_ARM) if(covered_locations & ARM_RIGHT) - return 0 + return FALSE if(BODY_ZONE_L_LEG) if(covered_locations & LEG_LEFT) - return 0 + return FALSE if(BODY_ZONE_R_LEG) if(covered_locations & LEG_RIGHT) - return 0 + return FALSE if(BODY_ZONE_PRECISE_L_HAND) if(covered_locations & HAND_LEFT) - return 0 + return FALSE if(BODY_ZONE_PRECISE_R_HAND) if(covered_locations & HAND_RIGHT) - return 0 + return FALSE if(BODY_ZONE_PRECISE_L_FOOT) if(covered_locations & FOOT_LEFT) - return 0 + return FALSE if(BODY_ZONE_PRECISE_R_FOOT) if(covered_locations & FOOT_RIGHT) - return 0 + return FALSE - return 1 + return TRUE diff --git a/code/modules/swarmers/swarmer_objs.dm b/code/modules/swarmers/swarmer_objs.dm index ee56aff87f..a7a657c162 100644 --- a/code/modules/swarmers/swarmer_objs.dm +++ b/code/modules/swarmers/swarmer_objs.dm @@ -16,7 +16,7 @@ . = ..() set_light(glow_range) -/obj/structure/swarmer/play_attack_sound(damage_amount, damage_type = BRUTE, damage_flag = NONE) +/obj/structure/swarmer/play_attack_sound(damage_amount, damage_type = BRUTE, damage_flag = 0) switch(damage_type) if(BRUTE) playsound(src, 'sound/weapons/egloves.ogg', 80, TRUE) diff --git a/code/modules/tooltip/tooltip.dm b/code/modules/tooltip/tooltip.dm index ab7dc91739..d06131801d 100644 --- a/code/modules/tooltip/tooltip.dm +++ b/code/modules/tooltip/tooltip.dm @@ -51,7 +51,7 @@ Notes: /datum/tooltip/proc/show(atom/movable/thing, params = null, title = null, content = null, theme = "default", special = "none") if (!thing || !params || (!title && !content) || !owner || !isnum(world.icon_size)) - return 0 + return FALSE if (!init) //Initialize some vars init = 1 @@ -83,7 +83,7 @@ Notes: if (queueHide) hide() - return 1 + return TRUE /datum/tooltip/proc/hide() diff --git a/code/modules/vehicles/ridden.dm b/code/modules/vehicles/ridden.dm index 71805a8e6f..f69847207e 100644 --- a/code/modules/vehicles/ridden.dm +++ b/code/modules/vehicles/ridden.dm @@ -2,7 +2,7 @@ name = "ridden vehicle" can_buckle = TRUE max_buckled_mobs = 1 - buckle_lying = FALSE + buckle_lying = 0 default_driver_move = FALSE var/legs_required = 2 var/arms_required = 1 //why not? diff --git a/code/modules/vending/_vending.dm b/code/modules/vending/_vending.dm index 1d1bded930..91ba5605d3 100644 --- a/code/modules/vending/_vending.dm +++ b/code/modules/vending/_vending.dm @@ -920,7 +920,7 @@ GLOBAL_LIST_EMPTY(vending_products) var/obj/throw_item = null var/mob/living/target = locate() in view(7,src) if(!target) - return 0 + return FALSE for(var/datum/data/vending_product/R in shuffle(product_records)) if(R.amount <= 0) //Try to use a record that actually has something to dump. @@ -933,13 +933,13 @@ GLOBAL_LIST_EMPTY(vending_products) throw_item = new dump_path(loc) break if(!throw_item) - return 0 + return FALSE pre_throw(throw_item) throw_item.throw_at(target, 16, 3) visible_message("[src] launches [throw_item] at [target]!") - return 1 + return TRUE /** * A callback called before an item is tossed out *