private void OnEnable()
 {
     _sourceType   = EditorPrefsExt.GetEnum(_sourceTypeKey, MeshSourceType.SelectedObject);
     _customMesh   = EditorPrefsExt.GetAsset <Mesh>(_customMeshKey);
     _subMeshIndex = EditorPrefs.GetInt(_subMeshIndexKey, -1);
     _uvIndex      = Mathf.Clamp(EditorPrefs.GetInt(_uvIndexKey, 0), 0, 4);
 }
Пример #2
0
 private void OnEnable()
 {
     _sourceType    = EditorPrefsExt.GetEnum(_sourceTypeKey, TextureSourceType.None);
     _materialId    = EditorPrefs.GetInt(_materialIdKey, 0);
     _propertyName  = EditorPrefs.GetString(_propertyNameKey, string.Empty);
     _filterMode    = Mathf.Clamp(EditorPrefs.GetInt(_filterModeKey, 1), 0, 1);
     _customTexture = EditorPrefsExt.GetAsset <Texture2D>(_customTextureKey);
     _repeating     = EditorPrefs.GetBool(_repeatingKey, false);
     _color         = EditorPrefsExt.GetColor(_colorKey, Color.white);
     _channelFlag   = EditorPrefsExt.GetEnum(_channelFlagKey, TextureChannelFlags.RGBA);
 }