Python 2.7.18 Update

  • Konbuyu başlatan Konbuyu başlatan Admin
  • Başlangıç tarihi Başlangıç tarihi
  • Cevaplar Cevaplar 0
  • Görüntüleme Görüntüleme 57

Admin

Metin2Lobby
Yönetici
Founder
Katılım
6 Mayıs 2022
Mesajlar
52,647
Ticaret : 1 / 0 / 0
Selamlar, MT2 için düzenleyip derlediğim Python 2.7.18 sürümünü paylaşacağım. Baştan sona ufak tefek düzenlemeler içermekte ayrıca MT2 için gereksiz olan tüm Python eklentileri de orijinale sadık kalacak şekilde kapatıldı (GF hala eski bir sürümü kullanıyor ama oyunun binary/lib klasöründen görebileceğiniz üzere kullanmayacakları her şeyi kapatmışlar, başlıca sebebi güvenlik tabii ki) bunun haricinde kullanışlı olabilecek decimal, JSON ve XML gibi destekleri aktif bıraktım çünkü işe yarayacakları senaryolar mevcut, zaten tüm kaynak kodunu paylaşıyorum kendiniz istediğinizi açıp kapatabilirsiniz fakat ben bu haliyle sorunsuz şekilde kullanıyorum kendi projemde, iyi eğlenceler.

README Dosyasından ufak kesit; (Çeşitli yerlerde paylaştığım için, ayrı ayrı uğraşmamak adına İngilizce yazdım kusura bakmayın)
Kod:
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ F.A.Q +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ //[/FONT] ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ " How To Build ? " ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ [/* INFO: If you don't want to bother with the compilation process, you can get the precompiled versions from the folder named "precompiled".*/] - Open "Change.cpp" file and do the neccesary changes. - After that, open the "MT2_Include_Path.rar" file and copy that Python folder to your "Client/Srcs/Extern/Include" path. - Go to "PCBuild / BUILD_PYTHON.sln" right click -> Build all (/*Do it both Release and Debug versions*/). - After build, all the outputs (/* .lib, .dll etc */) will take place at "PCBuild/". - Move .dll files to your binary path, move lib files to your "Client/Srcs/Extern/Library" path. + After the compilation process in "Release" mode is complete, the generated python.exe file automatically converts all py files in the lib to pyc. + You should add these new pyc and pyd files to the MT2 binary lib folder after the build process is complete. + (/* NOTE: When adding these pyc files to the Metin2 lib, you DO NOT NEED TO ADD THE FILES ; */ +  "compileall.pyc - py_compile.pyc - runpy.pyc - pkgutil.pyc - inspect.pyc - token.pyc - tokenize.pyc - dis.pyc - opcode.pyc" +  /* These are ONLY required during the compilation phase! */) ---------------------------------------------------------------------------------------------------------------------------------------------------------- /* NOTE II: During the process of converting py files to pyc, the log of all stages is written to the "PCBuild/PYC_Compile.log" file,             you can look here in case of errors while compile. */ ---------------------------------------------------------------------------------------------------------------------------------------------------------- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ " What Is The Diffrence ? " ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - All unnecessary Python features for MT2 have been deactivated, but a few new features have been added that might be useful. + For example, decimal, which can be used to increase damage limits, is also available, along with various other improvements like JSON and XML support. +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ " Why We Need To Use This Version ? " ++++++++++++++++++++++++++++++++++++++++++++++++++++ - The short answer is that you dont have to use it, but it is a fact that it will provide you with certain advantages if you do use it, let's take a look at them. + Unnecessary files and codes (/* for MT2 */) were cleaned and the build warnings were also fixed. + This version is the most suitable version for MT2 in terms of both performance and security, +    It is the last 2.7 version released and does not contain features that MT2 does not use (/* like ssl, socket, html etc */). +    It is also important that it includes the security fixes made by Python up to this 2.7.18 version. +    It is always best to use the most up-to-date version possible of any external libraries you use.


