Opened 12 years ago

Closed 12 years ago

#1042 closed defect (fixed)

Assertion failure in CCmpRallyPointRenderer::CreateMarker while using Atlas

Reported by: historic_bruno Owned by: vts
Priority: Release Blocker Milestone: Alpha 8
Component: UI & Simulation Keywords:
Cc: vts Patch:

Description

Possibly a component initialization order bug? (some info about that here)

To reproduce:

  1. Open Atlas.
  2. Create a civil centre.
  3. Start the simulation.
  4. Reset the simulation. Get the following assertion failure:
Assertion failed: "!cmpPlayerManager.null()"
Location: CCmpRallyPointRenderer.cpp:446 (CCmpRallyPointRenderer::CreateMarker)

Call stack:

CCmpRallyPointRenderer::CreateMarker (ccmprallypointrenderer.cpp:446)
    this = (unavailable)
    ownerId = 1 (0x00000001)

CCmpRallyPointRenderer::Init (ccmprallypointrenderer.cpp:413)
    this = (unavailable)
    paramNode = 0x0DFC7000 -> 
        m_Value = (unsupported basic_string<wchar_t,char_traits<wchar_t> >)
        m_Childs = (unsupported map<basic_string<char,char_traits<char> >,CParamNode >)
        m_IsOk = true 
        m_ScriptVal = 
            m_Val = 
                px = 0x00000000
                pn = 
                    pi_ = 0x00000000




    texturePropsBase = 
        m_Path = 
            path = (unsupported basic_string<wchar_t,char_traits<wchar_t> >)
            separator = 47 ('/')

        m_Filter = 9987 (0x00002703)
        m_WrapS = 33069 (0x0000812D)
        m_WrapT = 33071 (0x0000812F)
        m_Aniso = 4.000000 (0x40800000)

    texturePropsMask = 
        m_Path = 
            path = (unsupported basic_string<wchar_t,char_traits<wchar_t> >)
            separator = 47 ('/')

        m_Filter = 9987 (0x00002703)
        m_WrapS = 33069 (0x0000812D)
        m_WrapT = 33071 (0x0000812F)
        m_Aniso = 4.000000 (0x40800000)


CCmpProjectileManager::Deserialize (ccmpprojectilemanager.cpp:80)
    this = (unavailable)
    paramNode = 0x0DFC7000 (see above)
    __formal = 0x039AFA80 -> (IDeserializer)

