This file contains 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
<# | |
.SYNOPSIS | |
Runs Godot editor and automatically restarts it if it closes. | |
.DESCRIPTION | |
This script launches the Godot editor with specified arguments, and automatically restarts it if it closes. | |
.PARAMETER ExePath | |
The path to the Godot executable. Defaults to the console version of Godot 4.4 stable. | |
Use the _console.exe version of godot otherwise the script won't wait while godot is running. |
This file contains 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
//this is a snippet from my framework. you'll have to make some tiny syntax adjustments to use this. | |
//for details on json5, see https://json5.org/ | |
/// <summary> | |
/// Preprocess a JSON5 string to convert it to valid JSON for Microsoft's System.Text.Json deserializer. | |
/// </summary> | |
/// <param name="json5String">The JSON5 string to preprocess.</param> | |
/// <returns>A valid JSON string.</returns> | |
private static string PreprocessJson5ToJson(string json5String) | |
{ |
This file contains 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
<?xml version="1.0" encoding="UTF-8"?> | |
<doc xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | |
<assembly> | |
<name>ImGui.NET</name> | |
</assembly> | |
<members> | |
<member name="T:ImGuiNET.ImGuiWindowFlags"> | |
<summary> | |
Flags for ImGui window creation. | |
</summary> |
This file contains 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
//This code utilizes some of my private godot c# scafolding, so unfortunately you can't just copy/paste it. | |
// but the workflow is general to godot 4.3, so just follow the _Setup() workflow and then the workflow to use it is | |
// - AddToStage() | |
// - TakePicture() | |
// - ClearStage() | |
/// <summary> | |
/// PhotoBooth class represents a virtual photo booth for capturing images of 3D scenes. | |
/// It uses a separate scene with a Viewport to render the content, allowing snapshots to be taken with different configurations. | |
/// </summary> |
This file contains 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
//godot physics collison detection does not provide collision depth | |
//this code performs manual collision detection and geenerats depth also. | |
//this code has not been optimized, but should be relatively fast as it does all calculations in c# (no crossing to native) | |
//IF YOU FIND THIS CODE USEFUL AND WOULD LIKE A REPO: leave a comment and I can consider putting my entire (custom csharp) framework up. | |
using Godot; | |
public static class zz_Extensions_Shape3D_Collisions | |
{ | |
private const float EPSILON = 1e-6f; |
This file contains 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 AutoMapper.QueryableExtensions.Impl; | |
using Godot; | |
using GodotEx; | |
namespace NotNot.GodotNet.animation; | |
/// <summary> | |
/// convert any humanoid animation to root motion, and be able to save to disk. | |
/// </summary> | |
[Tool] |
This file contains 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
/// <summary> | |
/// thread safe event registration and invoking. | |
/// subscriptions are stored as weakRefs so they can be garbage collected. | |
/// </summary> | |
/// <typeparam name="TEventArgs"></typeparam> | |
public class Event<TEventArgs> where TEventArgs : EventArgs | |
{ | |
private List<WeakReference<EventHandler<TEventArgs>>> _storage = new(); | |
/// <summary> |
This file contains 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
//from: https://stackoverflow.com/a/49864522/1115220 re question: https://stackoverflow.com/questions/8165570/https-proxy-server-in-node-js | |
import http = require( 'http' ) | |
const port: number = Number.parseInt( process.env.PORT ) || 9191; | |
import net = require( 'net' ) | |
import url = require( 'url' ) | |
import xlib = require( "xlib" ); | |
This file contains 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
export interface IModuleImport { | |
(authOptions?: IAuthOptions): IGCloud; | |
} | |
export interface IAuthOptions { | |
projectId?: string; | |
keyFilename?: string; | |
} |
This file contains 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
/** | |
WHAT: A very simple example of redux + redux-simple-router using Typescript. | |
WHY: The official example found here: https://github.com/rackt/redux-simple-router/tree/1.0.2/examples/basic has problems: | |
1) it is spread over many files making it very hard to "skim" | |
2) it is organized by function, not by feature. (Example: learning "how to manipulate redux state" is spread over 5 files in 4 folders) | |
3) there are no comments explaining what's going on/why. | |
WHO: by [email protected] |