Jump to content

martysama0134

Honorable Member
  • Posts

    613
  • Joined

  • Last visited

  • Days Won

    96
  • Feedback

    100%

Posts posted by martysama0134

  1. #UPDATED

    What's New:

    • v2.0
      • The module's name check is now case-insensitive (colorInfo == colorinfo)
      • Added a new function rootlib/uiscriptlib.getList() to retrieve a tuple of all the available cythonized modules.
      • Now you can compile a uiscriptlib library from the uiscript*.py files! (implemented as __USE_EXTRA_CYTHON__)
      • Added a sample ui.py containing the code to run uiscriptlib.
    Preview:

    uc3Nymq.png

    • Love 4
  2. On 3/15/2015 at 11:45 AM, ѕeмa™ said:

    I think you forgot the .close() doesnt work with cython.

    LoginWindow.__LoadScript.BindObject - <type 'exceptions.AttributeError'>:'pack_file' object has no attribute 'close'
    
    Example:
    file=open("aaa.txt","w")
    file.write("heyy how are u?")
    file.close()
    and how to repair:
    file=open("aaa.txt","w").write("hey i solve the bug")

     

     

    On 3/15/2015 at 3:59 PM, Lyrex said:

    Well, open usually isn't the same as pack_open. I'm not sure if something related to this get's modified here.

    open = python open, which has a close method

    pack_open = metin2 open which doesn't

    On the recent official roots, the "pack_open" is renamed as "open", and "open" as "old_open".

    Post your old system.py (push it on pastebin/pastie).

     

     

    Probably, your lib folder contains .pyc files compiled with py2.2. You should use the ones for 2.7.

    This is the hidden content, please

    • Metin2 Dev 15
    • Good 1
    • Love 4
  3. I have this errors:  http://pastebin.com/xXfn4G84

     

    I use python22 on launcher and vs2008 , is needed 27 or work with 22?

     

    cpp file: http://pastebin.com/t6M9t7Gh

    PyMODINIT_FUNC doesn't exist in python2.2.

    I've added this in the python<modulename>Manager.cpp:

    #ifndef PyMODINIT_FUNC
    #define PyMODINIT_FUNC extern "C" __declspec(dllexport) void
    #endif
    Sadly, Cython doesn't work on py2.2 without refactoring itself.

    HqxjajQ.png

    • Metin2 Dev 1
    • Love 1
  4. Hi, marty. When cythonized, is there still need dynamic linking e.g: python27.dll or library files?

    Yes, the python27.dll, and the lib folder are still required.

    You can now develop an interesting hash check of these files in the __hybrid_import function inside system.py.

  5. I can compile a few files from the root or all files is needed?

    If you use the files as "they are", only system.py and prototype.py are required.

    If the module you want to include is not present in the rootlib one, the client will try to open the relative <modulename>.py file.

    • Love 1
  6. When I run the MakeFile_VC_Release.bat file, I get the following errors:

    'cl' is not recognized as an internal or external command, operable program or batch file.
    'lib' is not recognized as an internal or external command, operable program or batch file.

    It's simple: it happens when the visual studio path is not specified in the %PATH% environment variable.

    You have few solutions:

    • Add the visual studio path in the %PATH% environment variable. (I won't suggest it)
    • Add something like this at the beginning of the MakeFile_VC_Release.bat file and run it as administrator: (easy way)

      call "C:Program Files (x86)Microsoft Visual Studio 10.0VCvcvarsall.bat"
    • You should run as admininistrator the Visual Studio Command Prompt (2010)" and then recall the .bat from there. (highly preferable)
    NB: I've used vs2010, but it works without any problems with any vs version.
  7. Maybe a stupid question, but can you cythonize all the python files of the client? I mean really each py file, including every script :)

    The script as "it is", right now, creates a "rootlib" module. There are tons of way to do what you asked. (at least, 10 ways)

    The easier one to do so, using cython, would be making a "uiscriptlib" library, and re-writing the Sandbox.execfile method inside the utils.py file.

  8. Thanks, but i think you should put a guide of how to repair the errors give the *.py files when you are cythonicing, a lot of people cant use the system if dont know how repair it. <-- this is not going for me, I know how to fix it.

    Only to increase the information in the post.

    The only two errors you could get when you compile your root are:
    • "Decoding error, missing or incorrect coding"

      Since all the .py files are processed as korean strings, all of them written with a different charset (arabic) will trigger this issue.

      It's explained in the .txt file, and you can simply bypass this just writing the text in the locale_game.txt file.

    • "Expected an increase in indentation level"

      This happens when the .py file has a bad tabulation, so bad written:

      It's clear that you won't be able to compile unworkable/unrunnable/broken .py files.

    • Love 8
  9. M2 Download Center

    This is the hidden content, please
    ( Internal )

    Intro

    This release will explain how to "convert" your root .py files to .c ones.

    Actually, Cython only converts those files to pure CPython code.

     

    Download

     

    As requested by many people, you can download the compatible and clean official cn root dated 20131228-0034 without further edits:

     

    Is Cython really worth it?

    • Pros
      • All the modules are compiled, and they can't be "extracted as .py" anymore.

        We can always disassemble the launcher with IDA, but the result will be pseudo-c code after waiting 6-8h of analyzing.

      • Since we're not using .pyx files but directly .py ones, there's no "so much optimization".

        At least, 10% of performance increasing is guaranteed.

    • Cons
      • For testing purposes, it's heavy to maintain. Everytime you try to re-compile your root files, you should wait 5-10 minutes.

        You can always use the uncythonized root (.py files) when you perform tests, and compile cython whenever you will make an update in your live server.

      • The launcher's size will increase ~10mb. You can actually pack it to save space.

        If you directly use a .pyd (still 10mb), the launcher's size won't increase.

     

    VideoTutorial

    Credits

    • Me (lollo_9_1/martysama0134)
    • Night (OST suggestion)
    • Random Testers

     

    What's New:

    • vsimpl
      • Visual studio implementation
      • automatic cythonization when compiling
      • only the edited files will be compiled
    • v2.0
      • The module's name check is now case-insensitive (colorInfo == colorinfo)
      • Added a new function rootlib/uiscriptlib.getList() to retrieve a tuple of all the available cythonized modules.
      • Now you can compile a uiscriptlib library from the uiscript*.py files! (implemented as __USE_EXTRA_CYTHON__)
      • Added a sample ui.py containing the code to run uiscriptlib.
    • Metin2 Dev 211
    • kekw 2
    • Eyes 4
    • Dislove 1
    • Angry 1
    • Cry 1
    • Think 2
    • Confused 4
    • Lmao 1
    • Good 74
    • Love 13
    • Love 177
  10. can someone help us please, we need to understand how to fix it.

    I've reverse-engineered the official launcher for it: It's not so simple to re-create the event motion types 11-12 like the official did. (it's a bit of work since ymir re-wrote some skill handling functions)

    The event motion types 11-12 are a workaround of the reef attack animation. (to be more precise, they set the correct distance before diving in to the target)

    You can actually fix this issue without re-writing everything ymir did anyway. You now have a "tip" of what largely the event motion types 11-12 do.

    soBlk86.jpg

    ༼ つ ◕_◕ ༽つ RIP in PepPeRoni ༼ つ ◕_◕ ༽つ

    • Love 2
  11. 3kb file downloaded.... mmmmm wtf?!

    and google stopped the file once downloaded...i can fell something wrong inside that "free download"

    is it only me?

    Chrome detects as possible threat every binary (elf, .exe, .bat) inside every downloaded archive. (without analyzing the relative code; it's just an extension check)

    The easier solution to bypass such a thing is to set a password and also encrypt the index file list (tested on .rar).

    The archive (7zip compressed) actually contains 9340234 empty folders, "RootLibCythonizer.py", and a "MakeFile.bat".

    I have these files for quite a while, and they can be considered as the "real ones".

    There are many ways to cythonize your root, and any of them are acceptable solutions:

    • Using your cython implementation instead of using ymir's one http://cython.org/#download (this is what I did long time ago, but it's kinda boring because you have to write everything by your own)
    • Binding rootlib.lib into your vs project (this is what you do if you use the files in this thread)
    • Making an external rootlib.pyd (this is what I prefer the most)
    • Metin2 Dev 1
    • Love 2
  12. 399479Sanstitre2.jpg

    Crappy antivirus programs usually detect the debug symbols as "possible threat". (they even detected me once a "print hello world" program [only debug target] as a malicious one, but it was from a kinda awful antivirus one)

    Since that's the first time that someone reported me such a thing about such program, probably the issue is another.

    Searching on the web, it seems like WinZipper (the program you're using) could be also detected as false positive: http://www.shouldiremoveit.com/WinZipper-68598-program.aspx

     

    beznazvu.png

    123.png

    Please help me.

    Yes.

    1vy0.png

    You already have the files in "d:/ymir work" so "that's ok".

    You should now check if your zone and property folders are really "ok".

    ### NEWS ###

    In these days i'm working on the "v24" of such program.

    This is a little TODO-list of what it will contain:

    • New config options:
      • // the files from d: will be loaded from a local folder called "d"

        ENABLE_D_AS_LOCAL_PATH = 1

      • // the map settings will also export the wind speed

        ENABLE_WIND_SPEED_EXPORT = 1

      • // change the language of your worldeditor in the following: IT EN FR DE ES PT CZ AE KR (and so on)

        APP_LANGUAGE = EN

    • Code refactoring
    • Wolfman motion event implementation
    • Removed boring CTRL requirement (when moving the camera) after clicked the ATTR TAB
    • Other things
    • Love 4
  13. Yesterday a hacker logged in to vanillas skype account and added me.

    Vanilla's profile got hacked even one month ago:

    To be more precise, when this board got hacked, his twitter contact was spamming the database to everyone. (same "hacker"?)

    Anyway, leachers already started re-selling vanilla's files:

    6CgfAQA.png

    • Love 1
  14. Hello There

    Today i will Show you How To change the Icon of the metin2client.exe its really easy to do so

    Let's start

    first go to your client source and open the bin folder scroll down to see some icons chose your favorite one and copy it

    go to the user interface folder and past it there

    then open your solution with Visual Studio and press Strg+F then type in "metin2.ico" and change look in to "entired solution"

    then it will show you "UserInterface.rc"

    right click ->go to location

    then change the name "metin2.ico" to your chosen icon file

    compile and its done

    p.s. you can chose a self made icon to

    You just need to replace metin2.ico in the UserInterface folder and recompile the launcher. There's no need to change any manifest files at all.

    If you wanna change the icon from an already built launcher, Resource Hacker/PE Explorer can be used without any problems. (you could have some weird issues if you try to change the icon from a badly unpacked launcher anyway)

    • Love 1
  15. Since you sold what rights you have power over them?

    It's never a good thing trying to resell other people's work.

    From the screens, it looks like they claimed the payment. So the seller is actually seeing other people earning money with his own work. (and he actually received €0 from them)

    People should understand that they must support the main developer and not errant hungry dogs if they want real improvements.

     

    I have also seen host companies such as Cloud express and CEHOST that are selling my serverfile

    How could a host company selling such files? Isn't this quite abusive?
×
×
  • 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.