Files
Simulator/DroneSimulator/VisualData.cs
2025-05-23 19:48:37 +03:00

39 lines
1.4 KiB
C#
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System.Numerics;
namespace VisualData
{
public struct VisualHead
{
public enum VisualType : int { None = 0, Drone = 1 } // Тип объекта
public int Size; // Размер данных этой структуры в байтах (проверка для соответствия передачи структуры)
public VisualType Type; // Тип передоваемого объекта
}
public struct VisualDrone
{
public VisualHead Head;
public enum DroneState : int { Dead = 0, Disabled = 1, Waiting = 2, Active = 3 } // Переключения типа 3D модели
public int Count; // Всего дронов на полигоне
public int Index; // Номер дрона
public int ID; // Идентификатор (для привязки камеры)
public struct ARGB { public byte A, R, G, B; }
public struct Quat { public float X, Y, Z, W; }
public struct Vect3 { public float X, Y, Z; }
public ARGB Color; // Цвет корпуса
public Quat Rotate; // Кватернион вращения
public Vect3 Position; // Координаты в пространстве
public float Scale; // Масштаб модельки (1=оригинальный)
public DroneState State; // Тип прорисовываемой модели
public float Power; // Скорость всех двигателей
}
}