İndirme Linkleri;

-
VT:

Python 2.7.18 Güncellemesi ve Metin2 Geliştirme Sürecindeki Yeri

Metin2 özel sunucularının geliştirilmesi sürecinde kullanılan dillerden birisi olan Python, özellikle eski sistemlerde büyük rol oynamaktadır. Python 2.7.18, Python 2 serisinin son sürümüdür ve güvenlik güncellemeleriyle birlikte kararlı bir yapı sunmaktadır. Bu sürüm, Metin2 özel sunucu geliştiricileri tarafından hâlâ desteklenen sistemlerde aktif olarak kullanılmaktadır.

Python 2 Serisi Neden Hâlâ Kullanılıyor?

Metin2 kaynak kodları arasında Python 2 tabanlı sistemler bulunmaktadır. Özellikle UIScript ve PY Root gibi dosya yapıları, Python 2.7 ile çalışacak şekilde tasarlanmıştır. Bu nedenle birçok geliştirici, Python 2.7.18 sürümünü kullanmaya devam etmektedir. Ancak bu sürüm artık resmi olarak desteklenmemektedir ve güvenlik riskleri taşıyabilir.

Python 2.7.18 Güvenlik Açıkları

Python 2.7.18, 2020 yılında son güncelleme almıştır. Bu tarihten sonra herhangi bir güvenlik yaması yayınlanmamıştır. Bu durum, Metin2 özel sunucularında güvenlik açıklarına yol açabilir. Özellikle sunucu tarafında çalışan Python betikleri, doğru yapılandırılmazsa saldırıya açık hale gelebilir. Bu yüzden geliştiricilerin Python 3'e geçiş planlaması büyük önem taşımaktadır.

Metin2'de Python ve GUI Sistemleri

Python tabanlı GUI sistemleri, Metin2 istemci tarafında kullanıcı arayüzlerinin oluşturulmasında önemli rol oynar. PY GUI ve Python GUI yapıları sayesinde oyun içi menüler, eklentiler ve özel arayüzler kolayca geliştirilebilir. Bu sistemler genellikle UIScript ile birlikte çalışır ve PY Root klasörlerinde barındırılır.

UIScript ve PY Root Nedir?

UIScript, Metin2 istemci tarafında Python ile yazılmış arayüz dosyalarıdır. PY Root ise bu dosyaların bulunduğu kök dizindir. Bu yapılar, istemcinin kullanıcı ile etkileşimini sağlar. Örneğin, envanter, eşya listesi, yetenek penceresi gibi bileşenler burada tanımlanır. Python 2.7.18 ile uyumlu olarak çalışırlar.

Python 2'den Python 3'e Geçiş

Geliştiricilerin Python 3'e geçiş yapması, güvenlik ve performans açısından kritik öneme sahiptir. Ancak bu geçiş, mevcut PY Root ve UIScript dosyalarında değişiklikler gerektirebilir. Bazı sözdizimi farklılıkları, doğrudan uyumsuzluklara neden olabilir. Bu nedenle, geçiş öncesi kapsamlı testler yapılması gerekir.

Geçiş İçin Önerilen Adımlar

1. Mevcut Python 2.7 betiklerini Python 3 uyumlu hale getirmek.
2. PY GUI ve UIScript yapılarını gözden geçirip gerekli güncellemeleri yapmak.
3. Sunucu tarafında kullanılan Python betiklerini test etmek.
4. Derleme süreçlerinde Python bağımlılıklarını göz önünde bulundurmak.

Metin2 Geliştirme Sürecinde Python Kullanımı

Python, hem istemci hem de sunucu tarafında önemli bir araçtır. Oyun mantığı, veritabanı işlemleri, komut satırı araçları gibi alanlarda Python kullanımı yaygındır. Özellikle DB Core ve Game Core sistemlerinde Python betikleri aktif rol oynar. Bu nedenle Python bilgisi, Metin2 geliştiricileri için büyük avantaj sağlar.

