Example #1
0
// for editor only
static void OnSysSpecLightChange( ICVar *pVar )
{
	IEntityItPtr it	= GetIEntitySystem()->GetEntityIterator();
	it->MoveFirst();

	while(IEntity *pEntity = it->Next())
	{
		IScriptTable *pScriptTable = pEntity->GetScriptTable();
		if (pScriptTable && pScriptTable->HaveValue("OnSysSpecLightChanged"))
		{
			Script::CallMethod( pScriptTable, "OnSysSpecLightChanged" );
		}
	}
}