There are many ways conceivable for how multi-square pieces would behave, differing in the details. In the Dev case it is especially troublesome for the AI that all occupied squares should be under attack; this means the legality of moves that capture it cannot be judged on their own merits, but require examination of the entire move list. This is a problem that transcends that of multi-square pieces, btw: you would also encounter it in variants that specify some piece can only be captured if it has multiple attackers.
I suppose one could nearly implement this through custom scripting in the existing I.D. code, with the xxxTinker routine, but in a rather complex way: the routine could test whether it is called for a new node by examining the node count, and when it is clear a variable for each Dev to record which of its components is attacked, and set up an empty array for moves. Each move hitting one of the Dev components would initially be rejected, but moved to the array of reserve moves. And the corresponding Dev component would then be marked as attacked.
After generating all moves it should then be tested which Dev has all its components attacked, and the shelved captures of such a Dev could then be appended to the official move list. This can currently only be done by writing a wrapper for the move generator routine. But perhaps an official interface should be provided for the user to add a custom routine for calling after move generation completes (e.g. xxxDone).
There are many ways conceivable for how multi-square pieces would behave, differing in the details. In the Dev case it is especially troublesome for the AI that all occupied squares should be under attack; this means the legality of moves that capture it cannot be judged on their own merits, but require examination of the entire move list. This is a problem that transcends that of multi-square pieces, btw: you would also encounter it in variants that specify some piece can only be captured if it has multiple attackers.
I suppose one could nearly implement this through custom scripting in the existing I.D. code, with the xxxTinker routine, but in a rather complex way: the routine could test whether it is called for a new node by examining the node count, and when it is clear a variable for each Dev to record which of its components is attacked, and set up an empty array for moves. Each move hitting one of the Dev components would initially be rejected, but moved to the array of reserve moves. And the corresponding Dev component would then be marked as attacked.
After generating all moves it should then be tested which Dev has all its components attacked, and the shelved captures of such a Dev could then be appended to the official move list. This can currently only be done by writing a wrapper for the move generator routine. But perhaps an official interface should be provided for the user to add a custom routine for calling after move generation completes (e.g. xxxDone).