Skip to content

Commit

Permalink
Alt click rotate.
Browse files Browse the repository at this point in the history
  • Loading branch information
davipatury committed Jul 30, 2016
1 parent 662e4df commit 42a2d68
Show file tree
Hide file tree
Showing 8 changed files with 59 additions and 6 deletions.
8 changes: 8 additions & 0 deletions code/game/objects/structures/stool_bed_chair_nest/chairs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,14 @@
handle_rotation()
return

/obj/structure/stool/bed/chair/AltClick(mob/user)
if(user.incapacitated())
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
return
if(!Adjacent(user))
return
rotate()

// Chair types
/obj/structure/stool/bed/chair/wood
// TODO: Special ash subtype that looks like charred chair legs
Expand Down
8 changes: 8 additions & 0 deletions code/game/objects/structures/windoor_assembly.dm
Original file line number Diff line number Diff line change
Expand Up @@ -322,6 +322,14 @@ obj/structure/windoor_assembly/Destroy()
update_icon()
return

/obj/structure/windoor_assembly/AltClick(mob/user)
if(user.incapacitated())
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
return
if(!Adjacent(user))
return
revrotate()

//Flips the windoor assembly, determines whather the door opens to the left or the right
/obj/structure/windoor_assembly/verb/flip()
set name = "Flip Windoor Assembly"
Expand Down
8 changes: 8 additions & 0 deletions code/game/objects/structures/window.dm
Original file line number Diff line number Diff line change
Expand Up @@ -318,6 +318,14 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
return


/obj/structure/window/AltClick(mob/user)
if(user.incapacitated())
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
return
if(!Adjacent(user))
return
revrotate()

/*
/obj/structure/window/proc/updateSilicate()
if(silicateIcon && silicate)
Expand Down
11 changes: 11 additions & 0 deletions code/modules/pda/PDA.dm
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,17 @@ var/global/list/obj/item/device/pda/PDAs = list()
else
to_chat(usr, "<span class='notice'>You cannot do this while restrained.</span>")

/obj/item/device/pda/AltClick(mob/user)
..()
if(issilicon(usr))
return

if(can_use(user))
if(id)
remove_id()
else
to_chat(user, "<span class='warning'>This PDA does not have an ID in it!</span>")

/obj/item/device/pda/proc/remove_id()
if (id)
if (ismob(loc))
Expand Down
8 changes: 8 additions & 0 deletions code/modules/power/singularity/emitter.dm
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,14 @@
src.dir = turn(src.dir, 90)
return 1

/obj/machinery/power/emitter/AltClick(mob/user)
if(user.incapacitated())
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
return
if(!Adjacent(user))
return
rotate()

/obj/machinery/power/emitter/initialize()
..()
if(state == 2 && anchored)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,14 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
src.dir = turn(src.dir, 270)
return 1

/obj/structure/particle_accelerator/AltClick(mob/user)
if(user.incapacitated())
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
return
if(!Adjacent(user))
return
rotate()

/obj/structure/particle_accelerator/verb/rotateccw()
set name = "Rotate Counter Clockwise"
set category = "Object"
Expand Down
8 changes: 8 additions & 0 deletions code/modules/recycling/disposal-construction.dm
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,14 @@
dir = turn(dir, -90)
update()

/obj/structure/disposalconstruct/AltClick(mob/user)
if(user.incapacitated())
to_chat(user << "<span class='warning'>You can't do that right now!</span>")
return
if(!Adjacent(user))
return
rotate()

/obj/structure/disposalconstruct/verb/flip()
set name = "Flip Pipe"
set src in view(1)
Expand Down
6 changes: 0 additions & 6 deletions paradise.dme
Original file line number Diff line number Diff line change
Expand Up @@ -2069,12 +2069,6 @@
#include "code\modules\vehicle\sportscar.dm"
#include "code\modules\vehicle\vehicle.dm"
#include "goon\code\datums\browserOutput.dm"
#include "goon\code\datums\converter.dm"
#include "goon\code\datums\datum.dm"
#include "goon\code\datums\pooling.dm"
#include "goon\code\datums\robust_light.dm"
#include "goon\code\datums\testlight.dm"
#include "goon\code\datums\turf.dm"
#include "interface\interface.dm"
#include "interface\skin.dmf"
// END_INCLUDE

0 comments on commit 42a2d68

Please sign in to comment.