Python 2.7.18 ile Metin2 Kaynak Kodları

Metin2 kaynak kodları içinde Python 2.7.18 desteği olan birçok modül yer alır. Bu modüller, sunucu derlemelerinde ve sistem güncellemelerinde aktif olarak kullanılır. Ancak bu sürümün desteklenmemesi, uzun vadede sorunlara yol açabilir. Geliştiricilerin bu konuda bilinçli olması gerekir.

Sonuç

Python 2.7.18, Metin2 özel sunucu geliştirme sürecinde hâlâ kullanılan ancak artık desteklenmeyen bir sürümüdür. Güvenlik risklerini azaltmak ve daha iyi performans elde etmek için Python 3'e geçiş planlaması yapılmalıdır. Bu süreçte PY Root, UIScript ve diğer Python tabanlı sistemlerin güncellenmesi büyük önem taşır.


Python 2.7.18 Update and Its Place in Metin2 Development

In the process of developing Metin2 private servers, Python is one of the languages used, particularly in older systems. Python 2.7.18 is the final release of the Python 2 series and offers a stable structure with security updates. This version is still actively used by many developers on systems that continue to support it in Metin2 private server environments.

Why Is the Python 2 Series Still Being Used?

Within Metin2 source codes, there are systems based on Python 2. Particularly, file structures such as UIScript and PY Root are designed to work with Python 2.7. Therefore, many developers continue to use Python 2.7.18. However, this version is no longer officially supported and may carry security risks.

Python 2.7.18 Security Vulnerabilities

Python 2.7.18 last received updates in 2020. No security patches have been released since then. This situation can lead to security vulnerabilities in Metin2 private servers. Especially, Python scripts running on the server-side can become vulnerable to attacks if not properly configured. Thus, planning a migration to Python 3 is of great importance for developers.

Python and GUI Systems in Metin2

Python-based GUI systems play an important role in creating user interfaces within the Metin2 client. Thanks to PY GUI and Python GUI structures, in-game menus, plugins, and custom interfaces can be developed easily. These systems typically work alongside UIScript and are stored in PY Root folders.

What Are UIScript and PY Root?

UIScript refers to interface files written in Python on the Metin2 client side. PY Root is the main directory where these files are located. These structures allow the client to interact with users. For example, components like inventory, item lists, and skill windows are defined here. They operate compatibly with Python 2.7.18.

Transition from Python 2 to Python 3

Transitioning to Python 3 is critically important for developers in terms of security and performance. However, this transition may require modifications to existing PY Root and UIScript files. Certain syntax differences could cause direct incompatibilities. Therefore, comprehensive testing should be done before transitioning.

Recommended Steps for Transition

1. Make existing Python 2.7 scripts compatible with Python 3.
2. Review PY GUI and UIScript structures and apply necessary updates.
3. Test Python scripts used on the server-side.
4. Consider Python dependencies during build processes.

Using Python in Metin2 Development

Python is an essential tool on both client and server sides. It is commonly used in areas such as game logic, database operations, and command-line tools. Specifically, Python scripts play an active role in DB Core and Game Core systems. Therefore, knowledge of Python provides significant advantages for Metin2 developers.

Python 2.7.18 and Metin2 Source Codes

Many modules supporting Python 2.7.18 exist within Metin2 source codes. These modules are actively used in server builds and system updates. However, the lack of support for this version could cause problems in the long term. Developers must be aware of this issue.

Conclusion

Python 2.7.18 is a version still used in the development of Metin2 private servers but is no longer supported. Planning a transition to Python 3 is necessary to reduce security risks and achieve better performance. Updating PY Root, UIScript, and other Python-based systems during this process is highly critical.
 

Şuan Bu Konuyu Görüntüleyen Kullanıcılar (Toplam : 0, Üye : 0, Misafir : 0)

Benzer konular

Geri
Üst Alt