Skip to content

Commit 7320f7e

Browse files
author
ayoubx
committed
fixed credits time and added quit game option
1 parent 97dab85 commit 7320f7e

File tree

91 files changed

+603
-1604
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

91 files changed

+603
-1604
lines changed

Assembly-CSharp.csproj

+428-439
Large diffs are not rendered by default.

Assets/creditsScript.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ void Start () {
99
StartCoroutine("QuitGame");
1010
}
1111
IEnumerator QuitGame(){
12-
for(int i = 0; i < 300; i++){
12+
for(int i = 0; i < 1080; i++){
1313
yield return null;
1414
}
1515
Application.Quit();

Assets/scripts/PlayerHealthManager.cs

+1
Original file line numberDiff line numberDiff line change
@@ -152,4 +152,5 @@ IEnumerator ResetPause(){
152152
}
153153
canTogglepause = true;
154154
}
155+
155156
}

Assets/scripts/holder.cs

+29-4
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,16 @@ void Start () {
1616
counter = 0;
1717
}
1818

19+
bool paused;
1920
void Update () {
20-
buttonDown = Input.GetButtonDown("back");
21-
buttonUp = Input.GetButtonUp("back");
22-
21+
if(paused){
22+
buttonDown = Input.GetButtonDown("quit");
23+
buttonUp = Input.GetButtonUp("quit");
24+
}else{
25+
buttonDown = Input.GetButtonDown("back");
26+
buttonUp = Input.GetButtonUp("back");
27+
}
28+
2329
switch(state){
2430
case states.IDLE:
2531
if(buttonDown){
@@ -39,7 +45,11 @@ void Update () {
3945
state = states.IDLE;
4046
anim.Play("load", -1, 0f);
4147
anim.SetFloat("speed", 0);
42-
PlayerInstanciationScript.Player.GetComponentInChildren<PlayerHealthManager>().SendMessage("TakeDamage", 1);
48+
if(paused){
49+
Application.Quit();
50+
}else{
51+
PlayerInstanciationScript.Player.GetComponentInChildren<PlayerHealthManager>().SendMessage("TakeDamage", 1);
52+
}
4353
}
4454
}
4555
break;
@@ -60,4 +70,19 @@ void Update () {
6070

6171
}
6272
}
73+
74+
public void OnPauseGame()
75+
{
76+
paused = true;
77+
state = states.IDLE;
78+
counter = 0;
79+
80+
}
81+
82+
public void OnResumeGame()
83+
{
84+
paused = false;
85+
state = states.IDLE;
86+
counter = 0;
87+
}
6388
}

Assets/scripts/level_manager.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ public void EnterDoor(){
2929
GetComponent<AudioSource>().Play();
3030
playerHealth.IncrementScene();
3131
transitionText.SetActive(true);
32-
transitionText.GetComponentInChildren<Text>().text = (level + 1 == 31 ? "Credits" : "" + (level + 1));
32+
transitionText.GetComponentInChildren<Text>().text = (level + 1 == 31 ? "" : "" + (level + 1));
3333
StartCoroutine("pass");
3434
done = true;
3535
}

Library/AssetImportState

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2;0;196608;0;0
1+
5;0;4;0;0

Library/CurrentLayout.dwlt

