Coder Social home page Coder Social logo

metin2localecleaner's Introduction

Metin2 Locale File Cleaner

License: MIT

Description

Metin2 Locale File Cleaner is a Python 3.11 tool designed to clean unused lines from local files in the game Metin2. It uses the chardet package (specified in the requirements.txt file) for character encoding detection. The tool can be used simply by running the main.py script.

Usage

  1. Clone the repository or download the source code.
  2. Install the required dependencies using pip:
pip install -r requirements.txt
  1. Configuration
    • Place your locale files in the localedirectory.
    • Place your source files (root/uiscript/locale) in the source directory.
    • Configure the mapping dictionary in the main.py script with the paths to your locale files. For example:
mapping = {
    # "file_name" : "python_file_name"
    "locale_game.txt": "localeInfo",
    "locale_interface.txt": "uiScriptLocale",
}
  1. Run the main.py script to clean the unused lines from the locale files:
python main.py

You can now use your newly edited locale files located in the locale directory.

Note: The tool supports multi-language systems, allowing you to add multiple files to localeInfo, uiScriptLocale, etc., and have them processed one by one.

Configuration Options

You can configure the tool using the LocaleCleaner class.

  • locale_directory: Modify the folder for local files (default is locale).
  • source_directory: Modify the folder for source files (default is source).
  • extensions: Modify the extensions to be read by the script (default is ['.py']).

Refer to the docstring of the __init__ functions of the LocaleLCleaner class for more details on the configuration options.

Code Formatting

The project has been formatted with Black for code uniformity.

License

Metin2 Locale File Cleaner is distributed under the MIT License, which allows you to use, modify, and distribute the tool freely, including for commercial purposes. However, you must provide appropriate credit to the original author.

Author

Metin2 Locale File Cleaner was created by Nicolas Coudert.

Feel free to report any issues or sggest improvements via GitHub issues.

Happy cleaning!

metin2localecleaner's People

Contributors

nicolascdt avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.