Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gravity removal ;) unused var that was 1 on ALL tiles #6728

Merged
merged 7 commits into from
Aug 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 0 additions & 37 deletions code/game/area/areas.dm
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@

var/unique = TRUE

var/has_gravity = 1
// var/list/lights // list of all lights on this area
var/list/all_doors = list() //Added by Strumpetplaya - Alarm Change - Contains a list of doors adjacent to this area
var/air_doors_activated = 0
Expand Down Expand Up @@ -381,42 +380,6 @@
if(istype(M))
use_power(-M.calculate_current_power_usage(), M.power_channel)

/area/proc/gravitychange(gravitystate = 0, area/A)

A.has_gravity = gravitystate

if(gravitystate)
for(var/mob/living/carbon/human/M in A)
thunk(M)
for(var/mob/M1 in A)
M1.make_floating(0)
else
for(var/mob/M in A)
if(M.Check_Dense_Object() && istype(src,/mob/living/carbon/human/))
var/mob/living/carbon/human/H = src
if(istype(H.shoes, /obj/item/clothing/shoes/magboots) && (H.shoes.flags_inventory & NOSLIPPING)) //magboots + dense_object = no floaty effect
H.make_floating(0)
else
H.make_floating(1)
else
M.make_floating(1)

/area/proc/thunk(M)
if(istype(get_turf(M), /turf/open/space)) // Can't fall onto nothing.
return

if(istype(M,/mob/living/carbon/human/)) // Only humans can wear magboots, so we give them a chance to.
var/mob/living/carbon/human/H = M
if((istype(H.shoes, /obj/item/clothing/shoes/magboots) && (H.shoes.flags_inventory & NOSLIPPING)))
return
H.adjust_effect(5, STUN)
H.adjust_effect(5, WEAKEN)

to_chat(M, "Gravity!")




//atmos related procs

/area/return_air()
Expand Down
3 changes: 1 addition & 2 deletions code/game/area/space_station_13_areas.dm
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ NOTE: there are two lists of areas in the end of this file: centcom and station
requires_power = FALSE
static_lighting = FALSE
base_lighting_alpha = 255
has_gravity = 1

// === end remove

Expand All @@ -72,7 +71,7 @@ NOTE: there are two lists of areas in the end of this file: centcom and station
statistic_exempt = TRUE
ceiling = CEILING_METAL

base_lighting_alpha = 255
base_lighting_alpha = 255

/area/centcom/control
name = "\improper abandoned Centcom Control"
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items/tools/extinguisher.dm
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@
unpicked_targets -= TT
INVOKE_ASYNC(src, PROC_REF(release_liquid), TT, user)

if(istype(user.loc, /turf/open/space) || (user.lastarea && user.lastarea.has_gravity == 0))
if(istype(user.loc, /turf/open/space))
user.inertia_dir = get_dir(target, user)
step(user, user.inertia_dir)
return
Expand Down
2 changes: 1 addition & 1 deletion code/modules/mob/living/carbon/carbon.dm
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@

if(!lastarea)
lastarea = get_area(src.loc)
if((istype(loc, /turf/open/space)) || !lastarea.has_gravity)
if(istype(loc, /turf/open/space))
inertia_dir = get_dir(target, src)
step(src, inertia_dir)

Expand Down
4 changes: 2 additions & 2 deletions code/modules/mob/mob_movement.dm
Original file line number Diff line number Diff line change
Expand Up @@ -261,12 +261,12 @@

if(istype(src,/mob/living/carbon/human/)) // Only humans can wear magboots, so we give them a chance to.
var/mob/living/carbon/human/H = src
if((istype(turf,/turf/open/floor)) && (src.lastarea.has_gravity == 0) && !(istype(H.shoes, /obj/item/clothing/shoes/magboots) && (H.shoes.flags_inventory & NOSLIPPING)))
if((istype(turf,/turf/open/floor)) && !(istype(H.shoes, /obj/item/clothing/shoes/magboots) && (H.shoes.flags_inventory & NOSLIPPING)))
continue


else
if((istype(turf,/turf/open/floor)) && (src.lastarea && src.lastarea.has_gravity == 0)) // No one else gets a chance.
if(istype(turf,/turf/open/floor)) // No one else gets a chance.
continue


Expand Down
Loading