Examples of intX()


Examples of universalelectricity.api.vector.Vector3.intX()

  public boolean isInField(IFieldInteraction projector, Vector3 position)
  {
    Vector3 posScale = projector.getPositiveScale();
    Vector3 negScale = projector.getNegativeScale();

    int radius = (posScale.intX() + negScale.intX() + posScale.intZ() + negScale.intZ()) / 2;

    Vector3 projectorPos = new Vector3((TileEntity) projector);
    projectorPos.add(projector.getTranslation());

    Vector3 relativePosition = position.clone().subtract(projectorPos);
View Full Code Here

Examples of universalelectricity.api.vector.Vector3.intX()

      {
        int blockId = position.getBlockID(world);

        if (Block.blocksList[blockId] != null)
        {
          Chunk chunk = world.getChunkFromBlockCoords(position.intX(), position.intZ());

          if (chunk != null && chunk.isChunkLoaded && (MFFSHelper.hasPermission(world, position, Action.RIGHT_CLICK_BLOCK, entityPlayer) || MFFSHelper.hasPermission(world, position, Permission.REMOTE_CONTROL, entityPlayer)))
          {
            float requiredEnergy = (float) Vector3.distance(new Vector3(entityPlayer), position) * (FluidContainerRegistry.BUCKET_VOLUME / 100);
            int receivedEnergy = 0;
View Full Code Here

Examples of universalelectricity.api.vector.Vector3.intX()

              if (receivedEnergy >= requiredEnergy)
              {
                try
                {
                  Block.blocksList[blockId].onBlockActivated(world, position.intX(), position.intY(), position.intZ(), entityPlayer, 0, 0, 0, 0);
                }
                catch (Exception e)
                {
                  e.printStackTrace();
                }
View Full Code Here

Examples of universalelectricity.api.vector.Vector3.intX()

    NBTTagCompound nbt = NBTUtility.getNBTTagCompound(itemStack);

    list.add(LanguageUtility.getLocal("info.modeCustom.mode") + " " + (nbt.getBoolean(NBT_MODE) ? LanguageUtility.getLocal("info.modeCustom.substraction") : LanguageUtility.getLocal("info.modeCustom.additive")));

    Vector3 point1 = new Vector3(nbt.getCompoundTag(NBT_POINT_1));
    list.add(LanguageUtility.getLocal("info.modeCustom.point1") + " " + point1.intX() + ", " + point1.intY() + ", " + point1.intZ());

    Vector3 point2 = new Vector3(nbt.getCompoundTag(NBT_POINT_2));
    list.add(LanguageUtility.getLocal("info.modeCustom.point2") + " " + point2.intX() + ", " + point2.intY() + ", " + point2.intZ());

    int modeID = nbt.getInteger(NBT_ID);
View Full Code Here

Examples of universalelectricity.api.vector.Vector3.intX()

    Vector3 point1 = new Vector3(nbt.getCompoundTag(NBT_POINT_1));
    list.add(LanguageUtility.getLocal("info.modeCustom.point1") + " " + point1.intX() + ", " + point1.intY() + ", " + point1.intZ());

    Vector3 point2 = new Vector3(nbt.getCompoundTag(NBT_POINT_2));
    list.add(LanguageUtility.getLocal("info.modeCustom.point2") + " " + point2.intX() + ", " + point2.intY() + ", " + point2.intZ());

    int modeID = nbt.getInteger(NBT_ID);

    if (modeID > 0)
    {
View Full Code Here

Examples of universalelectricity.api.vector.Vector3.intX()

              else
              {
                list = new NBTTagList();
              }

              for (int x = minPoint.intX(); x <= maxPoint.intX(); x++)
              {
                for (int y = minPoint.intY(); y <= maxPoint.intY(); y++)
                {
                  for (int z = minPoint.intZ(); z <= maxPoint.intZ(); z++)
                  {
View Full Code Here

Examples of universalelectricity.api.vector.Vector3.intX()

  {
    Set<Vector3> fieldBlocks = new HashSet<Vector3>();
    Vector3 posScale = projector.getPositiveScale();
    Vector3 negScale = projector.getNegativeScale();

    for (float x = -negScale.intX(); x <= posScale.intX(); x += 0.5f)
    {
      for (float z = -negScale.intZ(); z <= posScale.intZ(); z += 0.5f)
      {
        for (float y = -negScale.intY(); y <= posScale.intY(); y += 0.5f)
        {
View Full Code Here

Examples of universalelectricity.api.vector.Vector3.intX()

    {
      for (float z = -negScale.intZ(); z <= posScale.intZ(); z += 0.5f)
      {
        for (float y = -negScale.intY(); y <= posScale.intY(); y += 0.5f)
        {
          if (y == -negScale.intY() || y == posScale.intY() || x == -negScale.intX() || x == posScale.intX() || z == -negScale.intZ() || z == posScale.intZ())
          {
            fieldBlocks.add(new Vector3(x, y, z));
          }
        }
      }
View Full Code Here

Examples of universalelectricity.api.vector.Vector3.intX()

  {
    Set<Vector3> fieldBlocks = new HashSet<Vector3>();
    Vector3 posScale = projector.getPositiveScale();
    Vector3 negScale = projector.getNegativeScale();

    for (float x = -negScale.intX(); x <= posScale.intX(); x += 0.5f)
    {
      for (float z = -negScale.intZ(); z <= posScale.intZ(); z += 0.5f)
      {
        for (float y = -negScale.intY(); y <= posScale.intY(); y += 0.5f)
        {
View Full Code Here

Examples of universalelectricity.api.vector.Vector3.intX()

    final Set<Vector3> fieldBlocks = new HashSet<Vector3>();

    final Vector3 posScale = projector.getPositiveScale();
    final Vector3 negScale = projector.getNegativeScale();

    final int xStretch = posScale.intX() + negScale.intX();
    final int yStretch = posScale.intY() + negScale.intY();
    final int zStretch = posScale.intZ() + negScale.intZ();
    final Vector3 translation = new Vector3(0, -negScale.intY(), 0);

    final int inverseThickness = (int) Math.max((yStretch + zStretch) / 4f, 1);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.