Game only supports up to mesh UNIT999.x

Have a feature request for SRU? Post here.

Moderators: Balthagor, Legend, Moderators

Post Reply
Nerei
General
Posts: 1354
Joined: Jan 11 2016
Human: Yes

Game only supports up to mesh UNIT999.x

Post by Nerei »

Please correct me if I am wrong but right now the game only supports up to mesh 999 . After that it starts to break from what I can tell picks the alphabetically first model in the meshes folder.

Would it be possible for the game to support a larger number of meshes so it goes to say 9999 or some other crazy-large number?
For UGBITS file maybe automatically look for and read from say UGBITS5 etc. if it calls for an ID not inside UGBITS1-4?

I mostly bring this up as for one modding on an existing UGBITS file already used by the Dev team is just a bad, messy option that should be avoided if at all possible.
Also if I keep releasing models in the 901+ region like I am doing right now I got a feeling it will not be that long before the 901-999 space is mostly filled.
User avatar
George Geczy
General
Posts: 2688
Joined: Jun 04 2002
Location: BattleGoat Studios
Contact:

Re: Game only supports up to mesh UNIT999.x

Post by George Geczy »

Nerei wrote:Please correct me if I am wrong but right now the game only supports up to mesh 999.
From what I can see it is true that this is a hard coded limit. I will investigate having this changed for the next update.

-- George.
MK4
Colonel
Posts: 488
Joined: Oct 08 2011
Human: Yes

Re: Game only supports up to mesh UNIT999.x

Post by MK4 »

Thank you, George! That would be great!
Nerei
General
Posts: 1354
Joined: Jan 11 2016
Human: Yes

Re: Game only supports up to mesh UNIT999.x

Post by Nerei »

George Geczy wrote:
Nerei wrote:Please correct me if I am wrong but right now the game only supports up to mesh 999.
From what I can see it is true that this is a hard coded limit. I will investigate having this changed for the next update.

-- George.
Any news on this?
User avatar
Balthagor
Supreme Ruler
Posts: 22083
Joined: Jun 04 2002
Human: Yes
Location: BattleGoat Studios

Re: Game only supports up to mesh UNIT999.x

Post by Balthagor »

Ticket 21312
Chris Latour
BattleGoat Studios
chris@battlegoat.com
User avatar
George Geczy
General
Posts: 2688
Joined: Jun 04 2002
Location: BattleGoat Studios
Contact:

Re: Game only supports up to mesh UNIT999.x

Post by George Geczy »

Nerei wrote:Any news on this?
In the next update the engine will support up to 4000 mesh numbers, in this ranges:

1 to 999 - current range
1000 to 1999 - reserved for engine use
2000 to 2999 - new range for unit meshes
3000 to 3999 - reserved for modder use (will not be used by BG)

-- George.
Nerei
General
Posts: 1354
Joined: Jan 11 2016
Human: Yes

Re: Game only supports up to mesh UNIT999.x

Post by Nerei »

George Geczy wrote:
In the next update the engine will support up to 4000 mesh numbers, in this ranges:

1 to 999 - current range
1000 to 1999 - reserved for engine use
2000 to 2999 - new range for unit meshes
3000 to 3999 - reserved for modder use (will not be used by BG)

-- George.
That is good news. If I might make a suggestion would it be possible to use the numbers
1-1024
1025-2048
2049-3072
3073-4096
?
okay the first 3 might not be that important but the last one might matter.
I am mostly suggesting this as the UGBITS files are in intervals of 256 so UGBITS12 (if my math is right) is covering 2817-3072 and thus would be a file used both by BG if you use the range 2817-3000 an any modders using range 3001-3072.


The only other thing that might be worth mentioning is that with the way UGBITS maps are cross compatibility quickly breaks even with 1000 spots as there is only 4-5 UGBITS maps but with only nandu and I even touching graphics as it is right now that is a concern for the future.
User avatar
George Geczy
General
Posts: 2688
Joined: Jun 04 2002
Location: BattleGoat Studios
Contact:

Re: Game only supports up to mesh UNIT999.x

Post by George Geczy »

Nerei wrote:That is good news. If I might make a suggestion would it be possible to use the numbers
1-1024
1025-2048
2049-3072
3073-4096
?
okay the first 3 might not be that important but the last one might matter.
I am mostly suggesting this as the UGBITS files are in intervals of 256 so UGBITS12 (if my math is right) is covering 2817-3072 and thus would be a file used both by BG if you use the range 2817-3000 an any modders using range 3001-3072.
Interesting point ... ugbits numbers ("picnums") are not necessarily a direct match to the mesh numbers, but I see now that by default we've made them almost always the same (probably to keep things easy to track). The idea was to have more re-use (for example, many picnums could refer to the same mesh but with different textures), but it turns out we rarely used this. In hindsight we probably could have used this more for "refit" and "upgrade" versions. Hmmm.

But I can see the benefit to keeping the picnums = meshnum default, which would mean, as you so wisely point out, that it would make sense to divide it up by ugbits boundary.

The only other thing that might be worth mentioning is that with the way UGBITS maps are cross compatibility quickly breaks even with 1000 spots as there is only 4-5 UGBITS maps but with only nandu and I even touching graphics as it is right now that is a concern for the future.
No easy way of resolving this through this manner. There is a plan to allow different mods to load custom UGBITS pages, that will hopefully resolve some of this.

-- George.
User avatar
George Geczy
General
Posts: 2688
Joined: Jun 04 2002
Location: BattleGoat Studios
Contact:

Re: Game only supports up to mesh UNIT999.x

Post by George Geczy »

Given Nerei's suggestions, here's the updated new breakdown:

1 to 999 - current range
1000 to 1023 - reserved for engine use
1024 to 1279 - reserved for engine use (Terrain)
1280 to 1535 - reserved for engine use
1536 to 3071 - new range for unit meshes
3072 to 4095 - reserved for modder use (will not be used by BG)

The number of UGBITS pages supported is increased to 16 from 4.

-- George.
Nerei
General
Posts: 1354
Joined: Jan 11 2016
Human: Yes

Re: Game only supports up to mesh UNIT999.x

Post by Nerei »

I admit my solution would not be ideal. It is basically trying to brute force it. If all else fails there is still the 1536-3071 range. And yes that equal number association is also the reason I suggested those numbers. I am probably a bit OCD with it.

Also you have to update the documentation for the default.picnums file at some point as I am sure there are some good options there that none but you know about.


Ultimately though I am just happy that there is support for more meshes. 901-999 is starting to get filled up with half done japanese stuff ^_^
Post Reply

Return to “Suggestions - SRU”