Sid Meier's Railroads Fan Site with the latest and largest Growing Mods database.    

  • PortalPreviousForumsPreviousRailroads ForumsPreviousBuilding BlocksPreviousTrain Cars Are Us!

    More Train Car Woes - this never gets easier

    TrainCars Building Blocks

    Forum rules

    This Sub-Forum is for TrainCars Are Us!
    only.
    Please Discuss them In the Post named TrainCars Are Us! Write About them here..
    slider38User avatar
    Mod Maker
     
    Posts: 1571
    Joined: Thu Oct 01, 2009 7:11 am

    Post Posted » Wed Jul 17, 2013 7:17 am

    Hi Guys, I am trying to create a whiskey car - a goods car with the boxes replaced by barrels, like this -
    Whiskey_car_v2.jpg


    I have gone into blender and taking a barrel from the winery, replaced the boxes in the version 2 goods car. I have assigned the barrels to the various vertex groups that the boxes were assigned to. I have taken the strange file that blender or niftools exports and added the Nistringextradata and Nimultitargettransform lines under the MD line. When I test it in nifskope the barrels will jump around when the kfs are run, but when you reach the empty car kfs, the barrels remain. When I ran it on my test map, all I get are carloads of barrels riding back and forth - no load or unload. I have tried evrything I can think of but I don't know why I am getting this result. If someone has the time to take a look at this I would appreciate it. I am just out of ideas to try.

    The attached file has the current iteration - test11 (though there have been several more). I have included in the attachment the goods kf files, the various sections of the xml files, the icons for the goods and the whiskeycarview files. I have also included a whiskey_car_test11_v1.kfm, but that is nothing but a goods car. I started with version 2 for this because the nif seemed a little simpler layout in the v2 file vs the v1. I have also included the goods_car_v2 nif and kfm files just for easy comparison.

    Thanks very much for any help you can give me. I am just stuck on this.

    Repaired
    You do not have the required permissions to view the files attached to this post.
    snoopy55User avatar
    Site Admin
     
    Posts: 4272
    Joined: Thu Aug 14, 2008 1:47 am
    Location: Centralia, ill - 2787

    Post Posted » Wed Jul 17, 2013 11:02 am

    Let me try to remember what all I changed.

    Line 54 - Flags - 16 changed to 30
    - your NiTexturingProperty was referring to the Boxes line. It should have referred to the Cars.
    - your NiAlphaProperty was referring to the Cars. Boxes should have had its own (see below) The Alphaing was being based on commands to the Car, not the Boxes
    - your orig_orig_10 - Defaul should have been left boxes (see below)

    Line 61 was NiTexturingProperty. It should have been a NiAlphaProperty. I copied the one from the original and pasted it over. NiAlphaProperty is what makes thing disappear.

    Line 62. This should have been left as boxes. While it may work to rename these lines, it is always best to leave them as they are originally. This game has a very nasty attitude toward changes.

    Line 63 You removed this line for some reason. This is the line that the KFs refer to when removing things from the game, such as car loads.

    Now, I cannot really tell you if the only problem was Line 63. The rest may have been just fine as they were. But unneeded changing of things can lead to problems. The only things I suggest people change is the 4 DDS names and the contents of the NiTriShapeData. And the position settings of the NiTriShape. If anyone can tell us what else can be changed, guaranteeing the info will work in all KFM, NIF and KFs, by all means, post it.

    Something you might want to think about with this car, darken the barrels you have on it, add a plate on top of them, and then add a second layer of barrels using the colors you now have. Hey, the more the merrier!

    You also need to rename the other three DDSs for the barrels. Yours uses the Winery, I just edited the Goods Car.

    You can rename the attached NIF to whatever you want.
    I NEVER MAKE MISTEAKS
    slider38User avatar
    Mod Maker
     
    Posts: 1571
    Joined: Thu Oct 01, 2009 7:11 am

    Post Posted » Wed Jul 17, 2013 11:28 pm

    Thanks for the feedback Snoopy. I'm going to study this and hopefully learn something. I didn't add anymore barrels to the car because I didn't want to make it too big i.e. vertices. A barrel contains a whole lot more than a box. I will have to go back and do some comparisons between what you posted and what I posted but I don't think I really changed that much. What comes out in the export from Blender creates some strange results. When I add the missing sections under MD they come out at the very bottom of the Nif. I have been moving them up to line 4 and 5. Perhaps the moving of those lines is creating other issues. I don't know if they really need to be moved or not in order to work properly. That orig_orig_10 was something that popped up in blender. I'm not sure where it came from - perhaps the winery.

    I didn't do anything with the dds files other than getting the barrel moved to the goods car v2 diff. I intend to go back in and re-paint, but until I could get the car to work properly, I didn't see a reason to spend time on that. I will probably raise the sides of the car as well. I have printed this material off and will spend some time studying this. I tried to use the dsc car as a guide since it is based on the version 2 goods car, but just couldn't quite get the darn thing to work. I really appreciate the assist. Take care and happy railroading. :up
    snoopy55User avatar
    Site Admin
     
    Posts: 4272
    Joined: Thu Aug 14, 2008 1:47 am
    Location: Centralia, ill - 2787

    Post Posted » Thu Jul 18, 2013 1:16 am

    slider38 wrote:When I add the missing sections under MD they come out at the very bottom of the Nif. I have been moving them up to line 4 and 5.


    Couple of quick things here. When adding Parts, they should be attached to MD NonAccum, not MD. But that is parts only. On a car it would be something added to the structure of the car itself, not the load. When you are playing with a load, you want to add it to the line, which in the case of your car, is called CAR_Layer. Things like opening lids and doors are something else. I'd have to research those.

    In any editing of any part of a NIF, keep the line connections the same way they are, in the same tree structure. If you do something in Blender, take it from the model you worked it out on as a Nif Block and attach it in the same place the original part was attached.
    I NEVER MAKE MISTEAKS
    slider38User avatar
    Mod Maker
     
    Posts: 1571
    Joined: Thu Oct 01, 2009 7:11 am

    Post Posted » Thu Jul 18, 2013 11:21 am

    Snoopy, this has been an interesting test. I tested the version of the car that you sent me and it works perfectly. Thanks.

    But I have a few questions ... and some information. First the questions:
    1.
    your NiTexturingProperty was referring to the Boxes line. It should have referred to the Cars.
    I don't understand this statement. We both had a NiTexturingProperty under the NiTriShape "Boxes". What makes yours refer the the Cars?

    2.
    your NiAlphaProperty was referring to the Cars. Boxes should have had its own (see below) The Alphaing was being based on commands to the Car, not the Boxes
    Same question. What makes yours and mine any different if they are both under the NiTriShape "Boxes"?

    The information: The part of your post about removing lines had me scratching my head because I didn't remove anything. I tried an experiment. I opened Blender and did 2 things - I imported the goods_car_v2.nif and I exported the goods_car_v2.nif. No keys were touched, nothing up my sleeve, etc. This was the result:

    BX_goods_car_nif.jpg


    First Blender removes the NiStringExtraData line (line 4) and the NiMultiTargetTransformController line (line 5).

    Within the "Boxes" NiTriShape it changed the flag from 30 to 16 and it changed the NiMaterialProperty from Boxes to Wheel. The NiAlphaProperty and the NiMaterialProperty were both moved down below the NiTexturingProperty. The NiAlphaController and the NiSkinPartition were removed.

    I have no doubt that this stuff causes all kinds of havoc with the nif file. I am wondering if I am using the correct version of Blender and Python. I am currently using Blender version 2.49b and Python version 2.6.2. If there are better versions to use, please let me know. Meanwhile I have a better understanding of what to look for after exporting nifs from Blender. It's unfortunate that it leaves you with so many things to fix. I don't know what else it may be doing to other sections of the nif file. The fact that it re-orders the file is also a pain.
    You do not have the required permissions to view the files attached to this post.
    snoopy55User avatar
    Site Admin
     
    Posts: 4272
    Joined: Thu Aug 14, 2008 1:47 am
    Location: Centralia, ill - 2787

    Post Posted » Thu Jul 18, 2013 9:00 pm

    slider38 wrote:I don't understand this statement. We both had a NiTexturingProperty under the NiTriShape "Boxes". What makes yours refer the the Cars?


    Basics. When you have a NIF open you need 4 windows open. The main one is the picture. Click on View at the top and click on Block List, Block Details and KFM. Arrange them how you choose on the screen.

    To the car, goods_car_v2.nif. Hilite line 62 - NiTriShape - Boxes. In Block Details you will find where the Nif (Nif, game, wizard..how ever you want to put it) gets it's data to do it's thing. Two lines have a + box. Click on both and you will see which lines it gets the data it needs. Under Properties you will see the third as 50 [NiTexturingProperty]. now, go up to liner 50 and hilite it. Click on the + box Base Texture and it will refer to line 51. This line is where it goes to get the file name to skin the Boxes, or Barrels in your case. Click on the last line there, Shader Textures, and by opening boxes you will see where it gets a lot of the other info from. Now, yours had this same line referred to, but that line, NiTexturingProperty, was replacing the NiAlphaProperty that should have been there. Thus, the Barrels did not disappear.

    As to the second I can only say the KFs control the animation. The animation is what makes the load come and go. The Alpha is what does it. The only difference I see in the Car and Boxes NiAlphaProperty is the Threshold line. The Car has 150 bytes and the Boxes has 0 bytes. I have no idea what this means, but it works when set up that way with the Goods Car. It allows your Car to work when set up that way.

    The important thing you were missing was line 71, NiAlphaController, which, as the name implies, controls the working of the Alpha, which makes the loads come and go.

    Blender is most likely easy to use. It was when Barney instructed me on it. Remembering it all with how little I have used it makes it hard. It most likely would come back to me as I get into it, but there are to many other things in this game to work in, I leave Blender and 3D Max to the rest of you.

    As to how to use things from Blender, myself I would work it up, export it, and then just use a single line from it, NiTriShapeData. I do believe there is a line in the Exporting where you tell it you are working with Sid Meier's Railroads. Yes, I'm correct on that. I did a tutorial on it while I was into it: viewtopic.php?p=6731#p6731 Read it and be sure you have the settings correct.

    And this does not leave me with so many things to fix. It is a question. It needs an answer. I learn, you learn, and anyone else who reads it can learn. We need more questions asked and fewer sessions that end up in hands thrown up in the air. And a few more people to write up tutorials on how to do things. Of course, we need people to read them also........

    Just for the heck of it I copied your barrels NiTriShapeData and pasted it over the Goods Car loads matching line. I got a single barrel, on it's side, off the car, with the lid and bottom next to it. There has to be a way to get the full barrel load in Blender exported so the same thing can be done and it will come out in the correct layout. Barney, NSrailfan or wingsofphoenix amy be able to assist you there.

    OK, 5 in the morning, and I know there is a bed in this house screaming that it misses me........... And don't be afraid to question what I write, any of you.

    PS. I did the basics above because I've been assuming that everyone has things set up and uses them the same way I do. That don't always work. It is not suggesting you don't know how to use NifSkope.
    I NEVER MAKE MISTEAKS
    slider38User avatar
    Mod Maker
     
    Posts: 1571
    Joined: Thu Oct 01, 2009 7:11 am

    Post Posted » Sat Jul 20, 2013 1:42 am

    Thanks Snoopy. I will print this off and study it. In my various attempts to get this to work I also got the barrel on it's side. I never did figure out why that did not come out correctly. Thanks again for all the help.
    BarneyUser avatar
    Member
     
    Posts: 189
    Joined: Wed Oct 15, 2008 11:49 am

    Post Posted » Sun Jul 21, 2013 4:22 am

    This is the point where it is important to refer to the original model in determining a method. As previously stated while the stock models may look the same in game, that does not mean they are built or animated the same. One case I can think of is the Log car or the wool car and the steel car. While the steel car simply alphas out the Steel Load, the Log and the wool car also alpha out the load, but also move the load from the rail car and attempt to hide the load below grade. The problem with this, is in hills or mountains, the load would still show if not alphaed out.

    The Ideal thing would be to create all of that style car as the steel car where the load just alphas out in place. This idea also includes converting the stock rail cars that like the Wool Car, log car etc..., as I believe the the style used by the steel car is of lower weight in game since the added animation could be removed. As well the standardization would make it easier to build and understand tutorials instead of having to build or create another tutorial so that someone could mod the wool car or the log car, etc.

    Sorry Slider as what you have ran into is the result of NIF Tools contaminating our profile. in older versions, the data used to get copied back so long as the node that it was attached to remained unaltered. Now, the script purposely cuts the data on export as it conflicts with other games like Civ 5, and NIF Tools could not be bothered to do the job correctly as to them, SMR is of no importance and not worth their time.
    slider38User avatar
    Mod Maker
     
    Posts: 1571
    Joined: Thu Oct 01, 2009 7:11 am

    Post Posted » Sun Jul 21, 2013 10:54 am

    Thanks for the info Barney. I never knew if the deletions were coming from Blender, Python or NifTools. Always glad to learn something new. Well, almost always :<)

    Return to Train Cars Are Us!

    Information

    Who is online

    Users browsing this forum: No registered users and 1 guest

    comment-drinking
    comment-drinking
    comment-drinking
    comment-drinking