Exemplo n.º 1
0
 public static PredatorPlayerJumpData EditJumpData(GameObject gameObject, PredatorPlayerJumpData jumpData)
 {
     jumpData.Name                  = EditorGUILayout.TextField("Name:", jumpData.Name);
     jumpData.JumpForwardTime       = EditorGUILayout.FloatField("Jump forward time", jumpData.JumpForwardTime);
     jumpData.JumpForwardSpeed      = EditorGUILayout.FloatField("Jump forward speed", jumpData.JumpForwardSpeed);
     jumpData.JumpOverSpeed         = EditorGUILayout.FloatField("Jump over speed", jumpData.JumpOverSpeed);
     jumpData.JumpOverCheckDistance = EditorGUILayout.FloatField("Jump over obstacle test distance", jumpData.JumpOverCheckDistance);
     jumpData.ObstacleToJumpOver    = EditorGUILayoutx.LayerMaskField("Jump over obstacle layer:", jumpData.ObstacleToJumpOver);
     jumpData.AnimationLayer        = EditorGUILayout.IntField("Jump animation layer:", jumpData.AnimationLayer);
     jumpData.PreJumpAnimation      = EditorCommon.EditPopup("PreJump Animation",
                                                             jumpData.PreJumpAnimation,
                                                             EditorCommon.GetAnimationNames(gameObject));
     jumpData.JumpingAnimation = EditorCommon.EditPopup("Jumping Animation",
                                                        jumpData.JumpingAnimation,
                                                        EditorCommon.GetAnimationNames(gameObject));
     jumpData.GroundingAnimation = EditorCommon.EditPopup("Grounding Animation",
                                                          jumpData.GroundingAnimation,
                                                          EditorCommon.GetAnimationNames(gameObject));
     return(jumpData);
 }
 public static PredatorPlayerJumpData EditJumpData(GameObject gameObject, PredatorPlayerJumpData jumpData)
 {
     jumpData.Name = EditorGUILayout.TextField ("Name:", jumpData.Name);
     jumpData.JumpForwardTime = EditorGUILayout.FloatField ("Jump forward time", jumpData.JumpForwardTime);
     jumpData.JumpForwardSpeed = EditorGUILayout.FloatField ("Jump forward speed", jumpData.JumpForwardSpeed);
     jumpData.JumpOverSpeed = EditorGUILayout.FloatField ("Jump over speed", jumpData.JumpOverSpeed);
     jumpData.JumpOverCheckDistance = EditorGUILayout.FloatField ("Jump over obstacle test distance", jumpData.JumpOverCheckDistance);
     jumpData.ObstacleToJumpOver = EditorGUILayoutx.LayerMaskField ("Jump over obstacle layer:", jumpData.ObstacleToJumpOver);
     jumpData.AnimationLayer = EditorGUILayout.IntField ("Jump animation layer:", jumpData.AnimationLayer);
     jumpData.PreJumpAnimation = EditorCommon.EditPopup ("PreJump Animation",
                                                        jumpData.PreJumpAnimation,
                                                        EditorCommon.GetAnimationNames (gameObject));
     jumpData.JumpingAnimation = EditorCommon.EditPopup ("Jumping Animation",
                                                        jumpData.JumpingAnimation,
                                                        EditorCommon.GetAnimationNames (gameObject));
     jumpData.GroundingAnimation = EditorCommon.EditPopup ("Grounding Animation",
                                                        jumpData.GroundingAnimation,
                                                        EditorCommon.GetAnimationNames (gameObject));
     return jumpData;
 }