diff --git a/src/main/java/gripe/_90/appliede/me/service/EMCStorage.java b/src/main/java/gripe/_90/appliede/me/service/EMCStorage.java index 7989dc0..aae1361 100644 --- a/src/main/java/gripe/_90/appliede/me/service/EMCStorage.java +++ b/src/main/java/gripe/_90/appliede/me/service/EMCStorage.java @@ -199,18 +199,19 @@ public long insertItem( if (mode == Actionable.MODULATE && mayLearn && totalInserted > 0) { source.player().ifPresent(player -> { - if (playerProvider != null) { + if (playerProvider != null && !playerProvider.get().hasKnowledge(what.toStack())) { addKnowledge(what, playerProvider.get(), player); + onLearn.run(); } }); source.machine().ifPresent(host -> { - if (machineProvider != null) { + if (machineProvider != null && !machineProvider.get().hasKnowledge(what.toStack())) { var node = Objects.requireNonNull(host.getActionableNode()); var player = IPlayerRegistry.getConnected(node.getLevel().getServer(), node.getOwningPlayerId()); addKnowledge(what, machineProvider.get(), player); + onLearn.run(); } }); - onLearn.run(); } return totalInserted;