Re: [nbos] [AS] Hooks for VBScripting
Sam Orton
Wed Sep 19th, 2007

NBOS Support <> wrote: At 11:51 AM 9/18/2007, you wrote:
>If o.children = 0 then RandomSystem o, true appears to be a good script
>command, but it won't accept o.children as a valid data field. Any ideas?

I believe either o.ChildrenCount() or o.GetBodyCount() will do what
you're looking for. o.ChildrenCount() will return 0 if there's no child
objects, o.GetBodyCount() will return 1 if there's no children.

Excellent, thank you. Runs like a champ, does exactly what I'd hoped. next question: Is there a switch on the RandomSystem command to stop it renaming systems? Getting a script to do the drudge work for you is all very well, but it doesn't save you much if the search function won't find anything now because the names have all changed.



P.S. Once I get this running the way I want, I'll post the script commands so that anyone else who wants it can have a go. I don't feel like I can take credit for it, I cannibalized the first half of the script from the blazon generator and the last half from the random system generator. All it needed was to make it conditional.

"I do not feel obliged to believe that the same God who endowed us with sense, reason and intellect intended us to forego their use." - Galileo Galilei

Tonight's top picks. What will you watch tonight? Preview the hottest shows on Yahoo! TV.
Nbossoftware mailing list

Copyright © 2003-2007, NBOS Software. All rights reserved. 'Fractal Mapper', 'ScreenMonkey', 'Character Sketcher', 'Inspiration Pad', 'Fractal World Explorer', 'Goblin API', 'AstroSynthesis' are trademarks of NBOS Software. 'Dwarven Beserker' art by V. Shane.
Member contributed resources