Jump to content

8 posts in this topic Last Reply

Highlighted Posts

Hopefully I'm posting this in the right area...

I have started an attempt at doing some modding of FLUP tiles as part of a region I'm working on. To start, I want to update the textures displayed with the FLUP custom tiles (originally Set A) to get the grass to match my current park/grass textures as well as update the sidewalk/brick. I've read through the tutorials and then jumped in with both feet, hoping for some success. I hoped wrong.

 

What I've done to try to change texture on a tile:

1. Identified and noted the EID I need to modify (0x53E61B00, though the zoom textures themselves start at 0x53E61BF0).

2. Created the PNG and FSH files for my desired replacement texture (128x128 size only, I use sc4tool to copy to the smaller sizes)

3. Deleted the old FSH files in the appropriate .dat files (FLUPs_Custom4_Plugin_MaxisParkGreen) and replaced them with the new FSH files. I ensured these are using the same ID (0x53E61BF0 through 0x53E61BF4) as the original textures.

4. Checked the DIR file to make sure IDs match the old IDs and saved the .dat

 

Upon loading this into the game, the base texture simply does not render - it's transparent. The tile works fine for transit, it's just transparent. I went back in and tried a few other things, also to no avail:

- Deleted the exemplar file within the .dat as the new texture has no props. No change in behavior.

- Updated the DIR file to have matching Group IDs between the preview and zoom textures. No change in behavior.

- Re-indexed the DIR file altogether. No change in behavior.

 

I'm pretty sure I'm making some newbie mistake here as this is my first foray outside of lot editing, but I can't for the life of me figure out what I'm missing. Anyone out there with experience doing this who can point me in the right direction to get this working?

Share this post


Link to post
Share on other sites

First off, when making mods, it's usually preferred not to mess with any original files, but to keep your changes as a unique one. This way your alterations can be loaded after the originals as an override. Once that's been verified as working, maybe then you decide to edit the original files with your modified ones, but I still wouldn't generally advise it.

The Mod by SFBT that alters the FLUPs relies on 6 pieces that exist in the NAM for this purpose. So the only reason to use that mod if you plan on customising them yourself is as a reference point to make them. Put another way, all you really need to accomplish this are textures that overrides those in the NAM itself.

First you should check the ID of your replacement texture is definitely correct. For example, you can select in SC4 tool to create either a Lot or Network texture. The GroupIDs of which are different: 

  • 0986135E (Lot Textures)
  • 1ABE787D (Network Textures)

So this task, you must be using the latter Network Texture Group ID or it simply won't work.

After that, the the next thing to check is that your texture is correctly loading after the NAM. Usually placing the .dat inside a folder named "z____LoadLast" should be sufficient. For testing purposes I'd recommend copy/pasting that folder name and using it.

Share this post


