I don't have MV in front of me now so I can't check, but if _equips is an array, you would have to do
$gameActor(1)._equips = $gameActor(2)._equips.clone() and consider that I might have some syntax errors in there.
However, I wonder if just assigning like that will lose the items that the first actor already had equipped. The Change Equipment command would first unequip the old item then equip the new item. If you just clone the whole array, I'm not sure it would put the old equipment back into inventory.
Are you using any plugins that might change item behavior? I ask cause if you use any independent item plugins, the clone solution will likely cause other issues.
Pretty much all of this stuff is over my head, so I can't really troubleshoot--only blindly try suggestions.
If the code itself looks right, then maybe it IS another of the issues mentioned above.
Thanks for the help.
If I can't get it working, then I guess I'll just manually unequip the characters and then throw up a text message reminding the player to re-equip everything 😅
Sorry, I guess it's ambiguous.
In my game, "Theodros" (Actor 7) grows up, which is represented by "Theodros" (Actor 16).
So the event is supposed to add Actor 16 to the party, transfer Actor 7 equipment to Actor 16, and then remove Actor 7.
When I test it, Actor 16 still has no equipment at the end. (He should have the sword and armor Actor 7 had)
how did you give actor 7 the equipment before the event?
And I strongly suggest to at least temporarily give all actors different names. You can rename them before deployment or before distributing any demos, but while you're developing the game the names should be different (for example "Theodros (young)" and "Theodros (adult)", just to prevent yourself from mistaken the commands because they look identical in the editor.
EDIT:
Error found. you're giving the actor 7 (first actor) the equipment worn by actor 16 (second actor) with your script command. Assignment commands (=) always means the first variable gets the data from the second.
but your description above said that you want to give actor 16 the equipment from actor 7, that means you'll have to switch the numbers in the script command
For my test, Actor(7) has starting equipment--a sword and body armour.--and Actor(16) has nothing.
I tried 7 and 16 both ways in the script, but neither work :rsad:
I kept both Actor(7) and Actor(16) in the party for the test. After the script, Actor(7) still has his sword and armour, and Actor(16) still has nothing.
Well, if the code had worked, it would've been easier, since the equipment is the only constant I wanted.
If I'm stuck, I guess I could do it with changing graphics, but would then need to manually adjust the old skills to the new ones I have set under the Grown Up Actor...
... Or, I guess you're saying that I could move all those Grow-Up-Actor-Skills and Traits into a Class instead?... That might work.
Thanks for the suggestion. I'll resort to it if this can't be solved with a quick Script.