From 9731082e3e80b32ea8b76ed6c24a9c03b7932d2a Mon Sep 17 00:00:00 2001 From: Loganbacca Date: Wed, 14 May 2014 19:59:40 +1200 Subject: [PATCH 1/6] Added a quick adjacent check for alt-clicking Since we really don't need to be doing a pathing check when we just want to return an object list. --- code/_onclick/adjacent.dm | 15 +++++++++++++++ code/_onclick/click.dm | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/code/_onclick/adjacent.dm b/code/_onclick/adjacent.dm index fa08ea6f6b..47e7e99a92 100644 --- a/code/_onclick/adjacent.dm +++ b/code/_onclick/adjacent.dm @@ -55,6 +55,21 @@ return 1 // we don't care about our own density return 0 +/* +Quick adjacency (to turf): +* If you are in the same turf, always true +* If you are not adjacent, then false +*/ +/turf/proc/AdjacentQuick(var/atom/neighbor, var/atom/target = null) + var/turf/T0 = get_turf(neighbor) + if(T0 == src) + return 1 + + if(get_dist(src,T0) > 1) + return 0 + + return 1 + /* Adjacency (to anything else): * Must be on a turf diff --git a/code/_onclick/click.dm b/code/_onclick/click.dm index fd0b658aa0..2fe09bb3bf 100644 --- a/code/_onclick/click.dm +++ b/code/_onclick/click.dm @@ -245,7 +245,7 @@ /atom/proc/AltClick(var/mob/user) var/turf/T = get_turf(src) - if(T && T.Adjacent(user)) + if(T && T.AdjacentQuick(user)) if(user.listed_turf == T) user.listed_turf = null else From 86190c0edb65e628b3b1a30a5a981381c05b1d6f Mon Sep 17 00:00:00 2001 From: Loganbacca Date: Wed, 14 May 2014 21:54:49 +1200 Subject: [PATCH 2/6] Fix resisting out of closets - Removed do_after proc since it was hanging somewhere --- code/modules/mob/living/living.dm | 77 +++++++++++++++---------------- 1 file changed, 38 insertions(+), 39 deletions(-) diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 4998c4cbc8..ec67f4912c 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -565,47 +565,46 @@ O.show_message("\red The [L.loc] begins to shake violently!", 1) - spawn(0) - if(do_after(usr,(breakout_time*60*10))) //minutes * 60seconds * 10deciseconds - if(!C || !L || L.stat != CONSCIOUS || L.loc != C || C.opened) //closet/user destroyed OR user dead/unconcious OR user no longer in closet OR closet opened + spawn(breakout_time*60*10) //minutes * 60seconds * 10deciseconds + if(!C || !L || L.stat != CONSCIOUS || L.loc != C || C.opened) //closet/user destroyed OR user dead/unconcious OR user no longer in closet OR closet opened + return + + //Perform the same set of checks as above for weld and lock status to determine if there is even still a point in 'resisting'... + if(istype(L.loc, /obj/structure/closet/secure_closet)) + var/obj/structure/closet/secure_closet/SC = L.loc + if(!SC.locked && !SC.welded) + return + else + if(!C.welded) return - //Perform the same set of checks as above for weld and lock status to determine if there is even still a point in 'resisting'... - if(istype(L.loc, /obj/structure/closet/secure_closet)) - var/obj/structure/closet/secure_closet/SC = L.loc - if(!SC.locked && !SC.welded) - return - else - if(!C.welded) - return - - //Well then break it! - if(istype(usr.loc, /obj/structure/closet/secure_closet)) - var/obj/structure/closet/secure_closet/SC = L.loc - SC.desc = "It appears to be broken." - SC.icon_state = SC.icon_off - flick(SC.icon_broken, SC) - sleep(10) - flick(SC.icon_broken, SC) - sleep(10) - SC.broken = 1 - SC.locked = 0 - usr << "\red You successfully break out!" - for(var/mob/O in viewers(L.loc)) - O.show_message("\red \the [usr] successfully broke out of \the [SC]!", 1) - if(istype(SC.loc, /obj/structure/bigDelivery)) //Do this to prevent contents from being opened into nullspace (read: bluespace) - var/obj/structure/bigDelivery/BD = SC.loc - BD.attack_hand(usr) - SC.open() - else - C.welded = 0 - usr << "\red You successfully break out!" - for(var/mob/O in viewers(L.loc)) - O.show_message("\red \the [usr] successfully broke out of \the [C]!", 1) - if(istype(C.loc, /obj/structure/bigDelivery)) //nullspace ect.. read the comment above - var/obj/structure/bigDelivery/BD = C.loc - BD.attack_hand(usr) - C.open() + //Well then break it! + if(istype(usr.loc, /obj/structure/closet/secure_closet)) + var/obj/structure/closet/secure_closet/SC = L.loc + SC.desc = "It appears to be broken." + SC.icon_state = SC.icon_off + flick(SC.icon_broken, SC) + sleep(10) + flick(SC.icon_broken, SC) + sleep(10) + SC.broken = 1 + SC.locked = 0 + usr << "\red You successfully break out!" + for(var/mob/O in viewers(L.loc)) + O.show_message("\red \the [usr] successfully broke out of \the [SC]!", 1) + if(istype(SC.loc, /obj/structure/bigDelivery)) //Do this to prevent contents from being opened into nullspace (read: bluespace) + var/obj/structure/bigDelivery/BD = SC.loc + BD.attack_hand(usr) + SC.open() + else + C.welded = 0 + usr << "\red You successfully break out!" + for(var/mob/O in viewers(L.loc)) + O.show_message("\red \the [usr] successfully broke out of \the [C]!", 1) + if(istype(C.loc, /obj/structure/bigDelivery)) //nullspace ect.. read the comment above + var/obj/structure/bigDelivery/BD = C.loc + BD.attack_hand(usr) + C.open() //breaking out of handcuffs else if(iscarbon(L)) From 03a01fc80561ec13b5dd05e9fa766b96a72acbfc Mon Sep 17 00:00:00 2001 From: Loganbacca Date: Wed, 14 May 2014 21:55:51 +1200 Subject: [PATCH 3/6] Closet wrapping fix - Removed ability to wrap closets if you are inside them --- code/modules/recycling/sortingmachinery.dm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/modules/recycling/sortingmachinery.dm b/code/modules/recycling/sortingmachinery.dm index eecba616fb..a5eb401019 100755 --- a/code/modules/recycling/sortingmachinery.dm +++ b/code/modules/recycling/sortingmachinery.dm @@ -99,6 +99,8 @@ return if(target in user) return + if(user in target) //no wrapping closets that you are inside - it's not physically possible + return user.attack_log += text("\[[time_stamp()]\] Has used [src.name] on \ref[target]") From c9dd123c2b42d43e9cb6626f15b4f27d73794d95 Mon Sep 17 00:00:00 2001 From: Mike Date: Wed, 14 May 2014 19:59:52 -0400 Subject: [PATCH 4/6] Fixes #4977 --- code/game/machinery/camera/camera.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/machinery/camera/camera.dm b/code/game/machinery/camera/camera.dm index daea3219d6..5d206b9f94 100644 --- a/code/game/machinery/camera/camera.dm +++ b/code/game/machinery/camera/camera.dm @@ -215,7 +215,7 @@ /obj/machinery/camera/proc/cancelCameraAlarm() alarm_on = 0 for(var/mob/living/silicon/S in mob_list) - S.cancelAlarm("Camera", get_area(src), list(src), src) + S.cancelAlarm("Camera", get_area(src), src) /obj/machinery/camera/proc/can_use() if(!status) From 78e022464999be9eee36782e4306c7cf1046a2f5 Mon Sep 17 00:00:00 2001 From: Loganbacca Date: Thu, 15 May 2014 23:03:21 +1200 Subject: [PATCH 5/6] Fixed resisting out of lockers --- code/__HELPERS/unsorted.dm | 4 +- code/modules/mob/living/living.dm | 79 ++++++++++++++++--------------- 2 files changed, 43 insertions(+), 40 deletions(-) diff --git a/code/__HELPERS/unsorted.dm b/code/__HELPERS/unsorted.dm index dd2a2b9dcc..ba60be32d7 100644 --- a/code/__HELPERS/unsorted.dm +++ b/code/__HELPERS/unsorted.dm @@ -727,14 +727,14 @@ proc/anim(turf/location as turf,target as mob|obj,a_icon,a_icon_state as text,fl return 0 var/delayfraction = round(delay/numticks) - var/turf/T = get_turf(user) + var/original_loc = user.loc var/holding = user.get_active_hand() for(var/i = 0, iThe [L.loc] begins to shake violently!", 1) - spawn(breakout_time*60*10) //minutes * 60seconds * 10deciseconds - if(!C || !L || L.stat != CONSCIOUS || L.loc != C || C.opened) //closet/user destroyed OR user dead/unconcious OR user no longer in closet OR closet opened - return - - //Perform the same set of checks as above for weld and lock status to determine if there is even still a point in 'resisting'... - if(istype(L.loc, /obj/structure/closet/secure_closet)) - var/obj/structure/closet/secure_closet/SC = L.loc - if(!SC.locked && !SC.welded) - return - else - if(!C.welded) + spawn(0) + if(do_after(usr,(breakout_time*60*10))) //minutes * 60seconds * 10deciseconds + if(!C || !L || L.stat != CONSCIOUS || L.loc != C || C.opened) //closet/user destroyed OR user dead/unconcious OR user no longer in closet OR closet opened return - //Well then break it! - if(istype(usr.loc, /obj/structure/closet/secure_closet)) - var/obj/structure/closet/secure_closet/SC = L.loc - SC.desc = "It appears to be broken." - SC.icon_state = SC.icon_off - flick(SC.icon_broken, SC) - sleep(10) - flick(SC.icon_broken, SC) - sleep(10) - SC.broken = 1 - SC.locked = 0 - usr << "\red You successfully break out!" - for(var/mob/O in viewers(L.loc)) - O.show_message("\red \the [usr] successfully broke out of \the [SC]!", 1) - if(istype(SC.loc, /obj/structure/bigDelivery)) //Do this to prevent contents from being opened into nullspace (read: bluespace) - var/obj/structure/bigDelivery/BD = SC.loc - BD.attack_hand(usr) - SC.open() - else - C.welded = 0 - usr << "\red You successfully break out!" - for(var/mob/O in viewers(L.loc)) - O.show_message("\red \the [usr] successfully broke out of \the [C]!", 1) - if(istype(C.loc, /obj/structure/bigDelivery)) //nullspace ect.. read the comment above - var/obj/structure/bigDelivery/BD = C.loc - BD.attack_hand(usr) - C.open() + //Perform the same set of checks as above for weld and lock status to determine if there is even still a point in 'resisting'... + if(istype(L.loc, /obj/structure/closet/secure_closet)) + var/obj/structure/closet/secure_closet/SC = L.loc + if(!SC.locked && !SC.welded) + return + else + if(!C.welded) + return + + //Well then break it! + if(istype(usr.loc, /obj/structure/closet/secure_closet)) + var/obj/structure/closet/secure_closet/SC = L.loc + SC.desc = "It appears to be broken." + SC.icon_state = SC.icon_off + flick(SC.icon_broken, SC) + sleep(10) + flick(SC.icon_broken, SC) + sleep(10) + SC.broken = 1 + SC.locked = 0 + SC.update_icon() + usr << "\red You successfully break out!" + for(var/mob/O in viewers(L.loc)) + O.show_message("\red \the [usr] successfully broke out of \the [SC]!", 1) + if(istype(SC.loc, /obj/structure/bigDelivery)) //Do this to prevent contents from being opened into nullspace (read: bluespace) + var/obj/structure/bigDelivery/BD = SC.loc + BD.attack_hand(usr) + SC.open() + else + C.welded = 0 + C.update_icon() + usr << "\red You successfully break out!" + for(var/mob/O in viewers(L.loc)) + O.show_message("\red \the [usr] successfully broke out of \the [C]!", 1) + if(istype(C.loc, /obj/structure/bigDelivery)) //nullspace ect.. read the comment above + var/obj/structure/bigDelivery/BD = C.loc + BD.attack_hand(usr) + C.open() //breaking out of handcuffs else if(iscarbon(L)) From 6db1484a804878b6b0e96d1338f2cdeead001ba8 Mon Sep 17 00:00:00 2001 From: Mloc-Argent Date: Thu, 15 May 2014 22:00:24 +0100 Subject: [PATCH 6/6] tools: update MapPatcher.jar, add mapclean helper MapPatcher.jar can now take a user-defined tile line when conflicted. Added a clean_map_git.sh file that will automatically clean maps without needing a prepare_map.bat call beforehand. Needs to be run in git bash, or have .sh associated with something that has git. Fixed line endings in install.txt to show up right in notepad. Signed-off-by: Mloc-Argent --- tools/mapmerge/MapPatcher.jar | Bin 10673 -> 10738 bytes tools/mapmerge/clean_map_git.sh | 9 +++++++++ tools/mapmerge/install.txt | 34 ++++++++++++++++---------------- 3 files changed, 26 insertions(+), 17 deletions(-) create mode 100644 tools/mapmerge/clean_map_git.sh diff --git a/tools/mapmerge/MapPatcher.jar b/tools/mapmerge/MapPatcher.jar index a8bc3560b4436b033d72da4248847b5c056bafcf..cb0a4f443380924b8a646b2bade7537ae6d7d7de 100644 GIT binary patch delta 4322 zcmV<85FPKaQ}R;{P)h>@6aWYa2mo-cuaONp18}XckxH2ZZmqAe=4S!}ZmqAgPy>$< z18%Lalj0O3e|db=)wTbgncw_=cYgUzW-`fyj1ZW(k%R;UG}wSrHZhNVQ6z{kWF|0> z%*12@NmSf$<+W;Ut)Nv3t*KfU&<2#2+E%T#Ri8_1wZ2!aTU~0aueKJ^^qk)>nPftO z_{aM^GM{trS?;;#p6%Wlp8Wjb0{|w{L=#C|uCPVne+q>w6|PdaTHzXnYfWs$e|ph~ zubKEdt}}4Gfg22b!;2g7O%u8JmI)tjQuww|ZZ@$E+fCepTMc~2z-}gz&t87X{m9Bke@-X+mI0 ze|t+h-k54lH}R5m1FH&^4z4LTTa=)t)HU=NX)Z~%HrK_^NQg;(-fdwtUAHdYJXSPW zI3LY~@vSY(dBq_RZ%EhSWEN!K;Rqe{B+fy`EuvKBYSo7cv9adTpAA{lL9>4sFDJvOtC({dv5bZeSd8kJ6FaP%yEjDJ{2 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/tools/mapmerge/clean_map_git.sh new file mode 100644 index 0000000000..6ff986e0ba --- /dev/null +++ b/tools/mapmerge/clean_map_git.sh @@ -0,0 +1,9 @@ +#!/bin/sh + +MAPFILE='tgstation.2.1.3.dmm' + +git show HEAD:_maps/map_files/$MAPFILE > tmp.dmm +java -jar MapPatcher.jar -clean tmp.dmm '../../_maps/map_files/'$MAPFILE '../../_maps/map_files/'$MAPFILE +dos2unix -U '../../_maps/map_files/'$MAPFILE +rm tmp.dmm + diff --git a/tools/mapmerge/install.txt b/tools/mapmerge/install.txt index 6319d31c4d..f9cbc4a022 100644 --- a/tools/mapmerge/install.txt +++ b/tools/mapmerge/install.txt @@ -1,17 +1,17 @@ -1. Install java(http://www.java.com/en/download/index.jsp) -2. Make sure java is in your PATH. To test this, open git bash, and type "java". If it says unknown command, you need to add JAVA/bin to your PATH variable. - -Committing -1. Before starting to edit the map, double-click "prepare_map.bat" in the tools/mapmerge/ directory. -2. After finishing your edit, and before your commit, double-click "clean_map.bat" in the tools/mapmerge/ directory. - -This will make sure in the new version of your map, no paths are needlessly changed, thus instead of 8000 lines changed you'll get 50 lines changed. This not only reduces size of your commit, it also makes it possible to get an overview of your map changes on the "files changed" page in your pull request. - -Merging -The easiest way to do merging is to install the merge driver. For this, open -tg-station/.git/config in a text editor, and paste the following lines to the end of it: - -[merge "merge-dmm"] - name = mapmerge driver - driver = ./tools/mapmerge/mapmerge.sh %O %A %B - -After this, merging maps should happen automagically unless there are conflicts(a tile that both you and someone else changed). If there are conflicts, you will unfortunately still be stuck with opening both versions in a map editor, and manually resolving the issues. +1. Install java(http://www.java.com/en/download/index.jsp) +2. Make sure java is in your PATH. To test this, open git bash, and type "java". If it says unknown command, you need to add JAVA/bin to your PATH variable (A guide for this can be found at https://www.java.com/en/download/help/path.xml ). + +Committing +1. Before starting to edit the map, double-click "prepare_map.bat" in the tools/mapmerge/ directory. +2. After finishing your edit, and before your commit, double-click "clean_map.bat" in the tools/mapmerge/ directory. + +This will make sure in the new version of your map, no paths are needlessly changed, thus instead of 8000 lines changed you'll get 50 lines changed. This not only reduces size of your commit, it also makes it possible to get an overview of your map changes on the "files changed" page in your pull request. + +Merging +The easiest way to do merging is to install the merge driver. For this, open `Baystation12/.git/config` in a text editor, and paste the following lines to the end of it: + +[merge "merge-dmm"] + name = mapmerge driver + driver = ./tools/mapmerge/mapmerge.sh %O %A %B + +After this, merging maps should happen automagically unless there are conflicts(a tile that both you and someone else changed). If there are conflicts, you will unfortunately still be stuck with opening both versions in a map editor, and manually resolving the issues.