2016-06-02 17:03:21 -07:00
|
|
|
package WayofTime.bloodmagic.api.iface;
|
|
|
|
|
|
|
|
import net.minecraft.block.state.IBlockState;
|
|
|
|
import net.minecraft.entity.player.EntityPlayer;
|
|
|
|
import net.minecraft.util.math.BlockPos;
|
|
|
|
import net.minecraft.util.text.ITextComponent;
|
|
|
|
import net.minecraft.world.World;
|
|
|
|
|
|
|
|
import javax.annotation.Nonnull;
|
|
|
|
import java.util.List;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Marks blocks as one that is documented.
|
2016-06-23 21:43:27 -04:00
|
|
|
*
|
|
|
|
* This documentation can be read by an
|
|
|
|
* {@link WayofTime.bloodmagic.item.ItemSanguineBook} (or child)
|
2016-06-02 17:03:21 -07:00
|
|
|
*/
|
|
|
|
public interface IDocumentedBlock
|
|
|
|
{
|
|
|
|
/**
|
2016-06-23 21:43:27 -04:00
|
|
|
* Provides the documentation to provide to the player. Usually a
|
|
|
|
* short'n'sweet description about basic usage.
|
|
|
|
*
|
2016-06-02 17:03:21 -07:00
|
|
|
* @param player
|
2016-06-23 21:43:27 -04:00
|
|
|
* - The EntityPlayer attempting to view the Documentation.
|
2016-06-02 17:03:21 -07:00
|
|
|
* @param world
|
2016-06-23 21:43:27 -04:00
|
|
|
* - The World interaction is happening in.
|
2016-06-02 17:03:21 -07:00
|
|
|
* @param pos
|
2016-06-23 21:43:27 -04:00
|
|
|
* - The BlockPos being interacted at.
|
2016-06-02 17:03:21 -07:00
|
|
|
* @param state
|
2016-06-23 21:43:27 -04:00
|
|
|
* - The IBlockState of the interacted Block.
|
|
|
|
*
|
|
|
|
* @return - A list of formatted ITextComponent to provide to the player.
|
|
|
|
* Provide an empty list if there is no available documentation.
|
2016-06-02 17:03:21 -07:00
|
|
|
*/
|
|
|
|
@Nonnull
|
|
|
|
List<ITextComponent> getDocumentation(EntityPlayer player, World world, BlockPos pos, IBlockState state);
|
|
|
|
}
|