Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v0.2.12-alpha make my save crash without any error message in the bepinex log #72

Closed
GIS-PuppetMaster opened this issue Jan 20, 2024 · 8 comments

Comments

@GIS-PuppetMaster
Copy link

GIS-PuppetMaster commented Jan 20, 2024

Especially when I use road replace tool to update the 6 lane road to 7 lane road (both side of the road have custom traffic lights and one side has custom lane direction)

@slyh
Copy link
Owner

slyh commented Jan 20, 2024

Could you share a screenshot of the road setup that caused the crash?

Although there is no error message, could you upload your BepInEx log? It contains valuable information, such as the mods you have installed, which could help us in replicating the issue.

@GIS-PuppetMaster
Copy link
Author

Could you share a screenshot of the road setup that caused the crash?您能否分享导致事故的道路设置的屏幕截图?

Although there is no error message, could you upload your BepInEx log? It contains valuable information, such as the mods you have installed, which could help us in replicating the issue.虽然没有错误消息,但您可以上传您的 BepInEx 日志吗?它包含有价值的信息,例如您安装的模组,这可以帮助我们重现问题。

image
image
image
image
image
After I replace the road and the game run normally for about 3 seconds, the game stucked

@GIS-PuppetMaster
Copy link
Author

The last picture is a custom parking that I made by invisible road with parking lot

@GIS-PuppetMaster

This comment was marked as outdated.

@GIS-PuppetMaster
Copy link
Author

It seems that the game will break if I replace other roads, I'm not sure

@slyh
Copy link
Owner

slyh commented Jan 20, 2024

I'm able to replicate this issue. The game might crash to desktop or throw an exception when upgrading a road.

