mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-21 12:02:31 +01:00
@@ -19,8 +19,10 @@ var/list/obj/effect/bump_teleporter/BUMP_TELEPORTERS = list()
|
||||
BUMP_TELEPORTERS -= src
|
||||
return ..()
|
||||
|
||||
/obj/effect/bump_teleporter/CollidedWith(atom/user)
|
||||
if(!ismob(user))
|
||||
/obj/effect/bump_teleporter/CollidedWith(atom/bumped_atom)
|
||||
. = ..()
|
||||
|
||||
if(!ismob(bumped_atom))
|
||||
//user.forceMove(src.loc) //Stop at teleporter location
|
||||
return
|
||||
|
||||
|
||||
@@ -30,11 +30,11 @@
|
||||
|
||||
precision = precise
|
||||
|
||||
/obj/effect/portal/CollidedWith(mob/M)
|
||||
set waitfor = FALSE
|
||||
/obj/effect/portal/CollidedWith(atom/bumped_atom)
|
||||
. = ..()
|
||||
|
||||
if(does_teleport)
|
||||
teleport(M)
|
||||
teleport(bumped_atom)
|
||||
|
||||
/obj/effect/portal/Crossed(AM)
|
||||
set waitfor = FALSE
|
||||
|
||||
@@ -233,7 +233,7 @@
|
||||
if(AM.loc != loc)
|
||||
AM.forceMove(loc)
|
||||
captured = WEAKREF(L)
|
||||
buckle(L)
|
||||
INVOKE_ASYNC(src, PROC_REF(buckle), L)
|
||||
layer = L.layer + 0.1
|
||||
playsound(src, 'sound/weapons/beartrap_shut.ogg', 100, 1)
|
||||
deployed = FALSE
|
||||
@@ -282,9 +282,9 @@
|
||||
|
||||
release()
|
||||
|
||||
/obj/item/trap/animal/CollidedWith(atom/AM)
|
||||
if(deployed && is_type_in_list(AM, allowed_mobs))
|
||||
Crossed(AM)
|
||||
/obj/item/trap/animal/CollidedWith(atom/bumped_atom)
|
||||
if(deployed && is_type_in_list(bumped_atom, allowed_mobs))
|
||||
Crossed(bumped_atom)
|
||||
else
|
||||
..()
|
||||
|
||||
|
||||
@@ -72,9 +72,11 @@
|
||||
else
|
||||
icon_state = initial(icon_state)
|
||||
|
||||
/obj/structure/grille/CollidedWith(atom/user)
|
||||
if(ismob(user))
|
||||
shock(user, 70)
|
||||
/obj/structure/grille/CollidedWith(atom/bumped_atom)
|
||||
. = ..()
|
||||
|
||||
if(ismob(bumped_atom))
|
||||
shock(bumped_atom, 70)
|
||||
|
||||
/obj/structure/grille/attack_hand(mob/user as mob)
|
||||
|
||||
|
||||
@@ -65,10 +65,10 @@
|
||||
if(lock)
|
||||
. += SPAN_NOTICE("It appears to have a lock.")
|
||||
|
||||
/obj/structure/simple_door/CollidedWith(atom/user)
|
||||
/obj/structure/simple_door/CollidedWith(atom/bumped_atom)
|
||||
..()
|
||||
if(!state)
|
||||
return TryToSwitchState(user)
|
||||
return TryToSwitchState(bumped_atom)
|
||||
return
|
||||
|
||||
/obj/structure/simple_door/attack_ai(mob/user as mob) //those aren't machinery, they're just big fucking slabs of a mineral
|
||||
@@ -123,22 +123,30 @@
|
||||
isSwitchingStates = 1
|
||||
playsound(loc, material.dooropen_noise, 100, 1)
|
||||
flick("[material.door_icon_base]opening",src)
|
||||
sleep(10)
|
||||
density = 0
|
||||
opacity = 0
|
||||
state = 1
|
||||
update_icon()
|
||||
isSwitchingStates = 0
|
||||
update_nearby_tiles()
|
||||
addtimer(CALLBACK(src, PROC_REF(change_state_after_openclode), TRUE), 1 SECONDS)
|
||||
|
||||
|
||||
/obj/structure/simple_door/proc/Close()
|
||||
isSwitchingStates = 1
|
||||
playsound(loc, material.dooropen_noise, 100, 1)
|
||||
flick("[material.door_icon_base]closing",src)
|
||||
sleep(10)
|
||||
density = 1
|
||||
opacity = 1
|
||||
state = 0
|
||||
addtimer(CALLBACK(src, PROC_REF(change_state_after_openclode), FALSE), 1 SECONDS)
|
||||
|
||||
/**
|
||||
* Complete the open/close of the door
|
||||
*
|
||||
* * to_open - Whether the door is to be set as open, if FALSE, it is to be set as closed instead
|
||||
*/
|
||||
/obj/structure/simple_door/proc/change_state_after_openclode(to_open = FALSE)
|
||||
if(to_open)
|
||||
density = 0
|
||||
opacity = 0
|
||||
state = 1
|
||||
else
|
||||
density = 1
|
||||
opacity = 1
|
||||
state = 0
|
||||
|
||||
update_icon()
|
||||
isSwitchingStates = 0
|
||||
update_nearby_tiles()
|
||||
|
||||
Reference in New Issue
Block a user