Ladysnake / Illuminations-for-Forge

https://ladysnake.github.io/wiki/illuminations.html
1 stars 1 forks source link

Crash when using /summon for fireflies #3

Open mcenderdragon opened 4 years ago

mcenderdragon commented 4 years ago

I used the minecraft /summon to create a firefly and it imedietly crashed.


java.lang.ArithmeticException: / by zero
    at ladysnake.illuminations.entity.FireFlyEntity.func_70071_h_(FireFlyEntity.java:182) ~[?:1.0.0.0] {re:classloading}
    at net.minecraft.client.world.ClientWorld.func_217418_a(ClientWorld.java:165) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraft.client.world.ClientWorld$$Lambda$7317/361317558.accept(Unknown Source) ~[?:?] {}
    at net.minecraft.world.World.func_217390_a(World.java:684) ~[?:?] {re:classloading,pl:accesstransformer:B}
    at net.minecraft.client.world.ClientWorld.func_217419_d(ClientWorld.java:133) ~[?:?] {re:classloading,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.func_71407_l(Minecraft.java:1344) ~[?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.func_195542_b(Minecraft.java:869) [?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:384) [?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.main.Main.main(SourceFile:155) [?:?] {re:classloading}
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_51] {}
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_51] {}
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_51] {}
    at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:56) [forge-1.14.4-28.1.117.jar:28.1] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$395/1904609259.call(Unknown Source) [forge-1.14.4-28.1.117.jar:28.1] {}
    at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37) [modlauncher-4.1.0.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54) [modlauncher-4.1.0.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72) [modlauncher-4.1.0.jar:?] {}
    at cpw.mods.modlauncher.Launcher.run(Launcher.java:81) [modlauncher-4.1.0.jar:?] {}
    at cpw.mods.modlauncher.Launcher.main(Launcher.java:65) [modlauncher-4.1.0.jar:?] {}

if you need the full crash report I can provide that too.

mcenderdragon commented 4 years ago

yeah the line is qeustion is this:

 if (this.world.getGameTime() % dataManager.get(RANDOM_TICK_OFFSET) >= 0)
            return;

and when RANDOM_TICK_OFFSET is 0 it will crash...