Object reference not set to an instance of an object
NullReferenceException: Object reference not set to an instance of an object
  at Unity.Entities.ECBChunk.Bump (System.Int32 size) [0x00000] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at Unity.Entities.EntityCommandBufferData.Reserve (Unity.Entities.EntityCommandBufferChain* chain, System.Int32 sortKey, System.Int32 size) [0x00116] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at Unity.Entities.EntityCommandBufferData.AddEntityComponentTypeWithValueCommand[T] (Unity.Entities.EntityCommandBufferChain* chain, System.Int32 sortKey, Unity.Entities.ECBCommand op, Unity.Entities.Entity e, T component) [0x0003c] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at Unity.Entities.EntityCommandBuffer.AddComponent[T] (Unity.Entities.Entity e, T component) [0x00018] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem+InitializeTrafficLightsJob.InitializeTrafficLights (Unity.Entities.DynamicBuffer`1[T] subLanes, Unity.Collections.NativeList`1[T] groups, System.Int32 groupCount, System.Boolean isLevelCrossing, Game.Net.TrafficLights& trafficLights) [0x000f9] in <dfcc6cdd930f477d9380235c3d3625a0>:0 
  at C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem+InitializeTrafficLightsJob.Execute (Unity.Entities.ArchetypeChunk& chunk, System.Int32 unfilteredChunkIndex, System.Boolean useEnabledMask, Unity.Burst.Intrinsics.v128& chunkEnabledMask) [0x000d9] in <dfcc6cdd930f477d9380235c3d3625a0>:0 
  at C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem+InitializeTrafficLightsJob.Unity.Entities.IJobChunk.Execute (Unity.Entities.ArchetypeChunk& chunk, System.Int32 unfilteredChunkIndex, System.Boolean useEnabledMask, Unity.Burst.Intrinsics.v128& chunkEnabledMask) [0x00000] in <dfcc6cdd930f477d9380235c3d3625a0>:0 
  at Unity.Entities.JobChunkExtensions+JobChunkProducer`1[T].ExecuteInternal (Unity.Entities.JobChunkExtensions+JobChunkWrapper`1[T]& jobWrapper, System.IntPtr bufferRangePatchData, Unity.Jobs.LowLevel.Unsafe.JobRanges& ranges, System.Int32 jobIndex) [0x000b5] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at Unity.Entities.JobChunkExtensions+JobChunkProducer`1[T].Execute (Unity.Entities.JobChunkExtensions+JobChunkWrapper`1[T]& jobWrapper, System.IntPtr additionalPtr, System.IntPtr bufferRangePatchData, Unity.Jobs.LowLevel.Unsafe.JobRanges& ranges, System.Int32 jobIndex) [0x00000] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at (wrapper delegate-invoke) Unity.Entities.JobChunkExtensions+JobChunkProducer`1+ExecuteJobFunction[C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem+InitializeTrafficLightsJob].invoke_void_JobChunkExtensions/JobChunkWrapper`1<T>&_intptr_intptr_JobRanges&_int(Unity.Entities.JobChunkExtensions/JobChunkWrapper`1<C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem/InitializeTrafficLightsJob>&,intptr,intptr,Unity.Jobs.LowLevel.Unsafe.JobRanges&,int)
Colossal.Logging.CustomLogHandler:LogException(Exception, Object)
UnityEngine.Logger:LogException(Exception, Object)
UnityEngine.Debug:CallOverridenDebugHandler(Exception, Object)

@GIS-PuppetMaster
Copy link
Author

I'm able to replicate this issue. The game might crash to desktop or throw an exception when upgrading a road.我能够复制这个问题。升级道路时,游戏可能会崩溃到桌面或引发异常。

Object reference not set to an instance of an object
NullReferenceException: Object reference not set to an instance of an object
  at Unity.Entities.ECBChunk.Bump (System.Int32 size) [0x00000] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at Unity.Entities.EntityCommandBufferData.Reserve (Unity.Entities.EntityCommandBufferChain* chain, System.Int32 sortKey, System.Int32 size) [0x00116] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at Unity.Entities.EntityCommandBufferData.AddEntityComponentTypeWithValueCommand[T] (Unity.Entities.EntityCommandBufferChain* chain, System.Int32 sortKey, Unity.Entities.ECBCommand op, Unity.Entities.Entity e, T component) [0x0003c] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at Unity.Entities.EntityCommandBuffer.AddComponent[T] (Unity.Entities.Entity e, T component) [0x00018] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem+InitializeTrafficLightsJob.InitializeTrafficLights (Unity.Entities.DynamicBuffer`1[T] subLanes, Unity.Collections.NativeList`1[T] groups, System.Int32 groupCount, System.Boolean isLevelCrossing, Game.Net.TrafficLights& trafficLights) [0x000f9] in <dfcc6cdd930f477d9380235c3d3625a0>:0 
  at C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem+InitializeTrafficLightsJob.Execute (Unity.Entities.ArchetypeChunk& chunk, System.Int32 unfilteredChunkIndex, System.Boolean useEnabledMask, Unity.Burst.Intrinsics.v128& chunkEnabledMask) [0x000d9] in <dfcc6cdd930f477d9380235c3d3625a0>:0 
  at C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem+InitializeTrafficLightsJob.Unity.Entities.IJobChunk.Execute (Unity.Entities.ArchetypeChunk& chunk, System.Int32 unfilteredChunkIndex, System.Boolean useEnabledMask, Unity.Burst.Intrinsics.v128& chunkEnabledMask) [0x00000] in <dfcc6cdd930f477d9380235c3d3625a0>:0 
  at Unity.Entities.JobChunkExtensions+JobChunkProducer`1[T].ExecuteInternal (Unity.Entities.JobChunkExtensions+JobChunkWrapper`1[T]& jobWrapper, System.IntPtr bufferRangePatchData, Unity.Jobs.LowLevel.Unsafe.JobRanges& ranges, System.Int32 jobIndex) [0x000b5] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at Unity.Entities.JobChunkExtensions+JobChunkProducer`1[T].Execute (Unity.Entities.JobChunkExtensions+JobChunkWrapper`1[T]& jobWrapper, System.IntPtr additionalPtr, System.IntPtr bufferRangePatchData, Unity.Jobs.LowLevel.Unsafe.JobRanges& ranges, System.Int32 jobIndex) [0x00000] in <9a7e91fb1c0a42bdb40b67eb2c0b13bb>:0 
  at (wrapper delegate-invoke) Unity.Entities.JobChunkExtensions+JobChunkProducer`1+ExecuteJobFunction[C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem+InitializeTrafficLightsJob].invoke_void_JobChunkExtensions/JobChunkWrapper`1<T>&_intptr_intptr_JobRanges&_int(Unity.Entities.JobChunkExtensions/JobChunkWrapper`1<C2VM.TrafficLightsEnhancement.Systems.TrafficLightInitializationSystem.PatchedTrafficLightInitializationSystem/InitializeTrafficLightsJob>&,intptr,intptr,Unity.Jobs.LowLevel.Unsafe.JobRanges&,int)
Colossal.Logging.CustomLogHandler:LogException(Exception, Object)
UnityEngine.Logger:LogException(Exception, Object)
UnityEngine.Debug:CallOverridenDebugHandler(Exception, Object)

Great! Glad to be helpful

slyh3 pushed a commit that referenced this issue Jan 20, 2024
slyh3 pushed a commit that referenced this issue Jan 21, 2024
@slyh
Copy link
Owner

slyh commented Jan 21, 2024

Unfortunately, I think it needs significant changes to fix the problem permanently. I have implemented a temporary fix that should reduce the number of crashes, making it unlikely to crash during normal gameplay.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants