Why is there a limit to how much tiles one tileset can have?

I recently started to work on a project and found some tiles I want to use. But thats when i ran into some trouble. that being a limit to the amount of tiles a tileset could hold. I had tried to put most of the things like different roofs and walls
togheter but at the limit of tiles the image is just cut off.
Why is there a limit? To preserve performance - uncompressed images are one of the most RAM-intensive things your game will deal with. You can pretty easily look up threads from people using parallax mapping (the entire map is an image), and they accidentally make it too large and their game starts stuttering or crashing.

Most people end up with several slightly different versions of each tileset with whatever things you need for a specific map. You can also save space on your tilesheets by making some things events with images or by using doodads.
Question:
Are you going to use all of the roofs and walls variants in a single map?
Question:
Are you going to use all of the roofs and walls variants in a single map?
If I could i would, I had this buzzling city with an festival in mind but I soon found out there was not enough tilesets
You could always have different parts of the city load as different maps. I find large maps pretty overwhelming most the time personally.
You can learn to parallax map. Then you can add as many tiles as you want anywhere you want.
To protect you from yourself. 🙂
Question:
Are you going to use all of the roofs and walls variants in a single map?
in my case, it's not so much about actually "using alle of [...]" at the end of my map,

but more about having them actually available during the mapping process, so, that i can choose on the fly what i actually need where ...

and the only "solution" the engine currently gives me are to:
1] split every single image into it's parts, to use them as doodads

which is a realy time consuming hassle
(the only program, i have found for that splits it into equal sizes ... without actually retaining stuff like 1x2 plants or 4x4 beds etc ... and it gives me a quality loss during the splitting process ... which also is realy bad)

and 2]
to manually recreate my entire tileset, everytime i want to change the tiniest detail within my map (which again is a tediouse hassle)

both of these "solutions" massively disrupt my workflow, though ...


if the maker would at verry least give me a program at hand,
to create something like a "master file" and then just drag and drop the tiles needed into the individual tilesets

or, if it would actually allow me, to choose from every tile i have available [while automatically creating the tileset accordingly] ... it would be so much more enjoyable and easyier to work with ...
If I could i would, I had this buzzling city with an festival in mind but I soon found out there was not enough tilesets
That is a fair answer.
Now I'm going to answer your question. We are going to use the case that you want to use more roofs and walls.

This is a bit technical, so brace yourself.

But before I answer your question, first we need to know how tileset is actually handled in-game. Each tileset has its own index. Starting from Index 0, it is from the top left in Tile B, in total it has 254 tiles. We have non-auto tile up to tile E, that's 4 tilesets. So the number goes up to 1024.

Up to this point, it is very straightforward. The tiles have no variant. It renders exactly like that. Theoretically, the engine could add more tiles past tile E, because index number 1024 up to 2048 is unused. But for some reason, they didn't use it.

From index 2048 onwards, things are getting wild. This is where the auto tiles are present. From the top left of A1 tiles, it starts from 2048 and it has 48 variants (with the 47th and 48th variants being exactly the same, but we rounded up because... uh computer uses binary). This variant comes from the fact that auto tiles change depending on the surrounding tiles. So, a single tile in your editor can have an index of 2048 to 2092.

