Naming an Age

Help bring our custom Ages to life! Share tips and tricks, as well as code samples with other developers.

Naming an Age

Postby Whilyam » Wed Feb 17, 2010 7:23 pm

Cyan has a number of examples of Ages with names on the KI that differ from their filenames (Eder Kemo instead of garden01). How can I do that for my own Ages, and how difficult is it?
User avatar
Whilyam
 
Posts: 1023
Joined: Sat Sep 29, 2007 5:55 pm

Re: Naming an Age

Postby Tsar Hoikas » Wed Feb 17, 2010 10:10 pm

In xKI.py there are two functions that tansform the age names. I think they are called IFilterAgeName and IConvertAgeName. Each one is run on the age name under specific circumstances that I do not recall. D'Lanor probably remembers, being slightly more versed with the KI code in general than I am. I specialize more in the baton puzzle python :P
Image
User avatar
Tsar Hoikas
Councilor of Technical Direction
 
Posts: 1822
Joined: Fri Nov 16, 2007 9:45 pm
Location: South Georgia

Re: Naming an Age

Postby Chacal » Wed Feb 17, 2010 11:58 pm

That's a question for diafero.
Chacal


"The weak can never forgive. Forgiveness is an attribute of the strong."
-- Mahatma Gandhi
User avatar
Chacal
 
Posts: 2411
Joined: Tue Nov 06, 2007 2:45 pm
Location: Quebec, Canada

Re: Naming an Age

Postby diafero » Thu Feb 18, 2010 2:12 am

Yeah, Hoikas is right, it's an absolutely crazy hard-coded system. However I got fed up with that and integrated my own age and link management with these functions. So the age display name is now set by the AvailableLinks.inf file. The bad point is that it can hardly be changed after the age was released because the visible name is saved in the vault.

So, basically, all you need to do is clearly state the actual visible name of your age when you release it, I will then put it into the AvailableLinks.inf file. If you want to be really sure, you can PM me right after the release.
I prefer e-mails to "diafero arcor de" (after adding the at and the dot) over PMs.

"Many people's horizon is a circle with a radius of zero. They call it their point of view."

Deep Island Shard | Offline KI
diafero
Deep Island Admin
 
Posts: 2800
Joined: Mon May 05, 2008 5:50 am
Location: Germany

Re: Naming an Age

Postby Whilyam » Thu Feb 18, 2010 5:32 am

diafero wrote:Yeah, Hoikas is right, it's an absolutely crazy hard-coded system. However I got fed up with that and integrated my own age and link management with these functions. So the age display name is now set by the AvailableLinks.inf file. The bad point is that it can hardly be changed after the age was released because the visible name is saved in the vault.

So, basically, all you need to do is clearly state the actual visible name of your age when you release it, I will then put it into the AvailableLinks.inf file. If you want to be really sure, you can PM me right after the release.

Great. Thanks!
User avatar
Whilyam
 
Posts: 1023
Joined: Sat Sep 29, 2007 5:55 pm

Re: Naming an Age

Postby Tsar Hoikas » Thu Feb 18, 2010 7:21 am

Chacal wrote:That's a question for diafero.


Wow. Somehow in my insanity, I forgot that diafero develops the OfflineKI... I thought about D'Lanor since I recall him explaining it somewhere :\
Image
User avatar
Tsar Hoikas
Councilor of Technical Direction
 
Posts: 1822
Joined: Fri Nov 16, 2007 9:45 pm
Location: South Georgia

Re: Naming an Age

Postby diafero » Thu Feb 18, 2010 8:35 am

D'Lanor is also on the (relatively long) list of developers who contributed code to my Offline KI, so it's not completely off ;-)
I prefer e-mails to "diafero arcor de" (after adding the at and the dot) over PMs.

"Many people's horizon is a circle with a radius of zero. They call it their point of view."

Deep Island Shard | Offline KI
diafero
Deep Island Admin
 
Posts: 2800
Joined: Mon May 05, 2008 5:50 am
Location: Germany

Re: Naming an Age

Postby D'Lanor » Thu Feb 18, 2010 1:23 pm

Ok, I'll chime in then. ;) IMO the best way to name your age differently than its file name is to use the age instance name. That has to be done when you link to the age so the age writer usually has no control over it. I believe this is the name diafero is referring to when he says the name is written to the vault. The vault name cannot be changed afterwards (unless you delete the age and recreate it through a link with the proper age info).

Age instance names do not have to be unique. For instance both city and BaronCityOffice have an age instance name Ae'gura. And unlike age names the age instance names can have spaces and apostrophes.

At some point Cyan must have decided that age instance naming still was not flexible enough so they set up separate filtering systems in the KI (yes, two different ones :roll: ). This is the system which for example makes the bahro caves show up as ??? if you did not finish your prime ages.
"It is in self-limitation that a master first shows himself." - Goethe
User avatar
D'Lanor
 
Posts: 1980
Joined: Sat Sep 29, 2007 4:24 am

Re: Naming an Age

Postby diafero » Fri Feb 19, 2010 12:38 am

That's exactly what I meant, D'Lanor. It's also the name showing up while linking to the age in online environments (the old UU/Alcugs ones).
One could even say there is a 3rd naming system, used to display the name another explorer is in - as one can only read the age filename from the player info node, there needs to be yet another table transalting age filenames into age display/instance names. And of course there is the Nexus, which duplicates a lot of this to show the correct names in all categories.
You see why I added one central file to set this name in one place, and modified the Python everywhere to use it? ;-)
I prefer e-mails to "diafero arcor de" (after adding the at and the dot) over PMs.

"Many people's horizon is a circle with a radius of zero. They call it their point of view."

Deep Island Shard | Offline KI
diafero
Deep Island Admin
 
Posts: 2800
Joined: Mon May 05, 2008 5:50 am
Location: Germany


Return to Scripting

Who is online

Users browsing this forum: No registered users and 1 guest