18.04.2016, 20:03
@valych I'm not great with architecture either, but I'm quite sure that one project with hundreds of files is not good. First of all, modules increase readability! You're looking for player stuff? Just check the player module and so on. Second, you can easily remove/add parts of your gm(and even do that at runtime with shoebill plugins).
As for them depending on each other, the biggest issue is that my CustomPlayer class has various methods, for example getVehicle which returns an instance of CustomVehicle, but that vehicle class has a method getDriver which returns a CustomPlayer object. A code example:
As for them depending on each other, the biggest issue is that my CustomPlayer class has various methods, for example getVehicle which returns an instance of CustomVehicle, but that vehicle class has a method getDriver which returns a CustomPlayer object. A code example:
Код:
// player api module public interface CustomPlayer { CustomVehicle getVehicle(); } // vehicle api module public interface CustomVehicle { CustomPlayer getDriver(); CustomPlayer[] getPassengers(); }