Package Introductory
Packages are a helpful feature of Java and many other programming languages that will help a coder organize the workspace. The name and placement of a package relatively does not matter and is for the coder to organize the workspace.
You can create a package by clicking the small brown icon that is near the new java class button (you could also right click and hit new package). When you do this a menu type screen will open and ask you several things. The first bit of information it wants is the "Source folder" This folder is likely going to be Minecraft/common if you are working with Minecraft. The next part of information it would like is the name for your package. The package can be named whatever you wish however it is common to use this format.
Com.Username.ModName (Src folder = Minecraft/common)
Client.Username.ModName (Src folder = Minecraft/Src)
Another common way of organizing your packages would be like this.
Username.Com.ModName.Core (src folder = Minecraft/common)
Username.Com.ModName.Items (Src folder = Minecraft/common)
Username.Com.ModName.Entities (Src folder = Minecraft/common)
Username.Com.ModName.Blocks (Src folder = Minecraft/common)
Username.Client.ModName.Core (src folder = Minecraft/Src)
Note: The above is just an example and not an actual way to organize your packages. It simply shows that you can use packages to organize different types of class files such as Item and Block class files.
Note 2: The examples used above may not be in the exact format that the tutorials are written in. It is not that big of a deal, As mentions above packages are a way for the coder to organize code.
Note 3: While the examples above do use capital letters, it is never a good practice to use capitals in package names.
You can create a package by clicking the small brown icon that is near the new java class button (you could also right click and hit new package). When you do this a menu type screen will open and ask you several things. The first bit of information it wants is the "Source folder" This folder is likely going to be Minecraft/common if you are working with Minecraft. The next part of information it would like is the name for your package. The package can be named whatever you wish however it is common to use this format.
Com.Username.ModName (Src folder = Minecraft/common)
Client.Username.ModName (Src folder = Minecraft/Src)
Another common way of organizing your packages would be like this.
Username.Com.ModName.Core (src folder = Minecraft/common)
Username.Com.ModName.Items (Src folder = Minecraft/common)
Username.Com.ModName.Entities (Src folder = Minecraft/common)
Username.Com.ModName.Blocks (Src folder = Minecraft/common)
Username.Client.ModName.Core (src folder = Minecraft/Src)
Note: The above is just an example and not an actual way to organize your packages. It simply shows that you can use packages to organize different types of class files such as Item and Block class files.
Note 2: The examples used above may not be in the exact format that the tutorials are written in. It is not that big of a deal, As mentions above packages are a way for the coder to organize code.
Note 3: While the examples above do use capital letters, it is never a good practice to use capitals in package names.