I can't believe I'm the only one who needs this.

Chris004

New member
My list of routes with missing deps is much longer than my list of complete routes. My list of downloaded routes that are complete can be counted on the fingers of two fingers.

What I really need is a tool that will replace missing assets. Either with a similar asset (when I have a good idea of whats missing) or an easy to find marker asset.

Creating this tool should be a trivial programming task for anyone with the specs for the file formats.

Surely I'm not the only one who sees the value of such a utility.

My best case in point:

The signal I couldn't find the other day has turned up on the DLS but is "unavailable." CM3.3 can't see it CM 3.7 sees it but turns red. DLS shows it to me but says I can't have it. There is a version of this signal built into TS12. I could guess how this layout was signaled and replicate it, but my main reason for downloading this particular route was the number of sessions that I could find for it. I rather doubt they'd work with my attempts at signaling. (Even if I really knew what I was doing, could I replicate the errors of the original route builder?) Will the route even open in surveyor to give me the chance to "Delete Missing Assets"?

If I had the clearance to see the file formats I would write the thing myself. I could really use some help from one of our software people. Or call my bluff and give me the specs and dump the thing in my lap, either way I would be truly grateful, and I think the whole community would benefit.

Thanks again,

-chris
 
Creating this tool should be a trivial programming task for anyone with the specs for the file formats.

Surely I'm not the only one who sees the value of such a utility.

You're probably not the only one....which may be why creating such a tool may not be such a trivial programming task.
 
Try posting something useful for once, instead of meaningless, snarky responses.

@Chris-

Such a tool already exists: Replace Asset in Surveyor. It's about as feasible as you're going to get. I suspect you're thinking of a CMP-based tool. The problem is, you can't make software 'think', so it can't figure out what asset would fit the place of an existing asset, and even if you know a kuid to use, CMP really isn't designed for manipulation of graphical objects. You can game the Replace Asset function though to accomplish pretty much what you're asking. I can think of some ways to potentially streamline it so you don't have to resort to such a kludge e.g. temporarily assigning some placeholders the missing kuids and using Replace Asset against those, which is what I (and probably a lot of people) do with the existing system.
 
Try posting something useful for once, instead of meaningless, snarky responses.

Pot. Kettle. Black

Im sick of those dreaded white lines and they should be able to be replaced with a track. However, since the White lines thing indicates all splines/tracks I don't think it'd work very well.
what happens if you replace a missing asset with another on the KUID table in the config or CCP?
 
Far as I know you can't replace an asset thats missing all together. Like you download a route, spend 3 days tracking down all the assets, only to find 1 ground texture is from a version of Trainz you can't get for your Mac therefore you have to manually paint a new texture to the entire route. If there is a way around this it would be great! Like switching the missing texture in the config file with one you have. I don't believe that works, but I've never tried.

Replace assets only works if you have the asset. Oh I see Cascade just asked the same thing as me haha.
 
Pot. Kettle. Black

Im sick of those dreaded white lines and they should be able to be replaced with a track. However, since the White lines thing indicates all splines/tracks I don't think it'd work very well.
what happens if you replace a missing asset with another on the KUID table in the config or CCP?

Hmm, yes, Pot. kettle. black to you of all people, your posting history speaks for itself.

I already explained how it can be done. Rather than your usual snarkiness, try reading. If you can't figure it out based on what I wrote above and want a step-by-step clarification, ask nicely (if you're able) and I'll run through a step-by-step process. I'll even post a listing of DLS-available assets so you can test the method yourself.

