Fix CoreConfig init to happen after SMGlobalClasses from logic bin are added.
This fixes OnSourceModConfigChanged not being called for logic classes when config is first read, matching behavior for core classes. The function is still called before each class's OnSourceModStartup func.
This commit is contained in:
		
							parent
							
								
									4ffe11a235
								
							
						
					
					
						commit
						f4ff0e574c
					
				@ -176,9 +176,6 @@ bool SourceModBase::InitializeSourceMod(char *error, size_t maxlength, bool late
 | 
				
			|||||||
		return false;
 | 
							return false;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	/* Initialize CoreConfig to get the SourceMod base path properly - this parses core.cfg */
 | 
					 | 
				
			||||||
	g_CoreConfig.Initialize();
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	/* There will always be a path by this point, since it was force-set above. */
 | 
						/* There will always be a path by this point, since it was force-set above. */
 | 
				
			||||||
	m_GotBasePath = true;
 | 
						m_GotBasePath = true;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -276,6 +273,9 @@ void SourceModBase::StartSourceMod(bool late)
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
	InitLogicBridge();
 | 
						InitLogicBridge();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						/* Initialize CoreConfig to get the SourceMod base path properly - this parses core.cfg */
 | 
				
			||||||
 | 
						g_CoreConfig.Initialize();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	/* Notify! */
 | 
						/* Notify! */
 | 
				
			||||||
	SMGlobalClass *pBase = SMGlobalClass::head;
 | 
						SMGlobalClass *pBase = SMGlobalClass::head;
 | 
				
			||||||
	while (pBase)
 | 
						while (pBase)
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user