#include "scripts/common.txt"
#include "scripts/BP_common.txt"

class BP_PickupFeather : BP_Pickup
{
	//------------------------------------------------------------------------------------------------------------------------
    BP_PickupFeather(kActor @actor)
	{
        super(@actor);
    }
	//------------------------------------------------------------------------------------------------------------------------
    void OnTick() override
	{
		self.Yaw() += 0.017453f;
		if (IsPlayerInRadius(self.Origin(), radius))
		{
			OnPickup();
		}
    }
	//------------------------------------------------------------------------------------------------------------------------
	void OnPickup() override
	{
		SetFeathers(GetFeathers() + 1);
		Game.PlaySound("sounds/shaders/generic_4_non_weapon_pickup.ksnd");
		Game.PrintLine(LTKey(29), 0);
		self.MarkPersistentBit(false);
		self.Remove();
	}
	//------------------------------------------------------------------------------------------------------------------------
}
