M2 Download Center
Download Here ( Internal )
Download Here ( GitHub )
First: sorry. My code is not clean, I am not a developer or anything, I am just a math student. I am just trying to do my best. And my skills in English are… non-existent. So, be nice please.
Using very often PyCharm, I wanted to be able to use it on Metin2, but PyCharm (or another IDE) hit me hard with baseball bat because he could not find the modules.
So, I have made this tool to create module’s python skeleton and use autocompletion with IDE. The biggest flaw is that you must have Python3 installed on your machine to use typing.
Example of result with PyCharm:
And you can't find an exemple of output here.
To follow this tutorial, you must have:
Python3 (i'm using Python3.8)
PyCharm or other IDE, but in this tutorial, I will use PyCharm (from JetBrains).
Tools to make skeletons.
I – Generate your module skeleton.
You can find just upper, a link to download my script. It is easy to use. You can find all the manipulations in README.md file, but I will explain it here too:
Move all your client’s .cpp file (with module) in src folder.
Just use now main.py with Python3 (I developed it with Python3.8)
You will see many files in bin folder.
II – Make a virtual environment of Python3 for IDEs
We will have to create a virtual environment for our IDEs to do not dirty our real Python installation. To do that, you can use the command :
python3 -m venv /path/to/new/virtual/environment
Find all information on the doc : https://docs.python.org/3/library/venv.html
I will show you how to do that with PyCharm:
And with Visual Studo Code:
III - Add our skeletons to virtualenv
For that, you just must move all your .py file in bin folder to venv/Lib/site-packages. Example :
This manipulation is a little dirty ... But I couldn't find anything better so as not to have too much change to make. If you have a better one, I take...
Don't forget to configure your IDE to use new virtualenv.
IV - Known issues:
Script cannot predict value of the constants;
It does not yed manage structures of this type:
V - Debug:
Script now support Tuple in functions' returns;
Add the method GetWindow for arguments.
With using Python3 IDE, he will consider print without parentheses and except bloc as error...
Thanks to @Gurgarath for his help