Files
LuckerGame/code/Minigames/FpsTest/PawnPropertyProxyComponent.cs
2023-08-03 21:32:33 -07:00

23 lines
721 B
C#

using System.ComponentModel;
using LuckerGame.Entities;
using Sandbox;
namespace LuckerGame.Minigames.FpsTest;
/// <summary>
/// Component attached to a Lucker that will allow us to use [ClientInput] in the actual minigame's Pawn.
/// </summary>
/// <
/// <para>
/// This is because [ClientInput] only works for the Pawn owned by the Client (Lucker), and the Lucker's components.
/// We create this component in the Minigame's Pawn, attach it to the Lucker, and use these properties from there.
/// </para>
public class PawnPropertyProxyComponent : EntityComponent<Lucker>
{
[ClientInput]
public Vector3 InputDirection { get; set; }
[ClientInput]
public Angles ViewAngles { get; set; }
}