Jump to content
dovapix

Replacing trees foliage cards

Recommended Posts

Hi there,

 

I am new here and i first want to say thank for all the good info here for us modders since so few place are helping us to understand how to put our vision into the game bryo engine.

 

I am a 15 years 3D and 2D artist and i made a lot of environment assets as a freelancer and i was trying to change the pine trees foliage cards distributed around the trunk and i discover that the change i made in nifskope didn't work at all in game.

For testing i just import the treepineforest01.nif in 3ds max and i deleted all foliage cards except one and then i export the modified version as obj and used an old nifskope version to re import to replace the original nitrishapedata. I check every nodes to make sure they had same entries and when i load the new tree in game it's simply show no modifications i made just like it is completely ignored and show the original tree.

I then tried by exporting as nif with 3ds max 2016 and just copy paste over the new nitrishapedata and same result tree show in game like nothing happen.

So is there a way to modify the trees nif or maybe there is an obscure setting i don't know about in nifskope?

Thank for anyone willing to lay a hand to a fellow modder.

Regards Peter

Share this post


Link to post
Share on other sites

Hi, welcome to AFK Mods. Have a :bigcookie:

First the obvious questions;

- did you place the modified nif file in the correct path? Data/meshes/landscape/trees ?

- are you sure you're looking at treepineforest01 in game?

- are you sure you're up close enough you're not looking at the old LOD model?

Share this post


Link to post
Share on other sites
22 minutes ago, Hana said:

Hi, welcome to AFK Mods. Have a :bigcookie:

First the obvious questions;

- did you place the modified nif file in the correct path? Data/meshes/landscape/trees ?

- are you sure you're looking at treepineforest01 in game?

- are you sure you're up close enough you're not looking at the old LOD model?

Hi Hana,

Thank for the warm welcome and yes the nif was in the right path and names were correct. Prior to testing i made sure with user info in CK where treepineforest01 was located and i even tried the replace option in CK with the same result.

And last yes i was close enough and it was not any lod level.

I saw that no one so far in the whole nexus mods made a working custom trees and the one who modified it lost the main trunk and branches animations and they all reintroduced their new custom trees in a regular static nif with collision without the BsTreeNode.

I think this has to do with vertex number not having the same count since i deleted many foliage cards to test if my nif was working. Even a very light change like moving one vertex yield the same result.

Maybe it is impossible to do since no one made it so far.

Share this post


Link to post
Share on other sites

Hi again,

I just made another test to see if i can import a new mesh with the tree so i just made a box and put it at the base of the tree and then i copy a nitrishape branch and deleted the nitrishapedata (I always put 4097 in UV set and spell update all tangent spaces)and import the box and save the nif.

The only thing that yield an error was updating tangent spaces here the message : "need vertices, normals, texture coordinates and faces to calculate tangents and binormals".

When i saved the nif i also have to deactivate sanitize file or else it wont saved it.

In game as you can guess no box is anywhere to be seen.

I am surprised no one ever really get involved in custom trees.

EDIT: I made a new test by copying a rock01.nif nitrishape branch and pasting it in the tree nif and again nothing show up in game and all flags are OK.

It certainly have something to do with the way nifskope save the nif for trees since it yield a few errors and need to unchecked the  auto sanitize feature to save the file.

 

Share this post


Link to post
Share on other sites

I will feed this thread with what i discover along the way.

 

So i made a little progress so far by simply copying the Skyrim SE treepineforest.nif and copy pasting the rock01 nitrishape branch on the BSTreeNode root and finally it show up in game.

My first test was done with Skyrim legendary edition tree nif instead of SE but since i saved my nif in the most recent version of nifskope that support Skyrim SE i don't see why it was not working but at least i am making slow progress here and i will report back with new test with foliage cards.

Share this post


Link to post
Share on other sites

Ok just made some more test and i hit another wall here since the foliage cards are showing as a BSTrishape/NiSkinInstance/NiSkinData and this is the bones weighting meaning that the tree foliage cards were not rigged the way i thought it was like only being child's of branch parent and vertex weight for animations, instead the whole foliage cards are directly rigged with bones.

So i think my hope of retaining only the trunk and branches for animations is now out of the question and it doesn't seem to be possible to import a fully working custom tree.

I know there a lengthy but very confusing tutorial here : https://www.darkcreations.org/forums/topic/4249-100-custom-tree-pyandonean-islands-tuto02/?page=2    but i read it 3 times and still don't understand the author that was not natively speaking English and overall that was very confusing and since no one made a custom tree fully working with animations.

Share this post


Link to post
Share on other sites

Right, so, hang on, let me look at the mesh...

It's a NiSwitchNode, so that means, there's basically double of everything, one skinned, and one (the one you see of the tree and foliage) is not skinned. They relate to each other. Which NiTriShape were you 'replacing' ? If you do one, you have to do the related one.

Share this post


Link to post
Share on other sites
19 minutes ago, Hana said:

Right, so, hang on, let me look at the mesh...

