Jump to content

PY - Map Object Remover


Recommended Posts

M2 Download Center

This is the hidden content, please
( Internal )

Hi! Today, i'm gonna give u simple tool, to remove all objects from map with one command, i think it's useful (;

 

import os, sys

try:
    directory = os.path.relpath(str(sys.argv[1]))
    dirs = []
except IndexError:
    print "usage: deleteObjects.py <mapfolder>"
else:
    if os.path.isdir(directory):
        directoryListing = os.listdir(directory)
        for file in directoryListing:
            file = os.path.join(directory, file)
            if os.path.isdir(file):
                dirs.append(file)

        for dir in dirs:
            with open(os.path.join(dir, "areadata.txt"), "a") as f:
                f.truncate()
                f.write("AreaDataFilennnObjectCount 0")
                f.close()
    else:
        print "Maaan, directory " + directory + " doesn't exist"
        print "usage: deleteObjects.py <mapfolder>"
 
 
  • Metin2 Dev 2
  • Not Good 2
  • Good 1
  • Love 3
Link to comment
Share on other sites

  • 11 months later...
  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Announcements



  • Similar Content

  • Activity

    1. 3

      Crystal Metinstone

    2. 3

      Feeding game source to LLM

    3. 113

      Ulthar SF V2 (TMP4 Base)

    4. 3

      Feeding game source to LLM

    5. 0

      Target Information System

    6. 3

      Feeding game source to LLM

    7. 2

      anti exp explanation pls

  • Recently Browsing

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.