Merge branch 'main' of https://gitlab.badbrain.dev/bloom-bois-2021/lucidity into main
This commit is contained in:
commit
1f40cb14b8
BIN
Assets/FMOD/Desktop/Master.bank (Stored with Git LFS)
BIN
Assets/FMOD/Desktop/Master.bank (Stored with Git LFS)
Binary file not shown.
BIN
Assets/FMOD/Desktop/Master.strings.bank (Stored with Git LFS)
BIN
Assets/FMOD/Desktop/Master.strings.bank (Stored with Git LFS)
Binary file not shown.
|
@ -133,7 +133,7 @@ Material:
|
||||||
m_Colors:
|
m_Colors:
|
||||||
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
|
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
|
||||||
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
- _Color1: {r: 0.3634766, g: 5.3403134, b: 0, a: 1}
|
- _Color1: {r: 1.4539073, g: 21.361254, b: 0, a: 1}
|
||||||
- _Color2: {r: 0.24509804, g: 0.3764706, b: 0, a: 1}
|
- _Color2: {r: 0.24509804, g: 0.3764706, b: 0, a: 1}
|
||||||
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
|
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
|
||||||
- _FarColor: {r: 1, g: 1, b: 1, a: 1}
|
- _FarColor: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
|
|
@ -29,6 +29,8 @@ public class EntityLives : MonoBehaviour
|
||||||
|
|
||||||
private void Die()
|
private void Die()
|
||||||
{
|
{
|
||||||
|
FMODUnity.RuntimeManager.PlayOneShot("event:/hit");
|
||||||
|
|
||||||
--lives;
|
--lives;
|
||||||
if (lives > 0)
|
if (lives > 0)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,6 +1,10 @@
|
||||||
using System;
|
using System;
|
||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using FMOD;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.InputSystem;
|
using UnityEngine.InputSystem;
|
||||||
|
using Debug = UnityEngine.Debug;
|
||||||
using PlayerInput = Input.PlayerInput;
|
using PlayerInput = Input.PlayerInput;
|
||||||
public class PlayerShootInput : ShootInputBase
|
public class PlayerShootInput : ShootInputBase
|
||||||
{
|
{
|
||||||
|
@ -25,6 +29,11 @@ public class PlayerShootInput : ShootInputBase
|
||||||
_actions.Default.Shoot.performed -= Shoot;
|
_actions.Default.Shoot.performed -= Shoot;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void Start()
|
||||||
|
{
|
||||||
|
StartCoroutine(MakePewSounds());
|
||||||
|
}
|
||||||
|
|
||||||
private void Shoot(InputAction.CallbackContext obj)
|
private void Shoot(InputAction.CallbackContext obj)
|
||||||
{
|
{
|
||||||
_isShooting = obj.ReadValueAsButton();
|
_isShooting = obj.ReadValueAsButton();
|
||||||
|
@ -35,4 +44,19 @@ public class PlayerShootInput : ShootInputBase
|
||||||
return _isShooting;
|
return _isShooting;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private IEnumerator MakePewSounds()
|
||||||
|
{
|
||||||
|
var wait = new WaitForSeconds(0.02f);
|
||||||
|
|
||||||
|
while (true)
|
||||||
|
{
|
||||||
|
if (_isShooting)
|
||||||
|
{
|
||||||
|
FMODUnity.RuntimeManager.PlayOneShot("event:/shoot");
|
||||||
|
}
|
||||||
|
|
||||||
|
yield return wait;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
BIN
Assets/StreamingAssets/Master.bank (Stored with Git LFS)
BIN
Assets/StreamingAssets/Master.bank (Stored with Git LFS)
Binary file not shown.
BIN
Assets/StreamingAssets/Master.strings.bank (Stored with Git LFS)
BIN
Assets/StreamingAssets/Master.strings.bank (Stored with Git LFS)
Binary file not shown.
Loading…
Reference in New Issue