magneticflux- / fabric-mumblelink-mod

A Fabric mod that connects to the MumbleLink plugin.
GNU Lesser General Public License v3.0
51 stars 13 forks source link

Coordinate system differs from Forge version #80

Closed MrEAZL closed 2 years ago

MrEAZL commented 2 years ago

I was setting this up and playing with my friends, it was working fine and I could hear my friends right in 3D space but when I resetted my mumble settings to default it stopped working, I can't understand why, my friends can't hear me too and I can't hear them too and if I turn minimum volume up I can hear them

magneticflux- commented 2 years ago

Please follow these steps first: https://github.com/magneticflux-/fabric-mumblelink-mod/wiki/Troubleshooting

MrEAZL commented 2 years ago

I already followed them, still doesn't work, I don't know what's wrong and there isn't anything on logs too

magneticflux- commented 2 years ago

Does "Minecraft Mumble Link Mod linked" appear in Mumble chat for you and your friends? Are you using the trivial or non-trivial Mumble server setup?

MrEAZL commented 2 years ago

Mumble does link with Minecraft and I don't know about the server setup, I use GuildBit, it works for my friends that use forge version but it doesn't work for me.

magneticflux- commented 2 years ago

Make sure you are all using the most recent versions of both the Fabric and Forge versions. In particular, ensure that the Forge users are all using a version that includes this change: https://github.com/zsawyer/MumbleLink/pull/41 (versions >= 5.0.0)

MrEAZL commented 2 years ago

The forge version of th mod they downloaded is the latest version and I have the latest version too, I checked github to make sure that nothing changed.

magneticflux- commented 2 years ago

Ensure the "Y-Axis multiplier for dimension IDs" config option in Minecraft is set to 0 and double-check that the Positional Audio checkbox under Audio Output is enabled and the Link plugin is enabled in Mumble.

MrEAZL commented 2 years ago

Double checked everything, still the same. It just works when I turn minimum volume thing up, I can't understand why, I can hear my friend's position changing when he walks around me after turning minimum volume up.

magneticflux- commented 2 years ago

Okay, that narrows it down a little. Are you near the center of the world (0,0)? Does your friend's audio's position line up to where their player is?

MrEAZL commented 2 years ago

Well, I'm not near the center of the world (I actually thought it's the problem, I didn't try to go to the center yet to see if my friend will hear me), and yeah, my friend's audio lines up to where he is.

magneticflux- commented 2 years ago

Have you tried just turning up the main volume in Mumble? And are you relatively close to your friends? The default settings mute people who are too far away (more than ~100 blocks).

It's clear that the position info is being sent and received because your relative orientations are correct. It's also not scaled by some constant in all directions because it worked away from 0,0. Mumble's orientation and distance calculations use the same coordinates, so if one works the other should work as well.

MrEAZL commented 2 years ago

I forgot to mention this, sorry; My voice doesn't go to my friends, they can't hear me. And also I just tried that and still doesn't work.

MrEAZL commented 2 years ago

I will try to reinstall Mumble, I will tell if it works.

magneticflux- commented 2 years ago

Are you microphone and speakers set up properly? Can everyone hear everyone without positional audio connected? Can everyone hear everyone when everyone is using the "Manual placement plugin" in Mumble?

MrEAZL commented 2 years ago

I don't know what's manual placement plugin but everyone can hear me when Minecraft isn't linked.

magneticflux- commented 2 years ago

Okay, that narrows it down a little more.

MrEAZL commented 2 years ago

I tried manual placement plugin too, it still doesn't work.

magneticflux- commented 2 years ago

I think I've figured out the issue. It's a problem with the way the Fabric mod and the Forge mod convert Minecraft coordinates to Mumble coordinates.

Forge: x,z,y https://github.com/zsawyer/MumbleLink/blob/9e2a8db41ed1a49977540f24f343df23cc95d656/mod/src/main/java/zsawyer/mods/mumblelink/mumble/UpdateData.java#L123-L127 Fabric: x,y,-z https://github.com/magneticflux-/fabric-mumblelink-mod/blob/develop/src/main/kotlin/com/skaggsm/mumblelinkmod/client/MathUtils.kt#L12

From Wikipedia:

Interchanging the labels of any two axes reverses the handedness. Reversing the direction of one axis (or of all three axes) also reverses the handedness.

Unfortunately, we chose two different methods of changing handedness of the coordinates. I'll see if we can fix this soon.

MrEAZL commented 2 years ago

Oh god, this worked like months ago, so is that why? Also is there a mumble plugin to reverse this effect or do I need to do it manually?

magneticflux- commented 2 years ago

That's strange that it worked before, because this hasn't changed recently at all. Maybe you were using a different mod back then? I can build a snapshot of this mod with the coordinates changed to see if it works for you.

MrEAZL commented 2 years ago

The time I used this mod was months ago as I said, and sure, I will try the snapshot.

magneticflux- commented 2 years ago

Unzip and try this: fabric-mumblelink-mod-0.8.4-SNAPSHOT.zip

I'll work on a more permanent fix and let you know how to upgrade then.

MrEAZL commented 2 years ago

Thank you so much! It works!

magneticflux- commented 2 years ago

Awesome, thanks for the debugging help!