Closed riking closed 11 years ago
See issue #81, folder organization.
The purpose of author-named packages is work-in-progress developer workspace. Part of any and all creative endeavors is the generation of garbage. There are quite a few files in developer folders that represent dead code, and resources that either have no use yet, or may never have a use.
The proposed move causes all of those "It could be valuable one day" type pieces of source code and other resources to appear in the main folders, and as such is not a good idea.
I'll refactor much of the source that is currently a working part of the mod to colonies/src today.
PS: you might inspect the file RNG.java https://github.com/AngleWyrm/Colonies/blob/master/anglewyrm/src/RNG.java It's used in Utility.java https://github.com/AngleWyrm/Colonies/blob/master/anglewyrm/src/Utility.java
It provides a mod-wide random number generator that has an additional function, nextRadian() Utility.rng.nextRadian() is used in several search functions in the AI modules.
May I suggest the use of branches for testing projects?
I did in fact inspect RNG.java. It is an extension of Random, only providing one additional function.
return nextFloat()*2.0f * (float)Math.PI;
This would be better implemented as a static function in another class.
Perhaps you could say why another class would be better, and which class that would be?
It would be better because you're not creating a whole new class for one piece of functionality
Author-named packages are totally unnecessary.
The structure has been modeled after Forge and Bukkit.
This code will not compile; imports still need to be fixed.
For the future, there are several useless classes (like RNG) that will need to be removed.