+43-43
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@ MonoBehaviour:
1313
m_EditorClassIdentifier:
1414
m_PixelRect:
1515
serializedVersion: 2
16-
x: 0
17-
y: 45
16+
x: 8
17+
y: 51
1818
width: 1680
1919
height: 938
2020
m_ShowMode: 4
2121
m_Title:
2222
m_RootView: {fileID: 2}
23-
m_MinSize: {x: 950, y: 542}
23+
m_MinSize: {x: 950, y: 300}
2424
m_MaxSize: {x: 10000, y: 10000}
2525
--- !u!114 &2
2626
MonoBehaviour:
@@ -43,7 +43,7 @@ MonoBehaviour:
4343
y: 0
4444
width: 1680
4545
height: 938
46-
m_MinSize: {x: 950, y: 542}
46+
m_MinSize: {x: 950, y: 300}
4747
m_MaxSize: {x: 10000, y: 10000}
4848
--- !u!114 &3
4949
MonoBehaviour:
@@ -108,7 +108,7 @@ MonoBehaviour:
108108
m_MinSize: {x: 613, y: 492}
109109
m_MaxSize: {x: 18008, y: 14042}
110110
vertical: 1
111-
controlID: 125
111+
controlID: 333
112112
--- !u!114 &6
113113
MonoBehaviour:
114114
m_ObjectHideFlags: 52
@@ -133,7 +133,7 @@ MonoBehaviour:
133133
m_MinSize: {x: 613, y: 492}
134134
m_MaxSize: {x: 18008, y: 14042}
135135
vertical: 0
136-
controlID: 126
136+
controlID: 334
137137
--- !u!114 &7
138138
MonoBehaviour:
139139
m_ObjectHideFlags: 52
@@ -157,7 +157,7 @@ MonoBehaviour:
157157
m_MinSize: {x: 102, y: 242}
158158
m_MaxSize: {x: 4002, y: 8042}
159159
vertical: 1
160-
controlID: 127
160+
controlID: 335
161161
--- !u!114 &8
162162
MonoBehaviour:
163163
m_ObjectHideFlags: 52
@@ -235,7 +235,7 @@ MonoBehaviour:
235235
m_MinSize: {x: 234, y: 492}
236236
m_MaxSize: {x: 10004, y: 14042}
237237
vertical: 1
238-
controlID: 27
238+
controlID: 305
239239
--- !u!114 &11
240240
MonoBehaviour:
241241
m_ObjectHideFlags: 52
@@ -279,8 +279,8 @@ MonoBehaviour:
279279
y: 487
280280
width: 247
281281
height: 401
282-
m_MinSize: {x: 200, y: 200}
283-
m_MaxSize: {x: 4000, y: 4000}
282+
m_MinSize: {x: 204, y: 221}
283+
m_MaxSize: {x: 4004, y: 4021}
284284
m_ActualView: {fileID: 21}
285285
m_Panes:
286286
- {fileID: 21}
@@ -332,7 +332,7 @@ MonoBehaviour:
332332
m_Pos:
333333
serializedVersion: 2
334334
x: 0
335-
y: 94
335+
y: 19
336336
width: 984
337337
height: 543
338338
m_PersistentViewDataDictionary: {fileID: 0}
@@ -346,10 +346,10 @@ MonoBehaviour:
346346
m_VRangeLocked: 0
347347
hZoomLockedByDefault: 0
348348
vZoomLockedByDefault: 0
349-
m_HBaseRangeMin: -233.75
350-
m_HBaseRangeMax: 233.75
351-
m_VBaseRangeMin: -131.5
352-
m_VBaseRangeMax: 131.5
349+
m_HBaseRangeMin: -467.5
350+
m_HBaseRangeMax: 467.5
351+
m_VBaseRangeMin: -263
352+
m_VBaseRangeMax: 263
353353
m_HAllowExceedBaseRangeMin: 1
354354
m_HAllowExceedBaseRangeMax: 1
355355
m_VAllowExceedBaseRangeMin: 1
@@ -358,7 +358,7 @@ MonoBehaviour:
358358
m_HSlider: 0
359359
m_VSlider: 0
360360
m_IgnoreScrollWheelUntilClicked: 0
361-
m_EnableMouseInput: 1
361+
m_EnableMouseInput: 0
362362
m_EnableSliderZoomHorizontal: 0
363363
m_EnableSliderZoomVertical: 0
364364
m_UniformScale: 1
@@ -369,23 +369,23 @@ MonoBehaviour:
369369
y: 17
370370
width: 984
371371
height: 526
372-
m_Scale: {x: 2, y: 2}
372+
m_Scale: {x: 1, y: 1}
373373
m_Translation: {x: 492, y: 263}
374374
m_MarginLeft: 0
375375
m_MarginRight: 0
376376
m_MarginTop: 0
377377
m_MarginBottom: 0
378378
m_LastShownAreaInsideMargins:
379379
serializedVersion: 2
380-
x: -246
381-
y: -131.5
382-
width: 492
383-
height: 263
380+
x: -492
381+
y: -263
382+
width: 984
383+
height: 526
384384
m_MinimalGUI: 1
385-
m_defaultScale: 2
385+
m_defaultScale: 1
386386
m_TargetTexture: {fileID: 0}
387387
m_CurrentColorSpace: 0
388-
m_LastWindowPixelSize: {x: 1968, y: 1086}
388+
m_LastWindowPixelSize: {x: 984, y: 543}
389389
m_ClearInEditMode: 1
390390
m_NoCameraWarning: 1
391391
m_LowResolutionForAspectRatios: 01000000000000000100
@@ -410,8 +410,8 @@ MonoBehaviour:
410410
m_Tooltip:
411411
m_Pos:
412412
serializedVersion: 2
413-
x: 0
414-
y: 94
413+
x: 8
414+
y: 100
415415
width: 984
416416
height: 543
417417
m_PersistentViewDataDictionary: {fileID: 0}
@@ -421,9 +421,9 @@ MonoBehaviour:
421421
m_isRotationLocked: 0
422422
m_AudioPlay: 0
423423
m_Position:
424-
m_Target: {x: -1376.0472, y: 675.95386, z: -28.81329}
424+
m_Target: {x: -483.1321, y: 751.14777, z: -29}
425425
speed: 2
426-
m_Value: {x: -1376.0472, y: 675.95386, z: -28.81329}
426+
m_Value: {x: -483.1321, y: 751.14777, z: -29}
427427
m_RenderMode: 0
428428
m_CameraMode:
429429
drawMode: 0
@@ -619,8 +619,8 @@ MonoBehaviour:
619619
m_Tooltip:
620620
m_Pos:
621621
serializedVersion: 2
622-
x: 0
623-
y: 658
622+
x: 8
623+
y: 664
624624
width: 984
625625
height: 303
626626
m_PersistentViewDataDictionary: {fileID: 0}
@@ -644,8 +644,8 @@ MonoBehaviour:
644644
m_Tooltip:
645645
m_Pos:
646646
serializedVersion: 2
647-
x: 988
648-
y: 94
647+
x: 996
648+
y: 100
649649
width: 243
650650
height: 466
651651
m_PersistentViewDataDictionary: {fileID: 0}
@@ -666,14 +666,14 @@ MonoBehaviour:
666666
m_StartGridSize: 64
667667
m_LastFolders: []
668668
m_LastFoldersGridSize: -1
669-
m_LastProjectPath: /Users/EVENGAMES/Desktop/TheMansion
669+
m_LastProjectPath: C:\Users\ayoub\Documents\Mansion
670670
m_LockTracker:
671671
m_IsLocked: 0
672672
m_FolderTreeState:
673673
scrollPos: {x: 0, y: 0}
674674
m_SelectedIDs: 10260000
675675
m_LastClickedID: 9744
676-
m_ExpandedIDs: 00000000802f0000aa2f00006e3000004a3200005e3200002e33000004340000
676+
m_ExpandedIDs: ffffffff00000000942b0000be2b0000f22b0000822c00005e2e0000722e0000422f000018300000
677677
m_RenameOverlay:
678678
m_UserAcceptedRename: 0
679679
m_Name:
@@ -701,7 +701,7 @@ MonoBehaviour:
701701
scrollPos: {x: 0, y: 1172}
702702
m_SelectedIDs:
703703
m_LastClickedID: 0
704-
m_ExpandedIDs: ffffffff00000000802f0000aa2f0000de2f00006e3000004a3200005e3200002e33000004340000
704+
m_ExpandedIDs: ffffffff00000000942b0000be2b0000f22b0000822c00005e2e0000722e0000422f000018300000
705705
m_RenameOverlay:
706706
m_UserAcceptedRename: 0
707707
m_Name:
@@ -776,16 +776,16 @@ MonoBehaviour:
776776
m_Tooltip:
777777
m_Pos:
778778
serializedVersion: 2
779-
x: 988
780-
y: 581
779+
x: 996
780+
y: 587
781781
width: 243
782782
height: 380
783783
m_PersistentViewDataDictionary: {fileID: 0}
784784
m_TreeViewState:
785-
scrollPos: {x: 0, y: 229}
786-
m_SelectedIDs: f6c8ffff
787-
m_LastClickedID: -14090
788-
m_ExpandedIDs: 7cefffff34f9ffff00000000
785+
scrollPos: {x: 0, y: 0}
786+
m_SelectedIDs:
787+
m_LastClickedID: 0
788+
m_ExpandedIDs: b87effffba7fffff1c81ffffda81ffff2e83ffffcc84ffffae85ffff8086ffff5c87ffff1e88ffffc888ffff408affff0a8cfffff28cffffba8dffffa48effff1490ffff4a91ffff3892ffffd092ffff9c93ffff5494ffff0095ffffb095ffffa696ffff7097ffff1e98ffff3499ffffba99ffff409affff109bffffd29bffffc89cffffce9cffff82a9ffff7eaaffffe4abffffa6acfffffeadffffa0afffff86b0ffff5cb1ffff3cb2ffff02b3ffffb0b3ffff2cb5fffffab6ffffe6b7ffffb2b8ffffa0b9ffff14bbffff4ebcffff40bdffffdcbdffffacbeffff68bfffff18c0ffffccc0ffffc6c1ffff94c2ffff46c3ffff62c4ffffecc4ffff76c5ffff4ac6ffff10c7ffff0ac8ffff14c8ffffbef4ffff7cf9ffff00000000
789789
m_RenameOverlay:
790790
m_UserAcceptedRename: 0
791791
m_Name:
@@ -804,7 +804,7 @@ MonoBehaviour:
804804
m_ClientGUIView: {fileID: 12}
805805
m_SearchString:
806806
m_ExpandedScenes:
807-
- level_21
807+
- level_0
808808
m_CurrenRootInstanceID: 0
809809
m_LockTracker:
810810
m_IsLocked: 0
@@ -829,8 +829,8 @@ MonoBehaviour:
829829
m_Tooltip:
830830
m_Pos:
831831
serializedVersion: 2
832-
x: 1235
833-
y: 94
832+
x: 1243
833+
y: 100
834834
width: 445
835835
height: 867
836836
m_PersistentViewDataDictionary: {fileID: 0}

0 commit comments

Comments
 (0)