No, this function is useless for this.
Problem is here:
Monster::isOpponent
This is not dynamic function, when monster see player and storage != sagaNumber then opponent return false, when player change storage, monster didn't see it.
You have add refresh when you change/add/set storage to...