Crash when entity attacked

Started by Trehmor on

Topic category: Troubleshooting, bugs, and solutions

Last seen on 17:39, 15. Jan 2024
Joined Feb 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Crash when entity attacked

Everytime i use a ranged weapon it crash the game. I will paste the crash report.

 

---- Minecraft Crash Report ----
// Surprise! Haha. Well, this is awkward.

Time: 10/09/20 19:15
Description: Ticking entity

java.lang.ClassCastException: net.minecraft.entity.projectile.ArrowEntity cannot be cast to net.minecraft.entity.LivingEntity
    at net.mcreator.uwu.procedures.VampirismpotionProcedure.executeProcedure(VampirismpotionProcedure.java:33) ~[?:?] {re:classloading}
    at net.mcreator.uwu.procedures.VampirismpotionProcedure.onEntityAttacked(VampirismpotionProcedure.java:80) ~[?:?] {re:classloading}
    at net.minecraftforge.eventbus.ASMEventHandler_16_VampirismpotionProcedure_onEntityAttacked_LivingAttackEvent.invoke(.dynamic) ~[?:?] {}
    at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:80) ~[eventbus-2.2.0-service.jar:?] {}
    at net.minecraftforge.eventbus.EventBus.post(EventBus.java:258) ~[eventbus-2.2.0-service.jar:?] {}
    at net.minecraftforge.common.ForgeHooks.onLivingAttack(ForgeHooks.java:320) ~[?:?] {re:classloading}
    at net.minecraft.entity.LivingEntity.func_70097_a(LivingEntity.java:827) ~[?:?] {re:classloading}
    at net.mcreator.uwu.entity.GoatEntity$CustomEntity.func_70097_a(GoatEntity.java:181) ~[?:?] {re:classloading}
    at net.minecraft.entity.projectile.AbstractArrowEntity.func_213868_a(AbstractArrowEntity.java:379) ~[?:?] {re:classloading}
    at net.minecraft.entity.projectile.AbstractArrowEntity.func_184549_a(AbstractArrowEntity.java:304) ~[?:?] {re:classloading}
    at net.minecraft.entity.projectile.AbstractArrowEntity.func_70071_h_(AbstractArrowEntity.java:222) ~[?:?] {re:classloading}
    at net.minecraft.entity.projectile.ArrowEntity.func_70071_h_(SourceFile:103) ~[?:?] {re:classloading}
    at net.minecraft.client.world.ClientWorld.func_217418_a(ClientWorld.java:235) ~[?:?] {re:classloading,xf:OptiFine:default}
    at net.minecraft.client.world.ClientWorld$$Lambda$6837/1724067349.accept(Unknown Source) ~[?:?] {}
    at net.minecraft.world.World.func_217390_a(World.java:536) ~[?:?] {re:classloading,pl:accesstransformer:B}
    at net.minecraft.client.world.ClientWorld.func_217419_d(ClientWorld.java:196) ~[?:?] {re:classloading,xf:OptiFine:default}
    at net.minecraft.client.Minecraft.func_71407_l(Minecraft.java:1398) ~[?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.func_195542_b(Minecraft.java:904) [?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:553) [?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A}
    at net.minecraft.client.main.Main.main(SourceFile:204) [?:?] {re:classloading}
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_51] {}
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_51] {}
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_51] {}
    at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_51] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:51) [forge-1.15.2-31.2.36.jar:31.2] {}
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$416/997294994.call(Unknown Source) [forge-1.15.2-31.2.36.jar:31.2] {}
    at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.Launcher.run(Launcher.java:81) [modlauncher-5.1.2.jar:?] {}
    at cpw.mods.modlauncher.Launcher.main(Launcher.java:65) [modlauncher-5.1.2.jar:?] {}
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_51] {}
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_51] {}
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:1.8.0_51] {}
    at java.lang.reflect.Method.invoke(Unknown Source) ~[?:1.8.0_51] {}
    at net.minecraft.a.m.main(Unknown Source) [laulib-1.0.jar:?] {}

