|
|
|
@ -10,10 +10,12 @@
@@ -10,10 +10,12 @@
|
|
|
|
|
package engine.devcmd.cmds; |
|
|
|
|
|
|
|
|
|
import engine.Enum; |
|
|
|
|
import engine.collision.Mesh; |
|
|
|
|
import engine.devcmd.AbstractDevCmd; |
|
|
|
|
import engine.gameManager.BuildingManager; |
|
|
|
|
import engine.objects.*; |
|
|
|
|
|
|
|
|
|
import java.awt.geom.Point2D; |
|
|
|
|
import java.lang.reflect.Field; |
|
|
|
|
|
|
|
|
|
public class RegionCmd extends AbstractDevCmd { |
|
|
|
@ -37,7 +39,6 @@ public class RegionCmd extends AbstractDevCmd {
@@ -37,7 +39,6 @@ public class RegionCmd extends AbstractDevCmd {
|
|
|
|
|
Regions region = ((AbstractCharacter)target).region; |
|
|
|
|
if (region == null) { |
|
|
|
|
this.throwbackInfo(pc, "No Region Found."); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if(region != null) { |
|
|
|
@ -48,7 +49,15 @@ public class RegionCmd extends AbstractDevCmd {
@@ -48,7 +49,15 @@ public class RegionCmd extends AbstractDevCmd {
|
|
|
|
|
output += "is Outside: " + region.isOutside(); |
|
|
|
|
this.throwbackInfo(pc, output); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if(building != null){ |
|
|
|
|
for(Mesh mesh : building.buildingMeshes){ |
|
|
|
|
if(mesh.boundsRect.contains(new Point2D.Float(((AbstractCharacter) target).loc.x,((AbstractCharacter) target).loc.z))){ |
|
|
|
|
this.throwbackInfo(pc, "Inside Mesh Bounds"); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
this.throwbackInfo(pc, "Outside Mesh Bounds"); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|