[OPTing] OPTech v2

Want to edit the game, build your own craft and missions? Here you'll find help, tools, guides and people to discuss with.
Post Reply

Re: [OPTing] OPTech v2

User avatar
Vince T
Fleet Admiral (Administrator)
Posts: 14045
Joined: Fri Apr 27, 2001 11:01 pm
Contact:

Post by Vince T » Mon Jan 03, 2022 8:36 am

Great work, Jeremy! All seems to work well now, thank you!

The idea of adding a confirmation dialog to the Reset functions is ingenious! Simple but effective!
Your ship, Captain. I need a drink. - Vince Trageton
Vince T's X-Wing HQ - where the bad guys get their gear

User avatar
Vince T
Fleet Admiral (Administrator)
Posts: 14045
Joined: Fri Apr 27, 2001 11:01 pm
Contact:

Post by Vince T » Fri Jan 07, 2022 8:01 am

Hmm, there's one issue remaining:
The Visibility checkbox works now, however, it functions very slow. If you try to hide or show a large number of meshes, the program stalls for several seconds.

One more thing, though I'm not sure if and how it can be fixed:
How is the zoom factor calculated in the various model views? It seems in some views(top/Bottom) the model properly fills the screen while in others I still have to manually zoom in
Your ship, Captain. I need a drink. - Vince Trageton
Vince T's X-Wing HQ - where the bad guys get their gear

User avatar
Vince T
Fleet Admiral (Administrator)
Posts: 14045
Joined: Fri Apr 27, 2001 11:01 pm
Contact:

Post by Vince T » Sun Jan 16, 2022 7:00 pm

@JeremyaFr could you take another look at this, if you get the chance? The latest changes work well but I think the performance has taken a serious hit. Along with the issue mentioned above, also the preview window is very slow to react, especially with more complex models. Maybe a case of memory leak?

Edit: OK after working with it over a longer time, I'm sorry to say but the selection box is still bugged. If you select several meshes with CTRL then use the Hide checkbox, it will affect other meshes further up the list as well. Also there are instances where I cannot unhide a specific mesh via its individual checkbox.
Your ship, Captain. I need a drink. - Vince Trageton
Vince T's X-Wing HQ - where the bad guys get their gear

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Sun Jan 30, 2022 7:38 pm

UPDATE

Hello,
I've updated OPTech.

I've improved the performance of the mesh visible checkbox.

User avatar
Vince T
Fleet Admiral (Administrator)
Posts: 14045
Joined: Fri Apr 27, 2001 11:01 pm
Contact:

Post by Vince T » Sun Jan 30, 2022 10:12 pm

Thank you Jeremy! I've been working with the new version for a few hours now and everything seems to work fine now!
Sorry for being a pain :)
Your ship, Captain. I need a drink. - Vince Trageton
Vince T's X-Wing HQ - where the bad guys get their gear

User avatar
Rookie_One1
Rebel Alliance
Posts: 1656
Joined: Thu Feb 26, 2004 12:01 am

Post by Rookie_One1 » Sun Mar 27, 2022 2:05 am

Have a weird bug, i'm trying to do a simple rotation of a cockpit opt (the family transport gunner one, for underneath), and i'm ending with the view as thrash (i'm using optech because it's permit moving the whole assembly instead of having to rotate individual parts and move them in position)

Anyone have an idea on what could cause that ?

Here what happens :
https://imgur.com/dLpGORq

For the record, the problem look like it lie with the MainHull mesh, but i'm not sure about what could cause that issue
Rookie One, is that you?? - Ru Merleen, Rebel Spy at Imdaar Alpha
Current Holder of the Frying Pan of Death

User avatar
Vince T
Fleet Admiral (Administrator)
Posts: 14045
Joined: Fri Apr 27, 2001 11:01 pm
Contact:

Post by Vince T » Sun Mar 27, 2022 10:56 am

Did you make sure the coordinates are correct, i.e. the meshes are in the right spot?

Also, if you rotate one or more meshes, I think it will use the last mesh selected as the center of the rotation.
Your ship, Captain. I need a drink. - Vince Trageton
Vince T's X-Wing HQ - where the bad guys get their gear

User avatar
Rookie_One1
Rebel Alliance
Posts: 1656
Joined: Thu Feb 26, 2004 12:01 am

