1
This commit is contained in:
@@ -80,10 +80,10 @@ namespace BITFALL.Throws
|
||||
if (IsEntered is false) return;
|
||||
if (eventName is not BITConstant.Player.Throw) return;
|
||||
if (!_equipmentContainer.TryUseEquip<EquipmentAsThrow>()) return;
|
||||
var instance = _assetableThrow.GetInstance();
|
||||
var instance =Instantiate(_assetableThrow.Prefab,
|
||||
throwPoint.position + throwPoint.forward * 0.016f,
|
||||
throwPoint.rotation) ;
|
||||
if (!instance.TryGetComponent<Rigidbody>(out var _rigidbody)) return;
|
||||
_rigidbody.rotation = throwPoint.rotation;
|
||||
_rigidbody.position = throwPoint.position;
|
||||
_rigidbody.AddForce(throwPoint.forward * throwForce, ForceMode.VelocityChange);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user