.com.unity Forums

.com.unity Forums (http://forum.shrapnelgames.com/index.php)
-   Scenarios, Maps and Mods (http://forum.shrapnelgames.com/forumdisplay.php?f=146)
-   -   Max mod nation description length? (http://forum.shrapnelgames.com/showthread.php?t=44045)

Stavis_L September 30th, 2009 12:34 PM

Max mod nation description length?
 
Does anyone know if there's a maximum length for the #descr command for nation modding, and if so, what that limit is?

My description keeps getting chopped off, and I'm not sure if it's due to bad formatting or exceeding a length limit; I know I'm well short of various vanilla nation description lengths, and it's not breaking at a "usual" length like 1024 chars or anything (not in front of the game at the moment, but it's something like 650 chars where it's cutting off for me presently.)

Also, the mod manual describes the syntax as
HTML Code:

#descr "<nation name>"
, but I assume the correct syntax is just
HTML Code:

#descr "<description text>"
as it seems to not like the 2nd argument.

...and, as long as I'm here, anyone aware of character limits for the other modding name/brief/descr(ription)/summary commands?

Burnsaber September 30th, 2009 01:43 PM

Re: Max mod nation description length?
 
Do you have a quote of some sort in the description text, perhaps closed with (") signs? I've had that happen to me many times.

Stavis_L September 30th, 2009 04:55 PM

Re: Max mod nation description length?
 
No, no stray double-quotes. I'm using a programming font to make sure things like that stand out (but I verified with a character search.) There is a single-quote in the text, but it's not aligned with the break.

lch October 3rd, 2009 05:47 AM

Re: Max mod nation description length?
 
Here are the limits for nation modding:

#name: 36 characters
#epithet: 36 characters
#flag: 2500 characters (for the filename)
#descr: 2500 characters
#summary: 500 characters
#brief: 500 characters

These limits are from the parser, per-nation. There might also be a global limit to the descriptions as well, I think I ran into that myself when preparing combined mods for my mod nation games.

Burnsaber October 3rd, 2009 06:03 AM

Re: Max mod nation description length?
 
Quote:

Originally Posted by lch (Post 713104)

These limits are from the parser, per-nation. There might also be a global limit to the descriptions as well, I think I ran into that myself when preparing combined mods for my mod nation games.

Nein! Nooo! Eiii! Inte!

First I learn that there's a limit on added spells and I had to scrap all sorts of cool ideas for the CPCS. Now max lenght descriptions (I hit the character limit often) can limit mod compactibility! Ugh. I'll have to learn to write more to the point I guess.

Tomorrow I'll learn that there is a limit on mod-image pixels and I'll have to make all my sprites 50% smaller.

Foodstamp October 3rd, 2009 11:10 AM

Re: Max mod nation description length?
 
Quote:

Originally Posted by lch (Post 713104)
Here are the limits for nation modding:

#name: 36 characters
#epithet: 36 characters
#flag: 2500 characters (for the filename)
#descr: 2500 characters
#summary: 500 characters
#brief: 500 characters

These limits are from the parser, per-nation. There might also be a global limit to the descriptions as well, I think I ran into that myself when preparing combined mods for my mod nation games.

I play with a TON of mod nations enabled at the same time and I have not noticed a global limit. It may be possible I have not hit the cap yet and if that is the case, it must be VERY high.

lch October 3rd, 2009 11:30 AM

Re: Max mod nation description length?
 
Quote:

Originally Posted by Foodstamp (Post 713119)
I play with a TON of mod nations enabled at the same time and I have not noticed a global limit. It may be possible I have not hit the cap yet and if that is the case, it must be VERY high.

The game doesn't crash in that case, it just doesn't include the nation descriptions anymore. If I recall correctly then first all the new unit and then spell descriptions are added, and then the nation descriptions. When preparing one all-mod-nations megagame I ran into each of these limitations, which required me to shorten some of the description texts. I'd have to look through old IRC logs to be able to tell specifics. It was a couple of patches ago, too, though, so the situation might be better now.

Burnsaber, there are limitations to everything, everywhere. :)

Foodstamp October 3rd, 2009 05:30 PM

Re: Max mod nation description length?
 
Well that makes me sad in the pants. I imagine by the time I retire, I will have every nation spot loaded with mod nations ;). I can do without descriptions I guess :D

Stavis_L October 7th, 2009 09:50 PM

Re: Max mod nation description length?
 
Quote:

Originally Posted by lch (Post 713104)
Here are the limits for nation modding:

#name: 36 characters
#epithet: 36 characters
#flag: 2500 characters (for the filename)
#descr: 2500 characters
#summary: 500 characters
#brief: 500 characters

These limits are from the parser, per-nation. There might also be a global limit to the descriptions as well, I think I ran into that myself when preparing combined mods for my mod nation games.

Hrm...well, I replaced my text with a block of lorem ipsum, and it seems that #descr (for nations) is actually limited to only 999 characters. However, some of the vanilla nations (e.g. LA Caelum) clearly exceed this, so perhaps you found the size of the in-game buffer, and something else is trimming the input to a smaller length prior to display?

I've only got my one mod that I'm working on installed, so it's presumably not a global limit being exceeded.

Perhaps I should report this as a bug?

lch October 8th, 2009 03:12 AM

Re: Max mod nation description length?
 
Quote:

Originally Posted by Stavis_L (Post 713827)
Hrm...well, I replaced my text with a block of lorem ipsum, and it seems that #descr (for nations) is actually limited to only 999 characters.

JK has a habit of limiting things at the value 999 (ex.: spell slots, damage), so it may very well be that input strings are limited by that amount.

Quote:

Originally Posted by Stavis_L (Post 713827)
However, some of the vanilla nations (e.g. LA Caelum) clearly exceed this, so perhaps you found the size of the in-game buffer, and something else is trimming the input to a smaller length prior to display?

As I said, I looked at the parser, but maybe the input from mods is indeed limited artificially by a greater amount than what the ingame limits are, yes.

Quote:

Originally Posted by Stavis_L (Post 713827)
Perhaps I should report this as a bug?

It's not a bug, you just found out the real limit. There will always be a limit, anyway.


All times are GMT -4. The time now is 09:29 AM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2025, Shrapnel Games, Inc. - All Rights Reserved.