Skip to content

Instantly share code, notes, and snippets.

View whoisryosuke's full-sized avatar
👾
Going deep with game development

Ryosuke whoisryosuke

👾
Going deep with game development
View GitHub Profile
@whoisryosuke
whoisryosuke / BlueskyFirehoseExample.tsx
Created November 26, 2024 21:38
Bluesky - Firehose Websocket Example for ReactJS
import React, { useEffect, useRef } from "react";
const FireHoseExample = () => {
const firehoseSocket = useRef<WebSocket | null>(null);
useEffect(() => {
firehoseSocket.current = new WebSocket(
"wss://jetstream2.us-east.bsky.network/subscribe?wantedCollections=app.bsky.feed.post"
);
@whoisryosuke
whoisryosuke / render_auto_save.py
Created September 26, 2024 19:10
Blender Addon - Auto Saves render (updated for Blender 4.2 and Eevee Next)
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
@whoisryosuke
whoisryosuke / GpuPrinter.cginc
Created August 12, 2024 18:20 — forked from FreyaHolmer/GpuPrinter.cginc
A unity shader .cginc to draw numbers in the fragment shader - see the first comment below for example usage!
///////////////////////////////////////////////////////////////////////////////
// ABOUT: A unity Shader .cginc to draw numbers in the fragment shader
// AUTHOR: Freya Holmér
// LICENSE: Use for whatever, commercial or otherwise!
// Don't hold me liable for issues though
// But pls credit me if it works super well <3
// LIMITATIONS: There's some precision loss beyond 3 decimal places
// CONTRIBUTORS: yes please! if you know a more precise way to get
// decimal digits then pls lemme know!
// GetDecimalSymbolAt() could use some more love/precision
@whoisryosuke
whoisryosuke / delta-filter-bloom-example.json
Created May 29, 2024 19:51
Delta iOS App Skinning Example - Bloom Filter
{
"name": "Onyx Comic (whoisryosuke)",
"identifier": "com.whoisryosuke.gba.onyxcomic",
"gameTypeIdentifier": "com.rileytestut.delta.game.gba",
"debug": false,
"representations": {
"iphone": {
"edgeToEdge": {
"portrait": {
"assets": {
@whoisryosuke
whoisryosuke / music-notes.ts
Created January 27, 2024 01:34
Typescript - Music Notation types using new template literal feature
export type BaseNote = "C" | "D" | "E" | "F" | "G" | "A" | "B";
export type Octaves = "1" | "2" | "3" | "4" | "5" | "6" | "7";
export type Note = `${BaseNote}${Octaves}`;
@whoisryosuke
whoisryosuke / render-all-frames-and-sleep.js
Created November 9, 2023 09:43
Blender Flamenco - Render Frames and Sleep - Select a series of frames, sleep duration, and batch size -- and it'll render all frames then in batches while sleeping between. Good for chunking renders and letting PC rest between segments in a single job (instead of queuing chunks manually)
// SPDX-License-Identifier: GPL-3.0-or-later
const JOB_TYPE = {
label: "Render All and Sleep",
settings: [
// Settings for artists to determine:
{
key: "frames",
type: "string",
required: true,
@whoisryosuke
whoisryosuke / render-frames-and-sleep.js
Created November 7, 2023 20:10
Blender Flamenco - Render Frames and Sleep - Select a series of frames and a sleep duration and it'll render all frames then sleep after. Good for chunking renders and letting PC rest between segments.
// SPDX-License-Identifier: GPL-3.0-or-later
const JOB_TYPE = {
label: "Render and Sleep",
settings: [
// Settings for artists to determine:
{
key: "frames",
type: "string",
required: true,
@whoisryosuke
whoisryosuke / transparent-egui-window.rs
Created April 24, 2023 19:48
egui / Bevy - Transparent Window styling
fn ui_example_system(mut contexts: EguiContexts) {
// Set window styles
let ctx = contexts.ctx_mut();
let old = ctx.style().visuals.clone();
ctx.set_visuals(egui::Visuals {
window_fill: Color32::TRANSPARENT,
panel_fill: Color32::TRANSPARENT,
window_stroke: egui::Stroke {
color: Color32::TRANSPARENT,
width: 0.0,
@whoisryosuke
whoisryosuke / GPUOptimizationForGameDev.md
Created December 19, 2022 07:32 — forked from silvesthu/GPUOptimizationForGameDev.md
GPU Optimization for GameDev
@whoisryosuke
whoisryosuke / body.css
Created November 12, 2022 09:04
Mastodon Theme - Dark Chakra UI - Based on Mastodon FlatCSS (https://github.com/trwnh/mastomods). Install using Stylus Chrome Extension
/*
* OK, now back to business... the rest of this code applies only to the instance.
*/
/*------------------------------------------------------------------------------
* MISC TWEAKS
*
* Miscellaneous tweaks that are more like extensions of the theme,
* rather than subsets or features. These could ostensibly be their
* own user-styles, and are only bundled in here for convenience.
* Or, they are not supported in all browsers. They may be removed