mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-20 16:59:43 +00:00
Renaming for Better Schema
This commit is contained in:
1 parent
7202f74e78
commit
6f1a837296
34 files changed
+175
-175
No files matched your search
@@ -19,9 +19,9 @@ import kamkeel.npcs.controllers.data.ability.conditions.AbilityCondition;
|
||||
import kamkeel.npcs.controllers.data.telegraph.Telegraph;
|
||||
import kamkeel.npcs.controllers.data.telegraph.TelegraphInstance;
|
||||
import kamkeel.npcs.controllers.data.telegraph.TelegraphType;
|
||||
import kamkeel.npcs.entity.EntityAbilityBarrier;
|
||||
import kamkeel.npcs.entity.EntityAbilityDome;
|
||||
import kamkeel.npcs.entity.EntityAbilityPanel;
|
||||
import kamkeel.npcs.entity.EntityEnergyBarrier;
|
||||
import kamkeel.npcs.entity.EntityEnergyDome;
|
||||
import kamkeel.npcs.entity.EntityEnergyPanel;
|
||||
import kamkeel.npcs.util.FileNameHelper;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.Entity;
|
||||
@@ -2475,9 +2475,9 @@ public abstract class Ability implements IAbility, IAbilityAction {
|
||||
double maxZ = Math.max(caster.posZ, target.posZ) + searchRange;
|
||||
|
||||
AxisAlignedBB searchBox = AxisAlignedBB.getBoundingBox(minX, minY, minZ, maxX, maxY, maxZ);
|
||||
List<EntityAbilityBarrier> barriers = world.getEntitiesWithinAABB(EntityAbilityBarrier.class, searchBox);
|
||||
List<EntityEnergyBarrier> barriers = world.getEntitiesWithinAABB(EntityEnergyBarrier.class, searchBox);
|
||||
|
||||
for (EntityAbilityBarrier barrier : barriers) {
|
||||
for (EntityEnergyBarrier barrier : barriers) {
|
||||
if (barrier.isDead) continue;
|
||||
if (barrier.isCharging()) continue;
|
||||
|
||||
@@ -2488,10 +2488,10 @@ public abstract class Ability implements IAbility, IAbilityAction {
|
||||
if (AbilityTargetHelper.isAlly(caster, (EntityLivingBase) barrierOwner)) continue;
|
||||
}
|
||||
|
||||
if (barrier instanceof EntityAbilityDome) {
|
||||
if (isDomeBlocking((EntityAbilityDome) barrier, caster, target)) return true;
|
||||
} else if (barrier instanceof EntityAbilityPanel) {
|
||||
if (isPanelBlocking((EntityAbilityPanel) barrier, caster, target)) return true;
|
||||
if (barrier instanceof EntityEnergyDome) {
|
||||
if (isDomeBlocking((EntityEnergyDome) barrier, caster, target)) return true;
|
||||
} else if (barrier instanceof EntityEnergyPanel) {
|
||||
if (isPanelBlocking((EntityEnergyPanel) barrier, caster, target)) return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2502,7 +2502,7 @@ public abstract class Ability implements IAbility, IAbilityAction {
|
||||
* Check if a dome blocks an attack from caster to target.
|
||||
* Blocks when caster is outside and target is inside the dome.
|
||||
*/
|
||||
private static boolean isDomeBlocking(EntityAbilityDome dome, EntityLivingBase caster, EntityLivingBase target) {
|
||||
private static boolean isDomeBlocking(EntityEnergyDome dome, EntityLivingBase caster, EntityLivingBase target) {
|
||||
float radius = dome.getDomeRadius();
|
||||
|
||||
double cdx = caster.posX - dome.posX;
|
||||
@@ -2523,7 +2523,7 @@ public abstract class Ability implements IAbility, IAbilityAction {
|
||||
* Check if a panel blocks an attack from caster to target.
|
||||
* Checks if the line from caster to target crosses through the panel bounds.
|
||||
*/
|
||||
private static boolean isPanelBlocking(EntityAbilityPanel panel, EntityLivingBase caster, EntityLivingBase target) {
|
||||
private static boolean isPanelBlocking(EntityEnergyPanel panel, EntityLivingBase caster, EntityLivingBase target) {
|
||||
float halfW = panel.getPanelData().panelWidth * 0.5f;
|
||||
float halfH = panel.getPanelData().panelHeight * 0.5f;
|
||||
|
||||
|
||||
Reference in new issue
Block a user