amorgun / blender_dow

Blender addon for import and export of Dawn of War models
GNU General Public License v3.0
15 stars 1 forks source link

Blender after export, unbinds the mesh from the new bones in the model! #10

Closed mrStafflink closed 1 day ago

mrStafflink commented 4 days ago

Hello! When creating a new bone or a copy of it, and then fixing it on the mesh, it all works in blender and you can safely customize animations, but after exporting the created bone is detached from the mesh and does not move the mesh..... if you import the same model, the bones are there, but the mesh is not attached...

The first photo, before exporting. Скриншот 27-11-2024 015254

Second photo, after exporting and opening again this model in blender. Скриншот 27-11-2024 015404

I attached the mesh and bone with ctr+p then selected “Bone”. And everything worked and I was able to make animations of firing, while rotating horizontally machine gun tank.

amorgun commented 4 days ago

I attached the mesh and bone with ctr+p then selected “Bone”. And everything worked and I was able to make animations of firing, while rotating horizontally machine gun tank.

While it'd probably worked in blender the correct way the addon expects is to parent the mesh to the armature and weight-paint it to the new bone. For your case simply adding all of the mesh vertices to the new bone vertex group should work fine.

mrStafflink commented 4 days ago

It's just that the mesh is attached to several bones, (2 pieces of them) and I just shift+P created a copy of it, and then attached it with ctr + P selected the bone and the desired mesh and everything worked..... all 2 original and new bones interacted with the mash gun, and everything worked smoothly, as soon as I made an export, it broke everything in blender and in OE.....

mrStafflink commented 4 days ago

Can this be fixed??? Or am I doing something wrong, sorry for my English as it is not my native language and I am writing with the help of a translator(

amorgun commented 4 days ago

There are different ways for rigging and the addon currently doesn't support what you are trying to do. Here is the relevant video: https://youtu.be/DDeB4tDVCGY?si=TaPKgguCOBUSJdTV Right now the addon supports the first way with bone weight and you are trying to use the second one. I'll see how to implement it as well but for now I recommend using the intended way.

mrStafflink commented 4 days ago

Ok, thanks for the tip, I'll try to study the video!

mrStafflink commented 4 days ago

Yes, it worked, I highlighted and made atomatomat scales, and already in the meshes, I removed the extra bones that joined the meshes and left me 3 necessary bones, all works, in oe checked! Now the tank will shoot and do the recoil of machine guns, in the future, I probably will realize the machine gun, vertical aiming!

amorgun commented 4 days ago

Окей, думаю можно перестать страдать с переводчиком. Я сделал новый релиз, теперь там можно привязывать меш к кости, как ты изначально пытался: https://github.com/amorgun/blender_dow/releases/tag/v0.14alpha10 Вообще странно, что в варианте с арматурой понадобилась привязка к трем костям, хотя изначально вроде бы работала привязка к одной кости.

mrStafflink commented 4 days ago

No does not help, yes exports for some reason weights break, namely from red blender makes green weights....

The first photo is before export. Скриншот 27-11-2024 202201

Second photo after exporting.... Скриншот 27-11-2024 202113

mrStafflink commented 4 days ago

Becomes pale green, and all vertex groups in this mesh model....

amorgun commented 4 days ago

Расскажи, что ты пытаешься сделать. Пока выглядит очень странно, у болтера нужна только одна кость, непонятно зачем ещё две надо.

mrStafflink commented 4 days ago

I figured it out, to attach 3 bones you just need to make an accordion, like the first bone is attached to the second, the second bone is attached to the third, the third bone to the base of the main bone in the model..... I want to make a machine gun synchronization animation that the bones do not interfere with each other. You can look at the turret of the space troopers, there are a lot of bones, and animations work together. In one meshes (and colored in red weight) used 2-3 bones, and they do not interfere with each other, in the animation.

mrStafflink commented 4 days ago

Скриншот 27-11-2024 212957 here are 3 bones in one mesh, and they're connected by an accordion.

mrStafflink commented 4 days ago

And then all 3 bones work, the only thing left to do is to set everything up correctly in the animation so that there are no conflicts in the bones.

mrStafflink commented 4 days ago

Yes! It works, on-board machine guns, not only shoot but also have a recoil and also when turning, machine guns smoothly turn and there are no conflicts between the markers!

amorgun commented 1 day ago

It looks like this problem is solved so I'm closing this issue.