Flat Sprite rotation fix

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is OFF
Smilies are ON

Topic review
   

Expand view Topic review: Flat Sprite rotation fix

Re: Flat Sprite rotation fix

by Major Cooke » Sun Aug 30, 2020 10:05 am

On second thought, I'm closing this. This would break VisibleAngles/Pitch with it, which some mods rely upon to hide the backside. Adding a compatibility option with it would only increase the code bloat in it as well, and cache misses.

Those that want to use the actual proper rotation can use a flat model.

Re: Flat Sprite rotation fix

by Graf Zahl » Sun Aug 30, 2020 10:04 am

I wish this feature could be shitcanned entirely.
One thing I definitely have on the table is to deprecate the entire flat/wallsprite functionality that's currently there and make these things useful by restricting them to what *walls* and *flats* actually are.

That said, this can only go in with a compatibility option.

Flat Sprite rotation fix

by Major Cooke » Sun Aug 30, 2020 9:49 am

Pull Request (Currently marked as draft)

I was made aware some time ago that flat sprites did not have the same rotation code as models, which is supposedly the appropriate manner of doing so. This PR will bring it in line with the model rotation code and behave just like it. However, any mods reliant on the old behavior will inevitably be forced to update their code as it's no longer representing the current means of rotation.

As such I'm expecting to get flak for this. Probably a lot. :shock:

Attached is a demonstration file. Use "give z" in console and two sprites will spawn, featuring a sprite on a flat model plane (left) and a flat sprite (right).

The current implementation means users can avoid using quaternions or whatever else is there to keep the angle and pitch consistent, but the PR will ensure consistency so those who use models don't need a separate condition.

Personally, I'm torn directly down the middle if I want this or not, so I've marked the PR as draft so we can have a calm and civil discussion about it.
Attachments
flatsprmodel.pk3
"give z" in console. Red is angle, green is pitch, blue is roll.
(1.22 KiB) Downloaded 48 times

Top