mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Merge branch 'master' of github.com:Baystation12/Baystation12 into dev
This commit is contained in:
@@ -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, i<numticks, i++)
|
||||
sleep(delayfraction)
|
||||
|
||||
|
||||
if(!user || user.stat || user.weakened || user.stunned || !(user.loc == T))
|
||||
if(!user || user.stat || user.weakened || user.stunned || (user.loc != original_loc))
|
||||
return 0
|
||||
if(needhand && !(user.get_active_hand() == holding)) //Sometimes you don't want the user to have to keep their active hand
|
||||
return 0
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -247,7 +247,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
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -592,6 +592,7 @@
|
||||
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 <B>\the [usr] successfully broke out of \the [SC]!</B>", 1)
|
||||
@@ -601,6 +602,7 @@
|
||||
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 <B>\the [usr] successfully broke out of \the [C]!</B>", 1)
|
||||
|
||||
@@ -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()]\] <font color='blue'>Has used [src.name] on \ref[target]</font>")
|
||||
|
||||
|
||||
Binary file not shown.
9
tools/mapmerge/clean_map_git.sh
Normal file
9
tools/mapmerge/clean_map_git.sh
Normal file
@@ -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
|
||||
|
||||
@@ -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.
|
||||
|
||||
Reference in New Issue
Block a user