Page 1 of 1

Do the number of token properties impact performance?

Posted: Mon Mar 27, 2017 7:51 am
by Zandel
Working on my own Pathfinder Framework, there are sooo many bonus types, just for skills alone, I will need over 300 properties. Just wondering if I put them all in if I am risking bloating the framework to the point of causing issues. MapTool Version: 1.3.b91

Re: Do the number of token properties impact performance?

Posted: Mon Mar 27, 2017 4:13 pm
by aliasmask
300 is not that bad, but I would recommend grouping them and putting them in either json or string property format for ease of readability and portability. Not everything has to be a "visible" token property. You can define "hidden" properties, those not defined in the token type by simply using setProperty in a macro.

Re: Do the number of token properties impact performance?

Posted: Mon Mar 27, 2017 4:30 pm
by Zandel
Yes, I plan on doing that, though you have to be careful with hidden properties because you can't give them a default value. I have to have an initialize token macro, to initialize all of the hidden properties each time I drag a new token in.

Re: Do the number of token properties impact performance?

Posted: Mon Mar 27, 2017 7:16 pm
by wolph42
to answer your topic question: check out the link in my sig on speeding up macros

Re: Do the number of token properties impact performance?

Posted: Mon Mar 27, 2017 8:43 pm
by Zandel
That was a very informative read thank you!

Re: Do the number of token properties impact performance?

Posted: Tue Mar 28, 2017 12:19 am
by aliasmask
Zandel wrote:Yes, I plan on doing that, though you have to be careful with hidden properties because you can't give them a default value. I have to have an initialize token macro, to initialize all of the hidden properties each time I drag a new token in.
Well, sort of. You could have a property that will initialize it the first time you mouse over the token.