mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 03:27:05 +01:00
Makes pods work with the force_eject_occupant proc
This commit is contained in:
@@ -24,7 +24,7 @@
|
||||
|
||||
if(isobj(usr.loc))
|
||||
var/obj/O = usr.loc
|
||||
O.force_eject_occupant()
|
||||
O.force_eject_occupant(usr)
|
||||
|
||||
admin_forcemove(usr, T)
|
||||
log_admin("[key_name(usr)] jumped to [A]")
|
||||
@@ -41,7 +41,7 @@
|
||||
|
||||
if(isobj(usr.loc))
|
||||
var/obj/O = usr.loc
|
||||
O.force_eject_occupant()
|
||||
O.force_eject_occupant(usr)
|
||||
log_admin("[key_name(usr)] jumped to [T.x], [T.y], [T.z] in [T.loc]")
|
||||
if(!isobserver(usr))
|
||||
message_admins("[key_name_admin(usr)] jumped to [T.x], [T.y], [T.z] in [T.loc]", 1)
|
||||
@@ -61,7 +61,7 @@
|
||||
message_admins("[key_name_admin(usr)] jumped to [key_name_admin(M)]", 1)
|
||||
if(isobj(usr.loc))
|
||||
var/obj/O = usr.loc
|
||||
O.force_eject_occupant()
|
||||
O.force_eject_occupant(usr)
|
||||
if(src.mob)
|
||||
var/mob/A = src.mob
|
||||
var/turf/T = get_turf(M)
|
||||
@@ -82,7 +82,7 @@
|
||||
if(T)
|
||||
if(isobj(usr.loc))
|
||||
var/obj/O = usr.loc
|
||||
O.force_eject_occupant()
|
||||
O.force_eject_occupant(usr)
|
||||
admin_forcemove(usr, T)
|
||||
if(isobserver(usr))
|
||||
var/mob/dead/observer/O = usr
|
||||
@@ -111,7 +111,7 @@
|
||||
message_admins("[key_name_admin(usr)] jumped to [key_name_admin(M)]", 1)
|
||||
if(isobj(usr.loc))
|
||||
var/obj/O = usr.loc
|
||||
O.force_eject_occupant()
|
||||
O.force_eject_occupant(usr)
|
||||
admin_forcemove(usr, M.loc)
|
||||
|
||||
feedback_add_details("admin_verb","JK") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
@@ -129,7 +129,7 @@
|
||||
|
||||
if(isobj(M.loc))
|
||||
var/obj/O = M.loc
|
||||
O.force_eject_occupant()
|
||||
O.force_eject_occupant(M)
|
||||
admin_forcemove(M, get_turf(usr))
|
||||
feedback_add_details("admin_verb","GM") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -156,7 +156,7 @@
|
||||
if(M)
|
||||
if(isobj(M.loc))
|
||||
var/obj/O = M.loc
|
||||
O.force_eject_occupant()
|
||||
O.force_eject_occupant(M)
|
||||
admin_forcemove(M, get_turf(usr))
|
||||
admin_forcemove(usr, M.loc)
|
||||
feedback_add_details("admin_verb","GK") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
@@ -172,7 +172,7 @@
|
||||
if(A)
|
||||
if(isobj(M.loc))
|
||||
var/obj/O = M.loc
|
||||
O.force_eject_occupant()
|
||||
O.force_eject_occupant(M)
|
||||
admin_forcemove(M, pick(get_area_turfs(A)))
|
||||
feedback_add_details("admin_verb","SMOB") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
log_admin("[key_name(usr)] teleported [key_name(M)] to [A]")
|
||||
|
||||
@@ -904,7 +904,7 @@ GLOBAL_PROTECT(AdminProcCallSpamPrevention)
|
||||
var/datum/map_template/ruin/template = landmark.ruin_template
|
||||
if(isobj(usr.loc))
|
||||
var/obj/O = usr.loc
|
||||
O.force_eject_occupant()
|
||||
O.force_eject_occupant(usr)
|
||||
admin_forcemove(usr, get_turf(landmark))
|
||||
|
||||
to_chat(usr, "<span class='name'>[template.name]</span>")
|
||||
|
||||
@@ -136,12 +136,10 @@
|
||||
QDEL_NULL(ion_trail)
|
||||
occupant_sanity_check()
|
||||
if(pilot)
|
||||
pilot.forceMove(get_turf(src))
|
||||
pilot = null
|
||||
eject_pilot()
|
||||
if(passengers)
|
||||
for(var/mob/M in passengers)
|
||||
M.forceMove(get_turf(src))
|
||||
passengers -= M
|
||||
eject_passenger(M)
|
||||
GLOB.spacepods_list -= src
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
return ..()
|
||||
@@ -203,6 +201,20 @@
|
||||
/obj/spacepod/blob_act(obj/structure/blob/B)
|
||||
deal_damage(30)
|
||||
|
||||
/obj/spacepod/force_eject_occupant(mob/target)
|
||||
if(target == pilot)
|
||||
eject_pilot()
|
||||
else
|
||||
eject_passenger(target)
|
||||
|
||||
/obj/spacepod/proc/eject_pilot()
|
||||
pilot.forceMove(get_turf(src))
|
||||
pilot = null
|
||||
|
||||
/obj/spacepod/proc/eject_passenger(mob/passenger)
|
||||
passenger.forceMove(get_turf(src))
|
||||
passengers -= passenger
|
||||
|
||||
/obj/spacepod/attack_animal(mob/living/simple_animal/user)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
if((user.a_intent == INTENT_HELP && user.ckey) || user.melee_damage_upper == 0)
|
||||
@@ -439,12 +451,11 @@
|
||||
src.visible_message("<span class='warning'>[user] is trying to rip the door open and pull [target] out of the [src]!</span>",
|
||||
"<span class='warning'>You see [user] outside the door trying to rip it open!</span>")
|
||||
if(do_after(user, 50, target = src))
|
||||
target.forceMove(get_turf(src))
|
||||
target.Stun(1)
|
||||
if(pilot)
|
||||
pilot = null
|
||||
eject_pilot()
|
||||
else
|
||||
passengers -= target
|
||||
eject_passenger(target)
|
||||
target.visible_message("<span class='warning'>[user] flings the door open and tears [target] out of the [src]</span>",
|
||||
"<span class='warning'>The door flies open and you are thrown out of the [src] and to the ground!</span>")
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user