A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- Head --
Thread: Render thread
Stacktrace:
    at net.mcreator.uwu.procedures.VampirismpotionProcedure.executeProcedure(VampirismpotionProcedure.java:33)
    at net.mcreator.uwu.procedures.VampirismpotionProcedure.onEntityAttacked(VampirismpotionProcedure.java:80)
    at net.minecraftforge.eventbus.ASMEventHandler_16_VampirismpotionProcedure_onEntityAttacked_LivingAttackEvent.invoke(.dynamic)
    at net.minecraftforge.eventbus.ASMEventHandler.invoke(ASMEventHandler.java:80)
    at net.minecraftforge.eventbus.EventBus.post(EventBus.java:258)
    at net.minecraftforge.common.ForgeHooks.onLivingAttack(ForgeHooks.java:320)
    at net.minecraft.entity.LivingEntity.func_70097_a(LivingEntity.java:827)
    at net.mcreator.uwu.entity.GoatEntity$CustomEntity.func_70097_a(GoatEntity.java:181)
    at net.minecraft.entity.projectile.AbstractArrowEntity.func_213868_a(AbstractArrowEntity.java:379)
    at net.minecraft.entity.projectile.AbstractArrowEntity.func_184549_a(AbstractArrowEntity.java:304)
    at net.minecraft.entity.projectile.AbstractArrowEntity.func_70071_h_(AbstractArrowEntity.java:222)
    at net.minecraft.entity.projectile.ArrowEntity.func_70071_h_(SourceFile:103)
    at net.minecraft.client.world.ClientWorld.func_217418_a(ClientWorld.java:235)
    at net.minecraft.client.world.ClientWorld$$Lambda$6837/1724067349.accept(Unknown Source)

-- Entity being ticked --
Details:
    Entity Type: minecraft:arrow (net.minecraft.entity.projectile.ArrowEntity)
    Entity ID: 673
    Entity Name: Flecha
    Entity's Exact location: 169.25, 63.90, 1639.32
    Entity's Block location: World: (169,63,1639), Chunk: (at 9,3,7 in 10,102; contains blocks 160,0,1632 to 175,255,1647), Region: (0,3; contains chunks 0,96 to 31,127, blocks 0,0,1536 to 511,255,2047)
    Entity's Momentum: -1.33, -0.38, 2.56
    Entity's Passengers: []
    Entity's Vehicle: ~~ERROR~~ NullPointerException: null
Stacktrace:
    at net.minecraft.world.World.func_217390_a(World.java:536)
    at net.minecraft.client.world.ClientWorld.func_217419_d(ClientWorld.java:196)

-- Affected level --
Details:
    All players: 1 total; [ClientPlayerEntity['Juani_124'/243, l='MpServer', x=171.95, y=63.00, z=1634.12]]
    Chunk stats: Client Chunk Cache: 225, 98
    Level dimension: DimensionType{minecraft:overworld}
    Level name: MpServer
    Level seed: 7308449473698198382
    Level generator: ID 00 - default, ver 1. Features enabled: false
    Level generator options: {}
    Level spawn location: World: (-921,70,2526), Chunk: (at 7,4,14 in -58,157; contains blocks -928,0,2512 to -913,255,2527), Region: (-2,4; contains chunks -64,128 to -33,159, blocks -1024,0,2048 to -513,255,2559)
    Level time: 33166 game time, 39776 day time
    Known server brands: 
    Level was modded: false
    Level storage version: 0x00000 - Unknown?
    Level weather: Rain time: 0 (now: false), thunder time: 0 (now: false)
    Level game mode: Game mode: creative (ID 1). Hardcore: false. Cheats: false
    Server brand: forge
    Server type: Integrated singleplayer server
