File tree Expand file tree Collapse file tree 1 file changed +8
-11
lines changed
Assets/View/Office/States Expand file tree Collapse file tree 1 file changed +8
-11
lines changed Original file line number Diff line number Diff line change @@ -20,17 +20,14 @@ private void Start() {
20
20
}
21
21
22
22
protected virtual void Update ( ) {
23
- if ( _brain . ActiveBlend == null ) {
24
- return ;
25
- }
26
-
27
- float progress ;
28
- if ( _brain . ActiveBlend . CamA == Camera ) {
29
- progress = 1 - _brain . ActiveBlend . BlendWeight ;
30
- } else if ( _brain . ActiveBlend . CamB == Camera ) {
31
- progress = _brain . ActiveBlend . BlendWeight ;
32
- } else {
33
- progress = IsActive ? 1 : 0 ;
23
+ float progress = IsActive ? 1 : 0 ;
24
+
25
+ if ( _brain . ActiveBlend != null ) {
26
+ if ( _brain . ActiveBlend . CamA == Camera ) {
27
+ progress = 1 - _brain . ActiveBlend . BlendWeight ;
28
+ } else if ( _brain . ActiveBlend . CamB == Camera ) {
29
+ progress = _brain . ActiveBlend . BlendWeight ;
30
+ }
34
31
}
35
32
36
33
if ( _progress . HasChanged ( progress ) ) {
You can’t perform that action at this time.
0 commit comments