Zombies machen jetzt Geräusche wenn sie durch Disable sterben
This commit is contained in:
parent
3bdf7231e3
commit
993b38c057
|
@ -0,0 +1,7 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 73951a4b66414d24999d439134425a40
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 022ee083930cfe04ba477ff4f4933734
|
||||||
|
timeCreated: 1486485811
|
||||||
|
licenseType: Store
|
||||||
|
NativeFormatImporter:
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
|
@ -282,7 +282,7 @@ MonoBehaviour:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
IsOn: 0
|
IsOn: 0
|
||||||
_turnOnTime:
|
_turnOnTime:
|
||||||
_hour: 21
|
_hour: 20
|
||||||
_minutes: 0
|
_minutes: 0
|
||||||
_turnOffTime:
|
_turnOffTime:
|
||||||
_hour: 6
|
_hour: 6
|
||||||
|
@ -296,7 +296,7 @@ Transform:
|
||||||
m_GameObject: {fileID: 37507747}
|
m_GameObject: {fileID: 37507747}
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
m_LocalPosition: {x: 27.598955, y: 1.3647667, z: -5.786058}
|
m_LocalPosition: {x: 27.598955, y: 1.3647667, z: -3.53}
|
||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children:
|
m_Children:
|
||||||
|
@ -397,6 +397,37 @@ Transform:
|
||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 60.966, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 60.966, y: 0, z: 0}
|
||||||
|
--- !u!1 &201896101
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 201896102}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: SpawnPoint1
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &201896102
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 201896101}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 29.519838, y: -0.21826363, z: 2}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!1 &227416517
|
--- !u!1 &227416517
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
@ -489,8 +520,19 @@ MonoBehaviour:
|
||||||
m_Script: {fileID: 11500000, guid: a61873b0f5608a44982d48387f34f682, type: 3}
|
m_Script: {fileID: 11500000, guid: a61873b0f5608a44982d48387f34f682, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
|
SpawnPoints:
|
||||||
|
- {fileID: 201896102}
|
||||||
|
- {fileID: 1946509920}
|
||||||
|
- {fileID: 959604379}
|
||||||
|
- {fileID: 1774227153}
|
||||||
|
ZombieDeathByDisableSoundeffects:
|
||||||
|
- {fileID: 8300000, guid: c792fd61575228d49bb4b4059f892a3c, type: 3}
|
||||||
|
- {fileID: 8300000, guid: 6919de8a1f2d3af43a02cf95a9ba0bd8, type: 3}
|
||||||
|
- {fileID: 8300000, guid: 78685af74d6fa4c46b006ae779d17129, type: 3}
|
||||||
|
- {fileID: 8300000, guid: 1896a757f58c7514fac60f967cb55901, type: 3}
|
||||||
|
- {fileID: 8300000, guid: e541b41adf0d8e542baa93445dca7816, type: 3}
|
||||||
ZombiePrefab: {fileID: 856601670117699726, guid: a34b2d22562c7214f9daf0d3dea8d85c, type: 3}
|
ZombiePrefab: {fileID: 856601670117699726, guid: a34b2d22562c7214f9daf0d3dea8d85c, type: 3}
|
||||||
_spawnRate: 2
|
_spawnRate: 4
|
||||||
_spawnTimer: 0
|
_spawnTimer: 0
|
||||||
--- !u!1001 &514859708
|
--- !u!1001 &514859708
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
|
@ -617,7 +659,11 @@ MonoBehaviour:
|
||||||
m_Bits: 4294967295
|
m_Bits: 4294967295
|
||||||
grounded: 0
|
grounded: 0
|
||||||
_hand: {fileID: 0}
|
_hand: {fileID: 0}
|
||||||
_carriedItem: {fileID: 0}
|
_carriedItemModel: {fileID: 0}
|
||||||
|
_carriedInteractible: {fileID: 0}
|
||||||
|
_dropItemForce: 3
|
||||||
|
_data: {fileID: 0}
|
||||||
|
_audioSource: {fileID: 0}
|
||||||
--- !u!1 &547927580
|
--- !u!1 &547927580
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
@ -1222,6 +1268,37 @@ RectTransform:
|
||||||
m_AnchoredPosition: {x: 117, y: -165.8}
|
m_AnchoredPosition: {x: 117, y: -165.8}
|
||||||
m_SizeDelta: {x: 200, y: 50}
|
m_SizeDelta: {x: 200, y: 50}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
|
--- !u!1 &959604378
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 959604379}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: SpawnPoint3
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &959604379
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 959604378}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 24.53, y: -0.21826363, z: -3.3542805}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!1 &983523618
|
--- !u!1 &983523618
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
@ -1254,6 +1331,7 @@ MonoBehaviour:
|
||||||
m_Script: {fileID: 11500000, guid: 6dcc72027d5c35441a351fdb5140b0f8, type: 3}
|
m_Script: {fileID: 11500000, guid: 6dcc72027d5c35441a351fdb5140b0f8, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
|
_name:
|
||||||
_baseStats:
|
_baseStats:
|
||||||
BaseEfficiency: 1
|
BaseEfficiency: 1
|
||||||
Fingers: 10
|
Fingers: 10
|
||||||
|
@ -1263,6 +1341,7 @@ MonoBehaviour:
|
||||||
HappinessDrainFactor: 1
|
HappinessDrainFactor: 1
|
||||||
CoffeePreference: 0.5
|
CoffeePreference: 0.5
|
||||||
MatePreference: 0.5
|
MatePreference: 0.5
|
||||||
|
_talkRange: 0
|
||||||
_currentEfficiency: 1
|
_currentEfficiency: 1
|
||||||
_fingersLeft: 10
|
_fingersLeft: 10
|
||||||
_caffeineLevel: 1
|
_caffeineLevel: 1
|
||||||
|
@ -1273,7 +1352,6 @@ MonoBehaviour:
|
||||||
_isHyperactive: 0
|
_isHyperactive: 0
|
||||||
_isOvercaffeinated: 0
|
_isOvercaffeinated: 0
|
||||||
_developerNeeds: {fileID: 0}
|
_developerNeeds: {fileID: 0}
|
||||||
_talkRange: 0
|
|
||||||
_caffeineNeed: {fileID: 0}
|
_caffeineNeed: {fileID: 0}
|
||||||
_wantedDrink: 0
|
_wantedDrink: 0
|
||||||
_hungerNeed: {fileID: 0}
|
_hungerNeed: {fileID: 0}
|
||||||
|
@ -1885,7 +1963,7 @@ PrefabInstance:
|
||||||
- target: {fileID: 3650884189301972455, guid: e1e33f0b2075b5c40817665dd8a86f31, type: 3}
|
- target: {fileID: 3650884189301972455, guid: e1e33f0b2075b5c40817665dd8a86f31, type: 3}
|
||||||
propertyPath: _player
|
propertyPath: _player
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 514859709}
|
objectReference: {fileID: 514859711}
|
||||||
- target: {fileID: 3650884189301972455, guid: e1e33f0b2075b5c40817665dd8a86f31, type: 3}
|
- target: {fileID: 3650884189301972455, guid: e1e33f0b2075b5c40817665dd8a86f31, type: 3}
|
||||||
propertyPath: _maxContextBufferSize
|
propertyPath: _maxContextBufferSize
|
||||||
value: 3
|
value: 3
|
||||||
|
@ -1902,6 +1980,10 @@ PrefabInstance:
|
||||||
propertyPath: NeedFullfilledParticleEffect
|
propertyPath: NeedFullfilledParticleEffect
|
||||||
value:
|
value:
|
||||||
objectReference: {fileID: 1620116211597326, guid: 094c049ae10f1c3419c96c4bce41cf8c, type: 3}
|
objectReference: {fileID: 1620116211597326, guid: 094c049ae10f1c3419c96c4bce41cf8c, type: 3}
|
||||||
|
- target: {fileID: 3650884189301972455, guid: e1e33f0b2075b5c40817665dd8a86f31, type: 3}
|
||||||
|
propertyPath: ZombieDeathByDisableParticleEffect
|
||||||
|
value:
|
||||||
|
objectReference: {fileID: 1655205912634366, guid: 022ee083930cfe04ba477ff4f4933734, type: 3}
|
||||||
m_RemovedComponents: []
|
m_RemovedComponents: []
|
||||||
m_RemovedGameObjects: []
|
m_RemovedGameObjects: []
|
||||||
m_AddedGameObjects: []
|
m_AddedGameObjects: []
|
||||||
|
@ -1999,6 +2081,37 @@ Transform:
|
||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
--- !u!1 &1774227152
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 1774227153}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: SpawnPoint4
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &1774227153
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1774227152}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 34.85, y: -0.21826363, z: -3.3542805}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!1001 &1814492790
|
--- !u!1001 &1814492790
|
||||||
PrefabInstance:
|
PrefabInstance:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
@ -2121,6 +2234,7 @@ MonoBehaviour:
|
||||||
m_Script: {fileID: 11500000, guid: 6dcc72027d5c35441a351fdb5140b0f8, type: 3}
|
m_Script: {fileID: 11500000, guid: 6dcc72027d5c35441a351fdb5140b0f8, type: 3}
|
||||||
m_Name:
|
m_Name:
|
||||||
m_EditorClassIdentifier:
|
m_EditorClassIdentifier:
|
||||||
|
_name:
|
||||||
_baseStats:
|
_baseStats:
|
||||||
BaseEfficiency: 1
|
BaseEfficiency: 1
|
||||||
Fingers: 10
|
Fingers: 10
|
||||||
|
@ -2130,6 +2244,7 @@ MonoBehaviour:
|
||||||
HappinessDrainFactor: 1
|
HappinessDrainFactor: 1
|
||||||
CoffeePreference: 0.5
|
CoffeePreference: 0.5
|
||||||
MatePreference: 0.5
|
MatePreference: 0.5
|
||||||
|
_talkRange: 2
|
||||||
_currentEfficiency: 1
|
_currentEfficiency: 1
|
||||||
_fingersLeft: 10
|
_fingersLeft: 10
|
||||||
_caffeineLevel: 1
|
_caffeineLevel: 1
|
||||||
|
@ -2140,7 +2255,6 @@ MonoBehaviour:
|
||||||
_isHyperactive: 0
|
_isHyperactive: 0
|
||||||
_isOvercaffeinated: 0
|
_isOvercaffeinated: 0
|
||||||
_developerNeeds: {fileID: 0}
|
_developerNeeds: {fileID: 0}
|
||||||
_talkRange: 2
|
|
||||||
_caffeineNeed: {fileID: 0}
|
_caffeineNeed: {fileID: 0}
|
||||||
_wantedDrink: 0
|
_wantedDrink: 0
|
||||||
_hungerNeed: {fileID: 0}
|
_hungerNeed: {fileID: 0}
|
||||||
|
@ -2244,6 +2358,37 @@ AudioSource:
|
||||||
m_PreInfinity: 2
|
m_PreInfinity: 2
|
||||||
m_PostInfinity: 2
|
m_PostInfinity: 2
|
||||||
m_RotationOrder: 4
|
m_RotationOrder: 4
|
||||||
|
--- !u!1 &1946509919
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 1946509920}
|
||||||
|
m_Layer: 0
|
||||||
|
m_Name: SpawnPoint2
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!4 &1946509920
|
||||||
|
Transform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 1946509919}
|
||||||
|
serializedVersion: 2
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 29.519838, y: -0.21826363, z: -9.93}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 0}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
--- !u!1 &2113596626
|
--- !u!1 &2113596626
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
|
@ -2365,3 +2510,7 @@ SceneRoots:
|
||||||
- {fileID: 1814492790}
|
- {fileID: 1814492790}
|
||||||
- {fileID: 514859708}
|
- {fileID: 514859708}
|
||||||
- {fileID: 37507749}
|
- {fileID: 37507749}
|
||||||
|
- {fileID: 201896102}
|
||||||
|
- {fileID: 1946509920}
|
||||||
|
- {fileID: 959604379}
|
||||||
|
- {fileID: 1774227153}
|
||||||
|
|
|
@ -12,6 +12,7 @@ public partial class GameManager : MonoBehaviourSingleton<GameManager>
|
||||||
[SerializeField] private Difficulty _difficulty = Difficulty.Medium;
|
[SerializeField] private Difficulty _difficulty = Difficulty.Medium;
|
||||||
|
|
||||||
public GameObject NeedFullfilledParticleEffect;
|
public GameObject NeedFullfilledParticleEffect;
|
||||||
|
public GameObject ZombieDeathByDisableParticleEffect;
|
||||||
|
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
private Character _player;
|
private Character _player;
|
||||||
|
|
|
@ -166,7 +166,7 @@ public class Text2Speech : MonoBehaviour
|
||||||
|
|
||||||
IEnumerator GenerateAndSynthesizeText(string context)
|
IEnumerator GenerateAndSynthesizeText(string context)
|
||||||
{
|
{
|
||||||
var generateTextTask = GenerateText(context);
|
var generateTextTask = GenerateTextAsync(context);
|
||||||
|
|
||||||
yield return new WaitUntil(() => generateTextTask.IsCompleted);
|
yield return new WaitUntil(() => generateTextTask.IsCompleted);
|
||||||
|
|
||||||
|
@ -181,7 +181,7 @@ public class Text2Speech : MonoBehaviour
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async Task<string> GenerateText(string context)
|
async Task<string> GenerateTextAsync(string context)
|
||||||
{
|
{
|
||||||
Model model = Model.ChatGPTTurbo;
|
Model model = Model.ChatGPTTurbo;
|
||||||
|
|
||||||
|
|
|
@ -5,6 +5,10 @@ using Utility;
|
||||||
|
|
||||||
public class ZombieSpawner : MonoBehaviour
|
public class ZombieSpawner : MonoBehaviour
|
||||||
{
|
{
|
||||||
|
[SerializeField]
|
||||||
|
List<Transform> SpawnPoints;
|
||||||
|
[SerializeField]
|
||||||
|
List<AudioClip> ZombieDeathByDisableSoundeffects;
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
GameObject ZombiePrefab;
|
GameObject ZombiePrefab;
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
|
@ -28,7 +32,7 @@ public class ZombieSpawner : MonoBehaviour
|
||||||
|
|
||||||
if (_spawnTimer <= 0)
|
if (_spawnTimer <= 0)
|
||||||
{
|
{
|
||||||
Instantiate(ZombiePrefab, transform.position, Quaternion.identity, transform);
|
SpawnZombie();
|
||||||
_spawnTimer = _secondsPerAliveTime / _spawnRate;
|
_spawnTimer = _secondsPerAliveTime / _spawnRate;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -47,14 +51,27 @@ public class ZombieSpawner : MonoBehaviour
|
||||||
if (GameManager.Instance.ContextBuffer != null)
|
if (GameManager.Instance.ContextBuffer != null)
|
||||||
GameManager.Instance.RemoveContext("The Developer informs Gottfried that Zombies appeared outside so Gottfried better not leave the office");
|
GameManager.Instance.RemoveContext("The Developer informs Gottfried that Zombies appeared outside so Gottfried better not leave the office");
|
||||||
// Destroy all children (zombies)
|
// Destroy all children (zombies)
|
||||||
for (int i = 0; i < transform.childCount; i++)
|
KillZombiesByDisable();
|
||||||
{
|
|
||||||
KillZombiesByDisable();
|
}
|
||||||
}
|
|
||||||
|
private void SpawnZombie()
|
||||||
|
{
|
||||||
|
Transform pos = SpawnPoints[Random.Range(0, SpawnPoints.Count)];
|
||||||
|
Instantiate(ZombiePrefab, pos.position, Quaternion.identity, transform);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void KillZombiesByDisable()
|
private void KillZombiesByDisable()
|
||||||
{
|
{
|
||||||
Destroy(transform.GetChild(i).gameObject);
|
for (int i = 0; i < transform.childCount; i++)
|
||||||
|
{
|
||||||
|
GameObject zombie = transform.GetChild(i).gameObject;
|
||||||
|
Vector3 zombiePosition = zombie.transform.position;
|
||||||
|
Destroy(zombie);
|
||||||
|
GameObject particleEffect = Instantiate(GameManager.Instance.ZombieDeathByDisableParticleEffect, zombiePosition, Quaternion.Euler(-90, 0, 0), GameManager.Instance.transform);
|
||||||
|
AudioSource audio = particleEffect.GetComponent<AudioSource>();
|
||||||
|
audio.clip = ZombieDeathByDisableSoundeffects[Random.Range(0, ZombieDeathByDisableSoundeffects.Count)];
|
||||||
|
audio.Play();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f077182842e813542976602513016f6c
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
Binary file not shown.
|
@ -0,0 +1,23 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: c792fd61575228d49bb4b4059f892a3c
|
||||||
|
AudioImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 7
|
||||||
|
defaultSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
loadType: 0
|
||||||
|
sampleRateSetting: 0
|
||||||
|
sampleRateOverride: 44100
|
||||||
|
compressionFormat: 1
|
||||||
|
quality: 1
|
||||||
|
conversionMode: 0
|
||||||
|
preloadAudioData: 0
|
||||||
|
platformSettingOverrides: {}
|
||||||
|
forceToMono: 0
|
||||||
|
normalize: 1
|
||||||
|
loadInBackground: 0
|
||||||
|
ambisonic: 0
|
||||||
|
3D: 1
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
Binary file not shown.
|
@ -0,0 +1,23 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 6919de8a1f2d3af43a02cf95a9ba0bd8
|
||||||
|
AudioImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 7
|
||||||
|
defaultSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
loadType: 0
|
||||||
|
sampleRateSetting: 0
|
||||||
|
sampleRateOverride: 44100
|
||||||
|
compressionFormat: 1
|
||||||
|
quality: 1
|
||||||
|
conversionMode: 0
|
||||||
|
preloadAudioData: 0
|
||||||
|
platformSettingOverrides: {}
|
||||||
|
forceToMono: 0
|
||||||
|
normalize: 1
|
||||||
|
loadInBackground: 0
|
||||||
|
ambisonic: 0
|
||||||
|
3D: 1
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
Binary file not shown.
|
@ -0,0 +1,23 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 78685af74d6fa4c46b006ae779d17129
|
||||||
|
AudioImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 7
|
||||||
|
defaultSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
loadType: 0
|
||||||
|
sampleRateSetting: 0
|
||||||
|
sampleRateOverride: 44100
|
||||||
|
compressionFormat: 1
|
||||||
|
quality: 1
|
||||||
|
conversionMode: 0
|
||||||
|
preloadAudioData: 0
|
||||||
|
platformSettingOverrides: {}
|
||||||
|
forceToMono: 0
|
||||||
|
normalize: 1
|
||||||
|
loadInBackground: 0
|
||||||
|
ambisonic: 0
|
||||||
|
3D: 1
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
Binary file not shown.
|
@ -0,0 +1,23 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 1896a757f58c7514fac60f967cb55901
|
||||||
|
AudioImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 7
|
||||||
|
defaultSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
loadType: 0
|
||||||
|
sampleRateSetting: 0
|
||||||
|
sampleRateOverride: 44100
|
||||||
|
compressionFormat: 1
|
||||||
|
quality: 1
|
||||||
|
conversionMode: 0
|
||||||
|
preloadAudioData: 0
|
||||||
|
platformSettingOverrides: {}
|
||||||
|
forceToMono: 0
|
||||||
|
normalize: 1
|
||||||
|
loadInBackground: 0
|
||||||
|
ambisonic: 0
|
||||||
|
3D: 1
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
Binary file not shown.
|
@ -0,0 +1,23 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: e541b41adf0d8e542baa93445dca7816
|
||||||
|
AudioImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 7
|
||||||
|
defaultSettings:
|
||||||
|
serializedVersion: 2
|
||||||
|
loadType: 0
|
||||||
|
sampleRateSetting: 0
|
||||||
|
sampleRateOverride: 44100
|
||||||
|
compressionFormat: 1
|
||||||
|
quality: 1
|
||||||
|
conversionMode: 0
|
||||||
|
preloadAudioData: 0
|
||||||
|
platformSettingOverrides: {}
|
||||||
|
forceToMono: 0
|
||||||
|
normalize: 1
|
||||||
|
loadInBackground: 0
|
||||||
|
ambisonic: 0
|
||||||
|
3D: 1
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
Loading…
Reference in New Issue