Link to post
Share on other sites
  • Original Poster
  • I agree on keeping lots separate. I'm using the existing lot instead of making a new one because it's the path of fewest changes (and thus easiest learning) - touch one thing, load, observe, repeat. Think of an aspiring artist doing some traces before sitting down to painting. Once I get the hang of things, I'll revert to the "default" mods and build out my own.

    The note about the distinction between lot and network textures seems to have been the secret sauce. I re-created the textures in sc4tool as network textures instead and applied them to the .dat and it's now rendering as expected...in most zoom levels. The 2 closest zooms still are coming up transparent, but this is progress. I'm also showing one zoom level (that last one that works before going transparent) isn't compressing for some reason, but I don't know if that's related yet.

    I suppose the next best step is to kick out the original SFBT Custom FLUP mod and just build a fresh .dat using the EIDs designated in the NAM for custom FLUPs. This will help me eliminate any possibility of something I'm not overriding, and now that I've seen and know that what I'm doing is the generally correct way to do this now, I feel better about losing the training wheels.

    Thanks!

    Share this post


    Link to post
    Share on other sites

    If you're having problems with only certain MipMaps (smaller textures), then usually that's an ID problem or issue with Alphas/Transparency. The easiest way to know is by looking at the DAT containing your new texture. If you can attach that to a post here I'm sure it would clear things up.

    Compression isn't always useful or needed, so if the texture displays fine, it's not necessarily an issue. The FSH format is quite specific in certain ways, but a tool like you are using will simply do everything automatically. So the algorthm probably just decided this one wasn't worth compressing.

    If you are going to get into texture making, you probably want to get hold of Batch PNG2FSH tool or GoFSH:

    Both make the creation of larger numbers of textures much, much simpler. The latter even has some amazing automation possibilities and useful utilities built in.

    P.s., you've used the term EID a couple time, but that's not commonly used terminology round these parts. Generally speaking, IID (Instance ID) or simply ID is going to be better understood. Since textures used fixed Type and Group IDs, usually IID is the most logical.

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • I tried a different approach this morning with the different but similar results:

    1. Per advice, I reverted all custom FLUP tiles to default.

    2. Create a new folder (z_fluptest) to load after all NAM plugins. In this folder, I created a single dat (flup_grass.dat) that contains only transit textures to override the original ones. Nothing else was changed.

    After loading the game, zoom levels 1 and 3 looked as I would expect, zoom levels 4 and 5 were transparent, and zoom 2, to borrow from Mel Brooks, went to plaid. As requested, I have also attached my .dat file containing only the new FLUP textures.

    One other minor question I encountered while working on this is how to insert custom preview tiles. It seems to use a custom ID for the preview (in this case 0x53E61B09) that sc4tool will not permit me to create. It gives me invalid ID when I try. As a workaround attempt, I created the FSH file with ID 0x53E61B09 from the PNG, but when inserting that file into the .dat the group and instance ID goes to null (0x00000000).

     

    zoom_1.jpg

    zoom_2.jpg

    zoom_3.jpg

    zoom_4.jpg

    flup_grass.dat

    Share this post


    Link to post
    Share on other sites

    I've taken a look at your file and it's curious why some zooms are working and others not. So I dug into the FLUPs file and I think it's because the models for zooms 3-5 have an additional "Ghost" texture that's layered over the base texture. This means modifying the addon pieces 4-6 will not be as simple as just a texture. Because you'll probably need to modify the S3D models texture settings, which frankly is some pretty complex stuff. If you use the default SFBT mod's overrides, you'll note the FLUPs remain transparent, but props are added to them. You can override the preview pieces fine and the Z1/Z2 also, because they didn't include the ghost pieces.

    Grass FLUPs is something I've got ready for an unreleased update to TGN, Appalachian version attached (TGN FLUPs.dat), since there is no point re-making the wheel. I figure that's what you really want in respect of the Grass pieces? Bear in mind this overrides the base Grass FLUPs, not the custom ones, but I don't think that should be an issue?

    Therefore I guess the next thing you'll want to do is to make the BSC park textures so that they too show the same grass pieces? By far and away the simplest and most reliable method I know of creating these would be to use GoFSH. You can load a DAT containing those textures you plan to edit. Extract those files as FSH, convert them into BMP pairs. Yes, I know every man and his dog seems to want to work with PNGs, but BMPs have so many advantages, especially for transit textures like these. After that a few simple edits to the Alpha images, converting them to Definition Alphas, you'll have everything you need to very quickly process and package the textures using automation. I've put together a set like this containing the Grass FLUPs and BSC Parks textures (also attached). You just need to run the included script and have the right grass texture to make this work.

    Literally GoFSH will add the custom grass for you, automatically colour correct it and then output everything into a DAT file. This methodology makes light work of any texture project and is absolutely the quickest and most flexible method of working. You can further modify the textures in the attached repository, run GoFSH again and it will reflect your changes. It's not complete, but I figured there is enough here to give you an idea of how GoFSH works. If you check out the included manual with the application, along with the dev thread here, it should be enough to understand this process hopefully. If not feel free to ask any questions.

    Note also, using the folder z_fluptest will not correctly load after all of the NAM. The NAM has a folder z___NAM, which loads after your chosen one. In this case it doesn't matter, because the FLUPs are located in the Network Addon Mod folder. But trust me on this one, when making overrides always use a prefix with z____ that's a minimum of four underscores. It's just a really good habit to get into.

    TGN FLUPs.dat

    FLUPs for GoFSH.zip

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • It seems after all that the problems I had were not so much my missing something as I picked the wrong IDs to cut my teeth on. Had I simply tried custom tile 1-3 instead of 4-6 we might not be in this thread at all.

    Indeed, I was trying to shore up the areas in my region that were not cleaned up by the TGN! I started with the FLUP pieces as they seemed to be much easier to get than extended/overhanging lots. I'm also considering taking up working on overhanging lots to fix some diagonal and smooth curve overhang lots, though I'm also hoping the next NAM release includes draggable one-way smooth curves which will deprecate the need for half of such lots.

    I do have GoFSH and found it marginally useful for making FSH files, but the pointer about auto-darkening is what just sold me. I had been doing the adjustments manually in GiMP to get lot and transit texture colors to match, but it looks like it just saved me a lot of time by doing it for me. I made a new FLUP texture for the first custom tile (0x53E61800), loaded your TGN dat, and tested both out. Things look much better now. It also means I can go back to Paeng's parks, which I personally prefer, and clean up my plugins a bit more. I'll need to rortate the brick textures to get them to align better, though it also looks like Paeng's lots also suffer from this at times.

    Regarding naming the test dir z_fluptest, I thought it *should* have worked with my plugins since I organize my plugins folder by following a SysV-styled naming convention (see image). The files within keep their original names, but this enables me to have finer control over which components load and when. It makes datpacking buildings and textures easier and more organized for me. If some Cleanitol scripts hard-code directory paths (bad practice if they do) they may miss a file, but I have yet to run into that problem and the system has worked well enough for me over the years. With such a naming scheme, shouldn't z_fluptest have worked fine, or would the unsightly underscores (4 no less) be required still?

    Commentary aside, I have three new questions:

    1. Is there a way I can enable Mayor-mode trees to be plopped on top of these specific FLUP pieces, or is the fact they're transit tiles going to render that impossible? If the latter, is the only way to populate the grass with some form of foliage to be to use a "ghost" texture such as what you mentioned were on FLUP tiles 4-6?

    2. With the custom IDs for FLUP, it doesn't look like there's an option to build any except for straight paths. Is this correct, or, like the grass IDs you overrode, are there also IDs to do curved/intersecting FLUPs on the custom tiles?

    3. I'm still not quite sure how to take my BMPs for the preview tiles and load them into the dat. If I try to insert just the 128x128 FSH as an ID (say 0x53E61809), I get an error. I thought that I could also insert all 5 at 0x53E61805 and then manually delete the first 4, but with ILives I didn't see a way to delete specific FSH files, only the entire group. What's the best practice for replacing preview tiles on these pieces?

    Thanks again for your help.

    flup.jpg

    plugins.jpg

    Share this post


    Link to post
    Share on other sites
    2 hours ago, IceDruid said:

    I started with the FLUP pieces as they seemed to be much easier to get than extended/overhanging lots.

    Without resorting to making BAT models, doing this will require of Overhanging S3D models with textures applied. The latter method is made more complex in a number of ways to get good/consistent results. Again as part of the TGN update, compatible textures will be included to override my own set of these. None of this is in the wild yet though, but if you want a copy, send me a PM about it and I'll happily pass them on. Included too are pieces for Paeng's Parks (my preference), which I've previously shown here:

    2 hours ago, IceDruid said:

    I'm also hoping the next NAM release includes draggable one-way smooth curves which will deprecate the need for half of such lots.

    I'm not sure if that will be the case. Although the current pieces won't show grass or sidewalks without a mod installed. It's totally possible to manually modify the textures.

    2 hours ago, IceDruid said:

    I'll need to rortate the brick textures to get them to align better, though it also looks like Paeng's lots also suffer from this at times.

    That's always an issue when the texture isn't able to be seamlessly tiled/symmetrical. In short, the pattern used could never work any other way.

    2 hours ago, IceDruid said:

    Regarding naming the test dir z_fluptest, I thought it *should* have worked with my plugins since I organize my plugins folder by following a SysV-styled naming convention (see image). The files within keep their original names, but this enables me to have finer control over which components load and when. It makes datpacking buildings and textures easier and more organized for me. If some Cleanitol scripts hard-code directory paths (bad practice if they do) they may miss a file, but I have yet to run into that problem and the system has worked well enough for me over the years. With such a naming scheme, shouldn't z_fluptest have worked fine, or would the unsightly underscores (4 no less) be required still?

    I was assuming use of the default folder names. Indeed if you've changed them, that will affect the load order. Cleanitol relies on searching for file names, not folders, so there should be no issues there.

    2 hours ago, IceDruid said:

    1. Is there a way I can enable Mayor-mode trees to be plopped on top of these specific FLUP pieces

    MMPs can never be placed upon transit networks, the game will never see any "space" for them to be placed. The only method for adding such props is by using T21s, in essence these are a lot that's "attached" to a certain ID. This is what is included with the SFBT mod, for example the PEG stream FLUP has a straight piece of the stream added on top of the transparent network underneath. The 2D texture is simply for the preview piece and otherwise unused when it's placed.

    2 hours ago, IceDruid said:

    2. With the custom IDs for FLUP, it doesn't look like there's an option to build any except for straight paths. Is this correct,

    Indeed, the custom FLUPs are straight pieces only. Each new configuration requires a separate model/coding/pathing etc. The 6 custom tiles were included so players could have some flexibility. But like many such insightful addons, few people see to actually use them, as such they were never really expanded upon. Making new puzzle pieces is extremely complex and even requires adding RUL code to the NAM controller. Not for the feint of heart.

    2 hours ago, IceDruid said:

    3. I'm still not quite sure how to take my BMPs for the preview tiles and load them into the dat. If I try to insert just the 128x128 FSH as an ID (say 0x53E61809), I get an error. I thought that I could also insert all 5 at 0x53E61805 and then manually delete the first 4, but with ILives I didn't see a way to delete specific FSH files, only the entire group. What's the best practice for replacing preview tiles on these pieces?

    GoFSH has the option via its main interface (untick "make a scaled set of 5") or scripts not to create the MipMaps. But you can also remove them from a DAT using Reader. Just highlight all the files/entries you don't want, right click and select "remove file" to delete them manually.

    Share this post


    Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an Account  

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

    Register a New Account

    Sign In  

    Already have an account? Sign in here.

    Sign In Now


    • Recently Browsing   0 members

      No registered users viewing this page.

    ×

    Thank You for the Continued Support!

    Simtropolis relies mainly on member donations to continue operating. Without your support, we just would not be able to be entering our 15th year online!  You've really help make this a great community.

    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, so that we can help keep bringing SimCity players together to share our creations.

    Make a Donation, Get a Gift!

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

    stexcollection-header.png

    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