Large child list in config

edited March 2014 in Help request
I want to implement a sort of "destructable object", consisting of X subobjects that act as one, controlled by a parent when solid and controlled individually when disintegrated. How would I go about doing that in the config? Since X might be large, writing out a child list doesn't seem right.

Thanks in advance...


  • edited March 2014
    Hi luffe_gaas,

    I think we'll need a bit more details to see what would work best in your case.

    The actual theoritical limit of elements in a config list is 65535 items.
    That being said, the buffer used for parsing is only 8kb, so you would probably only be able to fit a few hundreds items per list.
    Lastly, handling a list with hundreds or thousands of items would yield poor performances when getting elements as individual elements are not indexed within a list.

    That being said, there are a few other ways of doing it, either in config, by chaining ChildList, for example, or programmatically by creating the whole hierarchy at runtime using code and/or commands. We should be able to help more when we get more details about the use and the "size" of those destructible objects.

    As a side note, do you intend to be able to destroy parts individually or is it only for blowing up the whole object in one shot?
    What we traditionally do, for performance reasons, is to have 2 versions of destructible objects: one made of one piece and the exploded version that is swapped upon destruction.
  • edited March 2014
    Yes, of course, object swapping, doh. Still getting used to the config system so I was overcomplicating things in my late night brain fart. Got it working now.

    What I'm doing is making an object that will explode to a particle state where I can control the particles arbitrarily as well as the opposite, re-assembling from particle state to solid.

    Thanks for the prompt response!
  • edited March 2014
    My pleasure. I'm glad you got it working.

    Don't hesitate if you have any other questions or if you want to tell us more about your project. ;)
Sign In or Register to comment.