0.2.0-dev Download ZIP
73 lines ·2.1 KB Raw
| 1 | namespace EvilEngine.Host.Gait; |
| 2 | |
| 3 | public static class GaitSlots |
| 4 | { |
| 5 | public const string Idle = "idle"; |
| 6 | public const string Walk = "walk"; |
| 7 | public const string Run = "run"; |
| 8 | public const string CrouchIdle = "crouch.idle"; |
| 9 | public const string CrouchWalk = "crouch.walk"; |
| 10 | public const string Jump = "jump"; |
| 11 | public const string Swim = "swim"; |
| 12 | public const string Landing = "gesture.land"; |
| 13 | public const string Noclip = "gesture.noclip"; |
| 14 | } |
| 15 | |
| 16 | public static class GaitParameters |
| 17 | { |
| 18 | public const string MoveX = "move_x"; |
| 19 | public const string MoveY = "move_y"; |
| 20 | public const string AimYaw = "aim_yaw"; |
| 21 | public const string AimPitch = "aim_pitch"; |
| 22 | public const string HeadYaw = "head_yaw"; |
| 23 | public const string HeadPitch = "head_pitch"; |
| 24 | } |
| 25 | |
| 26 | public sealed record GaitRules |
| 27 | { |
| 28 | public static GaitRules Standard { get; } = new(); |
| 29 | |
| 30 | public double MovingSpeed { get; init; } = 0.0127; |
| 31 | |
| 32 | public double RunningSpeed { get; init; } = 3.81; |
| 33 | |
| 34 | public double VaultSpeed { get; init; } = 25.4; |
| 35 | |
| 36 | public double JumpLanding { get; init; } = 0.2; |
| 37 | |
| 38 | public int SwimmingWater { get; init; } = 2; |
| 39 | |
| 40 | public double RateSpeed { get; init; } = 0.00508; |
| 41 | |
| 42 | public double FastestRate { get; init; } = 2; |
| 43 | |
| 44 | public double SwimmingRate { get; init; } = 0.5; |
| 45 | |
| 46 | public double VaultRate { get; init; } = 0.1; |
| 47 | |
| 48 | public double StillTurn { get; init; } = 45; |
| 49 | |
| 50 | public double TurnRate { get; init; } = 12; |
| 51 | |
| 52 | public double SlowestTurn { get; init; } = 7.2; |
| 53 | |
| 54 | public double FastestTurn { get; init; } = 720; |
| 55 | |
| 56 | public double YawOrigin { get; init; } = -180; |
| 57 | |
| 58 | public double Fade { get; init; } = 0.2; |
| 59 | |
| 60 | public int LandingSlot { get; init; } = 2; |
| 61 | |
| 62 | public int NoclipSlot { get; init; } = 6; |
| 63 | |
| 64 | public IReadOnlyDictionary<string, string> Fallbacks { get; init; } = new Dictionary<string, string> |
| 65 | { |
| 66 | [GaitSlots.Run] = GaitSlots.Walk, |
| 67 | [GaitSlots.Walk] = GaitSlots.Idle, |
| 68 | [GaitSlots.CrouchWalk] = GaitSlots.CrouchIdle, |
| 69 | [GaitSlots.CrouchIdle] = GaitSlots.Idle, |
| 70 | [GaitSlots.Jump] = GaitSlots.Idle, |
| 71 | [GaitSlots.Swim] = GaitSlots.Idle |
| 72 | }; |
| 73 | } |