Non-terminating decimal expansion.

Issue #8 resolved
Former user created an issue

After claiming a few chunks in a straight line, I am greeted with the following error when doing /city The Error

Comments (3)

  1. Isaac Alich

    Hey there. Created this issue but had to make an account to comment:

    Here's the server error log:

    >  [17:32:11] [Server thread/ERROR] [Sponge]: Error occurred while executing command 'city' for source EntityPlayerMP['tenten8401'/272, l='world', x=5522.96, y=65.00, z=15554.41]: Non-terminating decimal expansion; no exact representable dec
    imal result.
    java.lang.ArithmeticException: Non-terminating decimal expansion; no exact representable decimal result.
        at java.math.BigDecimal.divide(BigDecimal.java:1690) ~[?:1.8.0_92-internal]
        at com.quequiere.cityplugin.command.CityCommand.displayCity(CityCommand.java:737) ~[CityCommand.class:?]
        at com.quequiere.cityplugin.command.CityCommand.process(CityCommand.java:60) ~[CityCommand.class:?]
        at org.spongepowered.api.command.dispatcher.SimpleDispatcher.process(SimpleDispatcher.java:333) ~[SimpleDispatcher.class:1.10.2-2202-5.1.0-BETA-2099]
        at org.spongepowered.common.command.SpongeCommandManager.process(SpongeCommandManager.java:295) [SpongeCommandManager.class:1.10.2-2202-5.1.0-BETA-2099]
        at net.minecraft.command.ServerCommandManager.func_71556_a(SourceFile:1083) [bd.class:?]
        at net.minecraft.network.NetHandlerPlayServer.func_147361_d(NetHandlerPlayServer.java:913) [me.class:?]
        at net.minecraft.network.NetHandlerPlayServer.func_147354_a(NetHandlerPlayServer.java:892) [me.class:?]
        at net.minecraft.network.play.client.CPacketChatMessage.func_148833_a(SourceFile:37) [im.class:?]
        at net.minecraft.network.play.client.CPacketChatMessage.func_148833_a(SourceFile:9) [im.class:?]
        at org.spongepowered.common.network.PacketUtil.onProcessPacket(PacketUtil.java:156) [PacketUtil.class:1.10.2-2202-5.1.0-BETA-2099]
        at net.minecraft.network.PacketThreadUtil$1.redirect$onProcessPacket$zje000(SourceFile:539) [fl$1.class:?]
        at net.minecraft.network.PacketThreadUtil$1.run(SourceFile:13) [fl$1.class:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_92-internal]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_92-internal]
        at net.minecraft.util.Util.func_181617_a(SourceFile:45) [h.class:?]
        at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:668) [MinecraftServer.class:?]
        at net.minecraft.server.dedicated.DedicatedServer.func_71190_q(DedicatedServer.java:387) [ld.class:?]
        at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:613) [MinecraftServer.class:?]
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:471) [MinecraftServer.class:?]
        at java.lang.Thread.run(Thread.java:745) [?:1.8.0_92-internal]
    

    and here's the city I'm working with:

    {
      "name": "Diamondz",
      "citychunk": [
        {
          "x": 341,
          "z": 972,
          "world": "world",
          "sellPrice": -1.0
        },
        {
          "x": 341,
          "z": 973,
          "world": "world",
          "sellPrice": -1.0
        },
        {
          "x": 340,
          "z": 973,
          "world": "world",
          "sellPrice": -1.0
        },
        {
          "x": 340,
          "z": 972,
          "world": "world",
          "sellPrice": -1.0
        },
        {
          "x": 342,
          "z": 972,
          "world": "world",
          "sellPrice": -1.0
        },
        {
          "x": 343,
          "z": 972,
          "world": "world",
          "sellPrice": -1.0
        },
        {
          "x": 344,
          "z": 972,
          "world": "world",
          "sellPrice": -1.0
        }
      ],
      "cityoutpost": [],
      "spawn": {
        "locationSerialized": [
          "5464:65:15561:world"
        ]
      },
      "residents": [
        "d523c836-6f58-4338-a89d-44b8a9cf0e68"
      ],
      "openJoin": false,
      "playerTax": 0.0,
      "removePlayerTax": false,
      "customName": "DMDZ",
      "bonusClaim": 0,
      "cityPerm": {
        "BUILD": {
          "outsider": false,
          "empire": false,
          "resident": false
        },
        "SWITH": {
          "outsider": false,
          "empire": false,
          "resident": false
        },
        "USEITEM": {
          "outsider": false,
          "empire": false,
          "resident": false
        },
        "DESTROY": {
          "outsider": false,
          "empire": false,
          "resident": false
        }
      }
    }
    
  2. Log in to comment