The script would have to be modified to combine keywords from both character styles into one index entry.
Problem: how to make sure every index entry in language A is then correctly assigned to language B?
Apart from that: what's the sense of an index in a dictionary? A dictionary is actually an index of words already, because usually sorted alphabetically.
The problem you address is indeed a real one. Especially as the situation is somewhat more complicated. There are also entries of the form:
(word language A) (translation language B--FIRST MEANING) (translation language B--SECOND MEANING) (other stuff)
One other idea I had was therefore to use the tag-function:
(word language A) and (translation language B--FIRST MEANING) would both receive tag X
(word language A) and (translation language B--SECOND MEANING) would both receive tag Y
(that is, (word language A) would have two tags, one shared with first meaning and one shared with second meaning)
To generate the index at the end, I would then however need to be able to read out the content of tag X (word1 + meaning 1), tag Y (word1 + meaning 2), etc.
I assume that something like that should be possible. But have no competencies in scripting. So if anyone knows of some such script (or of course also any better ideas), that would be great. (If it does not do exactly that, but something similar, I may be able to modify it, but I cannot do it from the scratch.)
About the second point: I think it does make sense. The dictionary gives you extensive information about language A. But when you use it, you may do so in order to translate from A to B, or from B to A. If you are doing the latter, you'll need the index. (But of course you are right, the original dictionary is also some kind of index)