Adds shift-middle click pointing (#7487)

* Adds shift-middle click pointing

* Borgs and buckled folk can now point

* Create Lorilili - pointing.yml
This commit is contained in:
listerla
2020-08-20 22:14:15 -04:00
committed by VirgoBot
parent 1e26cc77b4
commit 7e65840937
4 changed files with 22 additions and 3 deletions

View File

@@ -51,6 +51,9 @@
if(modifiers["shift"] && modifiers["ctrl"])
CtrlShiftClickOn(A)
return 1
if(modifiers["shift"] && modifiers["middle"])
ShiftMiddleClickOn(A)
return 1
if(modifiers["middle"])
MiddleClickOn(A)
return 1
@@ -229,6 +232,15 @@
return
*/
/*
Shift middle click
Used for pointing.
*/
/mob/proc/ShiftMiddleClickOn(atom/A)
pointed(A)
return
/*
Shift click
For most mobs, examine.

View File

@@ -9,7 +9,7 @@
/mob/living/silicon/robot/ClickOn(var/atom/A, var/params)
if(!checkClickCooldown())
return
setClickCooldown(1)
if(client.buildmode) // comes after object.Click to allow buildmode gui objects to be clicked
@@ -20,6 +20,9 @@
if(modifiers["shift"] && modifiers["ctrl"])
CtrlShiftClickOn(A)
return
if(modifiers["shift"] && modifiers["middle"])
ShiftMiddleClickOn(A)
return
if(modifiers["middle"])
MiddleClickOn(A)
return

View File

@@ -48,7 +48,7 @@
//mob verbs are faster than object verbs. See above.
/mob/living/pointed(atom/A as mob|obj|turf in view())
if(src.stat || !src.canmove || src.restrained())
if(src.stat || src.restrained())
return 0
if(src.status_flags & FAKEDEATH)
return 0
@@ -248,7 +248,7 @@ default behaviour is:
/mob/living/Crossed(var/atom/movable/AM) // Transplanting this from /mob/living/carbon/human/Crossed()
if(AM == src || AM.is_incorporeal()) // We're not going to run over ourselves or ghosts
return
if(istype(AM, /mob/living/bot/mulebot))
var/mob/living/bot/mulebot/MB = AM
MB.runOver(src)

View File

@@ -0,0 +1,4 @@
author: Lorilili
delete-after: True
changes:
- rscadd: "You can now point using shift and middle mouse button."