Currently diff does a reasonable job at creating patches for maps, however these patches are not reliable imperfect patching. This is because for imperfect patching relies on the context in the patch containing sufficient information to find where the change should happen. This situation is even worse for objects in inventories, where there will be no x or y coords in the context. This could make patching player unique files much more practical.
diff -u 20
” instead of “diff -u
”). patch -F 15
”) in order to reduce the risk of conflicts. So if the map or player object has not been modified, there will be a perfect match and the patch will be applied without problems. If there some differences in the 20 lines of context, then patch will report that the hunk has been applied with some fuzziness. In the end, it is very likely that diff and patch will do exactly what we expect them to do, without having to implement our own tools.