Jump to content
Edvarz

Strange issue with brown boxes

14 posts in this topic Last Reply

Highlighted Posts

Posted:
Last Online:  
 

I had a strange issue with some of @mattb325's buildings: Kensington Apartments, Gertrude Apartments, Millenium Hotel Knightsbridge, and Transport Indemnity Building

The lots were displaying brown boxes even though the model file was installed correctly (I'm using the Darknite versions). First I removed the files and re-installed them, same issue, so it was not a faulty installation. Next I tried looking at the files in PIM-X and everything showed up correctly; without making any changes, I went back to the game and plopped them again, then everything showed up correctly. Now, to check the files with PIM-X I had to move them to a different directory, a special folder that I use to tweak and fix things after installing them; just moving the files seems to have solved the issue, so for clarification, here are the paths:

1. Installation paths

Kensington: C:\Users\MyName\Documents\SimCity 4\Plugins\05a. Lots urbanos\A2. Residencial- Medianos\Mattb325\Mattb325 Kensington Apartments

Gertrude: C:\Users\MyName\Documents\SimCity 4\Plugins\05a. Lots urbanos\A2. Residencial- Medianos\Mattb325\Mattb325 Gertrude Apartments

Millenium: C:\Users\MyName\Documents\SimCity 4\Plugins\05a. Lots urbanos\B2. Comercial- Servicios\Mattb325\Mattb325 Millennium Hotel Knightsbridge

Transport: C:\Users\MyName\Documents\SimCity 4\Plugins\05a. Lots urbanos\B1. Comercial- Oficinas\Mattb325\Mattb325 Transport Indemnity Building

2. Edit path for PIM-X

C:\Users\MyName\Documents\SimCity 4\Plugins\08. Editar\Mattb325 Kensington Apartments

*The path here is the same for all four except for the last part after \08. Editar\ just change Kensington Apartments for the name of the other buildings*

.....

As you can see, the second directory ......\Plugins\08. Editar\...... loads after the first one ......\Plugins\05a. Lots urbanos...... so I didn't rule out an ID conflict somewhere as the source of the problem. The second path is also shorter, but I don't think this has anything to do with it. I don't know how it occured to me but I tried shortening the name of the folder that contains the files, I deleted Mattb's name so that it only had the name of the building. The paths resulted like this.

C:\Users\MyName\Documents\SimCity 4\Plugins\05a. Lots urbanos\A2. Residencial- Medianos\Mattb325\Kensington Apartments

Same with the other three.

And whaddayaknow!, everything works fine :???:. So I managed to solve it, but have no idea what might have caused the problem in the first place. I also noticed there was another person with this issue, check the comments section in the Kensington Apartments page, some internet-spoiled guy gave it a 1 star review for this same reason. It's not an urgent problem, but I'm curious about it's cause, It may have to do with the way I have structured my plugins folder, but I can't say anything more about it.

  • Like 1

Check out my content on the STEX

Or pay a visit to my Lot thread to see the projects I'm working on!

Mi taller de lotes, ¡Ahora en español!

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

Maybe the hypen after residencial and comercial? It seems like the only relevant difference between them both

  • Like 1

matias93's Unexpected Mod Workshop (dev thread)             Ciudad del Lago in the making (dev City Journal)

"Let us be scientists and as such, remember always that the purpose of politics
is not freedom, nor authority, nor is any principle of abstract character,
but it is to meet the social needs of man and the development of the society"

— Valentín Letelier, 1895

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 
Quote
56 minutes ago, Edvarz said:

As you can see, the second directory ......\Plugins\08. Editar\...... loads after the first one ......\Plugins\05a. Lots urbanos...... so I didn't rule out an ID conflict somewhere as the source of the problem. The second path is also shorter, but I don't think this has anything to do with it. I don't know how it occured to me but I tried shortening the name of the folder that contains the files, I deleted Mattb's name so that it only had the name of the building. The paths resulted like this.

C:\Users\MyName\Documents\SimCity 4\Plugins\05a. Lots urbanos\A2. Residencial- Medianos\Mattb325\Kensington Apartments

Same with the other three.

And whaddayaknow!, everything works fine

The reason the second path works is likely due to the length of the file/folder/directory structure: windows doesn't like very long file locations.

While you've noticed it with my lots, it could theoretically happen to others as well.

I would change your structure to "Lots urbanos" to "Lots_urb" and "Residencial- Medianos" to "Res-Med" (or similar) to avoid this issue from occurring again with my (or other files) *:)

 

  • Like 3
  • Yes 1
  • Thanks 1

Share this post


