Update PistolComponent.cs
This commit is contained in:
parent
0779b443ff
commit
1030fd2fb9
@ -129,22 +129,17 @@ namespace Item
|
|||||||
{
|
{
|
||||||
Fire(!hasCloseTarget);
|
Fire(!hasCloseTarget);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
[ServerRpc]
|
[ServerRpc]
|
||||||
private void SpawnBullet(GameObject projectile)
|
|
||||||
{
|
|
||||||
|
|
||||||
InstanceFinder.ServerManager.Spawn(projectile);
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
public void Fire(bool offsetWithTargetBall)
|
public void Fire(bool offsetWithTargetBall)
|
||||||
{
|
{
|
||||||
shootLightDuration = 0;
|
shootLightDuration = 0;
|
||||||
shootLight.gameObject.SetActive(true);
|
shootLight.gameObject.SetActive(true);
|
||||||
|
|
||||||
var projectile = Instantiate(projectilePrefab, bulletSpawnPoint);
|
|
||||||
SpawnBullet(projectile);
|
|
||||||
// var projectile = Instantiate(projectilePrefab, bulletSpawnPoint);
|
// var projectile = Instantiate(projectilePrefab, bulletSpawnPoint);
|
||||||
|
var projectile = Instantiate(projectilePrefab, bulletSpawnPoint);
|
||||||
|
InstanceFinder.ServerManager.Spawn(projectile); //var projectile = Instantiate(projectilePrefab, bulletSpawnPoint);
|
||||||
|
|
||||||
//InstanceFinder.ServerManager.Spawn(projectile);
|
//InstanceFinder.ServerManager.Spawn(projectile);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user