Of course, my method requires that "have a good idea of whats missing" (the OP's words), because, again, computers can't think and, therefore, know what it is that's missing.
 
amongst my Tips & Hints file I remember the following


:-Removing LOST track asset

I got this a while back from James Moody.

The following information comes via the lead developer for N3V Games. I had to use this last night and I know it works.

The dashed white lines isn't "a missing asset" - it's the asset that Trainz turns to when it can't find the asset it is supposed to draw there. These white lines are, in themselves, an asset. You can find this asset in CM. It's called "Missing spline", and it's by Rob. Open it for edit. Change the KUID from <kuid:523:1124> to <kuid2:523:1124:1>, and remove the whole privileges container (containing the line "permit-listing 0") Then install that asset as if it were a new asset - e.g. drag the folder from windows explorer back onto the CM interface. Once it's installed, revert the original one (you can't commit changes to it as it's a built-in asset). Result: The dashed white lines now show up in the menu, and can be selected just like any other track spline. You could lay some down if you wanted. More to the point, you can now use the 'replace items' tool to change them to any track spline you have installed...

I will add this. When you install the folder, use the install content option. This will save so much time. Also don't panic when the creator is shown as AURAN. I hope this helps some one.

My 2 pennyworth, the forums help me so often so maybe a little payback is in order :wave:.
Don't know if it helps and I can not remember who submitted it to the forum.
helian43
 
Im sick of those dreaded white lines and they should be able to be replaced with a track. However, since the White lines thing indicates all splines/tracks I don't think it'd work very well.
what happens if you replace a missing asset with another on the KUID table in the config or CCP?

To the extent that the missing spline is known to Trainz, shouldn't it be possible to discover what a given set of broken lines represent? The replace asset tool could then be geared to allow us replace that missing asset. Tr12 is littered with the things.
 
amongst my Tips & Hints file I remember the following


:-Removing LOST track asset

helian43


Great tip for replacing missing tracks, however, the dashed lines also replace missing splines from the objects tab such as roads and bushes. In this instance they change the type of asset as well as replace it. I guess a further temporary modification to the config.txt file could be made for these assets.
 
Thank You. Shiny!

[If you] want a step-by-step clarification and I'll run through a step-by-step process. I'll even post a listing of DLS-available assets so you can test the method yourself.
Yes, Please.
I suspect you're thinking of a CMP-based tool. The problem is, you can't make software 'think', so it can't figure out what asset would fit the place of an existing asset, and even if you know a kuid to use, CMP really isn't designed for manipulation of graphical objects
....
Of course, my method requires that "have a good idea of whats missing" (the OP's words), because, again, computers can't think and, therefore, know what it is that's missing.
You know, my post originally had the line
Creating the tool to figure out what KIND of asset (object, trackside, spline, texture or rollingstock) is missing is less trivial, but shouldn't be insurmountable.
I removed it when I realized that the route files must contain that information. Pretty sure there is a separate table (well, there are separate files in the route folder for map, objects and track).

I don't need the replacement object to be appropriate or pretty. I do need to see where the missing stuff was so I can figure out what the thing might have been.

In the (rare) case with which I began this thread, I have a perfect match [missing: Signal USA1 05, -12:24005. replace with: Signal USA 05 -12:214.] But I'd be completely happy with a 10 meter tall traffic cone.

If there is a way around this it would be great! Like switching the missing texture in the config file with one you have. I don't believe that works, but I've never tried.
what happens if you replace a missing asset with another on the KUID table in the config or CCP?
First thing I tried. It doesn't.

You can game the Replace Asset function though to accomplish pretty much what you're asking. I can think of some ways to potentially streamline it so you don't have to resort to such a kludge e.g. temporarily assigning some placeholders the missing kuids and using Replace Asset against those, which is what I (and probably a lot of people) do with the existing system.
Shiny! Tell me more.


Change the KUID from <kuid:523:1124> to <kuid2:523:1124:1>
I had no idea such a thing could be done. This has serious possibilities. For my signal case this might be all that's needed.

For the rest of the cases we still might need a utility to retrieve what information we can from the route files.

What I'm picturing is this:
A command-line program (like Texture2Tga). You give it one kuid and it reads the files in your editing folder and tells you where it found it and what it appears to be. Textures should be in the map file. Track and track objects in the track file ... If we just know the "kind" the missing asset is that would tell us what place-holder to use (A lot of the time one can tell the kind by adjacent kuids on the DLS. Creators tend to get on a roll).

The dashed white lines isn't "a missing asset" - it's the asset that Trainz turns to when it can't find the asset it is supposed to draw there. These white lines are, in themselves, an asset. You can find this asset in CM. It's called "Missing spline", and it's by Rob. ... More to the point, you can now use the 'replace items' tool to change them to any track spline you have installed...
If all missing splines (track or otherwise) get replaced by this one asset we'll have to do the replacement one asset at a time.

I'll stop rambling until I have a better idea of what RRSignal's method is. Meanwhile I'm gonna see if I can fool CM into thinking the signal I have is the signal it wants. Oh, wait then I can't "Replace Assets" it. Ok, I'll make a CNR Dwarf the stand-in... Hmm, lots to try.

Thanks to everyone who responded and especially helian43 and RRSignal for being particularly helpful.
 
Ultimately, you at least have to know if an asset is a spline or not for this method to work, or tolerate a lot of trial-and-error.

AFAIK, there is no storage of asset kind; to do that would require revamping the route format itself. I would encourage Windwalkr or

any of the other devs to join this discussion to tell us if that is in the cards or has been done, but AFAIK, it hasn't.

It appears that the way Trainz route files presently work is that a scenery item is specified by a kuid, with a position on the map,

and altitude, a roll value, and possibly some other miscellaneous data. A spline simply has multiple position/altitude/roll points,

so, regardless of whether an asset kind is stored or not, it narrows things down a little to be able to differentiate between a static

object and a spline. A tool to make THAT differentiation could be useful.

Unfortunately, working with what we have now, the arduous replace method I mentioned is all we have as far as I know. In the case of

H222's splines, the way one would go about replacing one is as such:

In CMP, select the route, right-click and select View Dependencies.

Pick out the one you think belongs to, say, track. Researching a kuid may tell you more. Jot down the kuid and revision.

Pick a piece of track content and open it for edit. Edit config.txt and change the kuid to that of the unknown object you jotted down

previously. You may wish to alter the username field and name the object in such a way that it stands out in the pick list in

Surveyor.

From CMP's file menu, select Import Content and import the 'new' track with the new kuid you just gave it. After it imports, you can

use CTRL-R to revert your edits to the original track.

Launch Trainz and go into Surveyor. Hopefully, your track will appear where track should be, or, at least where some spline would be.

If you're doing a project for your own use and you're satisfied with your replacement, you can probably stop right here. Otherwise,

use the Replace Asset function to swap the track for something else. When you save and exit into CMP, delete the kuid you imported above, since it's incorrect and no longer needed anyway.

Just to now, if you're seeing track while in Surveyor where some other spline should be e.g. a road, then may have to redo this using a road instead of a track. Also, bridges and tunnels do not function with Replace Asset, in which case you'll just have to outright substitute the missing kuid by changing the kuid as you did above, or re-lay the item manually.
 
So kind of you to spell that out for me.

From your earlier post and helian43's the gist of the idea was beginning to form in my head. I'm so glad I don't have to flesh it out on my own. With my limited knowledge of Trainz it would have been quite the process. I had no idea that I could swap kuids (the only time I work with a config it's an edit and if the kuid changes on a re-commit it fails, of course.)

This one thing is about 90% of what I was asking for. It's just instead of textually replacing the kuid in the map files we textually replace the kuid in our dummy asset. (still chuckling and shaking my head that we can do that).

Do you happen to know what I can expect if (when) I guess wrong (needed a spline, didn't use one)? Script exception errors? Crash to desktop? Guess I'm gonna find out:D.

I can't help but think that there's a bit more information tied up in those -bkm -gnd -lyr -obs -trk and -trc files that we could use. A spline object needs more than just the position of the nodes or when I reopened my route all my AJS Platform Postwar would be strung together in one big knot. Some notation about terminal node and next-node must be in there. And aren't track-object's positions given relative to track segment, rather than spatial position?

If we could just read the file, or had a tool to read the file. Or a tool that spat it out in XML...

Rambling again. Sleep, I think.

Thank you, again, for all your help.

-chris
 
Back
Top