My Animated 3D Weapon Model is Messed Up

Ask about editing graphics, sounds, models, music, etc here!
Shaders (GLSL) and SNDINFO questions also go here!

Moderators: GZDoom Developers, Raze Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
User avatar
SPZ1
Posts: 211
Joined: Wed Aug 02, 2017 3:01 pm
Location: Illinois

My Animated 3D Weapon Model is Messed Up

Post by SPZ1 »

It appears that the draw order is wrong. The cylinder is supposed to be in the center!! How do I fix this??


You do not have the required permissions to view the files attached to this post.
User avatar
Cherno
Posts: 1290
Joined: Tue Dec 06, 2016 11:25 am

Re: My Animated 3D Weapon Model is Messed Up

Post by Cherno »

It looks like your model's normals face the wrong way. Invert/flip them.
User avatar
SPZ1
Posts: 211
Joined: Wed Aug 02, 2017 3:01 pm
Location: Illinois

Re: My Animated 3D Weapon Model is Messed Up

Post by SPZ1 »

I tried flipping them a few times but it didn't do anything!
User avatar
SPZ1
Posts: 211
Joined: Wed Aug 02, 2017 3:01 pm
Location: Illinois

Re: My Animated 3D Weapon Model is Messed Up

Post by SPZ1 »

Sorry for the double post but I have the same problem again. This time it is an .OBJ of what is supposed to be a flower. Also I found that the ROTATING keyword doesn't work on weapon models.

Screenshot_Doom_20210418_112432.jpg
You do not have the required permissions to view the files attached to this post.
User avatar
SPZ1
Posts: 211
Joined: Wed Aug 02, 2017 3:01 pm
Location: Illinois

Re: My Animated 3D Weapon Model is Messed Up

Post by SPZ1 »

One more post about how weapon models are messed up. The weird thing is that they are not transparent when spawned into the map as normal actors.

Ocarina.png
You do not have the required permissions to view the files attached to this post.
User avatar
ramon.dexter
Posts: 1305
Joined: Tue Oct 20, 2015 12:50 pm
Graphics Processor: nVidia with Vulkan support
Location: Kozolupy, Bohemia

Re: My Animated 3D Weapon Model is Messed Up

Post by ramon.dexter »

Yep, I've got exactly the same problem. Model spawned in map is ok, when used as a hud model, it is messed up.
User avatar
ramon.dexter
Posts: 1305
Joined: Tue Oct 20, 2015 12:50 pm
Graphics Processor: nVidia with Vulkan support
Location: Kozolupy, Bohemia

Re: My Animated 3D Weapon Model is Messed Up

Post by ramon.dexter »

Hello, little update. I think I've found a halfway solution for this problem...

I noticed that my last weapon, that I created the same way as the others (the others work well without the bug of this thred) has the bug mentioned here. So, I grabbed it by the balls and spent some time playing with it.
- I don't think this is a bug of the model. After all, the model works 100% correct when placed on ground. The bug only appears when the model is used as a HUD weapon.
- so I started playing with model offsets. Because, the model placed on the ground is much farther from camera than the HUD weapon, maybe the bug is related to actual distance between the viewport (camera, etc.) and the model itself. So I checked my working model's offsets and found out that most of the models have Z offset like -10, while the new weapon has Z offset -3. So, I changed it to -4 ... and the problem is GONE!

So, if you want to solve this, try playing with models offsets in MODELDEF. I think this 'bug' is related to the renderer or camera. Not sure if I should report it.
User avatar
SPZ1
Posts: 211
Joined: Wed Aug 02, 2017 3:01 pm
Location: Illinois

Re: My Animated 3D Weapon Model is Messed Up

Post by SPZ1 »

This is quite a bump...

I figured it out by simply playing with the offset in MODELDEF...
ocarirna fix.png
You do not have the required permissions to view the files attached to this post.
User avatar
ramon.dexter
Posts: 1305
Joined: Tue Oct 20, 2015 12:50 pm
Graphics Processor: nVidia with Vulkan support
Location: Kozolupy, Bohemia

Re: My Animated 3D Weapon Model is Messed Up

Post by ramon.dexter »

Sometimes I have a feeling that I'm ignored...

Return to “Assets (and other stuff)”