2
0
mirror of https://github.com/raylib-cs/raylib-cs synced 2025-07-02 19:13:43 -04:00

Add .editorconfig and apply formatting

This commit is contained in:
2023-08-27 15:20:26 +01:00
parent d1f0b9fd91
commit 696955463f
32 changed files with 7217 additions and 7194 deletions

View File

@ -1,40 +1,39 @@
using System.Numerics;
using System.Runtime.InteropServices;
namespace Raylib_cs
namespace Raylib_cs;
/// <summary>
/// Camera2D, defines position/orientation in 2d space
/// </summary>
[StructLayout(LayoutKind.Sequential)]
public partial struct Camera2D
{
/// <summary>
/// Camera2D, defines position/orientation in 2d space
/// Camera offset (displacement from target)
/// </summary>
[StructLayout(LayoutKind.Sequential)]
public partial struct Camera2D
public Vector2 Offset;
/// <summary>
/// Camera target (rotation and zoom origin)
/// </summary>
public Vector2 Target;
/// <summary>
/// Camera rotation in degrees
/// </summary>
public float Rotation;
/// <summary>
/// Camera zoom (scaling), should be 1.0f by default
/// </summary>
public float Zoom;
public Camera2D(Vector2 offset, Vector2 target, float rotation, float zoom)
{
/// <summary>
/// Camera offset (displacement from target)
/// </summary>
public Vector2 Offset;
/// <summary>
/// Camera target (rotation and zoom origin)
/// </summary>
public Vector2 Target;
/// <summary>
/// Camera rotation in degrees
/// </summary>
public float Rotation;
/// <summary>
/// Camera zoom (scaling), should be 1.0f by default
/// </summary>
public float Zoom;
public Camera2D(Vector2 offset, Vector2 target, float rotation, float zoom)
{
this.Offset = offset;
this.Target = target;
this.Rotation = rotation;
this.Zoom = zoom;
}
this.Offset = offset;
this.Target = target;
this.Rotation = rotation;
this.Zoom = zoom;
}
}