This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pub const Ld = struct { | |
description: []const u8, | |
title: []const u8, | |
// renamed from: "$schema | |
schema: []const u8, | |
// renamed from: "$ref | |
ref: []const u8, | |
version: []const u8, | |
// renamed from: "LdtkJsonRoot | |
ldtk_json_root: LdtkJsonRoot, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import bevy_pbr::mesh_view_bindings | |
#import bevy_pbr::mesh_bindings | |
#import bevy_pbr::pbr_types | |
#import bevy_pbr::utils | |
#import bevy_pbr::clustered_forward | |
#import bevy_pbr::lighting | |
#import bevy_pbr::shadows | |
#import bevy_pbr::pbr_functions |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Diagnostics; | |
using System.Runtime.CompilerServices; | |
using System.Runtime.InteropServices; | |
namespace Nez.Unmanaged | |
{ | |
unsafe public struct BlobAllocator : IDisposable | |
{ | |
byte* m_RootPtr; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
namespace SimpleECS | |
{ | |
struct Position | |
{ | |
public float X, Y; | |
} | |
struct Velocity |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using ImGuiNET; | |
using Microsoft.Xna.Framework; | |
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using Num = System.Numerics; | |
namespace Nez.ImGuiTools | |
{ | |
public class FilePicker |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const int C2_GJK_ITERS = 20; | |
public const int C2_MAX_POLYGON_VERTS = 8; | |
// position of impact p = ray.p + ray.d * raycast.t | |
public static c2v c2Impact(c2Ray ray, float t) => c2Add(ray.p, c2Mulvs(ray.d, t)); | |
#region Wrapper Methods | |
public static unsafe bool c2Collided(void* A, c2x* ax, C2_TYPE typeA, void* B, c2x* bx, C2_TYPE typeB) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Microsoft.Xna.Framework; | |
using Microsoft.Xna.Framework.Graphics; | |
using Microsoft.Xna.Framework.Input; | |
using Nez; | |
namespace TheWall | |
{ | |
public class Game2 : Game | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Microsoft.Xna.Framework; | |
using Nez; | |
using Nez.Sprites; | |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using Vapor.Code.Utility; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ##### ##### ##### ##### ##### ##### ##### | |
// ##### ##### Common Uniforms ##### ##### | |
// ##### ##### ##### ##### ##### ##### ##### | |
float4x4 _objectToWorld; | |
float4x4 _worldToView; | |
float4x4 _projection; // viewToCamera? | |
float4x4 _screenToWorld; // this is used to compute the world-position | |
// color of the light |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static bool TestAABBSweep(Vector2 extents1, Vector2 centre1, Vector2 velocity1, Vector2 extents2, Vector2 centre2, Vector2 velocity2, out float t0, out float t1) | |
{ | |
var aabb1 = new AABB(centre1, extents1); | |
var aabb2 = new AABB(centre2, extents2); | |
//Check if the boxes are currently overlapping | |
if (aabb1.Overlaps(aabb2)) | |
{ | |
t0 = t1 = 0; | |
return true; |
NewerOlder