I have an issue in creating a datafile that's been bothering me for a while. I'll lay out the situation as best I can and see if anyone can offer a solution.
There is a leader ship that can carry a number of escort ships. Both the leader ship and the escort ships have a Leadership stat. The leadership of the leader ship is variable, and is set based on the selection count of an option, or by the selection of an admiral type character.
The leadership option (shLdr) uses the eval script:
unit.basestat[Ldr] = unit.option[shLdr].selection
Or the admiral unit sets the stat with the postlink script:
parent.basestat[Ldr] = unit.basestat[Ldr]
Now the tricky part is that the escort ships base their leadership stat on the stat of the leader unit, but form a separate squadron (squad). Also, if two of the leader type ships are squadron, then their follower escorts can squadron together.
I've tried using both the Leader/Follower mechanism and the attachment mechanism, but neither seems to work fully. I can get the attachment mechanism to set the leadership stat of the escort unit at the time of the attachment, but it doesn't update if the leadership stat is adjusted on the leader unit or the admiral type unit is added to the leader ship. And I simply could not figure out a way for the AB Leader/Follower mechanism to set the stat at all on the escort unit.
Any ideas, suggestions or questions?
There is a leader ship that can carry a number of escort ships. Both the leader ship and the escort ships have a Leadership stat. The leadership of the leader ship is variable, and is set based on the selection count of an option, or by the selection of an admiral type character.
The leadership option (shLdr) uses the eval script:
unit.basestat[Ldr] = unit.option[shLdr].selection
Or the admiral unit sets the stat with the postlink script:
parent.basestat[Ldr] = unit.basestat[Ldr]
Now the tricky part is that the escort ships base their leadership stat on the stat of the leader unit, but form a separate squadron (squad). Also, if two of the leader type ships are squadron, then their follower escorts can squadron together.
I've tried using both the Leader/Follower mechanism and the attachment mechanism, but neither seems to work fully. I can get the attachment mechanism to set the leadership stat of the escort unit at the time of the attachment, but it doesn't update if the leadership stat is adjusted on the leader unit or the admiral type unit is added to the leader ship. And I simply could not figure out a way for the AB Leader/Follower mechanism to set the stat at all on the escort unit.
Any ideas, suggestions or questions?