The treatment for tiles A1 and A2 is pretty much the same. Each tile can have 48 variants. And the code to handle is similar. The walls and roofs (A3 and A4 tile) however, have a different treatment (I haven't fully decoded how it works though). And thus the programmer can only specify the index range of which the engine should render the roof or the wall. (TLDR, different index range, different treatment. They hardcoded it). Thus, the auto tiles for roofs and walls are limited.

Tile A5, however, was treated exactly like tile B to tile E. But it is there for automatic layering (it is placed on the bottom, while tile B to tile E is placed on top).

In the past, RPG Maker XP allow you to use a very long tileset so you can use as many tilesets as possible. But RMXP has very few auto tiles. So you have to put everything manually. However, knowing this, most users just use the very long tiles for the sake of "convenience". This could affect the loading time and memory usage, despite the fact the map might not use most of the tiles.

Hope this answers your question.

EDIT:

but more about having them actually available during the mapping process, so, that i can choose on the fly what i actually need where ...
Yep, your answer is more like "for convenience"
But in game dev. "convenience" is usually evil. Because it makes you disregard optimization.
Granted, tilesets might not have much impact. But something like "I'm gonna put all resources in my project, just in case I need them" and then proceeding to ship a 2 GB game because you forgot to remove a lot of unused assets doesn't sound very good.
You got the technical explanation above, but in case you have problems with that, here is a (very) simplified short one:

The computer needs to remember which tile is placed where on a map. To do this, he has to reserve a number space in the grid of the map that will be filled with the ID for the tile.
Think of this like a mathematical/square grid in a notebook where you pencil in the numbers.

Now the higher the ID can go, the more space is needed to be reserved to hold that number - like you cannot place the number 123 in a space that can only hold two numbers from 0-9, you'll need three spaces for 123.

And it doesn't matter if a number is used or not, if it exists there needs to be space on the map.
But each space reserve will drain your computer of processing power - reserve too many for them and your game will lag.


So the programmer have to make a decision on how many IDs (or different tiles) they allow - and once that number is set for whatzever reason it is impossible to add more tiles because the numbers are all full.

What you need to do is to make different tilesets for different maps - you won't need dozens of library shelves for a farmer home, so have one tileset for the library map with a dozen variants of book shelves and another tileset for peasant homes with cooking place and so on.
to create something like a "master file" and then just drag and drop the tiles needed into the individual tilesets
Yep, your answer is more like "for convenience"
you call it convenience,
i call it undisrupted (and thus faster and less intrusive) workflow
[which - in the end of the day - also leads to better visualisation of my ideas, since i'm not getting pulled out of my thoughts at every single step]

But in game dev. "convenience" is usually evil. Because it makes you disregard optimization.
in my opinion, there is no such thing as "evil", when it comes to things like convenience,
also - like i said - these two issues don't have to automatically rule each other out,

if - for example - the program would give me accec, to my entire set of tiles during development,
would give me small (but visible) "warnings" at certain treashholds and then cut the stuff down (i.E creates a mix of tileset and doodads based on the used tiles for each map)

it could essentially have all 3 of the positives:
- uninteruptive / convenience during development
- optimized for the player and
- the freedom for the dev, to actually choose between his freedom vs the finished products optimization ...

becouse yes, i can create a game with nothing more then a pen and paper ... would be way more optimized and bugfree, then anything, i could ever make with a computer ... but there's a reason i chose, to use the "convenience" ... you know,


that said, thanks turan,
that might actually be worth a look at
it could essentially have all 3 of the positives:
There is an old saying among engineers - it goes somewhere like "Cost, Reliability, Efficiency - choose two of them to maximize and the third will go worse".
In your case, if you get everything you want you would also need to pay far too much both for the computer top handle the program, and for the programmers to write (and bughunt/optimize) it.
I get a lot of mileage out of my custom E sheets. Simply by remixing the tilesets, and adding a few elements from one sheet specific to that map, I never feel like I run out of variation.
To prevent performance issues m8.
if - for example - the program would give me accec, to my entire set of tiles during development
My "entire set of tiles" comes in at over 9GB - I've collected and made a lot. Searching through that amount while mapping would be far more disruptive of my workflow than deciding beforehand what I need.

I find that having to be selective is not only good for maintaining the visual coherence of a map, but also forces me to clarify upfront what I want this map to look like. It will then only be an occasional tile that I would need to stop and add to the tile set.
okay, so, for you it works better, to pre-select exactly and put it into limited tilesets beforehand
meanwhile, for me it would work better, to have different cathegories containing all of my respective elements from that cathegory

that maybe, becouse i don't make my own tiles and only work with, what the makers, humble's, dlc's and forum edit's give me at hand ... (which is nowhere even near 9 gb size)

or, becouse i already pre-select, the tiles i actually can use for my game
[i mean, certain styles don't mash together at all, right]


so, shouldn't the engine give us the capability, to choose for ourselfs,
which of these possible paths we would like to take?

becouse again, i don't see, why these things would have to rule each other out ...
if i could swip swap my tiles in engine on the fly during mapping,
it doesn't have to prevent you from pre-arranging your tiles, before you start mapping, doe's it,

these are not mutually exclusive to each other ... you know


becouse, in the end of the day, what works for you may not work for others,
and what works for others may not work for you
I'm not sure that a discussion is truly being asked for here. The thread title asked "Why is there a limit..." You have been told why. Yet, whatever people say, they are, in your opinion, wrong. Whether it be because of the programming limitations from the sort of price that people are willing to pay for the engine, the pitfalls from a development perspective and the other opinions put here. It seems to me that there is only one answer you're prepared to hear, one solution only that would suit you. Which is fine; but you can't insist people agree with you.

As what you want cannot be done and the developers won't be providing it, I think I'll bow out of what is now a somewhat pointless thread.

Good luck with your project.
To me this is like asking why you could buy a file cabinet which is just one huge drawer instead of five drawers. While you may prefer it, I don't think it's a rational desire.
more like asking, why you would put your 10 file cabinets into 20 different rooms,
so, that you have to walk through your entire building, everytime you need anything from them

instead of just putting them all against the wall in your office ...

Original thread: https://forums.rpgmakerweb.com/threads/why-is-there-a-limit-to-how-much-tiles-one-tileset-can-have.158382/