Triggering options with code
Hi,
I am trying to set up a some-what complex unit structure, and I'd like to be able to use options to help define the unit structure. Basically, the unit can consist of 1-3 models. The user can either build their own unit, or select from pre-defined formations. When selecting the formation, I'd like to be able to add the correct models, and trigger the options on the models that correspond to the formation. I realize I could do this (maybe, anyway) with LOTS of custom tags, many (MANY) specific units, etc... This seems REALLY complex, and my data file will be huge and unwieldy... BUT... Is there a way I can do something like: IF (unit.option[formation_X].selection = 1) then SET unit.option[addModel1].selection = 1 SET unit.option[addModel2].selection = 1 SET unit.option[addModel3].selection = 1 SET unit.child[linked:model1].option[a].selection = 1 SET unit.child[linked:model1].option[b].selection = 1 SET unit.child[linked:model2].option[a].selection = 1 SET unit.child[linked:model2].option[c].selection = 1 SET unit.child[linked:model3].option[b].selection = 1 SET unit.child[linked:model3].option[c].selection = 1 ENDIF Or something like that, anyway... Thanks |
Please break it down into what you're actually trying to accomplish - in AB terms or english, rather than pseudo-code, I can't really understand your if...then.
In the meantime, I'd suggest looking in the authoring kit manual, tips and tricks section, chaining options. That sounds like the sort of thing you're trying to do. You'll probably have to make two versions of each option - one version is hidden, and becomes visible when selected by the option that selects a formation, and the other version is visible to the user for use in constructing units piece-by-piece. |
I think, from what you are describing, there is no simple way of doing this without resorting to what you were saying about lots of units with minor variations or a complex tag system. I would say from experience that which ever way you decide to go if you do then keep it as simple as possible otherwise the files become unweildy and maintenance a nightmare.
|
All times are GMT -8. The time now is 08:57 PM. |
Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.