From 6d3f99556195c03fd479cb8fb7f52f4a9522d44b Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 3 Sep 2014 15:33:20 +0300 Subject: hercules: rename script actions. --- hercules/cachetotmx.py | 1 - hercules/extract.py | 1 - hercules/extractmaps.py | 1 + hercules/list.py | 1 - hercules/listmaps.py | 1 + hercules/mapstotmx.py | 1 + hercules/maptool.py | 18 +++++++++--------- 7 files changed, 12 insertions(+), 12 deletions(-) delete mode 120000 hercules/cachetotmx.py delete mode 120000 hercules/extract.py create mode 120000 hercules/extractmaps.py delete mode 120000 hercules/list.py create mode 120000 hercules/listmaps.py create mode 120000 hercules/mapstotmx.py diff --git a/hercules/cachetotmx.py b/hercules/cachetotmx.py deleted file mode 120000 index df2b3e6..0000000 --- a/hercules/cachetotmx.py +++ /dev/null @@ -1 +0,0 @@ -maptool.py \ No newline at end of file diff --git a/hercules/extract.py b/hercules/extract.py deleted file mode 120000 index df2b3e6..0000000 --- a/hercules/extract.py +++ /dev/null @@ -1 +0,0 @@ -maptool.py \ No newline at end of file diff --git a/hercules/extractmaps.py b/hercules/extractmaps.py new file mode 120000 index 0000000..df2b3e6 --- /dev/null +++ b/hercules/extractmaps.py @@ -0,0 +1 @@ +maptool.py \ No newline at end of file diff --git a/hercules/list.py b/hercules/list.py deleted file mode 120000 index df2b3e6..0000000 --- a/hercules/list.py +++ /dev/null @@ -1 +0,0 @@ -maptool.py \ No newline at end of file diff --git a/hercules/listmaps.py b/hercules/listmaps.py new file mode 120000 index 0000000..df2b3e6 --- /dev/null +++ b/hercules/listmaps.py @@ -0,0 +1 @@ +maptool.py \ No newline at end of file diff --git a/hercules/mapstotmx.py b/hercules/mapstotmx.py new file mode 120000 index 0000000..df2b3e6 --- /dev/null +++ b/hercules/mapstotmx.py @@ -0,0 +1 @@ +maptool.py \ No newline at end of file diff --git a/hercules/maptool.py b/hercules/maptool.py index 375a25d..51ff750 100755 --- a/hercules/maptool.py +++ b/hercules/maptool.py @@ -20,12 +20,12 @@ import struct import shutil def detectCommand(): - if sys.argv[0][-8:] == "/list.py": - return "list" - elif sys.argv[0][-11:] == "/extract.py": - return "extract" - elif sys.argv[0][-14:] == "/cachetotmx.py": - return "cachetotmx" + if sys.argv[0][-12:] == "/listmaps.py": + return "listmaps" + elif sys.argv[0][-15:] == "/extractmaps.py": + return "extractmaps" + elif sys.argv[0][-13:] == "/mapstotmx.py": + return "mapstotmx" return "help" def makeDir(path): @@ -161,11 +161,11 @@ def readMapCache(path, cmd): mapsCount = readInt16(f) print "Maps count: " + str(mapsCount) readInt16(f) # padding - if cmd == "list": + if cmd == "listmaps": listMapCache(f, mapsCount) - elif cmd == "extract": + elif cmd == "extractmaps": extractMaps(f, mapsCount) - elif cmd == "cachetotmx": + elif cmd == "mapstotmx": covertToTmx(f, mapsCount) -- cgit v1.2.3-70-g09d2