CComponentManager::DeserializeState (componentmanagerserialization.cpp:311)
    this = (unavailable)
    stream = 0x0CA618B0 -> (basic_istream<char,char_traits<char> >)
    rng = (unsupported basic_string<char,char_traits<char> >)
    deserializer = 
        (IDeserializer)
        m_ScriptBackrefs = (unsupported map<size_t,JSObject * >)
        m_ScriptInterface = 0x0053FE80 -> 
            m = (auto_ptr<ScriptInterface_impl>)

        m_Stream = 0x0CA618B0 (see above)

    noParam = 
        m_Value = (unsupported basic_string<wchar_t,char_traits<wchar_t> >)
        m_Childs = (unsupported map<basic_string<char,char_traits<char> >,CParamNode >)
        m_IsOk = true 
        m_ScriptVal = 
            m_Val = 
                px = 0x00000000
                pn = 
                    pi_ = 0x00000000




    templateManager = 0x0DB0B1F8 -> 
        
            m_EntityId = 1 (0x00000001)
            m_SimContext = 0x0053FE70 -> 
                m_ComponentManager = 0x0053FE80 (see above)
                m_UnitManager = 0x00515BB8 -> 
                    m_Units = (unsupported vector<CUnit * >)
                    m_ObjectManager = 0x0B527ED4 -> 
                        m_MeshManager = 0x0B527E8C -> 
                            m_MeshMap = 
                                table_ = 
                                    
                                        
                                            buckets_ = 0x0D00CBA0 -> 
                                                next_ = 0x0B680EE0 -> 
                                                    next_ = 0x0B680C40 -> 
                                                        next_ = 0x00000000



                                            bucket_count_ = 11 (0x0000000B)
                                            allocators_ = 
                                                
                                                    (unsupported )
                                                    (unsupported )



                                        
                                            current_ = false
                                            funcs_ = "s/i"

                                        size_ = 8 (0x00000008)
                                        mlf_ = 1.000000 (0x3F800000)
                                        cached_begin_bucket_ = 0x0D00CBA0 (see above)
                                        max_load_ = 11 (0x0000000B)



                            m_ColladaManager = 0x0B527E88 -> 
                                m = 0x00515BF8 -> 
                                    dll = 
                                        m_Name = 0x015A288C -> "Collada"
                                        m_Handle = 0x00000000

                                    set_logger = 0x00000014
                                    set_skeleton_definitions = 0x00000019
                                    convert_dae_to_pmd = 0x0000001A
                                    convert_dae_to_psa = 0x0000001D



                        m_SkeletonAnimManager = 0x0B527EB0 -> 
                            m_Animations = 
                                table_ = 
                                    
                                        
                                            buckets_ = 0x0DD105A8 -> 
                                                next_ = 0x00000000

                                            bucket_count_ = 11 (0x0000000B)
                                            allocators_ = 
                                                
                                                    (unsupported )
                                                    (unsupported )



                                        
                                            (too much output; skipping to next top-level symbol)

                                        size_ = 1 (0x00000001)
                                        mlf_ = 1.000000 (0x3F800000)
                                        cached_begin_bucket_ = 0x0DD105C4 -> 
                                            next_ = 0x0D636AD0 -> 
                                                next_ = 0x00000000


                                        max_load_ = 11 (0x0000000B)



                            m_ColladaManager = 0x0B527E88 (see above)

                        m_Simulation = 0x004F96B8 -> 
                            m = 0x0053FE70 (see above)

                        m_Objects = (unsupported map<CObjectManager::ObjectKey,CObjectEntry * >)
                        m_ObjectBases = (unsupported map<CStrW,CObjectBase * >)


                m_Terrain = 0x00515B98 -> 
                    m_MapSize = 257 (0x00000101)
                    m_MapSizePatches = 16 (0x00000010)
                    m_Patches = 0x0A790024 -> 
                        
                            m_WorldBounds = 
                                m_Data = [2] 
                                    
                                        X = 0.000000 (0x00000000)
                                        Y = 0.000000 (0x00000000)
                                        Z = 0.000000 (0x00000000)

                                    
                                        X = 64.000000 (0x42800000)
                                        Y = 22.382513 (0x41B30F63)
                                        Z = 64.000000 (0x42800000)


                            m_Transform = 
                                _11 = 1.000000 (0x3F800000)
                                _21 = 0.000000 (0x00000000)
                                _31 = 0.000000 (0x00000000)
                                _41 = 0.000000 (0x00000000)
                                _12 = 0.000000 (0x00000000)
                                _22 = 1.000000 (0x3F800000)
                                _32 = 0.000000 (0x00000000)
                                _42 = 0.000000 (0x00000000)
                                _13 = 0.000000 (0x00000000)
                                _23 = 0.000000 (0x00000000)
                                _33 = 1.000000 (0x3F800000)
                                _43 = 0.000000 (0x00000000)
                                _14 = 0.000000 (0x00000000)
                                _24 = 0.000000 (0x00000000)
                                _34 = 0.000000 (0x00000000)
                                _44 = 1.000000 (0x3F800000)
                                _data = [16] 
                                    1.000000 (0x3F800000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    1.000000 (0x3F800000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    1.000000 (0x3F800000)
                                    0.000000 (0x00000000) ...
                                _data2d = [4] 
                                    [4] { 1.000000 (0x3F800000), 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000) }
                                    [4] { 0.000000 (0x00000000), 1.000000 (0x3F800000), 0.000000 (0x00000000), 0.000000 (0x00000000) }
                                    [4] { 0.000000 (0x00000000), 0.000000 (0x00000000), 1.000000 (0x3F800000), 0.000000 (0x00000000) }
                                    [4] { 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000), 1.000000 (0x3F800000) }

                            m_InvTransform = 
                                _11 = 0.000000 (0x00000000)
                                _21 = 0.000000 (0x00000000)
                                _31 = 0.000000 (0x00000000)
                                _41 = 0.000000 (0x00000000)
                                _12 = 0.000000 (0x00000000)
                                _22 = 0.000000 (0x00000000)
                                _32 = 0.000000 (0x00000000)
                                _42 = 0.000000 (0x00000000)
                                _13 = 0.000000 (0x00000000)
                                _23 = 0.000000 (0x00000000)
                                _33 = 0.000000 (0x00000000)
                                _43 = 0.000000 (0x00000000)
                                _14 = 0.000000 (0x00000000)
                                _24 = 0.000000 (0x00000000)
                                _34 = 0.000000 (0x00000000)
                                _44 = 0.000000 (0x00000000)
                                _data = [16] 
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000)
                                    0.000000 (0x00000000) ...
                                _data2d = [4] 
                                    [4] { 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000) }
                                    [4] { 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000) }
                                    [4] { 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000) }
                                    [4] { 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000), 0.000000 (0x00000000) }

                            m_RenderData = 0x00000000
                            m_BoundsValid = true 

                        m_bWillBeDrawn = false
                        m_MiniPatches = [16] 
                            [16] 
                                
                                    Tex = 0x0D835CB8 -> 
                                        m_Tag = { (unsupported basic_string<char,char_traits<char> >) }
                                        m_pProperties = 
                                            px = 0x0D7EA718 -> 
                                                m_pParent = 
                                                    px = 0x0D730B78 -> 
                                                        m_pParent = 
                                                            px = 0x00000000
                                                            pn = 
                                                                pi_ = 0x00000000


                                                        m_BaseColor = 0 (0x00000000)
                                                        m_HasBaseColor = false
                                                        m_MovementClass = { (unsupported basic_string<char,char_traits<char> >) }
                                                        m_Groups = (unsupported vector<CTerrainGroup * >)

                                                    pn = 
                                                        pi_ = 0x0B5301F8 -> 
                                                            use_count_ = 20 (0x00000014)
                                                            weak_count_ = 1 (0x00000001)



                                                m_BaseColor = 0 (0x00000000)
                                                m_HasBaseColor = false
                                                m_MovementClass = { (unsupported basic_string<char,char_traits<char> >) }
                                                m_Groups = (unsupported vector<CTerrainGroup * >)

                                            pn = 
                                                pi_ = 0x0D836698 -> 
                                                    use_count_ = 16 (0x00000010)
                                                    weak_count_ = 1 (0x00000001)



                                        m_Texture = 
                                            px = 0x0D8425E0 -> 
                                                m_Properties = 
                                                    m_Path = 
                                                        path = (unsupported basic_string<wchar_t,char_traits<wchar_t> >)
                                                        separator = "/r✃"

                                                    m_Filter = 9987 (0x00002703)
                                                    m_WrapS = 10497 (0x00002901)
                                                    m_WrapT = 10497 (0x00002901)
                                                    m_Aniso = 2.000000 (0x40000000)

                                                m_Handle = 9502865 (0x0000000000910091)
                                                m_BaseColour = 4287075159 (0xFF879357)
                                                m_State = LOADED
                                                m_TextureManager = 0x00503310 -> 
                                                    m_VFS = 
                                                        px = 0x0048DA40 -> (IVFS)
                                                        pn = 
                                                            pi_ = 0x0048CDB8 -> 
                                                                use_count_ = 4 (0x00000004)
                                                                weak_count_ = 1 (0x00000001)



                                                    m_CacheLoader = 
                                                        m_VFS = 
                                                            px = 0x0048DA40 (see above)
                                                            pn = 
                                                                pi_ = 0x0048CDB8 (see above)


                                                        m_FileExtension = (unsupported basic_string<wchar_t,char_traits<wchar_t> >)

                                                    m_DisableGL = false
                                                    m_TextureConverter = 
                                                        m_VFS = 
                                                            px = 0x0048DA40 (see above)
                                                            pn = 
                                                                pi_ = 0x0048CDB8 (see above)


                                                        m_HighQuality = false
                                                        m_WorkerThread = 952 (0x000003B8)
                                                        m_WorkerMutex = 0x005E09B0
                                                        m_WorkerSem = 0x000003B4
                                                        m_RequestQueue = (unsupported deque<boost::shared_ptr<CTextureConverter::ConversionRequest> >)
                                                        m_ResultQueue = (unsupported deque<boost::shared_ptr<CTextureConverter::ConversionResult> >)
                                                        m_Shutdown = false

                                                    m_DefaultHandle = 65537 (0x0000000000010001)
                                                    m_ErrorHandle = 131074 (0x0000000000020002)
                                                    m_ErrorTexture = 
                                                        px = 0x0048BDB8 -> 
                                                            m_Properties = 
                                                                m_Path = 
                                                                    path = (unsupported basic_string<wchar_t,char_traits<wchar_t> >)
                                                                    separator = "/f✃"

                                                                m_Filter = 9987 (0x00002703)
                                                                m_WrapS = 10497 (0x00002901)
                                                                m_WrapT = 10497 (0x00002901)
                                                                m_Aniso = 1.000000 (0x3F800000)

                                                            m_Handle = 131074 (0x0000000000020002)
                                                            m_BaseColour = 0 (0x00000000)
                                                            m_State = LOADED
                                                            m_TextureManager = 0x00503310 (see above)
                                                            m_Self = 
                                                                px = 0x0048BDB8 (see above)
                                                                pn = 
                                                                    pi_ = 0x005173E8 -> 
                                                                        use_count_ = 1 (0x00000001)
                                                                        weak_count_ = 2 (0x00000002)




                                                        pn = 
                                                            pi_ = 0x005173E8 (see above)


                                                    m_TextureCache = 
                                                        table_ = 
                                                            
                                                                
                                                                    buckets_ = 0x0D858F30 -> 
                                                                        next_ = 0x00000000

                                                                    bucket_count_ = 769 (0x00000301)
                                                                    allocators_ = 
                                                                        
                                                                            (unsupported )
                                                                            (unsupported )



                                                                
                                                                    current_ = false
                                                                    funcs_ = [2] { { data_ = { buf = [2] { [8] { 3, 3, 0, 0, 0, 0, 0, 183 }, 3 }, align_ = 
                                                                                    t0 = 3
                                                                                    t1 = 3
                                                                                    t2 = 3
                                                                                    t3 = 3
                                                                                    t4 = 3
                                                                                    t5 = 3
                                                                                    t6 = 3
                                                                                    t7 = 3
                                                                                    t8 = 3
                                                                                    t9 = 3
                                                                                    t10 = 3
                                                                                    t11 = 3
                                                                                    t12 = 3
                                                                                    t13 = 3
                                                                                    t14 = 3
                                                                                    t15 = 3
                                                                                    t16 = 3
                                                                                    t17 = 3
                                                                                    t18 = 3
                                                                                    t19 = 3
                                                                                    t20 = 3
                                                                                    t21 = 3
                                                                                    t22 = 3
                                                                                    t23 = 3
 } }, { data_ = { buf = [2] { [8] { 0, 0, 0, 0, 0, 183, 2, 0 }, 0 }, align_ = 
                                                                                    t0 = 0
                                                                                    t1 = 0
                                                                                    t2 = 0
                                                                                    t3 = 0
                                                                                    t4 = 0
                                                                                    t5 = 0
                                                                                    t6 = 0
                                                                                    t7 = 0
                                                                                    t8 = 0
                                                                                    t9 = 0
                                                                                    t10 = 0
                                                                                    t11 = 0
                                                                                    t12 = 0
                                                                                    t13 = 0
                                                                                    t14 = 0
                                                                                    t15 = 0
                                                                                    t16 = 0
                                                                                    t17 = 0
                                                                                    t18 = 0
                                                                                    t19 = 0
                                                                                    t20 = 0
                                                                                    t21 = 0
                                                                                    t22 = 0
                                                                                    t23 = 0
 } } }

                                                                size_ = 695 (0x000002B7)
                                                                mlf_ = 1.000000 (0x3F800000)
                                                                cached_begin_bucket_ = 0x0D858F34 -> 
                                                                    next_ = 0x0D8A21B0 -> 
                                                                        next_ = 0x0D78C838 -> 
                                                                            next_ = 0x00000000



                                                                max_load_ = 769 (0x00000301)



                                                    m_HotloadFiles = 
                                                        table_ = 
                                                            
                                                                
                                                                    buckets_ = 0x0D859BB8 -> 
                                                                        next_ = 0x00000000

                                                                    bucket_count_ = 769 (0x00000301)
                                                                    allocators_ = 
                                                                        
                                                                            (unsupported )
                                                                            (unsupported )



                                                                
                                                                    current_ = false
                                                                    funcs_ = [2] { { data_ = { buf = [1] { [8] { 4, 0, 0, 214, 2, 0, 0, 0 } }, align_ = 
                                                                                    t0 = 4
                                                                                    t1 = 4
                                                                                    t2 = 4
                                                                                    t3 = 4
                                                                                    t4 = 4
                                                                                    t5 = 4
                                                                                    t6 = 4
                                                                                    t7 = 4
                                                                                    t8 = 4
                                                                                    t9 = 4
                                                                                    t10 = 4
                                                                                    t11 = 4
                                                                                    t12 = 4
                                                                                    t13 = 4
                                                                                    t14 = 4
                                                                                    t15 = 4
                                                                                    t16 = 4
                                                                                    t17 = 4
                                                                                    t18 = 4
                                                                                    t19 = 4
                                                                                    t20 = 4
                                                                                    t21 = 4
                                                                                    t22 = 4
                                                                                    t23 = 4
 } }, { data_ = { buf = [1] { [8] { 0, 0, 214, 2, 0, 0, 0, 0 } }, align_ = 
                                                                                    t0 = 0
                                                                                    t1 = 0
                                                                                    t2 = 0
                                                                                    t3 = 0
                                                                                    t4 = 0
                                                                                    t5 = 0
                                                                                    t6 = 0
                                                                                    t7 = 0
                                                                                    t8 = 0
                                                                                    t9 = 0
                                                                                    t10 = 0
                                                                                    t11 = 0
                                                                                    t12 = 0
                                                                                    t13 = 0
                                                                                    t14 = 0
                                                                                    t15 = 0
                                                                                    t16 = 0
                                                                                    t17 = 0
                                                                                    t18 = 0
                                                                                    t19 = 0
                                                                                    t20 = 0
                                                                                    t21 = 0
                                                                                    t22 = 0
                                                                                    t23 = 0
 } } }

                                                                size_ = 726 (0x000002D6)
                                                                mlf_ = 1.000000 (0x3F800000)
                                                                cached_begin_bucket_ = 0x0D859BBC -> 
                                                                    next_ = 0x0D8329A8 -> 
                                                                        next_ = 0x00000000


                                                                max_load_ = 769 (0x00000301)



                                                    m_SettingsFiles = 
                                                        table_ = 
                                                            
                                                                
                                                                    buckets_ = 0x0B606B60 -> 
                                                                        next_ = 0x0B5D7BE8 -> 
                                                                            next_ = 0x00000000


                                                                    bucket_count_ = 53 (0x00000035)
                                                                    allocators_ = 
                                                                        
                                                                            (unsupported )
                                                                            (unsupported )



                                                                
                                                                    current_ = false
                                                                    funcs_ = [2] { { data_ = { buf = [1] { [8] { 0, 0, 0, 31, 0, 0, 0, 0 } }, align_ = 
                                                                                    t0 = 0
                                                                                    t1 = 0
                                                                                    t2 = 0
                                                                                    t3 = 0
                                                                                    t4 = 0
                                                                                    t5 = 0
                                                                                    t6 = 0
                                                                                    t7 = 0
                                                                                    t8 = 0
                                                                                    t9 = 0
                                                                                    t10 = 0
                                                                                    t11 = 0
                                                                                    t12 = 0
                                                                                    t13 = 0
                                                                                    t14 = 0
                                                                                    t15 = 0
                                                                                    t16 = 0
                                                                                    t17 = 0
                                                                                    t18 = 0
                                                                                    t19 = 0
                                                                                    t20 = 0
                                                                                    t21 = 0
                                                                                    t22 = 0
                                                                                    t23 = 0
 } }, { data_ = { buf = [1] { [8] { 0, 0, 31, 0, 0, 0, 0, 0 } }, align_ = 
                                                                                    t0 = 0
                                                                                    t1 = 0
                                                                                    t2 = 0
                                                                                    t3 = 0
                                                                                    t4 = 0
                                                                                    t5 = 0
                                                                                    t6 = 0
                                                                                    t7 = 0
                                                                                    t8 = 0
                                                                                    t9 = 0
                                                                                    t10 = 0
                                                                                    t11 = 0
                                                                                    t12 = 0
                                                                                    t13 = 0
                                                                                    t14 = 0
                                                                                    t15 = 0
                                                                                    t16 = 0
                                                                                    t17 = 0
                                                                                    t18 = 0
                                                                                    t19 = 0
                                                                                    t20 = 0
                                                                                    t21 = 0
                                                                                    t22 = 0
                                                                                    t23 = 0
 } } }

                                                                size_ = 31 (0x0000001F)
                                                                mlf_ = 1.000000 (0x3F800000)
                                                                cached_begin_bucket_ = 0x0B606B60 (see above)
                                                                max_load_ = 53 (0x00000035)




                                                m_Self = 
                                                    px = 0x0D8425E0 (see above)
                                                    pn = 
                                                        pi_ = 0x0D836710 -> 
                                                            use_count_ = 2 (0x00000002)
                                                            weak_count_ = 9 (0x00000009)




                                            pn = 
                                                pi_ = 0x0D836710 (see above)


                                        m_BaseColor = 4287075159 (0xFF879357)
                                        m_BaseColorValid = true 
                                        m_Groups = (unsupported vector<CTerrainGroup * >)

                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)
 ...
                            [16] 
                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)
 ...
                            [16] 
                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)
 ...
                            [16] 
                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)
 ...
                            [16] 
                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)
 ...
                            [16] 
                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)
 ...
                            [16] 
                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)
 ...
                            [16] 
                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)

                                
                                    Tex = 0x0D835CB8 (see above)
                                    Priority = 0 (0x00000000)
 ... ...
                        m_X = 0 (0x00000000)
                        m_Z = 0 (0x00000000)
                        m_Parent = 0x00515B98 (see above)

                    m_Heightmap = 0x0D8C1B88 -> 16384 (0x4000)
                    m_BaseColour = 
                        R = [8] { 255 (0xFF), 255 (0xFF), 255 (0xFF), 255 (0xFF), 0 (0x00), 0 (0x00), 0 (0x00), 0 (0x00) }
                        G = 255 (0xFF)
                        B = 255 (0xFF)
                        A = 255 (0xFF)





    numComponentTypes = 47 (0x0000002F)
    i = 13 (0x0000000D)
    ctid = 27 (0x0000001B)
    ctname = (unsupported basic_string<char,char_traits<char> >)
    numComponents = 1 (0x00000001)
    j = 0 (0x00000000)
    ent = 11 (0x0000000B)

