@Miseryfactory77 all the code go into the passive state. The <custom passive condition> will be the trigger to the passive state : if false, the state isn't apply to your battler, and if true, then it apply.
Then next part of the code is a <custom apply effect> of the state : when the state apply, you check who's the battler who have the state, and in function he will learn the right skill.
When the shard is unequiped, the condition become false, and the <custom remove effect> will remove the skill the battler have learned.
I hope it's not confusiong. Here, the state is what check if equipe, give the skill and remove the skill.
Code:
<custom apply effect>
if (user.id==x){
user.learnSkill(x);
} else if (user.id==y){
user.learnSkill(y);
}
</custom apply effect>
The state is the same for every battler : one state per shards. That's also why your state have to check who's the user, and give the proper skill.