Settings.xml Format

言語: JP EN DE FR
2010-06-21
New Items
users online
フォーラム » Windower » Support » Settings.xml format
Settings.xml format
Offline
Posts: 21
By Dunbar 2021-11-30 09:33:18  
Hi,

I am trying to understand the settings.xml a little bit and using config.load for a file like:
Code
<?xml version="1.1" ?>
<settings>
    <global>
        <param>true</param>
        <anotherparam>false</anotherparam>
        <items>
	        <item>Some Item</item>
		<item>Another Item</item>
        </items>
    </global>
</settings>


When loaded into the addon, the items table only has one value. I assume this is because it is using the xml element name "item" as the key, so duplicates are being overwritten. Is this the case, and is there anyway to using non-unique element names? Wouldn't be a big deal to use <item1>...<itemN> tags, but was curious. Thanks!
 Fenrir.Niflheim
VIP
Offline
サーバ: Fenrir
Game: FFXI
user: Tesahade
Posts: 453
By Fenrir.Niflheim 2021-11-30 09:52:54  
Yes, the tag name is used as the key for the table. Depending on what you are doing with the data there are ways to avoid explicitly giving each subtag in items a unique name.

This question would be better asked on our discord, in the development channel. https://discord.com/channels/338590234235371531/633140308850376714
Offline
Posts: 21
By Dunbar 2021-11-30 10:10:49  
Thanks. That channel appears greyed out to me in discord. Does it need an invite? thebeerbaron2218#8074 is my discord username.
 Fenrir.Niflheim
VIP
Offline
サーバ: Fenrir
Game: FFXI
user: Tesahade
Posts: 453
By Fenrir.Niflheim 2021-11-30 10:26:34  
Dunbar said: »
Thanks. That channel appears greyed out to me in discord. Does it need an invite? thebeerbaron2218#8074 is my discord username.

Just follow the instruction in the welcome channel, and add your self to the v4 dev role. the channel will be available once you have that role.
Log in to post.