Merge branch 'feture/update_ver1.1.0' of bitbucket.org:usaya/popcorn into feture/update_ver1.1.0
This commit is contained in:
		
						commit
						9d7cd5797e
					
				|  | @ -125,6 +125,8 @@ AnimatorStateMachine: | ||||||
|   - {fileID: -4201787685094799525} |   - {fileID: -4201787685094799525} | ||||||
|   - {fileID: 1938256483501769669} |   - {fileID: 1938256483501769669} | ||||||
|   - {fileID: 265964369079198928} |   - {fileID: 265964369079198928} | ||||||
|  |   - {fileID: 3094950935946956014} | ||||||
|  |   - {fileID: 6534333494996636953} | ||||||
|   m_EntryTransitions: [] |   m_EntryTransitions: [] | ||||||
|   m_StateMachineTransitions: {} |   m_StateMachineTransitions: {} | ||||||
|   m_StateMachineBehaviours: [] |   m_StateMachineBehaviours: [] | ||||||
|  | @ -276,37 +278,49 @@ AnimatorController: | ||||||
|     m_DefaultFloat: 0 |     m_DefaultFloat: 0 | ||||||
|     m_DefaultInt: 0 |     m_DefaultInt: 0 | ||||||
|     m_DefaultBool: 0 |     m_DefaultBool: 0 | ||||||
|     m_Controller: {fileID: 9100000} |     m_Controller: {fileID: 0} | ||||||
|   - m_Name: Promotion |   - m_Name: Promotion | ||||||
|     m_Type: 9 |     m_Type: 9 | ||||||
|     m_DefaultFloat: 0 |     m_DefaultFloat: 0 | ||||||
|     m_DefaultInt: 0 |     m_DefaultInt: 0 | ||||||
|     m_DefaultBool: 0 |     m_DefaultBool: 0 | ||||||
|     m_Controller: {fileID: 9100000} |     m_Controller: {fileID: 0} | ||||||
|   - m_Name: Sleepy |   - m_Name: Sleepy | ||||||
|     m_Type: 9 |     m_Type: 9 | ||||||
|     m_DefaultFloat: 0 |     m_DefaultFloat: 0 | ||||||
|     m_DefaultInt: 0 |     m_DefaultInt: 0 | ||||||
|     m_DefaultBool: 0 |     m_DefaultBool: 0 | ||||||
|     m_Controller: {fileID: 9100000} |     m_Controller: {fileID: 0} | ||||||
|   - m_Name: Walk |   - m_Name: Walk | ||||||
|     m_Type: 9 |     m_Type: 9 | ||||||
|     m_DefaultFloat: 0 |     m_DefaultFloat: 0 | ||||||
|     m_DefaultInt: 0 |     m_DefaultInt: 0 | ||||||
|     m_DefaultBool: 0 |     m_DefaultBool: 0 | ||||||
|     m_Controller: {fileID: 9100000} |     m_Controller: {fileID: 0} | ||||||
|   - m_Name: Tasting |   - m_Name: Tasting | ||||||
|     m_Type: 9 |     m_Type: 9 | ||||||
|     m_DefaultFloat: 0 |     m_DefaultFloat: 0 | ||||||
|     m_DefaultInt: 0 |     m_DefaultInt: 0 | ||||||
|     m_DefaultBool: 0 |     m_DefaultBool: 0 | ||||||
|     m_Controller: {fileID: 9100000} |     m_Controller: {fileID: 0} | ||||||
|   - m_Name: TastingWalk |   - m_Name: TastingWalk | ||||||
|     m_Type: 9 |     m_Type: 9 | ||||||
|     m_DefaultFloat: 0 |     m_DefaultFloat: 0 | ||||||
|     m_DefaultInt: 0 |     m_DefaultInt: 0 | ||||||
|     m_DefaultBool: 0 |     m_DefaultBool: 0 | ||||||
|     m_Controller: {fileID: 9100000} |     m_Controller: {fileID: 0} | ||||||
|  |   - m_Name: Advertise | ||||||
|  |     m_Type: 9 | ||||||
|  |     m_DefaultFloat: 0 | ||||||
|  |     m_DefaultInt: 0 | ||||||
|  |     m_DefaultBool: 0 | ||||||
|  |     m_Controller: {fileID: 0} | ||||||
|  |   - m_Name: AdvertiseWalk | ||||||
|  |     m_Type: 9 | ||||||
|  |     m_DefaultFloat: 0 | ||||||
|  |     m_DefaultInt: 0 | ||||||
|  |     m_DefaultBool: 0 | ||||||
|  |     m_Controller: {fileID: 0} | ||||||
|   m_AnimatorLayers: |   m_AnimatorLayers: | ||||||
|   - serializedVersion: 5 |   - serializedVersion: 5 | ||||||
|     m_Name: Base Layer |     m_Name: Base Layer | ||||||
|  | @ -421,6 +435,31 @@ AnimatorStateTransition: | ||||||
|   m_InterruptionSource: 0 |   m_InterruptionSource: 0 | ||||||
|   m_OrderedInterruption: 1 |   m_OrderedInterruption: 1 | ||||||
|   m_CanTransitionToSelf: 1 |   m_CanTransitionToSelf: 1 | ||||||
|  | --- !u!1101 &3094950935946956014 | ||||||
|  | AnimatorStateTransition: | ||||||
|  |   m_ObjectHideFlags: 1 | ||||||
|  |   m_CorrespondingSourceObject: {fileID: 0} | ||||||
|  |   m_PrefabInstance: {fileID: 0} | ||||||
|  |   m_PrefabAsset: {fileID: 0} | ||||||
|  |   m_Name:  | ||||||
|  |   m_Conditions: | ||||||
|  |   - m_ConditionMode: 1 | ||||||
|  |     m_ConditionEvent: Advertise | ||||||
|  |     m_EventTreshold: 0 | ||||||
|  |   m_DstStateMachine: {fileID: 0} | ||||||
|  |   m_DstState: {fileID: 717229652548067075} | ||||||
|  |   m_Solo: 0 | ||||||
|  |   m_Mute: 0 | ||||||
|  |   m_IsExit: 0 | ||||||
|  |   serializedVersion: 3 | ||||||
|  |   m_TransitionDuration: 0 | ||||||
|  |   m_TransitionOffset: 0 | ||||||
|  |   m_ExitTime: 0.75 | ||||||
|  |   m_HasExitTime: 0 | ||||||
|  |   m_HasFixedDuration: 1 | ||||||
|  |   m_InterruptionSource: 0 | ||||||
|  |   m_OrderedInterruption: 1 | ||||||
|  |   m_CanTransitionToSelf: 1 | ||||||
| --- !u!1102 &4390197982913342166 | --- !u!1102 &4390197982913342166 | ||||||
| AnimatorState: | AnimatorState: | ||||||
|   serializedVersion: 5 |   serializedVersion: 5 | ||||||
|  | @ -497,6 +536,31 @@ AnimatorStateTransition: | ||||||
|   m_InterruptionSource: 0 |   m_InterruptionSource: 0 | ||||||
|   m_OrderedInterruption: 1 |   m_OrderedInterruption: 1 | ||||||
|   m_CanTransitionToSelf: 0 |   m_CanTransitionToSelf: 0 | ||||||
|  | --- !u!1101 &6534333494996636953 | ||||||
|  | AnimatorStateTransition: | ||||||
|  |   m_ObjectHideFlags: 1 | ||||||
|  |   m_CorrespondingSourceObject: {fileID: 0} | ||||||
|  |   m_PrefabInstance: {fileID: 0} | ||||||
|  |   m_PrefabAsset: {fileID: 0} | ||||||
|  |   m_Name:  | ||||||
|  |   m_Conditions: | ||||||
|  |   - m_ConditionMode: 1 | ||||||
|  |     m_ConditionEvent: AdvertiseWalk | ||||||
|  |     m_EventTreshold: 0 | ||||||
|  |   m_DstStateMachine: {fileID: 0} | ||||||
|  |   m_DstState: {fileID: -7903437373564134462} | ||||||
|  |   m_Solo: 0 | ||||||
|  |   m_Mute: 0 | ||||||
|  |   m_IsExit: 0 | ||||||
|  |   serializedVersion: 3 | ||||||
|  |   m_TransitionDuration: 0 | ||||||
|  |   m_TransitionOffset: 0 | ||||||
|  |   m_ExitTime: 0.75 | ||||||
|  |   m_HasExitTime: 0 | ||||||
|  |   m_HasFixedDuration: 1 | ||||||
|  |   m_InterruptionSource: 0 | ||||||
|  |   m_OrderedInterruption: 1 | ||||||
|  |   m_CanTransitionToSelf: 1 | ||||||
| --- !u!1102 &8708174739101812674 | --- !u!1102 &8708174739101812674 | ||||||
| AnimatorState: | AnimatorState: | ||||||
|   serializedVersion: 5 |   serializedVersion: 5 | ||||||
|  |  | ||||||
|  | @ -12,6 +12,8 @@ public class BrotherPinkView : SingletonMonoBehaviour<BrotherPinkView> | ||||||
|     private static readonly int Walk = Animator.StringToHash("Walk"); |     private static readonly int Walk = Animator.StringToHash("Walk"); | ||||||
|     private static readonly int Tasting = Animator.StringToHash("Tasting"); |     private static readonly int Tasting = Animator.StringToHash("Tasting"); | ||||||
|     private static readonly int TastingWalk = Animator.StringToHash("TastingWalk"); |     private static readonly int TastingWalk = Animator.StringToHash("TastingWalk"); | ||||||
|  |     private static readonly int Advertise = Animator.StringToHash("Advertise"); | ||||||
|  |     private static readonly int AdvertiseWalk = Animator.StringToHash("AdvertiseWalk"); | ||||||
|     private static readonly Vector2 RightPos = new Vector2(4.96f, -0.26f); |     private static readonly Vector2 RightPos = new Vector2(4.96f, -0.26f); | ||||||
|     private static readonly Vector2 LeftPos = new Vector2(-4.96f, -0.26f); |     private static readonly Vector2 LeftPos = new Vector2(-4.96f, -0.26f); | ||||||
|      |      | ||||||
|  | @ -46,6 +48,13 @@ public class BrotherPinkView : SingletonMonoBehaviour<BrotherPinkView> | ||||||
|         (TastingWalk, RightPos, 0f), |         (TastingWalk, RightPos, 0f), | ||||||
|         (Tasting, RightPos + Vector2.left * .03f, 5.35f), |         (Tasting, RightPos + Vector2.left * .03f, 5.35f), | ||||||
|     }; |     }; | ||||||
|  |     private readonly (int trigger, Vector2 wayPoint, float wait)[] pinkAdvertiseMoves = | ||||||
|  |     { | ||||||
|  |         (AdvertiseWalk, LeftPos, 0f), | ||||||
|  |         (Advertise, LeftPos + Vector2.right * .03f, 5.35f), | ||||||
|  |         (AdvertiseWalk, RightPos, 0f), | ||||||
|  |         (Advertise, RightPos + Vector2.left * .03f, 5.35f), | ||||||
|  |     }; | ||||||
|     private int moveIndex; |     private int moveIndex; | ||||||
|     private Vector2 wayPoint; |     private Vector2 wayPoint; | ||||||
|     private float durationDelta; |     private float durationDelta; | ||||||
|  | @ -80,7 +89,7 @@ public class BrotherPinkView : SingletonMonoBehaviour<BrotherPinkView> | ||||||
|             }).AddTo(this); |             }).AddTo(this); | ||||||
|         this.UpdateAsObservable().Subscribe(_ => |         this.UpdateAsObservable().Subscribe(_ => | ||||||
|         { |         { | ||||||
|             if (waitMove || isMoveLocked || isPromotion) |             if (waitMove || isMoveLocked) | ||||||
|             { |             { | ||||||
|                 return; |                 return; | ||||||
|             } |             } | ||||||
|  | @ -99,7 +108,7 @@ public class BrotherPinkView : SingletonMonoBehaviour<BrotherPinkView> | ||||||
|                 moveIndex++; |                 moveIndex++; | ||||||
|                 if (moveIndex == selectedMoves.Length) |                 if (moveIndex == selectedMoves.Length) | ||||||
|                 { |                 { | ||||||
|                     if (isTasting) |                     if (isTasting || isPromotion) | ||||||
|                     { |                     { | ||||||
|                         moveIndex = 0; |                         moveIndex = 0; | ||||||
|                         SetPinkMove(); |                         SetPinkMove(); | ||||||
|  | @ -157,7 +166,6 @@ public class BrotherPinkView : SingletonMonoBehaviour<BrotherPinkView> | ||||||
|         if (animator != null) |         if (animator != null) | ||||||
|         { |         { | ||||||
|             animator.ResetTrigger(Normal); |             animator.ResetTrigger(Normal); | ||||||
|             // animator.SetTrigger(move.trigger); |  | ||||||
|             setTrigger.OnNext(move.trigger); |             setTrigger.OnNext(move.trigger); | ||||||
|         } |         } | ||||||
|         if (Vector2.Distance(wayPoint, pinkTransform.localPosition.ToVector2()) < .01f) |         if (Vector2.Distance(wayPoint, pinkTransform.localPosition.ToVector2()) < .01f) | ||||||
|  | @ -195,23 +203,24 @@ public class BrotherPinkView : SingletonMonoBehaviour<BrotherPinkView> | ||||||
|      |      | ||||||
|     public void StartPromotion() |     public void StartPromotion() | ||||||
|     { |     { | ||||||
|  |         moveLockDispose?.Dispose(); | ||||||
|  |         isMoveLocked = false; | ||||||
|  |         waitMove = false; | ||||||
|  |          | ||||||
|         isPromotion = true; |         isPromotion = true; | ||||||
|         animator.ResetTrigger(Normal); |         selectedMoves = pinkAdvertiseMoves; | ||||||
|         animator.SetTrigger(Promotion); |         SetPinkMove(); | ||||||
|         Vector3 localPosition = RightPos; |  | ||||||
|         localPosition += Vector3.forward * (localPosition.y + Mathf.Abs(walkSideBottomPos)); |  | ||||||
|         pinkTransform.localPosition = localPosition; |  | ||||||
|         pinkTransform.localRotation = Quaternion.Euler(Vector3.zero); |  | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     public void StopPromotion() |     public void StopPromotion() | ||||||
|     { |     { | ||||||
|         if (animator != null) |         if (!isPromotion) | ||||||
|         { |         { | ||||||
|             animator.ResetTrigger(Promotion); |             return; | ||||||
|         } |         } | ||||||
|         ResetMove(); |  | ||||||
|         isPromotion = false; |         isPromotion = false; | ||||||
|  |         selectedMoves = pinkMoves; | ||||||
|  |         SetPinkMove(); | ||||||
|     } |     } | ||||||
|      |      | ||||||
|     public void StartTasting() |     public void StartTasting() | ||||||
|  |  | ||||||
|  | @ -260,9 +260,10 @@ public class MarketManager : MonoBehaviour | ||||||
|                 { |                 { | ||||||
|                     if (isPromotion) |                     if (isPromotion) | ||||||
|                     { |                     { | ||||||
|  |                         signBoardView.SetActiveTastingBoard(false); | ||||||
|                         // 宣伝ボタン表示 |                         // 宣伝ボタン表示 | ||||||
|                         rewardButtonView.gameObject.SetActive(true); |                         rewardButtonView.gameObject.SetActive(true); | ||||||
|                         signBoardView.SetActiveTastingBoard(false); |                         BrotherPinkView.Instance.StartPromotion(); | ||||||
|                     } |                     } | ||||||
|                     else if (gameData.TastingCount > 0) |                     else if (gameData.TastingCount > 0) | ||||||
|                     { |                     { | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue