Skip to content

Commit

Permalink
First Cutscene in False Sanctuary, no longer locks you. Helps with fi…
Browse files Browse the repository at this point in the history
…rst impressions. Also lowered splash SFX in intro, and made the boat harder to flip.
  • Loading branch information
TheYellowArchitect committed Aug 31, 2022
1 parent 37c5bff commit 985a53b
Show file tree
Hide file tree
Showing 18 changed files with 369 additions and 17 deletions.
225 changes: 221 additions & 4 deletions Assets/Co-Op Prototype/Scenes/EarthLevel.unity
Original file line number Diff line number Diff line change
Expand Up @@ -184941,6 +184941,110 @@ Transform:
m_PrefabParentObject: {fileID: 4170602764153098, guid: edf7604cd16a08c42b222dab0ab85d83,
type: 2}
m_PrefabInternal: {fileID: 630770540}
--- !u!1001 &631361952
Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 1077166637}
m_Modifications:
- target: {fileID: 4980449711511976, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4980449711511976, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_LocalPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4980449711511976, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_LocalPosition.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 4980449711511976, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_LocalRotation.x
value: -0
objectReference: {fileID: 0}
- target: {fileID: 4980449711511976, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_LocalRotation.y
value: -0
objectReference: {fileID: 0}
- target: {fileID: 4980449711511976, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_LocalRotation.z
value: -0
objectReference: {fileID: 0}
- target: {fileID: 4980449711511976, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 4980449711511976, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_RootOrder
value: 2
objectReference: {fileID: 0}
- target: {fileID: 114583120311519692, guid: bf81fd458abc7c249835e72e46f4b490,
type: 2}
propertyPath: haltZoomingFor
value: 1
objectReference: {fileID: 0}
- target: {fileID: 114583120311519692, guid: bf81fd458abc7c249835e72e46f4b490,
type: 2}
propertyPath: targetZoom
value:
objectReference: {fileID: 0}
- target: {fileID: 114583120311519692, guid: bf81fd458abc7c249835e72e46f4b490,
type: 2}
propertyPath: zoomIn
value: 30
objectReference: {fileID: 0}
- target: {fileID: 114583120311519692, guid: bf81fd458abc7c249835e72e46f4b490,
type: 2}
propertyPath: zoomExclusively
value: 1
objectReference: {fileID: 0}
- target: {fileID: 114583120311519692, guid: bf81fd458abc7c249835e72e46f4b490,
type: 2}
propertyPath: zoomEndDuration
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 1132425804393962, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_Name
value: Intro Dialogue
objectReference: {fileID: 0}
- target: {fileID: 61118895696018758, guid: bf81fd458abc7c249835e72e46f4b490,
type: 2}
propertyPath: m_Size.x
value: 16
objectReference: {fileID: 0}
- target: {fileID: 61118895696018758, guid: bf81fd458abc7c249835e72e46f4b490,
type: 2}
propertyPath: m_Size.y
value: 20
objectReference: {fileID: 0}
- target: {fileID: 4980449711511976, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
propertyPath: m_LocalScale.x
value: 1
objectReference: {fileID: 0}
m_RemovedComponents:
- {fileID: 114583120311519692, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
m_ParentPrefab: {fileID: 100100000, guid: bf81fd458abc7c249835e72e46f4b490, type: 2}
m_IsPrefabParent: 0
--- !u!1 &631361953 stripped
GameObject:
m_PrefabParentObject: {fileID: 1132425804393962, guid: bf81fd458abc7c249835e72e46f4b490,
type: 2}
m_PrefabInternal: {fileID: 631361952}
--- !u!114 &631361954
MonoBehaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 631361953}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: b4248dd926ceb52478809bae5c6f5337, type: 3}
m_Name:
m_EditorClassIdentifier:
dialogueIndex: 22
triggeredOnce: 0
--- !u!1001 &631580535
Prefab:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -321230,7 +321334,14 @@ Prefab:
propertyPath: m_Name
value: Start
objectReference: {fileID: 0}
m_RemovedComponents: []
- target: {fileID: 1832975919093270, guid: f9c206aeb98b84148a1f2e40f1f4f7f2, type: 2}
propertyPath: m_StaticEditorFlags
value: 4294967295
objectReference: {fileID: 0}
m_RemovedComponents:
- {fileID: 114037125597280032, guid: f9c206aeb98b84148a1f2e40f1f4f7f2, type: 2}
- {fileID: 61969376594614528, guid: f9c206aeb98b84148a1f2e40f1f4f7f2, type: 2}
- {fileID: 50112989638604216, guid: f9c206aeb98b84148a1f2e40f1f4f7f2, type: 2}
m_ParentPrefab: {fileID: 100100000, guid: f9c206aeb98b84148a1f2e40f1f4f7f2, type: 2}
m_IsPrefabParent: 0
--- !u!4 &1077166637 stripped
Expand Down Expand Up @@ -355507,6 +355618,108 @@ SpriteRenderer:
m_SpriteTileMode: 0
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
--- !u!1 &1180946676
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 5
m_Component:
- component: {fileID: 1180946677}
- component: {fileID: 1180946680}
- component: {fileID: 1180946679}
- component: {fileID: 1180946678}
- component: {fileID: 1180946681}
m_Layer: 15
m_Name: SkipDialogueHack
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 4294967295
m_IsActive: 1
--- !u!4 &1180946677
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1180946676}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 1077166637}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!50 &1180946678
Rigidbody2D:
serializedVersion: 4
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1180946676}
m_BodyType: 2
m_Simulated: 1
m_UseFullKinematicContacts: 0
m_UseAutoMass: 0
m_Mass: 1
m_LinearDrag: 0
m_AngularDrag: 0.05
m_GravityScale: 1
m_Material: {fileID: 0}
m_Interpolate: 0
m_SleepingMode: 1
m_CollisionDetection: 0
m_Constraints: 0
--- !u!61 &1180946679
BoxCollider2D:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1180946676}
m_Enabled: 1
m_Density: 1
m_Material: {fileID: 0}
m_IsTrigger: 1
m_UsedByEffector: 0
m_UsedByComposite: 0
m_Offset: {x: 0, y: 0}
m_SpriteTilingProperty:
border: {x: 0, y: 0, z: 0, w: 0}
pivot: {x: 0, y: 0}
oldSize: {x: 0, y: 0}
newSize: {x: 0, y: 0}
adaptiveTilingThreshold: 0
drawMode: 0
adaptiveTiling: 0
m_AutoTiling: 0
serializedVersion: 2
m_Size: {x: 16, y: 12}
m_EdgeRadius: 0
--- !u!114 &1180946680
MonoBehaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1180946676}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 817352157fccdda4a85ed97c32634709, type: 3}
m_Name:
m_EditorClassIdentifier:
targetIndex: 3
triggeredOnce: 0
--- !u!114 &1180946681
MonoBehaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1180946676}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f92dba18792a94741aa440edd6f38b5c, type: 3}
m_Name:
m_EditorClassIdentifier:
timeVoiceEnd: 12.9
--- !u!1 &1181045676
GameObject:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -401822,12 +402035,12 @@ GameObject:
m_Component:
- component: {fileID: 1343360395}
- component: {fileID: 1343360396}
m_Layer: 0
m_Layer: 16
m_Name: Archway1
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_StaticEditorFlags: 4294967295
m_IsActive: 1
--- !u!4 &1343360395
Transform:
Expand All @@ -401840,7 +402053,7 @@ Transform:
m_LocalScale: {x: 3.5, y: 3.5, z: 1}
m_Children: []
m_Father: {fileID: 1077166637}
m_RootOrder: 0
m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!212 &1343360396
SpriteRenderer:
Expand Down Expand Up @@ -471297,6 +471510,7 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
dialogueIndex: 5
triggeredOnce: 0
--- !u!1 &1577979762
GameObject:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -548282,6 +548496,7 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
dialogueIndex: 6
triggeredOnce: 0
--- !u!1 &1776462535
GameObject:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -626852,6 +627067,7 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
dialogueIndex: 4
triggeredOnce: 0
--- !u!1 &2063740041
GameObject:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -652621,6 +652837,7 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
dialogueIndex: 3
triggeredOnce: 0
--- !u!1001 &2143713320
Prefab:
m_ObjectHideFlags: 0
Expand Down
2 changes: 1 addition & 1 deletion Assets/Co-Op Prototype/Scenes/FundamentalScene.unity
Original file line number Diff line number Diff line change
Expand Up @@ -23820,7 +23820,7 @@ AudioSource:
type: 2}
m_audioClip: {fileID: 8300000, guid: a39fbc83dfffd924a9c0bc80eee79da1, type: 3}
m_PlayOnAwake: 0
m_Volume: 0.35
m_Volume: 0.2
m_Pitch: 1
Loop: 0
Mute: 0
Expand Down
2 changes: 1 addition & 1 deletion Assets/Co-Op Prototype/Scenes/IntroScene.unity
Original file line number Diff line number Diff line change
Expand Up @@ -58829,7 +58829,7 @@ Rigidbody2D:
m_UseAutoMass: 0
m_Mass: 1
m_LinearDrag: 0
m_AngularDrag: 0.3
m_AngularDrag: 0.4
m_GravityScale: 8
m_Material: {fileID: 0}
m_Interpolate: 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ public class TriggerMidCutscene : MonoBehaviour
[Tooltip("Go at the MidCutscenesDialoguesContainer, and check the dialogues. Then find the dialogue you want from these, and put the number of it here.")]
public int dialogueIndex;

private bool triggeredOnce = false;
public bool triggeredOnce = false;

private void OnTriggerEnter2D(Collider2D collision)
{
Expand Down
18 changes: 11 additions & 7 deletions Assets/Co-Op Prototype/Scripts/Enviroment/TutorialIntroMage.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,22 @@ public class TutorialIntroMage : MonoBehaviour
private MageBehaviour mageBehaviour;

private float timeCurrent = 0f;
[Tooltip("8.1f is both voicelines, 4.5f is P2 only")]
[Tooltip("8.1f is both voicelines, 4.5f is P2 only")]//Tutorial
public float timeVoiceEnd = 8.1f;//When no voicelines, do VanishMage();

// Use this for initialization
void Start ()
{
warriorBehaviour = GameObject.FindGameObjectWithTag("Player").GetComponent<WarriorMovement>();
mageBehaviour = GameObject.FindGameObjectWithTag("Mage").GetComponent<MageBehaviour>();
warriorBehaviour = WarriorMovement.globalInstance;
mageBehaviour = MageBehaviour.globalInstance;

mageBehaviour.StartLevelCutsceneDialogue();
mageBehaviour.transform.position = mageBehaviour.GetLevelDialoguePositions().tutorialStart;
mageBehaviour.DetermineFlip();
if (LevelManager.currentLevel == 0)
mageBehaviour.transform.position = mageBehaviour.GetLevelDialoguePositions().tutorialStart;
else if (LevelManager.currentLevel == 1)
mageBehaviour.transform.position = mageBehaviour.GetLevelDialoguePositions().level1Start;

mageBehaviour.transform.localScale = new Vector3(-1.4f, 1.4f, 1);

//Debug.Log("target position is: " + mageBehaviour.GetLevelDialoguePositions().tutorialStart);
if (GameObject.FindGameObjectWithTag("GameManager").GetComponent<DialogueManager>().skipMidCutsceneDialogue)
Expand All @@ -31,7 +35,7 @@ public void Update()
{
//Warrior starts with facing left.
//Could have a callback on flip of warrior, but whatever.
if (warriorBehaviour.GetFacingLeft() == true)
if (LevelManager.currentLevel == 0 && warriorBehaviour.GetFacingLeft() == true)
VanishMage();

if (warriorBehaviour.GetHasMageJumped() == true)
Expand All @@ -45,7 +49,7 @@ public void Update()

public void OnTriggerExit2D(Collider2D collisionDetected)
{
//Debug.Log("Exited!");
Debug.Log("Exited!");
VanishMage();
}

Expand Down
2 changes: 1 addition & 1 deletion Assets/Co-Op Prototype/Scripts/GameManager/IntroManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ IEnumerator IntroTasks()
GameObject.FindGameObjectWithTag("GameManager").transform.GetChild(2).gameObject.GetComponent<MasterInputManager>().DisableInput();

//Wait for cutscene to end, it should be as many seconds the voice clips together + the fade-in.
yield return new WaitForSeconds(18.6f);
yield return new WaitForSeconds(18f);

//Debug.Log("Current level is: " + LevelManager.currentLevel);//-1

Expand Down
3 changes: 3 additions & 0 deletions Assets/Co-Op Prototype/Scripts/Player/MageBehaviour.cs
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,9 @@ public void StartStaticDialogue()
//If not facing warrior, flip!
public void DetermineFlip()
{
//Race condition bug, when loaded from a level frame 1. Warrior behaviour's is previous level's
//Debug.Log("Local scale: " + transform.localScale.x + " and transform position.x: " + transform.position.x + " and warrior positionx: " + warriorBehaviour.transform.position.x);

//If facing right and player is to the left, face left
if (transform.localScale.x > 0 && transform.position.x > warriorBehaviour.transform.position.x)
transform.localScale = new Vector3(-1.4f, 1.4f, 1);
Expand Down
Loading

0 comments on commit 985a53b

Please sign in to comment.