[MIRROR] Telekinesis can throw non items (vending machines, lockers) only 1 tile far (#2626)

* Telekinesis can throw non items (vending machines, lockers) only 1 tile far (#56063)

Telekinesis users can now only throw items 10 tiles, everything else can only be thrown 1 tile

* Telekinesis can throw non items (vending machines, lockers) only 1 tile far

Co-authored-by: Gamer025 <33846895+Gamer025@users.noreply.github.com>
This commit is contained in:
SkyratBot
2021-01-10 23:18:35 +01:00
committed by GitHub
parent 69f42d8c2f
commit b8cde47f70
3 changed files with 7 additions and 1 deletions

View File

@@ -93,6 +93,7 @@
layer = ABOVE_HUD_LAYER
plane = ABOVE_HUD_PLANE
///Object focused / selected by the TK user
var/atom/movable/focus
var/mob/living/carbon/tk_user
@@ -171,7 +172,8 @@
else
. = TRUE
apply_focus_overlay()
focus.throw_at(target, 10, 1,user)
//Only items can be thrown 10 tiles everything else only 1 tile
focus.throw_at(target, focus.tk_throw_range, 1,user)
user.changeNext_move(CLICK_CD_MELEE)
update_icon()

View File

@@ -11,6 +11,8 @@
var/datum/thrownthing/throwing = null
var/throw_speed = 2 //How many tiles to move per ds when being thrown. Float values are fully supported
var/throw_range = 7
///Max range this atom can be thrown via telekinesis
var/tk_throw_range = 1
var/mob/pulledby = null
var/initial_language_holder = /datum/language_holder
var/datum/language_holder/language_holder // Mindless mobs and objects need language too, some times. Mind holder takes prescedence.

View File

@@ -138,6 +138,8 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
///Who threw the item
var/mob/thrownby = null
///Items can by default thrown up to 10 tiles by TK users
tk_throw_range = 10
///the icon to indicate this object is being dragged
mouse_drag_pointer = MOUSE_ACTIVE_POINTER