Finishes the forceMove port

This commit is contained in:
vuonojenmustaturska
2017-12-14 23:39:34 +02:00
committed by CitadelStationBot
parent a22b225015
commit fcceb5ec77
110 changed files with 364 additions and 239 deletions
+3 -3
View File
@@ -163,7 +163,7 @@
/obj/effect/chrono_field/New(loc, var/mob/living/target, var/obj/item/gun/energy/chrono_gun/G)
if(target && isliving(target) && G)
target.loc = src
target.forceMove(src)
src.captured = target
var/icon/mob_snapshot = getFlatIcon(target)
var/icon/cached_icon = new()
@@ -198,7 +198,7 @@
if(captured)
if(tickstokill > initial(tickstokill))
for(var/atom/movable/AM in contents)
AM.loc = loc
AM.forceMove(drop_location())
qdel(src)
else if(tickstokill <= 0)
to_chat(captured, "<span class='boldnotice'>As the last essence of your being is erased from time, you begin to re-experience your most enjoyable memory. You feel happy...</span>")
@@ -213,7 +213,7 @@
else
captured.Unconscious(80)
if(captured.loc != src)
captured.loc = src
captured.forceMove(src)
update_icon()
if(gun)
if(gun.field_check(src))
+1 -1
View File
@@ -328,7 +328,7 @@
O.unwield()
to_chat(user, "<span class='notice'>The paddles snap back into the main unit.</span>")
defib.on = 0
loc = defib
forceMove(defib)
defib.update_icon()
return unwield(user)
+2 -2
View File
@@ -543,7 +543,7 @@ GLOBAL_LIST_EMPTY(PDAs)
if("2") // Eject pAI device
var/turf/T = get_turf(src.loc)
if(T)
pai.loc = T
pai.forceMove(T)
//LINK FUNCTIONS===================================
@@ -578,7 +578,7 @@ GLOBAL_LIST_EMPTY(PDAs)
M.put_in_hands(id)
to_chat(usr, "<span class='notice'>You remove the ID from the [name].</span>")
else
id.loc = get_turf(src)
id.forceMove(drop_location())
id = null
update_icon()
@@ -85,7 +85,7 @@
/obj/item/device/chameleon/proc/eject_all()
for(var/atom/movable/A in active_dummy)
A.loc = active_dummy.loc
A.forceMove(active_dummy.loc)
if(ismob(A))
var/mob/M = A
M.reset_perspective(null)
@@ -106,7 +106,7 @@
VRD.force_dismount(M)
else
V.unbuckle_mob(M, force = TRUE)
M.loc = src
M.forceMove(src)
master = C
master.active_dummy = src
@@ -50,7 +50,7 @@
else if(istype(W, /obj/item/screwdriver))
if(diode)
to_chat(user, "<span class='notice'>You remove the [diode.name] from \the [src].</span>")
diode.loc = get_turf(src.loc)
diode.forceMove(drop_location())
diode = null
else
return ..()
@@ -227,7 +227,7 @@
if(keyslot)
var/turf/T = get_turf(user)
if(T)
keyslot.loc = T
keyslot.forceMove(T)
keyslot = null
@@ -235,7 +235,7 @@
if(keyslot2)
var/turf/T = get_turf(user)
if(T)
keyslot2.loc = T
keyslot2.forceMove(T)
keyslot2 = null
recalculateChannels()
@@ -569,7 +569,7 @@
if(keyslot)
var/turf/T = get_turf(user)
if(T)
keyslot.loc = T
keyslot.forceMove(T)
keyslot = null
recalculateChannels()
@@ -110,12 +110,12 @@
else if(stage == WIRED && istype(I, /obj/item/wrench))
if(beakers.len)
for(var/obj/O in beakers)
O.loc = get_turf(src)
O.forceMove(drop_location())
beakers = list()
to_chat(user, "<span class='notice'>You open the [initial(name)] assembly and remove the payload.</span>")
return // First use of the wrench remove beakers, then use the wrench to remove the activation mechanism.
if(nadeassembly)
nadeassembly.loc = get_turf(src)
nadeassembly.forceMove(drop_location())
nadeassembly.master = null
nadeassembly = null
else // If "nadeassembly = null && stage == WIRED", then it most have been cable_coil that was used.
@@ -167,7 +167,7 @@
playsound(loc, 'sound/items/screwdriver2.ogg', 50, 1)
if(beakers.len)
for(var/obj/O in beakers)
O.loc = get_turf(src)
O.forceMove(drop_location())
beakers = list()
stage_change(EMPTY)
return
@@ -1,3 +1,4 @@
<<<<<<< HEAD
/obj/item/implantcase
name = "implant case"
desc = "A glass case containing an implant."
@@ -77,3 +78,85 @@
name = "implant case - 'Adrenaline'"
desc = "A glass case containing an adrenaline implant."
imp_type = /obj/item/implant/adrenalin
=======
/obj/item/implantcase
name = "implant case"
desc = "A glass case containing an implant."
icon = 'icons/obj/items_and_weapons.dmi'
icon_state = "implantcase-0"
item_state = "implantcase"
lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi'
righthand_file = 'icons/mob/inhands/equipment/medical_righthand.dmi'
throw_speed = 2
throw_range = 5
w_class = WEIGHT_CLASS_TINY
materials = list(MAT_GLASS=500)
var/obj/item/implant/imp = null
var/imp_type
/obj/item/implantcase/update_icon()
if(imp)
icon_state = "implantcase-[imp.item_color]"
reagents = imp.reagents
else
icon_state = "implantcase-0"
reagents = null
/obj/item/implantcase/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/pen))
var/t = stripped_input(user, "What would you like the label to be?", name, null)
if(user.get_active_held_item() != W)
return
if(!in_range(src, user) && loc != user)
return
if(t)
name = "implant case - '[t]'"
else
name = "implant case"
else if(istype(W, /obj/item/implanter))
var/obj/item/implanter/I = W
if(I.imp)
if(imp || I.imp.imp_in)
return
I.imp.forceMove(src)
imp = I.imp
I.imp = null
update_icon()
I.update_icon()
else
if(imp)
if(I.imp)
return
imp.forceMove(I)
I.imp = imp
imp = null
update_icon()
I.update_icon()
else
return ..()
/obj/item/implantcase/Initialize(mapload)
. = ..()
if(imp_type)
imp = new imp_type(src)
update_icon()
/obj/item/implantcase/tracking
name = "implant case - 'Tracking'"
desc = "A glass case containing a tracking implant."
imp_type = /obj/item/implant/tracking
/obj/item/implantcase/weapons_auth
name = "implant case - 'Firearms Authentication'"
desc = "A glass case containing a firearms authentication implant."
imp_type = /obj/item/implant/weapons_auth
/obj/item/implantcase/adrenaline
name = "implant case - 'Adrenaline'"
desc = "A glass case containing an adrenaline implant."
imp_type = /obj/item/implant/adrenalin
>>>>>>> 5233ec1... Finishes the forceMove port (#33519)
+3 -3
View File
@@ -69,7 +69,7 @@
if(!l_arm && !r_arm && !l_leg && !r_leg && !chest && !head)
if (M.use(1))
var/obj/item/ed209_assembly/B = new /obj/item/ed209_assembly
B.loc = get_turf(src)
B.forceMove(drop_location())
to_chat(user, "<span class='notice'>You arm the robot frame.</span>")
var/holding_this = user.get_inactive_held_item()==src
qdel(src)
@@ -227,7 +227,7 @@
O.job = "Cyborg"
O.cell = chest.cell
chest.cell.loc = O
chest.cell.forceMove(O)
chest.cell = null
W.forceMove(O)//Should fix cybros run time erroring when blown up. It got deleted before, along with the frame.
if(O.mmi) //we delete the mmi created by robot/New()
@@ -271,7 +271,7 @@
O.cell = chest.cell
chest.cell.loc = O
chest.cell.forceMove(O)
chest.cell = null
O.locked = panel_locked
O.job = "Cyborg"
+4 -4
View File
@@ -131,7 +131,7 @@
..()
to_chat(user, "<span class='notice'>The mister snaps back onto the watertank.</span>")
tank.on = 0
loc = tank
forceMove(tank)
/obj/item/reagent_containers/spray/mister/attack_self()
return
@@ -236,13 +236,13 @@
tank = parent_tank
reagents = tank.reagents
max_water = tank.volume
loc = tank
forceMove(tank)
/obj/item/extinguisher/mini/nozzle/Move()
..()
if(loc != tank.loc)
loc = tank
forceMove(tank)
return
/obj/item/extinguisher/mini/nozzle/attack_self(mob/user)
@@ -268,7 +268,7 @@
..()
to_chat(user, "<span class='notice'>The nozzle snaps back onto the tank!</span>")
tank.on = 0
loc = tank
forceMove(tank)
/obj/item/extinguisher/mini/nozzle/afterattack(atom/target, mob/user)
if(nozzle_mode == EXTINGUISHER)
+1 -1
View File
@@ -447,7 +447,7 @@
return
if(explosive && wielded)
user.say("[war_cry]")
explosive.loc = AM
explosive.forceMove(AM)
explosive.prime()
qdel(src)