multitheftauto / mtasa-resources

This project maintains a list of up-to-date resources that come with Multi Theft Auto.
https://multitheftauto.com
MIT License
148 stars 145 forks source link

Rotating an object bug #496

Open NeblaStuff opened 4 weeks ago

NeblaStuff commented 4 weeks ago

Which resource(s) have this problem? Map editor

Describe the bug In map editor; you are not able to rotate any world objects sometimes.

To Reproduce Steps to reproduce the behaviour:

  1. Go to Map editor in Multi Theft Auto
  2. select any object you want to rotate & set object Y rotation to 90 or 270 and then press ok.
  3. Select the object again & Hold press Lctrl + arrow left or right
  4. It simply not rotating the object, stuck & glitching

Expected behavior You should be able to rotate the object in Z rotation when you rotate the object in X,Y rotations without having any bugs. mta-screen_2024-06-09_18-59-33

Version MTA.1.6.0

Additional context many mappers having this issue so some of them trying to hire old mta version servers for mapping because there had no bugs in previous mta versions

Dark-Dragon commented 4 weeks ago

Yes, I can reproduce this issue as described.

Dutchman101 commented 2 weeks ago

Yes, I can reproduce this issue as described. @Dark-Dragon

Do you want to fix it?

Fernando-A-Rocha commented 2 weeks ago

I can reproduce this. Demo video: https://streamable.com/j6xsxp

This object will not rotate when RY is 90 and RX is 0. I assume there are some math calculations being done wrong. I will check the code.

Fernando-A-Rocha commented 2 weeks ago

Presumably the problem is here https://github.com/multitheftauto/mtasa-resources/blob/master/%5Beditor%5D/editor_main/client/rotation.lua#L41