Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] UVs Are Distorted After Exporting New Scenes #84

Open
seancruzart opened this issue Jul 28, 2022 · 1 comment
Open

[BUG] UVs Are Distorted After Exporting New Scenes #84

seancruzart opened this issue Jul 28, 2022 · 1 comment
Labels

Comments

@seancruzart
Copy link

Description

UVs appear to not register or are distorted/re-arranged after export.

Steps to Reproduce

- What were you attempting to do?
Learning NMSDK. Created a new scene with new geometry with a custom diffuse texture and a NMS normal map. Made a reference to this new scene in the procedurally generated plant pots found on space stations and other buildings as a way to easily test the object in-game.

New Model Setup

  1. I first created a new NMS scene. MBINcompiler and PCBANKS locations were properly set. Created the cube, and made a simple material with only the diffuse. Renamed everything to CUBEY.SCENE or CUBEY in the Outliner/tree.
  2. In Blender's shader editor, I created an Image Texture node with the diffuse texture, and renamed the name and label to Texture Image - Diffuse.
  3. I set the reference node to //CUSTOMMODELS\CUBEY\CUBEY.SCENE. Originally, when using the Open File Browser button, it included the entire address going back to my drive. The new object seemed to work and show in-game with the reference having the full address, but I cut it back to //CUSTOMMODELS\CUBEY\CUBEY.SCENE anyways afterwards.

CUBEY SETUP

Setting the Reference In Plant Pots For Testing Setup

  1. Imported PLANTPOTLSYSPROC.SCENE.MBIN, selected its reference node PLANTPOTLSYSPROC.SCENE, then used the context menu to create a new reference node under that node named CUBEY.SCENE.
  2. Using the file browser button I selected the CUBEY.SCENE.MBIN. It initially displayed the full address, but I think after exporting PLANTPOTLSYSPROC.SCENE it corrected it to //CUSTOMMODELS\CUBEY\CUBEY.SCENE.MBIN.
  3. I exported this scene with Preserve Node Info.

Plantpot scene setup

Seeing the Result In-Game

  1. The first time I tested CUBEY out, the diffuse texture was showing, but I was not sure if it was distorted. I decided to place a normal map from the squid ship called SQUIDSCLASS_TRIM.BASE.NORMAL to test the normals. Renamed the new image texture node name and label to Texture Image - Normal. This is the result.

CUBEY SETUP
CUBEY SETUP

As you can see compared to the normals displayed in the blender screenshot, the normals are all stretched/mis-aligned.

  1. I decide to decompile CUBEY.SCENE.MBIN from my pak and import into blender and see if anything changed. The UVs are all out of place, and no material imports.

Imported CUBEY.SCENE from pak with messed up UVs/no material.

CUBEY SETUP

Original UVs in the original blend file.

CUBEY SETUP
CUBEY SETUP

Stack trace
Attaching them just in case but I didn't see any errors pop up.

Files Included are the Blend Files + Stack Traces, Pak Mod

BlendFiles.zip
cruzdroid_CubeyTest.zip

@monkeyman192
Copy link
Owner

I know it's been a while, but I believe this should have been fixed in the latest version.
If you could check and confirm that would be really good so we can close this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants