Jump to content

[Custom NPCs 1.7.10] [Question] Crash when attacked by mob


Recommended Posts

Posted

When a guard npc gets atacked by a mob of terrafirmacraft mod, the game crashes. I don't know if it is a easily fixable bug, but maybe there is a way to make the npc invisible to mobs, like player on creative mod? That could be temporary solution! Thanks!

Posted

I have to admit that I don't know the exactly version of MC, but the forge version is 10.13.4.1558 if that helps.

 

Here is the crash report:

 

---- Minecraft Crash Report ----
// Who set us up the TNT?

Time: 12/01/16 14:38
Description: Ticking entity

java.lang.ArrayIndexOutOfBoundsException: 2
at com.bioxx.tfc.Handlers.EntityDamageHandler.applyArmorCalculations(EntityDamageHandler.java:104)
at com.bioxx.tfc.Handlers.EntityDamageHandler.onEntityHurt(EntityDamageHandler.java:71)
at cpw.mods.fml.common.eventhandler.ASMEventHandler_57_EntityDamageHandler_onEntityHurt_LivingHurtEvent.invoke(.dynamic)
at cpw.mods.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:54)
at cpw.mods.fml.common.eventhandler.EventBus.post(EventBus.java:140)
at net.minecraftforge.common.ForgeHooks.onLivingHurt(ForgeHooks.java:298)
at net.minecraft.entity.EntityLivingBase.func_70665_d(EntityLivingBase.java:1129)
at net.minecraft.entity.EntityLivingBase.func_70097_a(EntityLivingBase.java:785)
at noppes.npcs.entity.EntityNPCInterface.func_70097_a(EntityNPCInterface.java:506)
at net.minecraft.entity.projectile.EntityArrow.func_70071_h_(SourceFile:270)
at com.bioxx.tfc.Entities.EntityProjectileTFC.func_70071_h_(EntityProjectileTFC.java:106)
at net.minecraft.world.World.func_72866_a(World.java:2070)
at net.minecraft.world.WorldServer.func_72866_a(WorldServer.java:648)
at net.minecraft.world.World.func_72870_g(World.java:2034)
at net.minecraft.world.World.func_72939_s(World.java:1887)
at net.minecraft.world.WorldServer.func_72939_s(WorldServer.java:489)
at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:636)
at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:547)
at net.minecraft.server.integrated.IntegratedServer.func_71217_p(IntegratedServer.java:111)
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:427)
at net.minecraft.server.MinecraftServer$2.run(MinecraftServer.java:685)


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

-- Head --
Stacktrace:
at com.bioxx.tfc.Handlers.EntityDamageHandler.applyArmorCalculations(EntityDamageHandler.java:104)
at com.bioxx.tfc.Handlers.EntityDamageHandler.onEntityHurt(EntityDamageHandler.java:71)
at cpw.mods.fml.common.eventhandler.ASMEventHandler_57_EntityDamageHandler_onEntityHurt_LivingHurtEvent.invoke(.dynamic)
at cpw.mods.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:54)
at cpw.mods.fml.common.eventhandler.EventBus.post(EventBus.java:140)
at net.minecraftforge.common.ForgeHooks.onLivingHurt(ForgeHooks.java:298)
at net.minecraft.entity.EntityLivingBase.func_70665_d(EntityLivingBase.java:1129)
at net.minecraft.entity.EntityLivingBase.func_70097_a(EntityLivingBase.java:785)
at noppes.npcs.entity.EntityNPCInterface.func_70097_a(EntityNPCInterface.java:506)
at net.minecraft.entity.projectile.EntityArrow.func_70071_h_(SourceFile:270)
at com.bioxx.tfc.Entities.EntityProjectileTFC.func_70071_h_(EntityProjectileTFC.java:106)
at net.minecraft.world.World.func_72866_a(World.java:2070)
at net.minecraft.world.WorldServer.func_72866_a(WorldServer.java:648)
at net.minecraft.world.World.func_72870_g(World.java:2034)

-- Entity being ticked --
Details:
Entity Type: arrowTFC (com.bioxx.tfc.Entities.EntityProjectileTFC)
Entity ID: 29775
Entity Name: Arrow
Entity's Exact location: 338,86, 143,91, -14600,01
Entity's Block location: World: (338,143,-14601), Chunk: (at 2,8,7 in 21,-913; contains blocks 336,0,-14608 to 351,255,-14593), Region: (0,-29; contains chunks 0,-928 to 31,-897, blocks 0,0,-14848 to 511,255,-14337)
Entity's Momentum: 1,03, 0,40, 0,43
Stacktrace:
at net.minecraft.world.World.func_72939_s(World.java:1887)
at net.minecraft.world.WorldServer.func_72939_s(WorldServer.java:489)

-- Affected level --
Details:
Level name: New World
All players: 1 total; [EntityPlayerMP['Spekiz'/36, l='New World', x=343,85, y=144,00, z=-14597,47]]
Chunk stats: ServerChunkCache: 808 Drop: 0
Level seed: 376020899036813378
Level generator: ID 00 - TFCDefault, ver 0. Features enabled: true
Level generator options: 
Level spawn location: World: (192,145,-14608), Chunk: (at 0,9,0 in 12,-913; contains blocks 192,0,-14608 to 207,255,-14593), Region: (0,-29; contains chunks 0,-928 to 31,-897, blocks 0,0,-14848 to 511,255,-14337)
Level time: 579876 game time, 615141 day time
Level dimension: 0
Level storage version: 0x04ABD - Anvil
Level weather: Rain time: 146680 (now: false), thunder time: 11238 (now: false)
Level game mode: Game mode: survival (ID 0). Hardcore: false. Cheats: true
Stacktrace:
at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:636)
at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:547)
at net.minecraft.server.integrated.IntegratedServer.func_71217_p(IntegratedServer.java:111)
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:427)
at net.minecraft.server.MinecraftServer$2.run(MinecraftServer.java:685)

-- System Details --
Details:
Minecraft Version: 1.7.10
Operating System: Windows 10 (amd64) version 10.0
Java Version: 1.8.0_25, Oracle Corporation
Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
Memory: 237629824 bytes (226 MB) / 716341248 bytes (683 MB) up to 1060372480 bytes (1011 MB)
JVM Flags: 6 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xmx1G -XX:+UseConcMarkSweepGC -XX:+CMSIncrementalMode -XX:-UseAdaptiveSizePolicy -Xmn128M
AABB Pool Size: 0 (0 bytes; 0 MB) allocated, 0 (0 bytes; 0 MB) used
IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 17
FML: MCP v9.05 FML v7.10.99.99 Minecraft Forge 10.13.4.1558 11 mods loaded, 11 mods active
States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored
UCHIJAAAA	mcp{9.05} [Minecraft Coder Pack] (minecraft.jar) 
UCHIJAAAA	FML{7.10.99.99} [Forge Mod Loader] (forge-1.7.10-10.13.4.1558-1.7.10.jar) 
UCHIJAAAA	Forge{10.13.4.1558} [Minecraft Forge] (forge-1.7.10-10.13.4.1558-1.7.10.jar) 
UCHIJAAAA	tfc_coremod{0.79.27} [TFC[coremod]] (minecraft.jar) 
UCHIJAAAA	cuchaz.ships.core{1.7.10-1.0.3} [ships Mod Core] (minecraft.jar) 
UCHIJAAAA	terrafirmacraft{0.79.27} [TerraFirmaCraft] ([1.7.10]TerraFirmaCraft-0.79.27.903.jar) 
UCHIJAAAA	customnpcs{1.7.10d} [CustomNpcs] (CustomNPCs_1.7.10d.jar) 
UCHIJAAAA	FastCraft{1.21} [FastCraft] (fastcraft-1.21.jar) 
UCHIJAAAA	ReiMinimap{1.7.10} [Rei's Minimap] (Reis-Minimap-Mod-1.7.10.jar) 
UCHIJAAAA	cuchaz.cuchazinteractive{1.7.10-1.0} [Cuchaz Interactive] (shipsMod-v1.7.10-1.0.4.jar) 
UCHIJAAAA	cuchaz.ships{1.7.10-1.0.3} [ships Mod] (shipsMod-v1.7.10-1.0.4.jar) 
GL info: ~~ERROR~~ RuntimeException: No OpenGL context found in the current thread.
Profiler Position: N/A (disabled)
Vec3 Pool Size: 0 (0 bytes; 0 MB) allocated, 0 (0 bytes; 0 MB) used
Player Count: 1 / 8; [EntityPlayerMP[Private/36, l='New World', x=343,85, y=144,00, z=-14597,47]]
Type: Integrated Server (map_client.txt)
Is Modded: Definitely; Client brand changed to 'fml,forge'

Posted

Yeah, but I am pretty sure Bioxx won't fix this and I don't wish that you waste your time fixing this. Just wanted to know if there's a way to make the NPC invisible so the npc will ignore it. The crash is due to mob attacking an npc, when an npc attacks a mob nothing happens.

  • 1 year later...
Posted
  On 1/15/2016 at 8:39 AM, Noppes said:

Not caused by my mod. com.bioxx.tfc is the one crashing.

Expand  
 
 

Hi I was just looking for the same bug and I can cross this issue with the explanation from the terrafirmacraft team.

Could you look at it?

 

 

  Quote

The problem is that CustomNPCs for whatever reason decided to extend EntityLivingBase instead of just EntityLiving like every other mod out there does, or they overriding the function getLastActiveItems(). Every single living entity in vanilla Minecraft as well as from mods that follow the "normal" route of extending EntityLiving or EntityPlayer always has the memory allocated for either 4 or 5 slots: the 4 armor slots and optionally the item they are holding. Our damage handler is based off of that assumption that the array of itemstacks for the armor will always be returned.

I would suggest you contact CustomNPC support and ask them if they have a specific reason for overriding EntityLivingBase.getLastActiveItems(), and if they could change their implementation to always return an array of at least size 4 like all other living entities do.

Expand  
4

Kittychanley

http://terrafirmacraft.com/f/topic/9581-problem-with-custom-npcs/

 

and also here

  Quote

You must have created a custom NPC that completely ignores the standard way of handling armor slots. Just about every entity in Minecraft has the 4 armor slots in the code regardless of if you can actually get them to wear armor. All of our calculations are based off the fact that every other mod is using that same standard, but in this case CustomNPC is not.

There's nothing we can do to fix this. The problem is with CustomNPC for not using armor standards.

Expand  
6

http://terrafirmacraft.com/f/topic/9137-solved-custom-npc-tfc-damagearmor-calculation-crash/

 

Can you look at the code if it's true because now it ended up in a dead end. And possibly backport the fix to 1.7.10? Both mods are awesome but they can't be used together just for this calculation crash.

Thanks

 

 

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • Cracked Launchers are not supported
    • Hi, I have a problem in minecraft java (only in forge 1.20.1), When I start the game after a moment the game crashed with code 1 this only in forge 1.20.1 , I tried to reinstall java, Upgrade java to 17, update the drivers to the latest version, downgrade the drivers to the pervious version, deleting .minecraft and reinstall it , but none of these ways working.   here is the log:   [Launcher] Launching Minecraft... I'm hiding! mods after C:\Users\Windows\AppData\Roaming\.minecraft\mods\tl_skin_cape_forge_1.20_1.20.1-1.32.jar [InnerMinecraftServersImpl]  search changers of the servers read servers from servers.dat [] [InnerMinecraftServersImpl]  prepare inner servers save servers to servers.dat [Launcher] Game skin type: TLAUNCHER [Launcher] Starting Minecraft Forge 1.20.1... [Launcher] Launching in: C:\Users\Windows\AppData\Roaming\.minecraft Starting garbage collector: 96 / 227 MB Garbage collector completed: 60 / 214 MB [Launcher] Processing post-launch actions. Assist launch: true =============================================================================================== [05:29:03] [main/INFO]: ModLauncher running: args [--username, *********, --version, Forge 1.20.1, --gameDir, C:\Users\Windows\AppData\Roaming\.minecraft, --assetsDir, C:\Users\Windows\AppData\Roaming\.minecraft\assets, --assetIndex, 5, --uuid, *************************************, --accessToken, вќ„вќ„вќ„вќ„вќ„вќ„вќ„вќ„, --clientId, null, --xuid, null, --userType, mojang, --versionType, modified, --width, 925, --height, 530, --launchTarget, forgeclient, --fml.forgeVersion, 47.3.22, --fml.mcVersion, 1.20.1, --fml.forgeGroup, net.minecraftforge, --fml.mcpVersion, 20230612.114412] [05:29:04] [main/INFO]: ModLauncher 10.0.9+10.0.9+main.dcd20f30 starting: java version 17.0.12 by Oracle Corporation; OS Windows 10 arch amd64 version 10.0 [05:29:15] [main/INFO]: Loading ImmediateWindowProvider fmlearlywindow [05:29:24] [main/INFO]: Trying GL version 4.6 [05:29:60] [main/INFO]: Requested GL version 4.6 got version 4.6 [05:29:67] [main/INFO]: SpongePowered MIXIN Subsystem Version=0.8.5 Source=union:/C:/Users/Windows/AppData/Roaming/.minecraft/libraries/org/spongepowered/mixin/0.8.5/mixin-0.8.5.jar%23100!/ Service=ModLauncher Env=CLIENT FATAL ERROR in native method: Thread[pool-2-thread-1,5,main]: No context is current or a function that is not available in the current context was called. The JVM will abort execution.     at org.lwjgl.opengl.GL11C.nglGetString(org.lwjgl.opengl@3.3.1+7/Native Method)     at org.lwjgl.opengl.GL11C.glGetString(org.lwjgl.opengl@3.3.1+7/GL11C.java:978)     at net.minecraftforge.fml.earlydisplay.DisplayWindow.initRender(fmlearlydisplay@1.20.1-47.3.22/DisplayWindow.java:209)     at net.minecraftforge.fml.earlydisplay.DisplayWindow.lambda$start$5(fmlearlydisplay@1.20.1-47.3.22/DisplayWindow.java:292)     at net.minecraftforge.fml.earlydisplay.DisplayWindow$$Lambda$437/0x000001fab120a618.run(fmlearlydisplay@1.20.1-47.3.22/Unknown Source)     at java.util.concurrent.Executors$RunnableAdapter.call(java.base@17.0.12/Executors.java:539)     at java.util.concurrent.FutureTask.run(java.base@17.0.12/FutureTask.java:264)     at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(java.base@17.0.12/ScheduledThreadPoolExecutor.java:304)     at java.util.concurrent.ThreadPoolExecutor.runWorker(java.base@17.0.12/ThreadPoolExecutor.java:1136)     at java.util.concurrent.ThreadPoolExecutor$Worker.run(java.base@17.0.12/ThreadPoolExecutor.java:635)     at java.lang.Thread.run(java.base@17.0.12/Thread.java:842) Here I am! [VersionManager] Refreshing versions locally... [VersionManager] Versions has been refreshed (6 ms) [Launcher] Launcher exited. [Launcher] Minecraft closed with exit code: 1 flush now [Launcher] [Crash] Signature "Bad video drivers" matches! [Crash] Signature "Bad video drivers" matches! [Launcher] [Crash] Crash has been recognized! [Crash] Crash has been recognized! flush now
    • https://mclo.gs/9Byd16j Hi, I've had my BetterMC world for a couple days now (1.19.2 vers & Fabric loader) but recently whenever I try to open the profile the minecraft launcher crashes and provides this error code. I've checked both this forum and google and haven't found any similar problems or solution to my problem. I'm not the best at reading crash logs but I gathered that there's an issue with fabric possibly, so I re-downloaded the same one on the modpack, then the latest version for 1.19.2 fabric and the issue still occurred. What can I do now?
    • it works now but idk why lmao. i removed terrablender and it didnt work. i then left it for a couple of days and, when i came back, updated the mods that needed updating because "what's the worst that could happen". i then tried launching it and now it works. i genuenly have no clue what i did to make it work, othen than updating the mods. so, thanks for your help
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.