Link to post
Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     
    2 hours ago, mattb325 said:

    While you've noticed it with my lots, it could theoretically happen to others as well.

    I would change your structure to "Lots urbanos" to "Lots_urb" and "Residencial- Medianos" to "Res-Med" (or similar) to avoid this issue from occurring again with my (or other files) *:)

    Thanks! I'll try to shorten all the directories in my Plugins folder then. Love your work BTW! :yes:


    Check out my content on the STEX

    Or pay a visit to my Lot thread to see the projects I'm working on!

    Mi taller de lotes, ¡Ahora en español!

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    @mattb325 is likely spot on, the suggestion he brings to light is something all players should carefully consider. I was discussing this issue only recently with some others in a private topic around here. But just to reinforce what's been said, keeping the number of folders/subfolders you use to a minimum is really important. Similarly, keeping file names within reasonable limits is also important, although there are good reasons why many of them are quite long. SC4 doesn't care what your files are called, that's simply only used so you can recognise them in Windows. Changing the names will change nothing at all you see in-game. If the combination of folder/file paths get's too long, Windows won't even let you move/copy files. But you might run into limits before then.

    Man, I recall the days when all filenames had a strict 8-charachter limit, we're so free now!

    Consider also that your Windows user name factors into this problem:

    Quote

    My default Plugins location is:

    C:\Users\MGB\Documents\SimCity 4\Plugins  --> + Path + Filename

    Consider how I've only used a 3 Character username for Windows, whereas many will be much longer, this is another factor.

    Here are some example folder/file names we came across in that conversion, as you can see pretty long:

    Folder: Bydgoszcz Dluga 72,Niedzwiedzia 1,Stary Rynek 27,39,T.Magdzinskiego 10

    • Bydgoszcz Dluga 72,Niedzwiedzia 1,Stary Rynek 27,39,T.Magdzinskiego 10_d5a4574f.SC4Lot
    • Bydgoszcz Dluga 72,Niedzwiedzia 1,Stary Rynek 29,37,T.Magdzinskiego 10-0x5ad0e817_0x73fefbad_0x1e00000.SC4Model
    • Bydgoszcz Dluga 72,Niedzwiedzia 1,Stary Rynek 29,37,T.Magdzinskiego 10-0x6534284a-0x73fefbad-0xd5a44853.SC4Desc

    Folder: Bydgoszcz Dluga 74,Stary Rynek 18,22,T.Magdzinskiego 10

    • Bydgoszcz Dluga 74,Stary Rynek 18,22,T.Magdzinskiego 10-0x5ad0e817_0x73fefbad_0x1de0000.SC4Model
    • Bydgoszcz Dluga 74,Stary Rynek 18,22,T.Magdzinskiego 10-0x6534284a-0x73fefbad-0x15a37ed8.SC4Desc

    So changing those to the following:

    Folder (remove one): Bydgoszcz Dluga

    • BD 72 Niedzwiedzia.SC4Lot/Desc/Model
    • BD 74 Stary Rynek.SC4Lot/Desc/Model

    You pretty much remove the odds of such issues occurring.

    Many items are suffixed with the ID as part of the file name, for example:

    File_name_or_description-0x5ad0e817_0x34f65f72_0x30000.SC4Model

    This can be really useful for modders, since I now have access to the ID of the item, which I can copy/paste right from the file name. But of course, it makes the file name much longer than is necessary. It highlights yet another good reason to DATPack your plugins folders. Because you may wish to keep the original file names, I often do to prevent duplicates making their way into my Plugins folder. So the archived un-packed set retains the useful data, but the working set will be much more optimised with less subfolders and no large filenames to worry about inside them.

    I had to redact quite a bit of the quoted text, but again I hope this illustrates how a little care when adding files/folders can prevent such problems.

    • Like 5
    • Thanks 1

    Head over to my Lot and Mod Shack to keep abreast of my latest developments.

    Do you like custom textures, but don't like all the work involved creating them?, take a look at the Texture Automation options here. Change the look and feel of your transit networks, with the minimum of effort, for example customised versions of my Sidewalk NAM (SWN) and Terrain Grass NAM (TGN) mods, and much more besides.

    New to the NAM? Check out my tutorials on YouTube. Latest upload: How to: RHW - MHO Roundabout Interchanges. (Nov 25).

    p.s. - I'm MGB over on SC4D and a member of the NAM team.

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

    @rsc204 Seems that my way of organizing Plugins wasn't as brilliant as I first thought *:lol: In addition to shortening folder names, I'll also see if I can merge some subfolders, and maybe also gut some of those many folders created by installers, it's not like someone's going to update content made ten years ago to need acces to the default installation path.

    I haven't datpacked anything because I like to do quality control on almost everything I install, but there are some exceptions like matt's content, where I can safely say everything is modded to the highest standards, It'll have to make a sizeable difference if I datpack all of his creations. I have added so many things to my Plugins recently, that a backup is already overdue, so this seems as good a time as any to restructure the whole thing.

    • Like 1

    Check out my content on the STEX

    Or pay a visit to my Lot thread to see the projects I'm working on!

    Mi taller de lotes, ¡Ahora en español!

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    Yeah I think the only thing I get a bit paranoid about when changing filenames, being sure I don't accidentally then end up with duplicates of it. DAT packing is optional, but it sure makes the game load quicker and more responsive, even with an SSD. I've only started doing that more recently, because I don't want to keep two versions of my plugins folder. I arleady have like 15 different plugins folders, managing those is hard enough. Thankfully I can tear apart DATs and merge/overwrite things with ease, so it's less of an issue for me than the average player.

    • Like 1

    Head over to my Lot and Mod Shack to keep abreast of my latest developments.

    Do you like custom textures, but don't like all the work involved creating them?, take a look at the Texture Automation options here. Change the look and feel of your transit networks, with the minimum of effort, for example customised versions of my Sidewalk NAM (SWN) and Terrain Grass NAM (TGN) mods, and much more besides.

    New to the NAM? Check out my tutorials on YouTube. Latest upload: How to: RHW - MHO Roundabout Interchanges. (Nov 25).

    p.s. - I'm MGB over on SC4D and a member of the NAM team.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     
    2 hours ago, rsc204 said:

    ...being sure I don't accidentally then end up with duplicates of it

    DataNode in file-view is good at highlighting where whole files have been overridden, which should expose any accidental duplication.

    • Like 2

    -- Jeff Fisher ><> Vancouver WA
    "I may be pissing into the wind, but if I keep my enemies behind me and aim carefully, I can still rain on their parade."

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    Further derailing the thread to plugin management, what works for me is Doc Rorlach's DIC, which creates an automatic backup of the plugins folder before datpacking. This allows to datpack only the changed folders (excluding the ones that have to be non packed) and to keep a serviceable version while having a faster, playable plugins folder for ordinary use. It also includes a tool to recommend optimisations of folder numbers and sizes depending on the full weight of the Plugins (which I use) and a downloads manager (which I still don't understand completely).

    • Like 3

    matias93's Unexpected Mod Workshop (dev thread)             Ciudad del Lago in the making (dev City Journal)

    "Let us be scientists and as such, remember always that the purpose of politics
    is not freedom, nor authority, nor is any principle of abstract character,
    but it is to meet the social needs of man and the development of the society"

    — Valentín Letelier, 1895

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    Conventional wisdom for some time has been that the only cause of a brown box is a missing model (or an improper reference to it).  I guess we now need to add inability to access/find the SC4Model file due to path length.

    Although Windows literature (https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247(v=vs.85).aspx) quotes the number 260 as the value it uses for MAX_PATH (for versions of Windows prior to 10), there are several caveats that chip away at this number.  As a practical matter, you actually have @ 247 characters for the total path length (starting with the drive letter and ending with the last character of the file extension, including any spaces). 

    @Edvarz, since you're seeing brown boxes, that would tend to indicate that the total path length of the respective .SC4Model files are at or exceeding this number with your original path.  If we go on the assumption that all of the files for the lot follow immediately after the path you gave for Kensington Apartments, given the length of the path you gave , and added to the length of the file name for the DN SC4Model file, unless you have a very long user name, you're sitting at about 195 characters - obviously quite a bit shorter than 247 characters.  Were there any additional folder levels between the path you gave and the actual SC4Model file?  The fact that you got things to work by removing 9 characters from the path would point in that direction.

    We have to be cognizant of the fact that often, as unzipped, there are folder levels unnecessary to proper functioning of the download, included in many downloads.  Sometimes this is just due to default behavior in the zip/unzip process.  Sometimes this is a result of the author packaging his/her files in a way that makes clear what files are required for proper functioning of their creation (@mattb325 is one who does this; I know there are others as well).  The bottom line is that it is worth a couple of extra steps to strip away what is essentially "excess packaging" from each download before dumping the download into Plugins.  This keeps Path Length as lean as possible, and provides more room to organize as we see fit, hopefully without causing problems as happened here.

    • Like 5

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    At least for XP one thing to keep in mind is when you think you are just in My Documents\SimCity 4\Plugins it's really C:\Documents and Settings\UserName\My Documents\SimCity 4\Plugins.

    And I guess this would be a good place to mention one time when I was unzipping some STEX files a couple of them popped up asking for a password. That seemed really strange and I was going to ask about it but I just moved on to some others. It was when some things worked and others didn't I started looking a little closer. A few files had truncated names. Like one that should end with .desc was only .de. Long story short, I was just at my limit in the path length and that's why some got chopped off. It was also why a few zips erroneously asked for a pw. I moved them to c:\x and then there was no trouble at all.

    • Like 2
    • Yes 1

    Chance favors the prepared mind. ― Louis Pasteur  
    Remember, a few hours of trial and error can save you several minutes of looking at the README. -- I Am Devloper (on Twitter)

    Clickable ---> The Best of Cori's Posts  (scroll down a wee bit there)    Something fun: MySimtropolis - Invitation to become a SimCity 4 MySim

    Are you new here? Check out the Introduction and Guide to Simtropolis.

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

    @matias93 That sounds useful, can you share a link?

    @twalsh102 Now that I check, yes, there were two more subfolders plus the name of the file, in the case of Kensington Apartments this would bring the count up to 262 characters:

    C:\Users\Oscar Eduardo\Documents\SimCity 4\Plugins\05a. Lots urbanos\A2. Residencial- Medianos\Mattb325\Mattb325 Kensington Apartments\Model Files KEEP ONLY ONE\Kensington Apartments DARK NITE\Mattb325_Kensington_Apartments-0x5ad0e817_0x88eb082f_0x30000.SC4Model

    So removing 9 characters made it 253, this was enough for it to work, and it's also why there wasn't any problem with the lot files, those only have one extra subfolder. As @rsc204 stated above, simply removing the TGI from the file name would be enough to keep the length of the path under the limit, in this case it would remove 29 characters (and i guess in most other cases, since TGI's seem to have all the same length). Since most players don't need to have the TGIs at hand it would be good if trimming the file names was common practice when installing plugins.

    I honestly never thought this could be an issue (or maybe I did, since reducing the path lenght did occur to me) It's just one of those things the common computer user never gives any thought about.

    • Like 2

    Check out my content on the STEX

    Or pay a visit to my Lot thread to see the projects I'm working on!

    Mi taller de lotes, ¡Ahora en español!

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     
    2 hours ago, Edvarz said:

    That sounds useful, can you share a link?

    http://www.sc4tools.co.uk/sc4t_downloads.asp ;)

    With this, the files that the game end reading are of the style of D:\docs\Documentos\SimCity 4\Plugins\A.dat or M2.dat or T-U-V-W.dat. That's under 50 characters!

     

     

    • Like 2
    • Thanks 1

    matias93's Unexpected Mod Workshop (dev thread)             Ciudad del Lago in the making (dev City Journal)

    "Let us be scientists and as such, remember always that the purpose of politics
    is not freedom, nor authority, nor is any principle of abstract character,
    but it is to meet the social needs of man and the development of the society"

    — Valentín Letelier, 1895

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    This might explain why some of my lots have missing models, even though I'm almost certain that I don't install lots without first ensuring that I've also downloaded all the dependencies at the same time.

    • Like 1
    • Yes 1

    My MD on SC4Devotion (updated first)
    And Here on Simtropolis
    NAM Associate

    "My mother always told me, 'Elwood, you can be two things in this world...you can either be Oh So Smart, or Oh So Pleasant.'

    Well, for years I was smart. I recommend pleasant."
    -Elwood P. Dowd, Harvey

    Share this post


    Link to post
    Share on other sites

    Sign In or register to comment...

    To comment in reply, you must be a community member

    Sign In  

    Already have an account? Sign in here.

    Sign In Now

    Create an Account  

    Sign up to join our friendly community. It's easy!  

    Register a New Account


    ×

    Thank You for the Continued Support!

    Simtropolis depends on donations to fund site maintenance costs.
    Without your support, we just would not be in our 24th year online!  You really help make this a great community. *:thumb:

    But we still need your support to stay online. If you're able to, please consider a donation to help us stay up and running. This helps sustain a platform where we can share our community creations for years to come.

    Make a Donation, Get a Gift!

    Expand your city with the best from the Simtropolis Exchange.
    Make a Donation and get one or all three discs today!

    STEX Collections

    By way of a "Thank You" gift, we'd like to send you our STEX Collector's DVD. It's some of the best buildings, lots, maps and mods collected for you over the years. Check out the STEX Collections for more info.

    Each donation helps keep Simtropolis online, open and free!

    Thank you for reading and enjoy the site!

    More About STEX Collections