Closed ilodev closed 1 year ago
The ms2 code that imports pyqt (material check) is currently unused. It could be moved to the validate function instead and just raise a warning there, instead of a question.
OvlFile and OvlReporter are totally interchangeable.
Done that, but the logic for ms2 material checking itself may need changing. It might be too annoying as is.
Awesome! Can’t touch the code again until Monday, I’ll do some testing there!
On Sat, 22 Jul 2023 at 14:15, HENDRIX-ZT2 @.***> wrote:
Done that, but the logic for ms2 material checking itself may need changing. It might be too annoying as is.
— Reply to this email directly, view it on GitHub https://github.com/OpenNaja/cobra-tools/issues/339#issuecomment-1646570076, or unsubscribe https://github.com/notifications/unsubscribe-auth/AG42R73ESGZPL7RL5SJ5BODXRO75XANCNFSM6AAAAAA2RPPYYU . You are receiving this because you authored the thread.Message ID: @.***>
Also done
This one is for Hex since I know you are working on this.
Currently the ovl creation is highly linked to the UI due to the system connecting the signals in the different loading/saving process. This is really breaking any attempt to integrate the main ovl file code into any other tool that doesn't have an UI (requiring QT5 even if not used at all).
The dependency is so clear that the Ovl class required to create an ovl file is inside Widgets.py, and is defined as:
class OvlReporter(OvlFile, QtCore.QObject, metaclass=CombinedMeta):
There are a few more problems after this, when the OvlFile class is loading, more and more dependencies start showing up, like this one:
a part of the error handling is done directly in the MS2.py module instead of propagated back properly. Additionally we could just not force pyqt5 here at all.
After some struggles I was able to remove the QT5 dependencies to build a basic Init.ovl from a diff tool just reusing the tools classes.
This is the same sublime command:![image](https://github.com/OpenNaja/cobra-tools/assets/28944639/c4da5bea-5620-4ff9-afc9-32c2583868fd)
There is another alternative, where I can use 'external executables' as a building tool, however when I read the input provided by the tool it really comes formatted for a terminal (even if not running in a terminal anymore).
Since Hex is working on refactoring the whole UI stuff, maybe these things can be considered as a decoupling exercise so we can make additional tools faster (without having to deal with a whole set of dependencies).