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

Null reference while creating dwarf sprite (source parameter) [extremely rare] #1011

Open
mklingen opened this issue Feb 16, 2019 · 1 comment
Labels
A Bug High priority bug Crash

Comments

@mklingen
Copy link
Collaborator

https://sentry.io/cfg/dwarfcorp/issues/885777624/?referrer=github_plugin

TargetInvocationException: Exception has been thrown by the target of an invocation.
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\Entities\EntityFactory.cs", line 88, in Initialize { <lambda> }
    DwarfCorp.GameComponent <Initialize>b__1(Microsoft.Xna.Framework.Vector3, DwarfCorp.Blackboard)
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\Entities\EntityFactory.cs", line 106, in CreateEntity
    T CreateEntity[T](System.String, Microsoft.Xna.Framework.Vector3, DwarfCorp.Blackboard)
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\World\WorldManager-NewGameSetup.cs", line 54, in CreateInitialDwarves
    Void CreateInitialDwarves(Microsoft.Xna.Framework.Vector3)
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\World\WorldManager-NewGameSetup.cs", line 88, in CreateInitialEmbarkment
    Void CreateInitialEmbarkment()
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\World\WorldManager-Loading.cs", line 432, in LoadThreaded
    Void LoadThreaded()
...
(3 additional frame(s) were not displayed)

ArgumentNullException: Value cannot be null.
Parameter name: source
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\Entities\Dwarves\Dwarf.cs", line 195, in CreateDwarfSprite
    Void CreateDwarfSprite(DwarfCorp.EmployeeClass, DwarfCorp.ComponentManager)
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\Entities\Dwarves\Dwarf.cs", line 124, in CreateCosmeticChildren
    Void CreateCosmeticChildren(DwarfCorp.ComponentManager)
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\Entities\Dwarves\Dwarf.cs", line 73, in .ctor
    Void .ctor(DwarfCorp.ComponentManager, DwarfCorp.CreatureStats, System.String, DwarfCorp.PlanService, DwarfCorp.Faction, System.String, DwarfCorp.EmployeeClass, Microsoft.Xna.Framework.Vector3)
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\Entities\Dwarves\DwarfFactory.cs", line 91, in GenerateDwarf
    DwarfCorp.GameComponent GenerateDwarf(Microsoft.Xna.Framework.Vector3, DwarfCorp.ComponentManager, System.String, DwarfCorp.EmployeeClass, Int32, DwarfCorp.Gender, Int32)
  File "C:\Users\matth\Desktop\dwarfcorp\DwarfCorp\DwarfCorpXNA\Entities\Dwarves\DwarfFactory.cs", line 50, in __factory0
    DwarfCorp.GameComponent __factory0(DwarfCorp.ComponentManager, Microsoft.Xna.Framework.Vector3, DwarfCorp.Blackboard)
...
(1 additional frame(s) were not displayed)

Exception has been thrown by the target of an invocation.
@Blecki
Copy link
Owner

Blecki commented Feb 17, 2019

It looks like the dwarf layer library is not loading. I could see this happening if the graphics device was lost at a very, very bad moment. I don't see anyway to recover unfortunately... and honestly can't see why it's crashing instead of just being empty.

@mklingen mklingen added Crash A Bug High priority bug labels Feb 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A Bug High priority bug Crash
Projects
None yet
Development

No branches or pull requests

2 participants