Actually fix revive
This commit is contained in:
parent
eb6f1dd61f
commit
98421cb784
|
@ -811,10 +811,6 @@ PrefabInstance:
|
|||
propertyPath: m_IncludeLayers.m_Bits
|
||||
value: 4294967295
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3086165646112058191, guid: 30e0cc55a67f02d4f92b2677ec4b1511, type: 3}
|
||||
propertyPath: onlyCallZeroHealthOnce
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3086165646112058191, guid: 30e0cc55a67f02d4f92b2677ec4b1511, type: 3}
|
||||
propertyPath: OnHealthZero.m_PersistentCalls.m_Calls.Array.size
|
||||
value: 1
|
||||
|
@ -1451,10 +1447,6 @@ PrefabInstance:
|
|||
propertyPath: m_Parameters.widthCurve.m_Curve.Array.data[1].outWeight
|
||||
value: 0.33333334
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3086165646112058191, guid: 99a6ff8b9591949439b620b13bd249a4, type: 3}
|
||||
propertyPath: onlyCallZeroHealthOnce
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3086165646112058191, guid: 99a6ff8b9591949439b620b13bd249a4, type: 3}
|
||||
propertyPath: OnHealthZero.m_PersistentCalls.m_Calls.Array.size
|
||||
value: 1
|
||||
|
@ -4260,6 +4252,10 @@ PrefabInstance:
|
|||
propertyPath: m_Name
|
||||
value: UI
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 9075173710402410956, guid: 48e0e53445d42474895d37a321c39d1c, type: 3}
|
||||
propertyPath: m_AnchoredPosition.x
|
||||
value: -9.998047
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_RemovedGameObjects: []
|
||||
m_AddedGameObjects: []
|
||||
|
|
|
@ -21,17 +21,14 @@ public class GameManager : MonoBehaviour
|
|||
|
||||
void Awake()
|
||||
{
|
||||
if (Instance == null)
|
||||
if (Instance != null)
|
||||
{
|
||||
Instance = this;
|
||||
DontDestroyOnLoad(gameObject);
|
||||
Revives = 1;
|
||||
ReviveText.text = Revives + "x";
|
||||
}
|
||||
else
|
||||
{
|
||||
Destroy(gameObject);
|
||||
Destroy(Instance);
|
||||
}
|
||||
|
||||
Instance = this;
|
||||
Revives = 1;
|
||||
ReviveText.text = Revives + "x";
|
||||
}
|
||||
|
||||
void Start()
|
||||
|
@ -40,6 +37,7 @@ public class GameManager : MonoBehaviour
|
|||
|
||||
public void playerDied(GameObject who)
|
||||
{
|
||||
Debug.Log($"{who.name} died");
|
||||
if (Revives == 0)
|
||||
{
|
||||
AudioManager.Instance.StopAllAudio();
|
||||
|
|
|
@ -109,7 +109,10 @@ public class HealthComponent : MonoBehaviour, ISquezeDamageReceiver
|
|||
maxHealth = amount;
|
||||
|
||||
if (heal)
|
||||
{
|
||||
currentHealth = amount;
|
||||
alreadyReachedZero = false;
|
||||
}
|
||||
}
|
||||
|
||||
public void TakeDamage(float damage)
|
||||
|
|
|
@ -139,7 +139,8 @@ PlayerSettings:
|
|||
vulkanEnableCommandBufferRecycling: 1
|
||||
loadStoreDebugModeEnabled: 0
|
||||
bundleVersion: 1.0
|
||||
preloadedAssets: []
|
||||
preloadedAssets:
|
||||
- {fileID: 11400000, guid: de04e34f85a966e4da851d9b3d804fa1, type: 2}
|
||||
metroInputSource: 0
|
||||
wsaTransparentSwapchain: 0
|
||||
m_HolographicPauseOnTrackingLoss: 1
|
||||
|
|
Loading…
Reference in New Issue