Jump to content

Trainz/AM&C/Removing Unwanted Assets

From Wikibooks, open books for an open world
logo
Trainz Asset Maintenance and Creation
TOC | BeginningsFun | AM&C | Creation | InBook Refs ORP Refs:  • Index • Containers • Kinds • Tags | Appendixes  • Vers
 Glossary
 HKeys-CM
 HKeys-DVR
 HKeys-SUR
 HKeys-WIN
 Mouse use
 Notations

Introduction

[edit | edit source]

Beginner Steps in Trainz

[edit | edit source]

For those new to Trainz, a typical starting point involves selecting an existing route and beginning to modify it. This method is not only highly recommended but also utilized in our tutorials. It serves as an effective way for beginners to learn about terrain matching, coloring, and modifying routes. Often, new users start by choosing a route with an appealing name, only to find it underwhelming yet full of potential. This process is vital for gaining experience and understanding the nuances of route modification.

Route Upgrading and Exploration

[edit | edit source]

A key phase in the Trainz journey is upgrading older, less interactive routes into dynamic, engaging environments. This involves adding functional passenger stations, industries that interact with products, and creating portals. Such enhancements are crucial for understanding the capabilities of your Trainz installation and serve as an introduction to exploring the Content Manager (CM) and the Download Station (DLS). The goal is often to transform older routes from mere visual attractions into fully interactive and enjoyable experiences. This section aims to guide users through this process intelligently, avoiding common pitfalls.

Thinking Like a Programmer in Trainz

[edit | edit source]

It's important in Trainz to adopt a mindset similar to that of a programmer: be cautious and always plan for the possibility of reverting changes. Before implementing major additions or radical changes, it is advisable to save the route. Cloning the route for significant modifications is considered a best practice, enabling users to experiment while preserving the original state of their work. This approach helps in advancing with new insights and avoids repeating past mistakes.

How to Manage Unwanted Assets

[edit | edit source]

When you're new to Trainz and start modifying routes, you might end up with too many assets from the Download Station (DLS). You may not need all these extra items at first. But as you get more experience, you'll learn which ones are useful for your projects. Here, we'll talk about ways to handle these extra assets without having to delete them.

Often, when you download a route from the DLS, it comes with many other assets. These are called dependencies. At first, this might seem overwhelming, but these routes can actually have some really good stuff in them. Sometimes, you might not want to use certain assets, like catenary wiring or trolley-style rail lines. Here's what you can do instead of deleting them:

1. Disable Unused Assets: In the Content Manager (CM), you can choose assets you don't want and disable them. This means they won't show up in Surveyor anymore. To do this, select the asset and use the right mouse button. You can manage many assets at once or select them one by one. If you're managing a lot of assets, it's easier to work with a few at a time. You can use keyboard shortcuts like CTRL and SHIFT with your mouse to make selecting easier.

2. Archive Assets: Another option is to archive assets. This is like putting them in storage. You do this the same way as disabling, but instead, you're moving them to a special folder. They won't appear in Surveyor, but they're still there if you need them later. When you archive assets, remember where you put them. You can't move the folder later, but the assets are still usable for driving sessions or other routes.

3. Uncluttering Surveyor: Both disabling and archiving help make Surveyor less crowded. This lets you focus on the assets that are really useful for your current project. These methods don't hide the assets in the Content Manager, so you can still find them if you need to. In the Content Manager, you can set up filters to show or hide certain assets. This way, you have control over what you see.

With large hard drives being common now, you might not need to delete assets often. But if you decide to delete, especially if you want to improve a route you're not happy with, this page has tips to help you do that. Remember, managing assets well can make your Trainz experience more enjoyable and less cluttered.

Backing up, in case

[edit | edit source]

