Simple sounds added
This commit is contained in:
parent
6118a32fc6
commit
7914198bcb
3 changed files with 30 additions and 6 deletions
|
@ -170,7 +170,7 @@ Transform:
|
|||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 816024605}
|
||||
m_RootOrder: 1
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!82 &368878861
|
||||
AudioSource:
|
||||
|
@ -448,9 +448,9 @@ Transform:
|
|||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 1908750962}
|
||||
- {fileID: 368878860}
|
||||
- {fileID: 1028937043}
|
||||
- {fileID: 1908750962}
|
||||
m_Father: {fileID: 734498092}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
|
@ -512,6 +512,7 @@ GameObject:
|
|||
- component: {fileID: 881384369}
|
||||
- component: {fileID: 881384368}
|
||||
- component: {fileID: 881384372}
|
||||
- component: {fileID: 881384373}
|
||||
m_Layer: 0
|
||||
m_Name: Main Camera
|
||||
m_TagString: MainCamera
|
||||
|
@ -595,6 +596,25 @@ MonoBehaviour:
|
|||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
followThis: {fileID: 0}
|
||||
--- !u!114 &881384373
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_PrefabParentObject: {fileID: 0}
|
||||
m_PrefabInternal: {fileID: 0}
|
||||
m_GameObject: {fileID: 881384367}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 4e40ea81463f7264a8ce9334d6bf62ac, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
mixer: {fileID: 24100000, guid: efb934a745665924d8c7dd46c0a117ae, type: 2}
|
||||
maintheme: {fileID: 24500006, guid: efb934a745665924d8c7dd46c0a117ae, type: 2}
|
||||
end: {fileID: 245089854461186482, guid: efb934a745665924d8c7dd46c0a117ae, type: 2}
|
||||
gameovers: {fileID: 801288609}
|
||||
soundeffects:
|
||||
- {fileID: 1908750963}
|
||||
- {fileID: 368878861}
|
||||
- {fileID: 801288609}
|
||||
--- !u!1 &1028937042
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -622,7 +642,7 @@ Transform:
|
|||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 816024605}
|
||||
m_RootOrder: 2
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!82 &1028937044
|
||||
AudioSource:
|
||||
|
@ -820,7 +840,7 @@ Prefab:
|
|||
- target: {fileID: 224150154901314796, guid: 460d856ea4eb14cedb5fecde1fe6d743,
|
||||
type: 2}
|
||||
propertyPath: m_AnchoredPosition.x
|
||||
value: 0
|
||||
value: 64.16286
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 224150154901314796, guid: 460d856ea4eb14cedb5fecde1fe6d743,
|
||||
type: 2}
|
||||
|
@ -1081,7 +1101,7 @@ Transform:
|
|||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 816024605}
|
||||
m_RootOrder: 0
|
||||
m_RootOrder: 2
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!82 &1908750963
|
||||
AudioSource:
|
||||
|
|
|
@ -27,13 +27,13 @@ namespace Assets.Scripts.Entities.Attack {
|
|||
public void Attack() {
|
||||
if ( bulletPrefab == null )
|
||||
return;
|
||||
Debug.Log("Instantiate Bullet");
|
||||
GameObject b = GameObject.Instantiate(bulletPrefab);
|
||||
b.transform.rotation = spawn.rotation;
|
||||
b.transform.position = spawn.position;
|
||||
Bullet bu = b.GetComponent<Bullet>();
|
||||
bu.SetDamage(damage);
|
||||
bu.SetOwner(owner);
|
||||
GameController.instance.GetAudioControl().SfxPlay(0);
|
||||
}
|
||||
|
||||
public float GetCooldownTime() {
|
||||
|
|
|
@ -240,12 +240,16 @@ public class GameController : MonoBehaviour {
|
|||
//Time.timeScale = 0;
|
||||
if ( ui != null ) {
|
||||
Debug.Log("show Gameover UI");
|
||||
cam.GetComponent<AudioControl>().SfxPlay(2);
|
||||
ui.GetComponent<UIController>().ShowGameOverUI();
|
||||
} else {
|
||||
Debug.Log("No UI specified");
|
||||
}
|
||||
}
|
||||
|
||||
public AudioControl GetAudioControl() {
|
||||
return cam.GetComponent<AudioControl>();
|
||||
}
|
||||
|
||||
public UIController GetUI() {
|
||||
return ui.GetComponent<UIController>();
|
||||
|
|
Loading…
Add table
Reference in a new issue