Ap Preload Shortener

Discussion in 'General Discussion' started by 749006, Nov 19, 2024.

  1. 749006

    749006 Well-Known Member

    Joined:
    Dec 10, 2016
    Messages:
    10,088
    Likes Received:
    3,145
    A post on a Train Simulator forum lead me to this program which shortens the over long AP files names in their PreLoad folders.
    https://github.com/sbrugel/ap-preload-shortener
    But I'm having a problem where it goes thru the process and gets to about 50% and stops telling me it cannot find a file
    Screenshot (455).png
    Even though the file is says is missing is in plain view.
    If I say Continue I also click on the program bar but it then goes backwards and starts doing the same thing again until it reaches the same file it cannot find.

    I'm having to rename some of the PreLoad folders by adding an X afterwards to make the program finish.
     
  2. Spikee1975

    Spikee1975 Guest

    This is the stuff I'd do manually (being a control freak). Unserz the preloads and shorten <DisplayName> and the localised english name. Or just do it in TSTools.
     
    Last edited by a moderator: Nov 19, 2024
  3. knuckleshed

    knuckleshed Well-Known Member

    Joined:
    Jul 14, 2024
    Messages:
    441
    Likes Received:
    448
    Just for science Serz the bin and leave the .xml in the same folder.
     
  4. Spikee1975

    Spikee1975 Guest

    That's where you'd just use SerzMaster.exe as it processes whole folders (and subfolders if you tick "recursively").
     
  5. knuckleshed

    knuckleshed Well-Known Member

    Joined:
    Jul 14, 2024
    Messages:
    441
    Likes Received:
    448
    Not my point. Peter (the other one) is having issues with it hanging on one single file, I'm wondering if it was a compile error on that bin, unserzing it would serve to see if the program can then find it or not
     
  6. Spikee1975

    Spikee1975 Guest

    I do not know that tool, just giving alternatives. I only trust .bat files that I can read before using ;)

    I see that screenshot and wonder where the .xmls are too...
     
    Last edited by a moderator: Nov 19, 2024
  7. knuckleshed

    knuckleshed Well-Known Member

    Joined:
    Jul 14, 2024
    Messages:
    441
    Likes Received:
    448
    No I don't know it either.
     
  8. Kim Olesen

    Kim Olesen Well-Known Member

    Joined:
    Jun 21, 2018
    Messages:
    729
    Likes Received:
    565
    Personally i don’t think it’s a good idea to shorten filenames. Too many things that can go wrong.
     
  9. 749006

    749006 Well-Known Member

    Joined:
    Dec 10, 2016
    Messages:
    10,088
    Likes Received:
    3,145
    It is only the PreLoad Display name that is changed - none of the vehicles bin files are the altered.
     
    • Like Like x 1
  10. Spikee1975

    Spikee1975 Guest

    Yes but the preloads are also bins containing the consist display name and the loco name under which they appear in QD.
     
    Last edited by a moderator: Nov 19, 2024
  11. Gary Padley

    Gary Padley Active Member

    Joined:
    Dec 10, 2016
    Messages:
    881
    Likes Received:
    239
    There's probably less typing involved in editing the files manually than there is in posting for help.
    If you take faulting .bin out Peter, does the tool do the rest OK?
     
  12. 749006

    749006 Well-Known Member

    Joined:
    Dec 10, 2016
    Messages:
    10,088
    Likes Received:
    3,145
    It does but for some reason there are a number of files it hangs on.
    I was just wondering if someone else had the same problem,
     
  13. Gary Padley

    Gary Padley Active Member

    Joined:
    Dec 10, 2016
    Messages:
    881
    Likes Received:
    239
    Just what is the descriptive name for that consist?
     
  14. 749006

    749006 Well-Known Member

    Joined:
    Dec 10, 2016
    Messages:
    10,088
    Likes Received:
    3,145
    I think I have found the problem. My fault.

    I have two TSC setups on my computer - the newer one is mainly for European routes and stock.
    Although I copied my AP folder I don't have all the required trains installed on my new setup.

    The program found the AP PreLoad files but the actual Assets and therefore the bin files were not installed as I did not think I would use them on my other Railworks Setup.

    I have been going thru my copied AP folder and removing the stuff I won't use.
    Actually just renaming the PreLoad folders with a X Suffix so the game does not see them.
     
  15. Spikee1975

    Spikee1975 Guest

    Hmm. I couldn't do without them. Do you want to assemble an HST manually each time?
     
  16. 749006

    749006 Well-Known Member

    Joined:
    Dec 10, 2016
    Messages:
    10,088
    Likes Received:
    3,145
    When I created the earlier version of TSC V72.3 I copied most of my EU and some UK Routes to this folder.
    I also copied my AP folder to this setup but because I had not copied all of my UK Stock the AP shortener could not find the bin files mentioned in the PreLoad folders so it fell over.
    By renaming the un required PreLoad to PreLoadX the program ignored them and completed the process.
    No point in having a PreLoad for a train that is not in the Asset folder.
     

Share This Page