SimState::Thaw (simstate.cpp:41)
    this = (unavailable)

ViewGame::RestoreState (view.cpp:325)
    this = (unavailable)
    label = 0x039AFB60 -> (unsupported basic_string<wchar_t,char_traits<wchar_t> >)

AtlasMessage::fSimStateRestore_wrapper (mischandlers.cpp:131)
    msg = 0x0D2E4B28 -> (AtlasMessage::IMessage)

RunEngine (gameloop.cpp:171)
    data = 0x003DF6B4
    hooks = 
        override_gl_upload_caps = 0x00000000
        get_log_dir = 0x00000000
        bundle_logs = 0x00000000
        translate = 0x00000000
        translate_free = 0x00000000
        log = 0x00000000
        display_error = 0x01495AC0 -> (AtlasDisplayError)

    msgPasser = 0x003DEC98 -> 
        (AtlasMessage::MessagePasser)
        m_Mutex = 
            m_Mutex = 0x005951F0

        m_SemaphoreName = { (unsupported basic_string<char,char_traits<char> >) }
        m_Semaphore = 0x00427CA8 -> 540 (0x0000021C)
        m_Queue = (unsupported queue<AtlasMessage::IMessage *,deque<AtlasMessage::IMessage * > >)
        m_Trace = false

    last_activity = 35.0672 (0x4041889A50029B49)
    args = 
        m_Args = (unsupported vector<pair<CStr8,CStr8> >)
        m_Arg0 = 
            path = (unsupported basic_string<wchar_t,char_traits<wchar_t> >)
            separator = 92 ('\')


    recent_activity = true 
    time = 2.10768e-307 (0x0042F1E02C5814E4)
    ev = 
        ev = 
            type = 10 (0x0A)
            active = { type = 10 (0x0A), gain = 209 (0xD1), state = 130 (0x82) }
            key = 
                type = 10 (0x0A)
                keysym = { sym = 1076594528, unicode = 63328 (0xF760) }

            motion = { type = 10 (0x0A), x = 3970 (0x0F82), y = 34656 (0x8760) }
            button = 
                type = 10 (0x0A)
                button = 209 (0xD1)
                state = 130 (0x82)
                x = 34656 (0x8760)
                y = 16427 (0x402B)

            resize = { type = 10 (0x0A), w = 1076594528 (0x402B8760), h = 5371744 (0x0051F760) }
            expose = { type = 10 (0x0A) }
            quit = { type = 10 (0x0A) }
            user = { type = 10 (0x0A), code = 1076594528 (0x402B8760), data1 = 0x0051F760 }


    length = 0.000000 (0x0D2E4B28)
    last_time = 35.1173 (0x40418F05381DA643)
    msg = 0x0D2E4B28 (see above)
    name = (unsupported basic_string<char,char_traits<char> >)
    sleepUntil = 2.10768e-307 (0x0042F1E02C5814E4)

thread_start (wpthread.cpp:624)
    param = 0x005993E8
    ret = 0x6B980350

endthreadex (:0)

endthreadex (:0)

RtlInitializeExceptionChain (:0)

RtlInitializeExceptionChain (:0)


errno = 0 (No error reported here)
OS error = 0 (no error code was set)

Change History (6)

comment:1 by historic_bruno, 12 years ago

Priority: Should HaveRelease Blocker

Actually it breaks saving too (test during a game using Shift+F5 and Shift+F8).

comment:2 by vts, 12 years ago

Owner: set to vts
Status: newassigned

comment:3 by vts, 12 years ago

This is caused because while writing the code I assumed that SYSTEM_ENTITY components are always available, and wrote ENSUREs to guarantee this at runtime. The line in question is:

CmpPtr<ICmpPlayerManager> cmpPlayerManager(GetSimContext(), SYSTEM_ENTITY);
ENSURE(!cmpPlayerManager.null());

in CCmpRallyPointRenderer::Init, which is called from Deserialize in response to CSimulation2::DeserializeState.

So it would seem that at the time of this crash, the player manager system entity is not in fact available. This contradicts the documentation page linked to by ben, stating:

The order of Init/Deserialize/Deinit between entities is mostly undefined, so they must not rely on other entities or components already existing; except that the SYSTEM_ENTITY is created before anything else and therefore may be used

In CSimulation2::DeserializeState, there is the following comment:

// TODO: need to make sure the required SYSTEM_ENTITY components get constructed
return m->m_ComponentManager.DeserializeState(stream);

So at first sight it would seem that this TODO is the real issue here. The symptomps of this bug could be fixed rather easily by doing an if-check for cmpPlayerManager.null() before using it, but that would not be addressing the true nature of this bug. However, considering how close we are to A8 feature freeze and depending on how quickly the underlying issue can be solved, it may be useful to prevent the crash from happening with a quick fix while keeping this ticket open to track the larger issue.

comment:4 by vts, 12 years ago

The same TODO seems to be responsible for the crash on quickload as well (also goes through a call to CSimulation2::DeserializeState).

comment:5 by vts, 12 years ago

Philip has more information:

12:40:33 ‹@Philip`› vtsj: I think that TODO was about the possibility of old or corrupted saved games not containing all the system components which the engine assumes exist, causing it to crash
12:40:58 ‹@Philip`› but that shouldn't matter with normal non-old non-corrupted saves
12:42:44 ‹@Philip`› I think the issue is probably that deserialization doesn't deserialize SYSTEM_ENTITY before other entities
12:43:08 ‹@Philip`› It does components by ComponentTypeId order instead
12:43:21 ‹@Philip`› and RallyPointRenderer comes before PlayerManager
12:43:44 ‹@Philip`› I guess that's one of the reasons why you shouldn't depend on init order :-)
13:09:18 ‹vtsj› Philip` -- ah, ok
13:09:47 ‹vtsj› so what's the plan, do we want to fix SYSTEM_ENTITY deserializing before any other entities or accept the TypeList order?
13:12:37 ‹vtsj› it's probably more difficult to have SYSTEM_ENTITY deserialize first, from the looks of CComponentManager::DeserializeState
13:13:17 ‹vtsj› but I also thought it should be preferred to not introduce order dependencies in TypeList :<
13:16:29 ‹@Philip`› I think it would be better to continue not guaranteeing init order between entities, to avoid adding complexity and rigidity into the map-loading and deserialization code
13:17:05 ‹@Philip`› I think PlayerManager is a JS component so it will always come after C++ components like RallyPointRenderer, so you can't make them load in the other order

So, the plan is to not introduce any additional component order initialization dependencies and call CCmpRallyPointRenderer::CreateMarker on-demand instead of at initialization time.

comment:6 by vts, 12 years ago

Resolution: fixed
Status: assignedclosed

(In [10722]) Allocated rally point flag entity on-demand instead of at initialization time. Fixes #1042.

Note: See TracTickets for help on using tickets.