Jump to content

Granny Converter to 2.11.8


Recommended Posts

  • Bronze

M2 Download Center

This is the hidden content, please
( Internal )

Password: metin2.dev

 

Hi guys, its small release Granny Converter to 2.11.8 version :D

Spoiler

image.jpg

Download: 

This is the hidden content, please

Src: 

This is the hidden content, please

Virustotal

This is the hidden content, please


Note: The folder name can not contain spaces.
Example: "...\converter\old\ymir work\monster" -> "...\converter\old\monster"


If you find any shortcomings write in the comments... sorry for my english

Edited by Metin2 Dev
Core X - External 2 Internal
  • Metin2 Dev 135
  • kekw 2
  • Eyes 5
  • Dislove 2
  • Angry 3
  • Not Good 3
  • Sad 1
  • Cry 2
  • Think 5
  • Confused 1
  • Scream 3
  • Lmao 3
  • Good 59
  • Love 9
  • Love 104
Link to comment
Share on other sites

  • Bronze
4 minutes ago, .plechito' said:

1. I have to start run.bat as administrator
2. It wrote me that files are trnasformed succesfully but it doesnt create new folder and doesnt convert the files :(:D

u have 2 folder: "new" and "old". You put your files on folder "old" and then start "run.bat".

If u dont have this folder -> create.

 try :D

Link to comment
Share on other sites

https://metin2.download/picture/r3F9504x09DVmF8K988YXgTtGTP6KMUj/.gif This is my problem, although it converts them i cannot open any file.

 

@niokio I suggest editing the first post to "Do not run as administrator" so it's grammatically and syntactically right. 

Edited by Metin2 Dev
Core X - External 2 Internal
  • Love 1
Link to comment
Share on other sites

  • 8 months later...
  • Bronze

#Update 0.2
- Added change log.
- Writes paths to all files (on "granny_list").
- Converter goes through all folders and subfolders.
- The converter is written in C++
- Recompile preprocessor.
- Removed .bat bullshit :D


Note: The folder name can not contain spaces.
Example: "...\converter\old\ymir work\monster" -> "...\converter\old\monster"

Link to comment
Share on other sites

  • Premium
4 hours ago, niokio said:

#Update 0.2
- Added change log.
- Writes paths to all files (on "granny_list").
- Converter goes through all folders and subfolders.
- The converter is written in C++
- Recompile preprocessor.
- Removed .bat bullshit :D


Note: The folder name can not contain spaces.
Example: "...\converter\old\ymir work\monster" -> "...\converter\old\monster"

Try something do to convert all .gr2 in a folder.


 

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...
  • Silver
On 8/27/2018 at 2:06 PM, Chyu ^^ said:

Would you post sources?

It's so easy.
 

1.Download this: LINK
2. compile gstate and preprocessor.
3. use command example cmd_line: preprocessor.exe TouchVersion old_mesh.gr2 -output new_mesh.gr2

May be 
i will create GUI for comfort using.

--UPD


Best regards
Helia01

  • Love 1
Link to comment
Share on other sites

  • 3 weeks later...
  • Former Staff
On 9/29/2018 at 7:34 PM, Shogun said:

Does this have any practical use?

upgrading libraries has it's own advantages  such as speed and optimizing  but upgrading the models them self doesn't benefits much  unless you have the full granny source .. 

so i think the answer is no 

Link to comment
Share on other sites

  • 2 weeks later...
  • 5 weeks later...
  • Bronze

Just compile the Preprocessor and use it

And for texture modification for example

 

RebaseTextureFiles is intended to change the filestrings reported
for textures from absolute paths (used by Max and Maya), to paths
relative to the root of your game data directory, the character
file itself, or any other root you want to specify.

preprocessor RebaseTextureFiles file.gr2 -output file_relative.gr2 -basepath c:/game/data/root

For modifying textures the granny preprocessor provides

Renames granny_file_info members specified by "-rename Name[idx]"

 

preprocessor RenameElement base.gr2 -output base.gr2 -rename textures[0] -newname "d:/ymir work/npc_mount/new_texture_name.dds"

Would change texture index 0 to d:/ymir work/npc_mount/new_texture_name.dds

You can event automate most of this process just by creating a batch file the processor takes and executes on the given file

BonesPerMesh -bonelimit 100
CleanMaterials
VertexCacheOptimize
PlatformConvert -pointer 32 -endian little
Compress

With just this and Granny 2.11 you have a good amount of performance gain in metin2 for example

This little script for example takes an directory collects all gr2 files and applies a file called dx9.ppb to the collected files

from __future__ import print_function
import fnmatch
import os
import subprocess
import sys

#http://code.activestate.com/recipes/577058/
def query_yes_no(question, default="yes"):
    """Ask a yes/no question via raw_input() and return their answer.

    "question" is a string that is presented to the user.
    "default" is the presumed answer if the user just hits <Enter>.
        It must be "yes" (the default), "no" or None (meaning
        an answer is required of the user).

    The "answer" return value is True for "yes" or False for "no".
    """
    valid = {"yes": True, "y": True, "ye": True,
             "no": False, "n": False}
    if default is None:
        prompt = " [y/n] "
    elif default == "yes":
        prompt = " [Y/n] "
    elif default == "no":
        prompt = " [y/N] "
    else:
        raise ValueError("invalid default answer: '%s'" % default)

    while True:
        sys.stdout.write(question + prompt)
        choice = raw_input().lower()
        if default is not None and choice == '':
            return valid[default]
        elif choice in valid:
            return valid[choice]
        else:
            sys.stdout.write("Please respond with 'yes' or 'no' "
                             "(or 'y' or 'n').\n")


# Print iterations progress
#https://stackoverflow.com/questions/3173320/text-progress-bar-in-the-console?page=1&tab=votes#tab-top
def printProgressBar(iteration, total, prefix = '', suffix = '', decimals = 1, length = 100, fill = '#'):
    """
    Call in a loop to create terminal progress bar
    @params:
        iteration   - Required  : current iteration (Int)
        total       - Required  : total iterations (Int)
        prefix      - Optional  : prefix string (Str)
        suffix      - Optional  : suffix string (Str)
        decimals    - Optional  : positive number of decimals in percent complete (Int)
        length      - Optional  : character length of bar (Int)
        fill        - Optional  : bar fill character (Str)
    """
    percent = ("{0:." + str(decimals) + "f}").format(100 * (iteration / float(total)))
    filledLength = int(length * iteration // total)
    bar = fill * filledLength + '-' * (length - filledLength)
    print('\r%s |%s| %s%% %s' % (prefix, bar, percent, suffix), end = '\r')
    # Print New Line on Complete
    if iteration == total: 
        print()


print("ATTENTION! This script should only be executed in single folders")
print("as it always changes the granny files recursively. We do")
print("not want that data bloat in our git repository")
print("")

accepted = query_yes_no("Are you sure you want to execute the updater?")
if not accepted:
    sys.exit()
    
path = raw_input("Enter the path that you want to convert:")
if path == ".":
	accepted = query_yes_no("Do you know that . is everything?")
	if not accepted:
		sys.exit()

matches = []
for root, dirnames, filenames in os.walk("source/" + path):
    for filename in fnmatch.filter(filenames, '*.gr2'):
        matches.append(os.path.join(root, filename))

total = len(matches)

if total <= 0:
	print("No gr2 file found in path: " + path)
	sys.exit()

printProgressBar(0, total, prefix = 'Progress:', suffix = 'Complete', length = 50)

for i, match in enumerate(matches):
    printProgressBar(i, total, prefix = 'Progress:', suffix = 'Complete', length = 50)
    subprocess.call(['preprocessor.exe', 'RunBatch', '-batch', 'dx9.ppb', match])
	
print("Done")

 

  • Love 2
Link to comment
Share on other sites

Announcements



×
×
  • 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.