Weapon Models "select/deselect" rotation no good..

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

Moderator: GZDoom 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.

Weapon Models "select/deselect" rotation no good..

Postby Viper » Wed Nov 27, 2019 12:13 am

I'm doing 3d weapons finally, but this rotation of the model downwards during deselect and upward during select is no good, I have an arm attached to the weapon and so it can't be rotated. I really don't see how this is to be used, unless there's no arms or hands?

Using TNT1 A 1 A_Lower/etc, it can be hidden until ready but I'd like them to be raised and lowered like sprites are (without rotation).

Would love to hear there's some flag I can set..
Viper
 
Joined: 08 Oct 2019

Re: Weapon Models "select/deselect" rotation no good..

Postby Nash » Wed Nov 27, 2019 1:03 am

Yes, seems for some reason, the model drawer is coded such that the PSprite's X and Y offset becomes ROTATION when drawn as a model, and not actually X/Y translation.

Would love to know why this was done... some legacy reason... ?
User avatar
Nash
 
 
 
Joined: 27 Oct 2003
Location: Kuala Lumpur, Malaysia
Github ID: nashmuhandes

Re: Weapon Models "select/deselect" rotation no good..

Postby Viper » Thu Nov 28, 2019 6:47 am

Thanks for the reply, weapon bobbing is also using rotation instead of translation...
Viper
 
Joined: 08 Oct 2019

Re: Weapon Models "select/deselect" rotation no good..

Postby Viper » Wed Dec 04, 2019 4:10 am

The bobbing is some what tolerable but,

https://zdoom.org/wiki/Offset

This is also affected.. (does not offset the position, only the rotation)

--

This should be in the bugs thread I suppose..


I had a look in the source for gzDoom, I found some references to bobbing but nothing about rotation..
Viper
 
Joined: 08 Oct 2019

Re: Weapon Models "select/deselect" rotation no good..

Postby Cherno » Wed Dec 04, 2019 9:03 am

Look into usage of the A_Lower and A_Raise functions, and animate the lowering and raising manually.
User avatar
Cherno
 
Joined: 06 Dec 2016


Return to Assets (and other stuff)

Who is online

Users browsing this forum: No registered users and 1 guest