You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
435 B
18 lines
435 B
namespace Unity.FPS.Gameplay
|
|
{
|
|
public class JetpackPickup : Pickup
|
|
{
|
|
protected override void OnPicked(PlayerCharacterController byPlayer)
|
|
{
|
|
var jetpack = byPlayer.GetComponent<Jetpack>();
|
|
if (!jetpack)
|
|
return;
|
|
|
|
if (jetpack.TryUnlock())
|
|
{
|
|
PlayPickupFeedback();
|
|
Destroy(gameObject);
|
|
}
|
|
}
|
|
}
|
|
}
|