Post by Rookie_One1 » Sun Mar 27, 2022 6:37 pm

meshes are in the right spot, but the last mesh selected is mesh 4, i'll try to select mesh 1 and see what happens
Rookie One, is that you?? - Ru Merleen, Rebel Spy at Imdaar Alpha
Current Holder of the Frying Pan of Death

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Sat May 07, 2022 3:53 pm

UPDATE

Hello,
I've added 2 tools to XwaToolsDownloader:
- XwaOptFlatTexturesFixer
- XwaOpzTrianglesFixer

The source code of these tools is on GitHub.

XwaOptFlatTexturesFixer is a tool to fix flat textures in opt files.
XwaOpzTrianglesFixer is a tool to fix triangles in OPTech opz files.

These tools were created while developping OPTech.

User avatar
Vince T
Fleet Admiral (Administrator)
Posts: 14045
Joined: Fri Apr 27, 2001 11:01 pm
Contact:

Post by Vince T » Sat May 07, 2022 8:29 pm

Interesting.
Exactly what do these tools do? Are those OPTech functions which you "exported" into standalone programs?

- I'm guessing FlatTexturesFixer resets the texture coordinates on faces with flat textures to 0,0,1,1?
- TIs the TrianglesFixer the same as the tools in OPTech used to convert tris to quads and vice versa? Or does it fix Tris with 4 vertices which is a common issue with models coming from certain 3d programs like Rhino 3D?
Your ship, Captain. I need a drink. - Vince Trageton
Vince T's X-Wing HQ - where the bad guys get their gear

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Sun May 08, 2022 7:14 am

FlatTexturesFixer removes faces with flat textures. It's a feature that has then been included into OPTech.

Code: Select all

        static bool HasFaceFlatTexture(Face face)
        {
            Indices tex = face.TextureCoordinatesIndex;

            if (tex.A == tex.B || tex.B == tex.C || tex.A == tex.C)
            {
                return true;
            }

            if (tex.D >= 0)
            {
                if (tex.A == tex.D || tex.B == tex.D || tex.C == tex.D)
                {
                    return true;
                }
            }

            return false;
        }
TrianglesFixer fixes triangles with 4 vertices.

Code: Select all

        static bool IsFaceTri(OpzFace face)
        {
            if (OpzVector3.Equals(face.VertexCoord0, face.VertexCoord3))
            {
                return true;
            }

            if (OpzVector3.Equals(face.VertexCoord1, face.VertexCoord3))
            {
                return true;
            }

            if (OpzVector3.Equals(face.VertexCoord2, face.VertexCoord3))
            {
                return true;
            }

            return false;
        }

User avatar
Vince T
Fleet Admiral (Administrator)
Posts: 14045
Joined: Fri Apr 27, 2001 11:01 pm
Contact:

Post by Vince T » Thu Jun 16, 2022 8:12 am

Hey @JeremyaFr small request:
In Vertice Mode under the Textures tab you can sort the vertex lists by either index or U and V coordinate.
Could you add a similar feature to the Geometry tab so I can sort the vertex lists via the X, Y or Z coordinate?
Your ship, Captain. I need a drink. - Vince Trageton
Vince T's X-Wing HQ - where the bad guys get their gear

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Thu Jun 16, 2022 4:44 pm

UPDATE

Hello,
I've updated OPTech.

Now you can sort the vertices by X, Y, Z, I, J, K coordinates.

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Sun Aug 14, 2022 9:40 am

UPDATE

Hello,
I've updated OPTech.

On exporting you can now choose to export the whole craft or only selected meshes.

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Sat Sep 03, 2022 7:49 pm

UPDATE

Hello,
I've updated OPTech.

Now the texture names are preserved.

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Fri Jan 20, 2023 5:15 pm

UPDATE

Hello,
I've updated OPTech.

Changes are:
- Add a Cut hardpoint button
- Add a Cut engine glow button
- Update the meshes count error

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Sun Feb 05, 2023 7:00 pm

UPDATE

Hello,
I've updated OPTech.

Changes are:
- Add a mesh merge button
- Add a face split button

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Mon Apr 10, 2023 2:46 pm

UPDATE

Hello,
I've updated OPTech.