Stacktrace:
    at net.minecraft.client.world.ClientWorld.func_72914_a(ClientWorld.java:611)
    at net.minecraft.client.Minecraft.func_71396_d(Minecraft.java:1763)
    at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:567)
    at net.minecraft.client.main.Main.main(SourceFile:204)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:51)
    at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$416/997294994.call(Unknown Source)
    at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37)
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54)
    at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72)
    at cpw.mods.modlauncher.Launcher.run(Launcher.java:81)
    at cpw.mods.modlauncher.Launcher.main(Launcher.java:65)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at net.minecraft.a.m.main(Unknown Source)

-- System Details --
Details:
    Minecraft Version: 1.15.2
    Minecraft Version ID: 1.15.2
    Operating System: Windows 8.1 (amd64) version 6.3
    Java Version: 1.8.0_51, Oracle Corporation
    Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
    Memory: 383541040 bytes (365 MB) / 1362624512 bytes (1299 MB) up to 2863661056 bytes (2731 MB)
    CPUs: 2
    JVM Flags: 3 total; -Xmx3G -XX:+IgnoreUnrecognizedVMOptions -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump
    ModLauncher: 5.1.2+70+master.2845bb9
    ModLauncher launch target: fmlclient
    ModLauncher naming: srg
    ModLauncher services: 
        /eventbus-2.2.0-service.jar eventbus PLUGINSERVICE 
        /forge-1.15.2-31.2.36.jar object_holder_definalize PLUGINSERVICE 
        /forge-1.15.2-31.2.36.jar runtime_enum_extender PLUGINSERVICE 
        /accesstransformers-2.1.3-shadowed.jar accesstransformer PLUGINSERVICE 
        /forge-1.15.2-31.2.36.jar capability_inject_definalize PLUGINSERVICE 
        /forge-1.15.2-31.2.36.jar runtimedistcleaner PLUGINSERVICE 
        /preview_OptiFine_1.15.2_HD_U_G1_pre30.jar OptiFine TRANSFORMATIONSERVICE 
        /forge-1.15.2-31.2.36.jar fml TRANSFORMATIONSERVICE 
    FML: 31.2
    Forge: net.minecraftforge:31.2.36
    FML Language Providers: 
        javafml@31.2
        minecraft@1
    Mod List: 
        forge-1.15.2-31.2.36-client.jar Minecraft {minecraft@1.15.2 DONE}
        forge-1.15.2-31.2.36-universal.jar Forge {forge@31.2.36 DONE}
        Epicraft.jar Epicraft {epicraft@2.0 DONE}
        NaturesCompass-1.15.2-1.8.5.jar Nature's Compass {naturescompass@1.15.2-1.8.5 DONE}
    Launched Version: 1.15.2-forge-31.2.36
    Backend library: LWJGL version 3.2.2 build 10
    Backend API: Intel(R) HD Graphics GL version 3.1.0 - Build 9.17.10.4459, Intel
    GL Caps: Using framebuffer using OpenGL 3.0
    Using VBOs: Yes
    Is Modded: Definitely; Client brand changed to 'forge'
    Type: Client (map_client.txt)
    Resource Packs: vanilla
    Current Language: Español (Argentina)
    CPU: 2x Intel(R) Celeron(R) CPU G470 @ 2.00GHz
    OptiFine Version: OptiFine_1.15.2_HD_U_G1_pre30
    OptiFine Build: 20200622-083032
    Render Distance Chunks: 5
    Mipmaps: 0
    Anisotropic Filtering: 1
    Antialiasing: 0
    Multitexture: false
    Shaders: null
    OpenGlVersion: 3.1.0 - Build 9.17.10.4459
    OpenGlRenderer: Intel(R) HD Graphics
    OpenGlVendor: Intel
    CpuCount: 2

Last seen on 09:40, 10. Apr 2024
Joined Nov 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I had this happen to me,…
Fri, 10/02/2020 - 00:27

I had this happen to me, whats happening is that when it gets hurt by an arrow or ranged item, it will do the effect as if it gets hurt, and the arrow I believe also gets hit, which crashes your game, try changing up some things with the code to make it not damage to add to the bow, also it would help if you sent me a picture of the entity gets attacked procedure