[Code Enhancement] Bounding Area abstraction
WeAthFoLD opened this issue ยท 0 comments
There are currently LOTS of code in individual skills handling bounding area logics, with different shapes. This logic is very common and can be re-used.
Abstraction
A Bounding Area is a predicate to test whether an Vector3
is in the area.
Note: Use MC's Vec3
. It is more common. lwjgl/javax's Vector3
can't be used in server.
Implementation
There are some common implementations scattered throught the code, or required to be implemented:
- MC's
AxisAlignedBB
bounding area is directly used. - Ranged View Frustum: used in Meltdowner's
RayBarrage
skill. - Cylinder: specified by
begin
,direction
andrange
. One implementation can be found inRangedRayDamage
class. Can be used inGroundshock
.