Changes are:
- disable error check for power of 2 textures
- update error check for texture count from 200 to 1024

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Fri May 19, 2023 3:26 pm

UPDATE

Hello,
I've updated OPTech.

Changes are:
- Set default texture scale value from 2.0 to 0.5
- Preserve the position on mesh duplicate
- Add Copy to the name of duplicated mesh

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Wed Jul 05, 2023 1:43 pm

UPDATE

Hello,
I've updated OPTech.

Changes are:
- merge the Face Count and Model Dimensions menu items into a OPT Info menu item

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Tue Jul 11, 2023 3:23 pm

UPDATE

Hello,
I've updated OPTech.

Changes are:
- fix a bug where the dimensions are wrong in OPT Info menu item

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Thu Sep 14, 2023 7:57 pm

UPDATE

Hello,
I've updated OPTech.

Changes are:
- new keyboard shortcuts

OPTech commands:
EDIT: remove commands list

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Mon Sep 18, 2023 5:59 pm

UPDATE

Hello,
I've updated OPTech.

Changes are:
- update mouse and keyboard commands

OPTech commands:

Mesh/face/vertice selection:
- Left-click on mesh/face/vertice: Select
- Left-click on background: Deselect
- SHIFT + Left-click on mesh/face/vertice: Add to selection
- SHIFT + Left-click on background: Do nothing
- CTRL + Left-click on mesh/face/vertice: Remove from selection
- CTRL + Left-click on background: Do nothing

Camera Control (Hold Mouse Button)
Mouse 2: Rotate Camera up/down/left/right
SHIFT+Mouse 2: Roll Camera left/right
CTRL+Mouse 2: Pan Camera up/down/left/right
CTRL+SHIFT+Mouse 2: Zoom in/out
Mouse 3: Pan camera up/down/left/right
Mouse wheel: zoom

Camera Control (Keyboard)
Arrow keys: Rotate Camera
SHIFT + Arrow keys: Roll Camera
ALT + Arrow keys: Pan camera
Num +/-: Zoom in/out
What do you mean with page rate?

text boxes:
PageUp: increase value by interval
PageDn: decrease value by interval
Up arrow: increase Interval
Down arrow: reset Interval to 0
Return: Confirm

Keyboard shorcuts:
Ctrl+S: quick save
Ctrl+N: new project
Ctrl+O: open project
Ctrl+I: import OPT
Ctrl+D: import DXF
Ctrl+P: create OPT
Ctrl+H: compute hitzones
Ctrl+Q: Tri to Quad
Ctrl+T: Quad to Tri
Ctrl+PgUp: select hight version
Ctrl+PgDow: select low version
Ctrl+Home: mesh zoom off
Ctrl+End: mesh zoom on
Alt+W: wireframe
Alt+T: textures
Alt+N: normals
Alt+M: mesh view
Alt+F: face view
Alt+V: vertex view
Alt+Arrows: move camera
Plus: zoom in
Minus: zoom out
Ctrl+NumPad1: perspective view
Ctrl+NumPad2: bottom view
Ctrl+NumPad3: back view
Ctrl+NumPad4: left view
Ctrl+NumPad5: front view
Ctrl+NumPad6: right view
Ctrl+NumPad8: top view
Alt+Num: change view
F1: Geometry Editor > Geonetry Tab
F2: Geometry Editor > Textures Tab (Only in Face/Vertex mode)
F3: Texture Editor
F4: Hitzone Editor
F5: Transformation Editor
F6: Hardpoints Editor
F7: Engine Glow Editor

User avatar
Vince T
Fleet Admiral (Administrator)
Posts: 14045
Joined: Fri Apr 27, 2001 11:01 pm
Contact:

Post by Vince T » Mon Sep 18, 2023 6:31 pm

Great work! Really happy with the new Mouse controls. Much more natural and intuitive now!
Your ship, Captain. I need a drink. - Vince Trageton
Vince T's X-Wing HQ - where the bad guys get their gear

User avatar
JeremyaFr
XWAU Member
Posts: 3921
Joined: Mon Jan 18, 2010 5:52 pm
Contact:

Post by JeremyaFr » Tue Oct 03, 2023 3:23 pm

UPDATE

Hello,
I've updated OPTech.

Changes are:
- add support for importing opt with 32 bpp textures

Post Reply