splat
This commit is contained in:
parent
fab64aa3c4
commit
89eb7ff07d
File diff suppressed because it is too large
Load diff
|
|
@ -4,5 +4,5 @@ folderAsset: yes
|
|||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleName: ntrsamurai/common
|
||||
assetBundleVariant:
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ AnimationClip:
|
|||
m_Level: 0
|
||||
m_CycleOffset: 0
|
||||
m_HasAdditiveReferencePose: 0
|
||||
m_LoopTime: 1
|
||||
m_LoopTime: 0
|
||||
m_LoopBlend: 0
|
||||
m_LoopBlendOrientation: 0
|
||||
m_LoopBlendPositionY: 0
|
||||
|
|
|
|||
|
|
@ -97,7 +97,7 @@ AnimationClip:
|
|||
m_Level: 0
|
||||
m_CycleOffset: 0
|
||||
m_HasAdditiveReferencePose: 0
|
||||
m_LoopTime: 1
|
||||
m_LoopTime: 0
|
||||
m_LoopBlend: 0
|
||||
m_LoopBlendOrientation: 0
|
||||
m_LoopBlendPositionY: 0
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ AnimationClip:
|
|||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: {x: 0.9, y: 0.9, z: 0.9}
|
||||
value: {x: 1, y: 1, z: 1}
|
||||
inSlope: {x: 0, y: 0, z: 0}
|
||||
outSlope: {x: 0, y: 0, z: 0}
|
||||
tangentMode: 0
|
||||
|
|
@ -113,7 +113,7 @@ AnimationClip:
|
|||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0.9
|
||||
value: 1
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
|
|
@ -132,7 +132,7 @@ AnimationClip:
|
|||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0.9
|
||||
value: 1
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
|
|
@ -151,7 +151,7 @@ AnimationClip:
|
|||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0.9
|
||||
value: 1
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
|
|
|
|||
|
|
@ -0,0 +1,366 @@
|
|||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!74 &7400000
|
||||
AnimationClip:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: ObjMelonPickelSplat
|
||||
serializedVersion: 6
|
||||
m_Legacy: 0
|
||||
m_Compressed: 0
|
||||
m_UseHighQualityCurve: 1
|
||||
m_RotationCurves: []
|
||||
m_CompressedRotationCurves: []
|
||||
m_EulerCurves:
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: {x: 0, y: 0, z: 0}
|
||||
inSlope: {x: 0, y: 0, z: 0}
|
||||
outSlope: {x: 0, y: 240, z: 0}
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
- serializedVersion: 3
|
||||
time: 1.5
|
||||
value: {x: 0, y: 360, z: 0}
|
||||
inSlope: {x: -0, y: 240, z: -0}
|
||||
outSlope: {x: 0, y: 0, z: 0}
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
path:
|
||||
m_PositionCurves:
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: {x: 0, y: 0, z: 0}
|
||||
inSlope: {x: 0, y: 0, z: 0}
|
||||
outSlope: {x: 0, y: 0, z: 0}
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
- serializedVersion: 3
|
||||
time: 0.75
|
||||
value: {x: 0, y: 0.1, z: 0}
|
||||
inSlope: {x: 0, y: 0, z: 0}
|
||||
outSlope: {x: 0, y: 0, z: 0}
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
- serializedVersion: 3
|
||||
time: 1.5
|
||||
value: {x: 0, y: 0, z: 0}
|
||||
inSlope: {x: 0, y: 0, z: 0}
|
||||
outSlope: {x: 0, y: 0, z: 0}
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
outWeight: {x: 0.33333334, y: 0.33333334, z: 0.33333334}
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
path:
|
||||
m_ScaleCurves: []
|
||||
m_FloatCurves: []
|
||||
m_PPtrCurves:
|
||||
- curve:
|
||||
- time: 0
|
||||
value: {fileID: 3194603433930847069, guid: 410272bf8a685fe4caa52d69b027a25e, type: 3}
|
||||
attribute: m_Sprite
|
||||
path:
|
||||
classID: 212
|
||||
script: {fileID: 0}
|
||||
m_SampleRate: 60
|
||||
m_WrapMode: 0
|
||||
m_Bounds:
|
||||
m_Center: {x: 0, y: 0, z: 0}
|
||||
m_Extent: {x: 0, y: 0, z: 0}
|
||||
m_ClipBindingConstant:
|
||||
genericBindings:
|
||||
- serializedVersion: 2
|
||||
path: 0
|
||||
attribute: 1
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 0
|
||||
isPPtrCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 0
|
||||
attribute: 4
|
||||
script: {fileID: 0}
|
||||
typeID: 4
|
||||
customType: 4
|
||||
isPPtrCurve: 0
|
||||
- serializedVersion: 2
|
||||
path: 0
|
||||
attribute: 0
|
||||
script: {fileID: 0}
|
||||
typeID: 212
|
||||
customType: 23
|
||||
isPPtrCurve: 1
|
||||
pptrCurveMapping:
|
||||
- {fileID: 3194603433930847069, guid: 410272bf8a685fe4caa52d69b027a25e, type: 3}
|
||||
m_AnimationClipSettings:
|
||||
serializedVersion: 2
|
||||
m_AdditiveReferencePoseClip: {fileID: 0}
|
||||
m_AdditiveReferencePoseTime: 0
|
||||
m_StartTime: 0
|
||||
m_StopTime: 1.5
|
||||
m_OrientationOffsetY: 0
|
||||
m_Level: 0
|
||||
m_CycleOffset: 0
|
||||
m_HasAdditiveReferencePose: 0
|
||||
m_LoopTime: 1
|
||||
m_LoopBlend: 0
|
||||
m_LoopBlendOrientation: 0
|
||||
m_LoopBlendPositionY: 0
|
||||
m_LoopBlendPositionXZ: 0
|
||||
m_KeepOriginalOrientation: 0
|
||||
m_KeepOriginalPositionY: 1
|
||||
m_KeepOriginalPositionXZ: 0
|
||||
m_HeightFromFeet: 0
|
||||
m_Mirror: 0
|
||||
m_EditorCurves:
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 69
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 1.5
|
||||
value: 0
|
||||
inSlope: -0
|
||||
outSlope: 0
|
||||
tangentMode: 69
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
attribute: localEulerAnglesRaw.x
|
||||
path:
|
||||
classID: 4
|
||||
script: {fileID: 0}
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 240
|
||||
tangentMode: 69
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 1.5
|
||||
value: 360
|
||||
inSlope: 240
|
||||
outSlope: 0
|
||||
tangentMode: 69
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
attribute: localEulerAnglesRaw.y
|
||||
path:
|
||||
classID: 4
|
||||
script: {fileID: 0}
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 69
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 1.5
|
||||
value: 0
|
||||
inSlope: -0
|
||||
outSlope: 0
|
||||
tangentMode: 69
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
attribute: localEulerAnglesRaw.z
|
||||
path:
|
||||
classID: 4
|
||||
script: {fileID: 0}
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 0.75
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 1.5
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
attribute: m_LocalPosition.x
|
||||
path:
|
||||
classID: 4
|
||||
script: {fileID: 0}
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 0.75
|
||||
value: 0.1
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 1.5
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
attribute: m_LocalPosition.y
|
||||
path:
|
||||
classID: 4
|
||||
script: {fileID: 0}
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 0.75
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 1.5
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 136
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
attribute: m_LocalPosition.z
|
||||
path:
|
||||
classID: 4
|
||||
script: {fileID: 0}
|
||||
m_EulerEditorCurves:
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve: []
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
attribute: m_LocalEulerAngles.x
|
||||
path:
|
||||
classID: 4
|
||||
script: {fileID: 0}
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve: []
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
attribute: m_LocalEulerAngles.y
|
||||
path:
|
||||
classID: 4
|
||||
script: {fileID: 0}
|
||||
- curve:
|
||||
serializedVersion: 2
|
||||
m_Curve: []
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
attribute: m_LocalEulerAngles.z
|
||||
path:
|
||||
classID: 4
|
||||
script: {fileID: 0}
|
||||
m_HasGenericRootTransform: 1
|
||||
m_HasMotionFloatCurves: 0
|
||||
m_Events: []
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 49ef3cd2199b5c841bad4e5e7fabe0f0
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 7400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
|
@ -121,7 +121,7 @@ AnimationClip:
|
|||
m_Level: 0
|
||||
m_CycleOffset: 0
|
||||
m_HasAdditiveReferencePose: 0
|
||||
m_LoopTime: 1
|
||||
m_LoopTime: 0
|
||||
m_LoopBlend: 0
|
||||
m_LoopBlendOrientation: 0
|
||||
m_LoopBlendPositionY: 0
|
||||
|
|
|
|||
|
|
@ -100,6 +100,9 @@ AnimatorStateMachine:
|
|||
- serializedVersion: 1
|
||||
m_State: {fileID: -8309853701920162082}
|
||||
m_Position: {x: 590, y: 880, z: 0}
|
||||
- serializedVersion: 1
|
||||
m_State: {fileID: 8073444301321621089}
|
||||
m_Position: {x: 625, y: 945, z: 0}
|
||||
m_ChildStateMachines: []
|
||||
m_AnyStateTransitions: []
|
||||
m_EntryTransitions: []
|
||||
|
|
@ -366,6 +369,32 @@ AnimatorState:
|
|||
m_MirrorParameter:
|
||||
m_CycleOffsetParameter:
|
||||
m_TimeParameter:
|
||||
--- !u!1102 &8073444301321621089
|
||||
AnimatorState:
|
||||
serializedVersion: 6
|
||||
m_ObjectHideFlags: 1
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_Name: ObjMelonPickelSplat
|
||||
m_Speed: 1
|
||||
m_CycleOffset: 0
|
||||
m_Transitions: []
|
||||
m_StateMachineBehaviours: []
|
||||
m_Position: {x: 50, y: 50, z: 0}
|
||||
m_IKOnFeet: 0
|
||||
m_WriteDefaultValues: 1
|
||||
m_Mirror: 0
|
||||
m_SpeedParameterActive: 0
|
||||
m_MirrorParameterActive: 0
|
||||
m_CycleOffsetParameterActive: 0
|
||||
m_TimeParameterActive: 0
|
||||
m_Motion: {fileID: 7400000, guid: 49ef3cd2199b5c841bad4e5e7fabe0f0, type: 2}
|
||||
m_Tag:
|
||||
m_SpeedParameter:
|
||||
m_MirrorParameter:
|
||||
m_CycleOffsetParameter:
|
||||
m_TimeParameter:
|
||||
--- !u!1102 &8615591886951508214
|
||||
AnimatorState:
|
||||
serializedVersion: 6
|
||||
|
|
|
|||
|
|
@ -104,7 +104,7 @@ TextureImporter:
|
|||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spritePixelsToUnits: 92
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 0
|
||||
alphaUsage: 1
|
||||
|
|
|
|||
|
|
@ -1813,5 +1813,5 @@ TextureImporter:
|
|||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleName: ntrsamurai/common
|
||||
assetBundleVariant:
|
||||
|
|
|
|||
|
|
@ -10,9 +10,10 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
public class NtrSamuraiObject : MonoBehaviour
|
||||
{
|
||||
[Header("Objects")]
|
||||
public ParticleSystem moneyBurst;
|
||||
public ParticleSystem pickelBurst;
|
||||
public Animator anim;
|
||||
[SerializeField] ParticleSystem moneyBurst;
|
||||
[SerializeField] ParticleSystem pickelBurst;
|
||||
[SerializeField] ParticleSystem pickelBurstSplat;
|
||||
[SerializeField] Animator anim;
|
||||
public NtrSamuraiObject secondHalf;
|
||||
|
||||
[Header("Transforms")]
|
||||
|
|
@ -108,15 +109,11 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
{
|
||||
case -3: // near miss on board launch
|
||||
flyPos = cond.GetPositionFromBeat(startBeat, 2f);
|
||||
transform.position = currentCurve.GetPoint(flyPos);
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (180f * Time.deltaTime));
|
||||
|
||||
if (flyPos > 1f)
|
||||
{
|
||||
// TODO: splat
|
||||
GameObject.Destroy(gameObject);
|
||||
return;
|
||||
}
|
||||
transform.position = currentCurve.GetPoint(Mathf.Clamp01(flyPos));
|
||||
if (flyPos >= 1)
|
||||
transform.rotation = Quaternion.identity;
|
||||
else
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (180f * Time.deltaTime * cond.SongPitch));
|
||||
break;
|
||||
case -2: // being carried by a child
|
||||
flyPos = cond.GetPositionFromBeat(startBeat + 2f, 4f);
|
||||
|
|
@ -130,9 +127,9 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
case -1: // sliced by samurai, falling towards child
|
||||
flyPos = cond.GetPositionFromBeat(startBeat, 1f);
|
||||
transform.position = currentCurve.GetPoint(flyPos);
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + ((isDebris ? 360f : -360f) * Time.deltaTime));
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + ((isDebris ? 360f : -360f) * Time.deltaTime * cond.SongPitch));
|
||||
|
||||
if (flyPos > 1f)
|
||||
if (flyPos >= 1f)
|
||||
{
|
||||
SoundByte.PlayOneShotGame("samuraiSliceNtr/ntrSamurai_catch");
|
||||
if (!isDebris)
|
||||
|
|
@ -144,24 +141,20 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
secondHalf.transform.parent = child.DebrisPosL;
|
||||
}
|
||||
flyProg = -2;
|
||||
GetComponent<SpriteRenderer>().sortingOrder = 7;
|
||||
anim.GetComponent<SpriteRenderer>().sortingOrder = 7;
|
||||
return;
|
||||
}
|
||||
break;
|
||||
case 2: // fish first bounce
|
||||
float jumpPos = cond.GetPositionFromBeat(launchProg.startBeat, 2f);
|
||||
jumpPos = Mathf.Min(jumpPos, 1.215f);
|
||||
float yMul = jumpPos * 2f - 1f;
|
||||
float yWeight = -(yMul * yMul) + 1f;
|
||||
transform.position = doubleLaunchPos.position + new Vector3(0, 4.5f * yWeight);
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (-2 * 360f * Time.deltaTime));
|
||||
|
||||
if (jumpPos > 2f)
|
||||
{
|
||||
// missed...
|
||||
// TODO: splat
|
||||
GameObject.Destroy(gameObject);
|
||||
return;
|
||||
}
|
||||
if (jumpPos >= 1.215f)
|
||||
transform.rotation = Quaternion.identity;
|
||||
else
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (-2 * 360f * Time.deltaTime * cond.SongPitch));
|
||||
break;
|
||||
case 1: // launched from board to samurai
|
||||
float flyDur = 3f;
|
||||
|
|
@ -175,35 +168,55 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
break;
|
||||
}
|
||||
flyPos = cond.GetPositionFromBeat(hitProg.startBeat, flyDur);
|
||||
transform.position = currentCurve.GetPoint(flyPos);
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (3 * 360f * Time.deltaTime));
|
||||
|
||||
if (flyPos > 1f)
|
||||
{
|
||||
// missed...
|
||||
// TODO: splat
|
||||
GameObject.Destroy(gameObject);
|
||||
return;
|
||||
}
|
||||
transform.position = currentCurve.GetPoint(Mathf.Clamp01(flyPos));
|
||||
if (flyPos >= 1)
|
||||
transform.rotation = Quaternion.identity;
|
||||
else
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (3 * 360f * Time.deltaTime * cond.SongPitch));
|
||||
break;
|
||||
|
||||
default: // object initial spawn, flying towards board
|
||||
flyPos = cond.GetPositionFromBeat(launchProg.startBeat, 3f);
|
||||
transform.position = currentCurve.GetPoint(flyPos);
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (-360f * Time.deltaTime));
|
||||
|
||||
if (flyPos > 1f)
|
||||
{
|
||||
// missed...
|
||||
// TODO: splat
|
||||
GameObject.Destroy(gameObject);
|
||||
return;
|
||||
}
|
||||
Debug.Log(flyPos);
|
||||
transform.position = currentCurve.GetPoint(Mathf.Clamp01(flyPos));
|
||||
if (flyPos >= 1)
|
||||
transform.rotation = Quaternion.identity;
|
||||
else
|
||||
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (-360f * Time.deltaTime * cond.SongPitch));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void DoSplat(double beat)
|
||||
{
|
||||
MultiSound.Play(new MultiSound.Sound[] {
|
||||
new MultiSound.Sound("samuraiSliceNtr/item_splat", beat)
|
||||
});
|
||||
BeatAction.New(this, new()
|
||||
{
|
||||
new BeatAction.Action(beat, delegate {
|
||||
switch (type)
|
||||
{
|
||||
case (int)SamuraiSliceNtr.ObjectType.Fish:
|
||||
anim.Play("ObjFishSplat");
|
||||
break;
|
||||
case (int)SamuraiSliceNtr.ObjectType.Demon:
|
||||
anim.Play("ObjDemonSplat");
|
||||
break;
|
||||
case (int)SamuraiSliceNtr.ObjectType.Melon2B2T:
|
||||
anim.Play("ObjMelonPickelSplat");
|
||||
pickelBurstSplat.transform.position = transform.position;
|
||||
pickelBurstSplat.Play();
|
||||
break;
|
||||
default:
|
||||
anim.Play("ObjMelonSplat");
|
||||
break;
|
||||
}}),
|
||||
new BeatAction.Action(beat + 3, delegate { Destroy(gameObject); })
|
||||
});
|
||||
}
|
||||
|
||||
void DoLaunch()
|
||||
{
|
||||
switch (type)
|
||||
|
|
@ -272,6 +285,7 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
flyProg = -3;
|
||||
SoundByte.PlayOneShotGame("samuraiSliceNtr/ntrSamurai_launchImpact", pitch: 2f);
|
||||
launchProg.Disable();
|
||||
DoSplat(startBeat + 2);
|
||||
return;
|
||||
}
|
||||
launchProg.Disable();
|
||||
|
|
@ -283,6 +297,15 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
public void LaunchMiss(PlayerActionEvent caller)
|
||||
{
|
||||
missedLaunch = true;
|
||||
switch (flyProg)
|
||||
{
|
||||
case 2:
|
||||
DoSplat(caller.startBeat + 2.215);
|
||||
break;
|
||||
default:
|
||||
DoSplat(caller.startBeat + 3);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
public void LaunchThrough(PlayerActionEvent caller) { }
|
||||
|
|
@ -296,6 +319,7 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
flyProg = -3;
|
||||
SoundByte.PlayOneShotGame("samuraiSliceNtr/ntrSamurai_ng");
|
||||
hitProg.Disable();
|
||||
DoSplat(startBeat + 2);
|
||||
return;
|
||||
}
|
||||
flyProg = -1;
|
||||
|
|
@ -316,7 +340,7 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
|
||||
mobj.transform.position = transform.position;
|
||||
mobj.transform.rotation = transform.rotation;
|
||||
mobj.GetComponent<SpriteRenderer>().sortingOrder = 4;
|
||||
// mobj.GetComponent<SpriteRenderer>().sortingOrder = 4;
|
||||
mobj.SetActive(true);
|
||||
|
||||
secondHalf = mobjDat;
|
||||
|
|
@ -340,6 +364,17 @@ namespace HeavenStudio.Games.Scripts_NtrSamurai
|
|||
|
||||
public void HitMiss(PlayerActionEvent caller)
|
||||
{
|
||||
double flyDur;
|
||||
switch (type)
|
||||
{
|
||||
case (int)SamuraiSliceNtr.ObjectType.Demon:
|
||||
flyDur = 5;
|
||||
break;
|
||||
default:
|
||||
flyDur = 3;
|
||||
break;
|
||||
}
|
||||
DoSplat(caller.startBeat + flyDur);
|
||||
missedHit = true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue