PDA

View Full Version : isStatic()



Tenian
December 3rd, 2008, 20:12
I am trying to create a module that has both static reference type data (i.e. a <library></library> structure) and non-static data (i.e. <npc></npc>).

I've tried various iterations to set the static to be false (<npc static="false"></npc> etc). And yet the isStatic() is still returning true.

I've stared at modules created via exporting, and the ones I am creating and nothing jumps out at me. It's probably something obvious.

Any help would be great.

I can post sections of a module or even a whole module as needed.

Tenian
December 3rd, 2008, 21:48
NM I found it.

Apparently if any node has a static (even static=false) indicator, then every node after it defaults to static.

Foen
December 4th, 2008, 06:37
Yup, static="true" sets the condition for a node and all of its children (which is usually a handy thing, rather than a bad thing).

Tenian
December 4th, 2008, 11:13
static = "false" doesn't appear to work. Even worse, it sets all the following nodes in the module to be static.


<foo static="false">
....
</foo>
<npc>
....
</npc>

will result in a static npcs. Changing it to:


<foo static="false">
....
</foo>
<npc static="false">
....
</npc>

Doesn't appear to help.

The only two options I found that worked are:


<npc>
....
</npc>
<foo static="false">
....
</foo>

= NPCs you can edit. Everything from <foo> onward is static

or


<foo>
....
</foo>
<npc>
....
</npc>

Nothing static