Thanks for the explanation. Just to be sure, here's my current interpretation:
- You've made a 3 x 2 room with floor tiles at these positions:
- {x = 959, y = 1001, z = 7}, {x = 958, y = 1001, z = 7}, {x = 957, y = 1001, z = 7}, {x = 959, y = 1002, z = 7}, {x = 958, y = 1002, z = 7},{x = 957, y = 1002, z = 7}
- It will be used as a vault, and it will be filled from right to left.
- You've chosen tiles to represent piles of gold. The gold tiles are:
- {14973, 14974, 14975, 14976, 14977, 14978}
- The vault won't always be full of gold, so you distinguish between tiles with gold, and "edge tiles" without gold.
- Since the vault is filled from R to L, you only need one edge tile, which is tile
- Vault graphics will be updated for each increment to the total that takes it over a "100K boundary" - e.g. at 100K, 200K, 300K, etc. After 600K, no further graphic updates will be made (but see below - we can do better than that
- Initial graphics state is two edge tiles at {x = 957, y = 1001, z = 7} and {x = 957, y = 1002, z = 7}, representing the range (0, 99,999)
I've probably left something out, but that's why even coders (who tend to hate documentation) are prepared to make written specs
Change or remove what's wrong, add what's missing.
A. At this point there are some obvious questions due to the graphics. BTW - feel free to choose the simplest option if you like - in part this is a lesson in specification as well as (hopefully) basic coding
1.
Will you always add two gold tiles at a time, so the edge is always two identical tiles side by side in the Y-axis? Your desription says you'll add one fold tile at a time, but that will produce an potentially ugly graphic effect.
Imagine tiles arrayed like this:
edge, gold, gold
edge, edge, gold
The second column won't look good - but it will still be clear where the gold is stored.
If you're making your own tile graphics, or if there are more available already, you could make more edge tiles: for example in the case above, two "diagonal edge" tiles at (1,1) and (2,2), and a plain floor tile at (2,1) would look better.
2.
Do you want to select gold tiles at random so you have some variation., or do you want them to represent more/less gold?
You could have e.g. three values: plain (lowest, 2 tiles); jewels (medium, two tiles); chest/sword (highest, two tiles)
B. And there's a logic question: do you want the vault to become bigger later (e.g. what if it was 4x4?), and if so, do you have the other tiles available already?
For this you'd need a full set of edge tiles (8 in total) The code for this would be different of course, but:
- It's always better to consider requirements for the next couple of steps before starting to code
- Don't be scared to talk about medium-term objectives - it doesn't mean you have build the final solution in one huge step
- Don't aim too high for the first cut - but don't try to steer the early design by hiding information from your coder. When a good coder realizes you've done this they will transfer off the project ...
- ... and there's a flip side: if your coder doesn't know how to make a simple, functioning, testable skeleton to start with, fire them