Skip to content

Instantly share code, notes, and snippets.

@shinyquagsire23
shinyquagsire23 / DrawableWrapper.swift
Last active June 12, 2025 09:04
DrawableQueue/LowLevelTexture wrapper class for visionOS 2.0 beta
// Open license, I don't care what you do with this.
// idk how many of these are needed
import SwiftUI
import RealityKit
import Metal
import MetalKit
import Spatial
class DrawableWrapper {
// Caishen SDK Integration Example
// GitHub Repository: https://github.com/CaishenTech/caishen-sdk
//
// This example demonstrates:
// 1. SDK initialization with project key
// 2. Wallet creation for ETHEREUM
// 3. Crypto swap functionality
// 4. Balance checking and token operations
import { CaishenSDK, createAgentTools } from "@caishen/sdk";
@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active June 12, 2025 09:02
Complete Recent Discord Quest

Complete Recent Discord Quest

Note

This does not works in browser for non-video, non-activity quests! For stream/play quests use the desktop app!

Note

When doing stream quests, you need at least 1 other account in the vc!

How to use this script:

  1. Accept a quest under Discover -> Quests
@ingoogni
ingoogni / _iteroscillator.nim
Created June 11, 2025 07:30
Nim closure iterators for audio synthesis.
import math, sugar
import iterit
const
SampleRate {.intdefine.} = 44100
SRate* = SampleRate.float32
proc linOsc*[Tf, Tp: float or iterator:float](
@ingoogni
ingoogni / _lutsynth.nim
Last active June 12, 2025 09:02
Quarter sine wave look up table synth with various oscillators in Nim
import math
const
SampleRate {.intdefine.} = 44100
SRate* = SampleRate.float
LutSize = 256 # Quarter sine wave
Lut = static:
var arr: array[LutSize, float]
for i in 0..<LutSize:
let angle = (i.float / LutSize.float) * (PI / 2.0)
@ingoogni
ingoogni / _modal synthesis
Last active June 12, 2025 09:02
Nim Modal synthesis
Modal synthesis in Nim with a pool for modes, so one excite fast and they still properly decay. Cheesy bell, gong & mallet modes.
@Koshimizu-Takehito
Koshimizu-Takehito / MazeGenerator.swift
Last active June 12, 2025 09:01
迷路生成ロジック
import Combine
import Foundation
// MARK: - MazeGenerator (Model)
/// An actor that generates a maze using a depth-first search (DFS) based approach.
/// 深さ優先探索 (DFS) ベースのアルゴリズムを用いて迷路を生成する。
///
/// This actor provides an async stream of snapshots (`MazeGenerator.Snapshot`) so that observers
/// can track the maze's state and generation progress in real time.
@doichev-kostia
doichev-kostia / get_session.go
Created June 10, 2025 08:38
Go script for getting the Twitter/X oauth token for nitter
package main
import (
"bufio"
"bytes"
"context"
"encoding/json"
"fmt"
"io"
"log/slog"
/*
* Copyright (C) 2006 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software