Solved Multiple NMS

Discussion in 'Spigot Plugin Development' started by OhhhZenix, Apr 17, 2019.

  1. Use the Liskov Substitution principle. Hide your NMS usage behind abstraction (interfaces) and create different interface implementations for different NMS versions. Then, on startup, you could use dependency injection to pass the correct instance into the classes that need it.