Java Exporter still broken in 2.9?

Get help and support for using Cubik Studio.
Post Reply

Java Exporter still broken in 2.9?

Post by Tango Tek » 26 Feb 2018, 09:01

I just got 2.9 and created a simple model to try out the java exporter.

Things still seem off a bit.

I've attached a screenshot of my crude model in Cubik and a shot of how it is rendering in game.

This is the generated java Model code.

Code: Select all

        textureWidth = 64;
        textureHeight = 64;

        e1_Head = new ModelRenderer(this, 0, 6);
        e1_Head.setRotationPoint(-16F, 77F, -14F);
        e1_Head.addBox(5.5F, -32.5F, 5.5F, 5, 6, 3);
        e1_Head.setTextureSize(64, 64);
        e1_Head.mirror = false;
        setRotation(e1_Head, 0F, 0F, 0F);
        e2_Rightleg = new ModelRenderer(this, 44, 17);
        e2_Rightleg.setRotationPoint(-7F, 24F, -9F);
        e2_Rightleg.addBox(0F, -13F, 0F, 2, 13, 2);
        e2_Rightleg.setTextureSize(64, 64);
        e2_Rightleg.mirror = false;
        setRotation(e2_Rightleg, 0F, 0F, 0F);
        e3_Leftleg = new ModelRenderer(this, 52, 17);
        e3_Leftleg.setRotationPoint(-11F, 24F, -9F);
        e3_Leftleg.addBox(0F, -13F, 0F, 2, 13, 2);
        e3_Leftleg.setTextureSize(64, 64);
        e3_Leftleg.mirror = false;
        setRotation(e3_Leftleg, 0F, 0F, 0F);
        e4_Torso = new ModelRenderer(this, 0, 15);
        e4_Torso.setRotationPoint(-16F, 51F, -14F);
        e4_Torso.addBox(5F, -26.5F, 5F, 6, 13, 4);
        e4_Torso.setTextureSize(64, 64);
        e4_Torso.mirror = false;
        setRotation(e4_Torso, 0F, 0F, 0F);
        e5_Rightarm = new ModelRenderer(this, 20, 19);
        e5_Rightarm.setRotationPoint(-5F, 46.5F, -16.5F);
        e5_Rightarm.addBox(0F, -2.5F, 0F, 2, 3, 10);
        e5_Rightarm.setTextureSize(64, 64);
        e5_Rightarm.mirror = false;
        setRotation(e5_Rightarm, 0F, 0F, 0F);
        e6_Leftarm = new ModelRenderer(this, 20, 6);
        e6_Leftarm.setRotationPoint(-13F, 46.5F, -16.5F);
        e6_Leftarm.addBox(0F, -2.5F, 0F, 2, 3, 10);
        e6_Leftarm.setTextureSize(64, 64);
        e6_Leftarm.mirror = false;
        setRotation(e6_Leftarm, 0F, 0F, 0F);

Everything seems upside down, offset and stretched in the Z still.
For instance, I'm not sure where the 77F Z coordinate rotation point is coming from for the Head. That value isn't anywhere in Cubik for its offset or position.

The Java exporter was the entire reason I bought this tool. I really need to get it working.
Am I doing something wrong in Cubik?
Humbly looking for some help.
2018-02-26_01.43.51.png
2018-02-26_01.43.51.png
Attachments
cubik_shot2.png
x
User avatar
Tango Tek
Supporter
Posts: 3
Joined: 23 Jan 2018, 20:01

Re: Java Exporter still broken in 2.9?

Post by Sphax » 27 Feb 2018, 23:38

I'll have a look... I compared the output of Cubik with the output of Tabula and everything looked exactly the same (for the same test models).
Is Tabula producing right JAVA class for you?
x
For support, use forum (not DM or PM or email) and create your own topic :3d:
User avatar
Sphax
Admin
Posts: 1315
Joined: 10 Nov 2011, 10:44

Re: Java Exporter still broken in 2.9?

Post by JTK222 » 28 Feb 2018, 15:35

Issue #1 (quote from the java models suggestion thread):
You can fix it by substracting the model position from the rotationPosition for each element.
Issue #2: Entity Models are for some reason upside down D:
But this can be fixed either in code: GL11.glRotatef(1f,0f,0f, 180F);
Or trough exporting the models upside down so they are correct when rendered ingame.
x
User avatar
JTK222
Supporter
Posts: 53
Joined: 02 Nov 2016, 08:35

Post Reply

Return to “Help Centre”