Class SubArea
java.lang.Object
tfagaming.projects.minecraft.homestead.models.SubArea
-
Constructor Summary
ConstructorsConstructorDescriptionSubArea(long id, long regionId, String name, UUID worldId, org.bukkit.block.Block point1, org.bukkit.block.Block point2, long playerFlags, SeRent rent, long createdAt) SubArea(long id, long regionId, String name, UUID worldId, SeBlock point1, SeBlock point2, long playerFlags, SeRent rent, long createdAt) SubArea(long regionId, String name, org.bukkit.World world, org.bukkit.block.Block point1, org.bukkit.block.Block point2, long playerFlags) -
Method Summary
Modifier and TypeMethodDescriptionlongintgetMaxX()intgetMaxY()intgetMaxZ()intgetMinX()intgetMinY()intgetMinZ()@NotNull StringgetName()long@NotNull SeBlock@NotNull SeBlock@Nullable RegionReturns the region by directly fetching with region ID from cache.long@NotNull StringReturns the region name safely by directly fetching with region ID from cache.@Nullable SeRentgetRent()longint@Nullable org.bukkit.WorldgetWorld()@NotNull UUIDbooleanisBlockInside(org.bukkit.block.Block block) booleanisBlockInside(SeBlock block) booleanisIntersecting(SubArea other) booleanisLocationInside(org.bukkit.Location location) booleanisLocationInside(SeLocation location) voidsetAutoUpdate(boolean autoUpdate) Toggle Auto-Update for caching.voidvoidsetPlayerFlags(long playerFlags) voidsetPoint1(@NotNull org.bukkit.block.Block block) voidvoidsetPoint2(@NotNull org.bukkit.block.Block block) voidvoidsetRegionId(long regionId) voidvoidsetWorldId(@NotNull UUID worldId)
-
Constructor Details
-
SubArea
public SubArea(long regionId, String name, org.bukkit.World world, org.bukkit.block.Block point1, org.bukkit.block.Block point2, long playerFlags) -
SubArea
-
SubArea
-
-
Method Details
-
setAutoUpdate
public void setAutoUpdate(boolean autoUpdate) Toggle Auto-Update for caching. Iftrue, any call for setters will automatically update the cache. Otherwise, only the instance of the class will be updated.- Parameters:
autoUpdate- Auto-Update toggle
-
getUniqueId
public long getUniqueId() -
getRegionId
public long getRegionId() -
setRegionId
public void setRegionId(long regionId) -
getRegion
Returns the region by directly fetching with region ID from cache.- Returns:
- The region if found,
nullotherwise.
-
getRegionName
Returns the region name safely by directly fetching with region ID from cache.- Returns:
- The region name if found,
"?"otherwise.
-
getName
-
setName
-
getWorldId
-
setWorldId
-
getWorld
@Nullable public @Nullable org.bukkit.World getWorld() -
getPoint1
-
setPoint1
-
setPoint1
public void setPoint1(@NotNull @NotNull org.bukkit.block.Block block) -
getPoint2
-
setPoint2
-
setPoint2
public void setPoint2(@NotNull @NotNull org.bukkit.block.Block block) -
getPlayerFlags
public long getPlayerFlags() -
setPlayerFlags
public void setPlayerFlags(long playerFlags) -
getRent
-
setRent
-
getCreatedAt
public long getCreatedAt() -
getMinX
public int getMinX() -
getMaxX
public int getMaxX() -
getMinY
public int getMinY() -
getMaxY
public int getMaxY() -
getMinZ
public int getMinZ() -
getMaxZ
public int getMaxZ() -
getVolume
public int getVolume() -
isBlockInside
-
isBlockInside
public boolean isBlockInside(org.bukkit.block.Block block) -
isLocationInside
-
isLocationInside
public boolean isLocationInside(org.bukkit.Location location) -
isIntersecting
-