private bool CacheFields(SerializedProperty property, GUIContent label) { // if you refactor a class, it's field names might change but that won't be reflected here. // fail gracefully by returning false instead of emitting hundreds of hard exceptions. try { this._animationClipField = property.FindPropertyRelativeExplosive("_animationClip"); this._parentOverrideField = property.FindPropertyRelativeExplosive("_parentOverride"); this._yRotationFixField = property.FindPropertyRelativeExplosive("_yRotationFix"); } catch (Exception e) { this._cacheFieldsFailureMessage = e.Message; return false; } return true; }
private bool CacheFields(SerializedProperty property, GUIContent label) { // if you refactor a class, it's field names might change but that won't be reflected here. // fail gracefully by returning false instead of emitting hundreds of hard exceptions. try { this._pivotHostField = property.FindPropertyRelativeExplosive("_pivotHost"); this._pivotHostOffsetField = property.FindPropertyRelativeExplosive("_pivotHostOffset"); this._useCameraCollisionField = property.FindPropertyRelativeExplosive("_useCameraCollision"); } catch (Exception e) { this._cacheFieldsFailureMessage = e.Message; return false; } return true; }
private bool CacheFields(SerializedProperty property, GUIContent label) { // if you refactor a class, it's field names might change but that won't be reflected here. // fail gracefully by returning false instead of emitting hundreds of hard exceptions. try { this._mouseOrbitField = property.FindPropertyRelativeExplosive("_mouseOrbit"); this._targetOffsetField = property.FindPropertyRelativeExplosive("_targetOffset"); this._mouseOrbitDistanceField = property.FindPropertyRelativeExplosive("_mouseOrbitDistance"); this._mousePitchRangeField = property.FindPropertyRelativeExplosive("_mousePitchRange"); this._mouseSensitivityField = property.FindPropertyRelativeExplosive("_mouseSensitivity"); this._mouseInvertYField = property.FindPropertyRelativeExplosive("_mouseInvertY"); this._motionSmoothingField = property.FindPropertyRelativeExplosive("_motionSmoothing"); this._useCameraCollisionField = property.FindPropertyRelativeExplosive("_useCameraCollision"); } catch (Exception e) { this._cacheFieldsFailureMessage = e.Message; return false; } return true; }
private bool CacheFields(SerializedProperty property, GUIContent label) { // if you refactor a class, it's field names might change but that won't be reflected here. // fail gracefully by returning false instead of emitting hundreds of hard exceptions. try { this._positionRootTransformField = property.FindPropertyRelativeExplosive("_positionRootTransform"); this._characterTransformField = property.FindPropertyRelativeExplosive("_characterTransform"); this._positionOffsetField = property.FindPropertyRelativeExplosive("_positionOffset"); this._pitchRangeField = property.FindPropertyRelativeExplosive("_pitchRange"); this._mouseLookSensitivityField = property.FindPropertyRelativeExplosive("_mouseLookSensitivity"); this._mouseSmoothingField = property.FindPropertyRelativeExplosive("_mouseSmoothing"); } catch (Exception e) { this._cacheFieldsFailureMessage = e.Message; return false; } return true; }