As a safety precaution, you may wish to backup assets that you have created and/or downloaded before removing any of them. Do as you will with routes, but good scenery assets, trackside signals and boxes, and different track and bridge types make the rounds to many a route, so you may need such assets again for some other route.

  1. The obvious method for that is to export them to CDP, so you need to scheme out a naming and tracking system for yourself, if nothing else, cut and paste kuids into a text file listing the cdp contents using the same name and folder.
    1. TIMESAVER — Capture that 'name' before saving the first file (recommend the text file first— when you save as, Tab ↹ to the extension selection line, then ⇧ Shift+Tab ↹ to back-TAB to the Save As title line, this will then be fully highlighted, CTRL+C to copy the name for the cdp file operation.)
    2. If CDPing a single asset, one 'Good Practice is to systematically append the KUID as part of the title in a standard never-varying method (to aid searching). RECOMMEND format syntax (kuid2_nnnnn_mmmmmm_#). That's a valid format for base initial KUID codes expressed in Windows compatible file notations— and it allows you to search for just the (kuid2_nnnnn_mmmmmm' when needing something.
    3. If you sort your List after applying selection criteria filters by KUID (Handy_Technique: Click on the column header, it will sort to that column)
    4. This dual save by same name gives you a Near Instant way to find them, going forwar. Many text search utilities (including the built-in Notepad++ SAR ability) can see into many files to Search (Find) a kuid then. Details on how-to see into files is covered elsewhere, but being systematic and organized about the prospect will speed success in finding them later.
  2. For another method, this one giving you a stash of things you can examine at your leisure to see how content is put together:
    1. Open them for edit, Run PEV-tools from a batch file in the folder,
    2. Copy them all to another temporary directory,
    3. edit their kuid to a Kuid2 suffixed ':+1', pseudo-improvement. (for example:
      <kuid:zzz:xxx:yyy> to <kuid2:zzz:xxx:yyy:1> or
      <kuid2:zzz:xxx:yyy:4> to <kuid2:zzz:xxx:yyy:5>)
    4. re-import the 'pseudo-fixed' asset to verify it is all in that folder (Textures, meshes in particular might be missing)
    5. recommit both of them (Note: Trainz will have made a new local folder in ..\editing when you import the changed one, so best to also change the asset name when promoting the kuid and/or version. I suffix a '-a' meaning adjusted, and can search THAT in CM→Names search to find all non-stock assets immediately.)
      1. afterwards, copy or move the error tested one in the temp folder (That can just be dragged into your archive directory once you know it's gestalt--next step), then after committing the +1-kuid test version and the original, delete both of them.
      2. Recommitting before deleting is in some cases an necessary step, so form the habit and make it a 'good practice' of yours from the start.
    6. If successful, move the folder to the 'manually managed' archive directory you manage without Trainz knowledge, freeing up the temp folder for 2-3 new assets to pillage.
    7. Trainz will promptly forget they were around, especially after quitting out and reloading it, which is recommended every couple hours as a good practice.
Running PEV's tools from the batch will usually grab the meshes and textures into the local folder.
  • Recommitting the 'original folders files' after running the batch, will likely get an error complaining that the texture is already in CM's cache folder. So sort by extension, delete all the textures, recommit, then delete using CM. But only after you're sure all the contents are in the folder you want to keep. (Silly to go through all this and not make sure of THAT!) But the goodies will be safe, ...just in case you want them later.



Pruning Routes and Sessions

[edit | edit source]
This section also covers a process to try and move a session onto a newer version of the layout.

Layouts that you have created yourself can be deleted in Surveyor Main Menu where the Table of Contents of Routes, Sessions and Scenarios is displayed.

  1. First delete any related sessions, for if kept, their referencing the Route asset KUID as a dependency, so will create a Missing Dependency Fault or a problem to be dealt with by deleting in CM.
  2. The second option has two forks, start by doing a author name search for yourself, this can be your Trainz Kuid pre-fix preceded by the # key: '#497853' for example. Refine that if you wish by filtering for just Routes and Sessions.
    1. Now with your target(s) in sight you have a choice, providing you have done as many of us do routinely and saved major change versions with a suffixed version number (Mod XXX, or V15-7) AND you want to try to put some of those old sessions on the new version, before deleting the route, Hand Edit the Session Config.txt for the Route and change it's KUIDs by searching for the old route, and replacing each place the kuid appears. In pre-2009-SP4, their will be one in the body near the English description field data or above the English string-table, and if later versions hold true, as the last item in the kuid-table container.
    2. This gives you better than even chances(check the old session will work on the new route. It's a crap shoot if you have positioned train consists somewhere where you have adjusted track heights and/or moved the track a bit.
    3. One reason to hang onto that old Route until testing is it can possibly be recovered by moving back to the old kuids (Reverse the above), Edit the old route & Session, relocate the cars missing the tracks to a place you didn't molest, then repeat starting above. Loop a couple of times through such attempts before giving up.
    4. If the consist has just been a little off it's 3D co-ordinates, using the F7+M tool can allow you to grab the engine or cars from the minimap. Best to rotate the camera straight down, do a CTRL+F (Find) on one of the cars, then without moving the mouse try to grab and move it. If successful, the entire consist will move too, per normal, and you will see it snaps to the track at the new height. All is well... if you can grab them. If not, delete the session and forget it.
    5. Did you record the session rules settings as you went on a card-file or spreadsheet? If you did a thorough job documenting it (Easiest way to write a complicated session) you can just refer to that and re-enter it.
  3. In all the CM versions, all assets can be deleted from inside the Content Manager screen. Once you've done so, it's gone. Hopefully to bit heaven. Other older Trainz are more basic. TRS2004 and earlier Trainz assets can be removed by manually deleting their kuid folder in Windows Explorer. Alternatively, for this older generation, TrainzObjectz can be used to delete unwanted assets.

Deleting an asset does not delete any of its dependencies. With a layout, the dependencies may number in the hundreds to several thousands.

  • TrainzObjectz includes an option to list and delete orphaned dependencies.
  • The CMs don't care if you orphan them, but only reports when one is missing. However, you can filter and weed things out if you like. Surround a bunch on the screen with a big selection, test using the dependent assets drop down RMBHd to see if any kuids need the proposed victims, if not, delete away.



TRS2006

[edit | edit source]
This Trainz page is dated or in need of reorganization and improvement, and as such has been listed for Clean-up as soon as we can get around to it. It has been listed at Category:Trainz pages needing attention, and we apologize for any inconvenience you may incur because our vlunteer staff hasn't found time to make it better.

(The following information is kindly supplied by ColPrice2002)

Routes that have been created by you can be deleted in Surveyor.

Also you can delete any asset that is not built-in with CMP.

To delete a layout and its dependencies:

Open CMP, search form "Location = Local" + "Category = Routes" and select the layout to be deleted.

Right-click and select "show dependencies" from the menu. This lists the dependencies in a pop-up window.

Now click the "view in main screen" button, and all of the dependencies are listed. Press CTRL/A (or use the Select All menu option), then "Delete" to actually delete the assets.

Then return to the CMP list of layouts, select the relevant layout and delete that.

You will receive error messages if you try to delete built-in content and these can be ignored.

The only problem is that you may delete a dependency that's used by another route. You won't find out until you look at all the routes you have installed and look for the missing dependency flag (or try to load the route).

One way of reducing the impact is to archive the route and its dependencies (create a new archive for deleted routes). Carry on as before - deleting everything - if you need a deleted asset CMP will pull it from the archive. Once you're happy that the archive isn't needed you can delete it - this saves you re-downloading.