i want the unit A to cost resources when i build it from a factory, then i want unit A to morph into unit B for free, and lastly i want unit B to be able to morph back into unit A for free...
this is exactly what i am trying to do
Ok, sorry, I had not understood that.
Yes, that being the case, what I said does not solve it.
And I agree madmanntis is right about your choices.
Hey, if the discount
after option does not suit you ... I guess you could sitll make a dirty hack of the other option (you know, the one where C costs money to produce but then it can freely morph to either A or B and between the later two).
Here's my take:
Produce unit C for say 100 gold. Unit C name is Swordman (I've chosen this one on purpose).
Unit C (Swordman) can morph for free to unit A (Swordsman - get the little difference?...
It is just an example but...).
Unit A (Swordsman) can morph into Unit B (Archer) for free.
Unit B (Archer) can morph into unit A (Swordsman) for free.
Of course, you would need your units C and A to have names that would enable you that kind of dirty "illusion"...
Alternatively, you could have unit C be called e.g. "Soldier" and unit A be called "Skilled Soldier" or something of the sort.
The
models,
images and
sounds folders of units A and C would be the exact same (link one of them to the other's) and only the respective XML's would differ.
While you wait for that discount
before morph to be implemented in megaglest or gae...