It's a NiSwitchNode, so that means, there's basically double of everything, one skinned, and one (the one you see of the tree and foliage) is not skinned. They relate to each other. Which NiTriShape were you 'replacing' ? If you do one, you have to do the related one.

Hi Hana,

I was trying to replace the BSTriShape 19 since it has no string name not to be confuse with TreePineForest01_1:1 that is the lod nitrishapedata.

I think the only way is to completely do a new tree from scratch but i am not sure it's possible.

Share this post


Link to post
Share on other sites

That's the problem right there. NiTriShape 19 is the skinned mesh, and you cannot just copy/paste over that with an unskinned mesh. Have you tried replacing NiTriShape 38 instead?

What exactly are you trying to do? I haven't looked at the tutorial you linked above but I know there's tree mesh resources on Nexus, so it is do-able. Perhaps just a retexture can get you what you want?

Share this post


Link to post
Share on other sites
2 hours ago, Hana said:

That's the problem right there. NiTriShape 19 is the skinned mesh, and you cannot just copy/paste over that with an unskinned mesh. Have you tried replacing NiTriShape 38 instead?

What exactly are you trying to do? I haven't looked at the tutorial you linked above but I know there's tree mesh resources on Nexus, so it is do-able. Perhaps just a retexture can get you what you want?

Hi Hana,

I know i cannot simply replace an animated mesh with a non animated mesh but at first i thought the foliage cards were only child of branches with the vertex animation automaton in Skyrim so i was having in mind to simply try replacing the foliage cards.

The trees available on resources are not using the BStreenode structure they are like the aspentree04 only animated via vertex alpha and i already tried and lost so much time on getting a decent re texture but my texture is very good the problem is the way they put these foliage cards in a very unrealistic way and good luck having some decent snowy pines with theses!

Unfortunately i think that i have no other choice then to try this tutorial and see if i can bring my rigged tree with bones in Skyrim since i only have access to 3ds max 2016, 2017 and 2013 and they mention it is working only with 3ds max 2012.

Well i will comment back and if this work i will make a video tutorial about it.

Share this post


Link to post
Share on other sites

Hi guy's,

 

I try very hard and i am not a noob at modding but the custom tree tutorials here : https://www.darkcreations.org/forums/topic/4249-100-custom-tree-pyandonean-islands-tuto02/?page=1  is not working since the BSTreeNode setup is not well explain and i think the author miss a lot of complementary explanations to set the BSTreeNode correctly.

I did my bones rig with skin for my tree in 3ds max and i export it smoothly but i end up with a different NiSkinInstance structure since i have more bones in my rig and the tutorial does not deal with that.

Is there a place where someone explain how to setup a BSTreeNode correctly?

Share this post


Link to post
Share on other sites

OK i finally managed to make it work with a completely new custom tree with custom skeleton and the result is amazing!

I will make a video tutorial showing the process from start to finish and with the new bones rig the trees look amazing since including some top bones in the BStreeNode make the tree sway realistically like in real life.

 

The process is very short and easy to do in Nifskope, once you have your tree and bones rig ready it take about 5 min to setup each trees.

 

So i think after my video tutorial is done we are going to see a lot more trees variety nicely animated.

Share this post


Link to post
Share on other sites
58 minutes ago, Hana said:

Awesome, can't wait. :)

Hi Hana,

Nothing more satisfying than a good fight with Nifskope and winning over it! I sweat for a complete week doing gazillions of test until i found the correct way to setup the bones rig so the bones were exporting correctly and by playing with a few bones i found out i could use a few bones from what would be the upper trunk rig and make them behave as branches to get that nice swaying of tip of trees that was cruelly braking immersion when looking at trees.

That one small victory and later on i am also planning to find a quicker and easier way to import custom rig animations for static in Skyrim.

Share this post


Link to post
Share on other sites

OK just did a few test in Skyrim SE and the rotation axis is wrong instead of swaying the tip of the tree like in Skyrim regular edition it rotate the branch on it local axis so Skyrim SE must have change something regarding animations or bones rig setup.

I will rebuild the whole tree in Nifskope latest edition and see if it fix the problem.

Share this post


Link to post
Share on other sites

Hi guy's,

More good news i fix the Skyrim SE problem that was related to change made by 64 bits on skin partitions also 3ds max 2016 was use with nif plugins from figment 3.8 and Nifskope 2.0 so there is no need to use older versions to make this work.

If i have time i will upload a video of my tree on my channel today.

Share this post


Link to post
Share on other sites

Hi guy's.

Another test with 62 active bones in the BStreeNode show no performance lost at all so the next test i want to make is replacing all  pine trees with the same one i have currently finish to see if performance hold the line.

Share this post


Link to post
Share on other sites
3 hours ago, InsanePlumber said:

And how many trees were in sight? (more or less)

Only a few close to 20 or 30 i would say and i didn't notice any frame drop. The other tutorial mention he was having 33 bones in his own tree without any performance lost.

Also if any performance issues were to show in later test i still have room for optimization on 2 front, one on assigning only 2 bones per vertex instead of 4 and i can reduce the current tree to 938 vertices without losing too much detail.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Support us on Patreon!

×