Malus Containment - 10/10/2015 - Not-so-brutal workarounds
Page 1 of 1
Malus Containment - 10/10/2015 - Not-so-brutal workarounds
If you don't already know, Malus has been on hold thanks to a pretty nasty bug in Unity. For a simple explanation, whenever a GameObject is scaled negatively, it's rotations completely break.
What's a GameObject used for? Well, in older versions of Witness Protection, an empty GameObject was used to dictate where bullets come from when fired from your weapon. In Malus, that system is exactly what we use.
This worked in Witness Protection because it was a 3D game, and all we had to do to re-position models was to do a bit of rotation.
Malus, on the other hand, is a 2D game, which means that things aren't as likely to change direction via rotation. To flip Clyde around, we relied on scaling his model negatively. This makes it so he's literally "flipped" the other way.
Sadly, thanks to that Unity bug, stuff breaks when we scale it negatively.
I've placed a cube object at the front of Clyde's pistol for an example.
Works fine here, unflipped...
...but when Clyde is scaled negatively, the cube's collider doesn't rotate properly.
One day, my girlfriend (Cannibun on the forums) gave me an idea: I could make a seperate model and seperate animations for whenever Clyde would be flipped. I initially thought this wouldn't work, as the only method I knew to mirror models could only mirror geometry and not the skeleton or animations. This meant I would have to precisely and painstakingly re-create every animation for use on the flipped model. As such, we decided to take it the easy way and just waited for Unity to fix the bug.
Obviously, the bug wasn't (and still hasn't been) fixed. I grew impatient, so I decided to try and revisit Cannibun's idea.
The modelling software I use is called Milkshape3D. I got it a long time ago. It's more fit for Quake 3 or Half-Life, but most somewhat-modern formats aren't an issue with it.
At first, I tried flipping the geometry, then rotating the skeleton, which broke the animations pretty badly...
A bit later, I noticed an option in the "Tools" menu of Milkshape3D:
I then tried using the tool, thinking "No, there's no way it's this easy..."
And to my surprise, it worked!!
But I had a feeling it wouldn't work as well with mirroring anima-
...it really DOES work wonders!
So, in a nutshell, Malus should be back on track as soon as Stryke puts aside whatevermad science experiment DEAD PROJECT he's currently working on.
We'd also like to raise awareness to the bug, as it apparently hasn't seen a fix in 2 years, maybe even longer.
-Landy
What's a GameObject used for? Well, in older versions of Witness Protection, an empty GameObject was used to dictate where bullets come from when fired from your weapon. In Malus, that system is exactly what we use.
This worked in Witness Protection because it was a 3D game, and all we had to do to re-position models was to do a bit of rotation.
Malus, on the other hand, is a 2D game, which means that things aren't as likely to change direction via rotation. To flip Clyde around, we relied on scaling his model negatively. This makes it so he's literally "flipped" the other way.
Sadly, thanks to that Unity bug, stuff breaks when we scale it negatively.
I've placed a cube object at the front of Clyde's pistol for an example.
Works fine here, unflipped...
...but when Clyde is scaled negatively, the cube's collider doesn't rotate properly.
One day, my girlfriend (Cannibun on the forums) gave me an idea: I could make a seperate model and seperate animations for whenever Clyde would be flipped. I initially thought this wouldn't work, as the only method I knew to mirror models could only mirror geometry and not the skeleton or animations. This meant I would have to precisely and painstakingly re-create every animation for use on the flipped model. As such, we decided to take it the easy way and just waited for Unity to fix the bug.
Obviously, the bug wasn't (and still hasn't been) fixed. I grew impatient, so I decided to try and revisit Cannibun's idea.
The modelling software I use is called Milkshape3D. I got it a long time ago. It's more fit for Quake 3 or Half-Life, but most somewhat-modern formats aren't an issue with it.
At first, I tried flipping the geometry, then rotating the skeleton, which broke the animations pretty badly...
A bit later, I noticed an option in the "Tools" menu of Milkshape3D:
I then tried using the tool, thinking "No, there's no way it's this easy..."
And to my surprise, it worked!!
But I had a feeling it wouldn't work as well with mirroring anima-
...it really DOES work wonders!
So, in a nutshell, Malus should be back on track as soon as Stryke puts aside whatever
We'd also like to raise awareness to the bug, as it apparently hasn't seen a fix in 2 years, maybe even longer.
-Landy
Landy- Developer
- Posts : 46
Points : 3649
Join date : 2015-04-21
Location : Probably behind you
Similar topics
» Malus Containment OST remake on Bandcamp
» Malus Containment - 1/5/2016 - New player model
» Witness Protection - 10/2/2015 - Character model/animations, and more
» Malus Containment - 1/5/2016 - New player model
» Witness Protection - 10/2/2015 - Character model/animations, and more
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum