mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 02:34:00 +00:00
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:
@@ -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.
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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)
|
||||
|
||||
4
html/changelogs/Lorilili - pointing.yml
Normal file
4
html/changelogs/Lorilili - pointing.yml
Normal file
@@ -0,0 +1,4 @@
|
||||
author: Lorilili
|
||||
delete-after: True
|
||||
changes:
|
||||
- rscadd: "You can now point using shift and middle mouse button."
|
||||
Reference in New Issue
Block a user