Skip to content

Commit

Permalink
Fixing some javadoc issues for release
Browse files Browse the repository at this point in the history
  • Loading branch information
ProgrammerDan committed Oct 2, 2019
1 parent e30c833 commit 07ccdf5
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 27 deletions.
4 changes: 2 additions & 2 deletions src/main/java/com/github/devotedmc/hiddenore/BlockConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ public boolean checkBlock(Block check) {
* Allows check against an expanded list of valid blocks that ores can generate in -- companion blocks, effectively.
* For instance, if you separately configure stone types but want generation in stone of all types;
*
* @param check
* @return
* @param check the block to check
* @return true if we can generate into this block
*/
public boolean checkGenerateBlock(Block check) {
if (checkBlock(check)) return true;
Expand Down
14 changes: 7 additions & 7 deletions src/main/java/com/github/devotedmc/hiddenore/DropConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -138,12 +138,12 @@ public double getXPMaxAmount(String biome) {
/**
* Gives even chance of any amount.
*
* @param drop
* @param biome
* @param modify modification to drop based on tool
* @param biome the biome at play
* @return Items that can be rendered.
*/
public List<ItemStack> renderDrop(String biome, ToolConfig modify) {
/** multipliers **/
/* multipliers */
double min = getMinAmount(biome) + (modify != null ? modify.getMinAmountModifier() : 0.0);
double max = getMaxAmount(biome) + (modify != null ? modify.getMaxAmountModifier() : 0.0);
double amount = (min == max) ? min : (double) ((max - min) * Math.random() + min);
Expand All @@ -163,8 +163,8 @@ public List<ItemStack> renderDrop(String biome, ToolConfig modify) {
/**
* Gives even chance of any amount.
*
* @param modify
* @param biome
* @param modify modification to drop based on tool
* @param biome the biome at play
* @return Items that can be transformed.
*/
public List<ItemStack> renderTransform(String biome, ToolConfig modify) {
Expand All @@ -188,8 +188,8 @@ public List<ItemStack> renderTransform(String biome, ToolConfig modify) {
/**
* Gives chance to drop XP
*
* @param biome
* @param modify
* @param biome the biome at play
* @param modify the tool config to modify XP
* @return XP to drop
*/
public int renderXP(String biome, ToolConfig modify) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public class PlayerStateConfig {
/**
* All states are applied successively
*
* @param player
* @param player the player to apply adjustments to
* @return value 0+ indicating adjustment to chance
*/
public double statusRate(Player player) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ public BlockBreakListener(HiddenOre plugin) {

/**
* Core method of interest, captures block breaks and checks if we care; if we do, continue
*
* @param event The break event to check
*/
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onBlockBreak(BlockBreakEvent event) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public ExploitListener(HiddenOre plugin) {
* for a world. So to counter-balance, on each extension we track the location of the blocks and increment their Y
* counters.
*
* @param event
* @param event the piston event
*/
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
public void onPistonExtend(BlockPistonExtendEvent event) {
Expand All @@ -60,7 +60,7 @@ public void onPistonExtend(BlockPistonExtendEvent event) {
/**
* Should cover even more clever implementations involving sticky pistons to game things.
*
* @param event
* @param event the piston retract event
*/
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
public void onPistonRetract(BlockPistonRetractEvent event) {
Expand All @@ -85,7 +85,7 @@ public void onPistonRetract(BlockPistonRetractEvent event) {
/**
* Catch block placement directly.
*
* @param event
* @param event block place event
*/
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
public void onPlacingThings(BlockPlaceEvent event) {
Expand All @@ -104,7 +104,7 @@ public void onPlacingThings(BlockPlaceEvent event) {
*
* TODO Issue#20: Support mining via TNT?
*
* @param event
* @param event explode event
*/
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
public void onExplodingThings(BlockExplodeEvent event) {
Expand All @@ -120,7 +120,7 @@ public void onExplodingThings(BlockExplodeEvent event) {
/**
* Prevent gaming by dropping sand/gravel/gravity blocks
*
* @param event
* @param event Change Block event
*/
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
public void onFallingThings(EntityChangeBlockEvent event) {
Expand Down Expand Up @@ -148,7 +148,7 @@ public void onFallingThings(EntityChangeBlockEvent event) {
*
* Credit for basic generator detector to fireblast709 (https://bukkit.org/threads/blocking-cobblestone-generators.120924/)
*
* @param event
* @param event block from to event
*/
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
public void onGeneratingThings(BlockFromToEvent event) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@ public class WorldGenerationListener implements Listener {

/**
* When creating, pass in a config with three sub-elements. Now supports UUID reference of world.
* <br/>
* <br>
* <code>
* world: world_name (or UUID)
* replace:
* - IRON_ORE
* - REDSTONE_ORE
* with: STONE
* </code>
* <br/>
* <br>
* This should be specified per world.
*
* @param config The world-specific config.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -303,8 +303,8 @@ public void saveMap() {
/**
* This has a specific purpose of tracking a generation of an ore. For breaks or manipulations, use trackBreak.
*
* @param loc
* @return
* @param loc the location to track gen
* @return true if new gen, false otherwise
*/
public boolean trackGen(Location loc) {
if (!Config.isMapActive()) return true;
Expand Down Expand Up @@ -368,8 +368,8 @@ public boolean trackGen(Location loc) {
*
* As of 1.5.3, checks the recent list for a match, just in case.
*
* @param loc
* @return
* @param loc the location to check
* @return true if ok to gen, otherwise false
*/
public boolean testGen(Location loc) {
int j = recentPtr;
Expand Down Expand Up @@ -422,9 +422,8 @@ public boolean testGen(Location loc) {
*
* Basically, once a block is exposed it doesn't transform.
*
* @param loc
* @param exp TODO
* @return
* @param loc the location to check after a break
* @param exp expand to nearby layers/chunks?
*/
public void postTrackBreak(Location loc, boolean exp) {
if (!Config.isMapActive()) return;
Expand Down Expand Up @@ -495,8 +494,8 @@ public void postTrackBreak(Location loc, boolean exp) {
* Tracks a first order break or manip.
* Locks that location from generating new drop opportunities or from transforming.
*
* @param loc
* @return
* @param loc the location to check
* @return true if OK to break, false otherwise
*/
public boolean trackBreak(Location loc) {
long initChunk = 0l;
Expand Down

0 comments on commit 07ccdf5

Please sign in to comment.