[MIRROR] makes movement reset tolerance less harsh on jousting component, adds keycheck to mob riding (#2966)

* makes movement reset tolerance less harsh on jousting component, adds keycheck to mob riding (#56497)

the current tolerance on jousting is 2 deciseconds not enough to do fun stuff with any of the mobs you can ride on station like cows or goliaths, this is now 3
mob riding never had a keycheck so u could ride goliaths without a lasso and stuff like that

* makes movement reset tolerance less harsh on jousting component, adds keycheck to mob riding

Co-authored-by: Fikou <piotrbryla@onet.pl>
This commit is contained in:
SkyratBot
2021-01-31 03:46:53 +00:00
committed by GitHub
co-authored by Fikou
parent 031080333e
commit efd87b13c4
3 changed files with 9 additions and 3 deletions
+1 -1
View File
@@ -3,7 +3,7 @@
var/max_tile_charge = 5
var/min_tile_charge = 2 //tiles before this code gets into effect.
var/current_tile_charge = 0
var/movement_reset_tolerance = 2 //deciseconds
var/movement_reset_tolerance = 3 //deciseconds
var/unmounted_damage_boost_per_tile = 0
var/unmounted_knockdown_chance_per_tile = 0
var/unmounted_knockdown_time = 0
+5 -1
View File
@@ -78,7 +78,11 @@
/datum/component/riding/creature/driver_move(atom/movable/movable_parent, mob/living/user, direction)
if(!COOLDOWN_FINISHED(src, vehicle_move_cooldown))
return COMPONENT_DRIVER_BLOCK_MOVE
if(!keycheck(user))
if(ispath(keytype, /obj/item))
var/obj/item/key = keytype
to_chat(user, "<span class='warning'>You need a [initial(key.name)] to ride [movable_parent]!</span>")
return COMPONENT_DRIVER_BLOCK_MOVE
var/mob/living/living_parent = parent
var/turf/next = get_step(living_parent, direction)
step(living_parent, direction)