Skip to content

Instantly share code, notes, and snippets.

View drewcassidy's full-sized avatar

Andrew Cassidy drewcassidy

View GitHub Profile
@drewcassidy
drewcassidy / BumpedSpecularSootNoKSP.shader
Created May 21, 2023 20:09
Why does this work in Unity 2019 but not 2017?
Shader "KSP/Bumped Specular Soot"
{
Properties
{
[Header(Texture Maps)]
_MainTex("_MainTex (RGB spec(A))", 2D) = "gray" {}
_Soot1("_Soot1", 2D) = "gray" {}
_Soot2("_Soot2", 2D) = "gray" {}
_Alpha1 ("_Alpha1", Range (0, 1)) = 0
_Alpha2 ("_Alpha2", Range (0, 1)) = 0
[LOG 15:58:02.620] Collision ignored between 0 and 0: False
[LOG 15:58:02.620] Collision ignored between 1 and 0: False
[LOG 15:58:02.621] Collision ignored between 1 and 1: False
[LOG 15:58:02.621] Collision ignored between 2 and 0: False
[LOG 15:58:02.621] Collision ignored between 2 and 1: False
[LOG 15:58:02.621] Collision ignored between 2 and 2: False
[LOG 15:58:02.621] Collision ignored between 3 and 0: False
[LOG 15:58:02.622] Collision ignored between 3 and 1: False
[LOG 15:58:02.622] Collision ignored between 3 and 2: False
[LOG 15:58:02.622] Collision ignored between 3 and 3: False
Process: Mastonaut [59090]
Path: /Applications/Mastonaut.app/Contents/MacOS/Mastonaut
Identifier: app.mastonaut.mac
Version: 1.3.3 (116)
App Item ID: 1450757574
App External ID: 835410332
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: Mastonaut [59090]
User ID: 501
<Shutesie> How fast would I have to spin a spaghetti noddle (indestructible one) above my head in order to hit all the rain falling towards me
<Cineboxandrew> hmm. rain falls at 10m/s and has a max diameter of 4mm, spaghetti is nominally 30cm long and 2mm thick, which means that the end of the noodle needs to pass through a given point at least (4mm+2mm)/10m/s= 0.6ms.
so you need to spin the noodle at at least 1.66khz
<CobaltWolf> what the fuck
<Katten> Hmm, as a skydiver I fall 50m/s. I have the same density as water, but a droplet is an optimized aerodynamic shape. I would guess it would have abotu the same or faster speed as me?
<Cineboxandrew> for a tip speed of 3.14km/s, or about mach 9
<Katten> Is that gonna have any ramifications for the air in the room? :smiley:
<Shutesie> What kind of energy is stored in a piece of spaghetti going mach 9
<Cineboxandrew> yes you and any rain nearby will be instantly vaporized. uh, for some reason I cant find the mass of a spaghetti noodle. brb getting a scale. one co
qrc:/qml/AccountSummary.qml:9:5: QML RowLayout: Detected anchors on an item that is managed by a layout. This is undefined behavior; use Layout.alignment instead.
qrc:/qml/AccountSummary.qml:60:5: QML RowLayout: Detected anchors on an item that is managed by a layout. This is undefined behavior; use Layout.alignment instead.
qrc:/qml/AccountSummary.qml:9:5: QML RowLayout: Detected anchors on an item that is managed by a layout. This is undefined behavior; use Layout.alignment instead.
qrc:/qml/AccountSummary.qml:60:5: QML RowLayout: Detected anchors on an item that is managed by a layout. This is undefined behavior; use Layout.alignment instead.
qrc:/qml/MessageView.qml:302:21: QML RowLayout: Detected anchors on an item that is managed by a layout. This is undefined behavior; use Layout.alignment instead.
qrc:/qml/MessageView.qml:281:17: QML RowLayout: Detected anchors on an item that is managed by a layout. This is undefined behavior; use Layout.alignment instead.
qrc:/qml/MessageView.qml:212:17: QML Label:
Error registering app: Post cybre.space/api/v1/apps: unsupported protocol scheme ""
@drewcassidy
drewcassidy / NoDXT.cs
Last active March 28, 2019 22:46
Stops Unity from compressing textures on import (must reset any existing texture imports to take effect, or group select and set compression to "none"). Drag this file into Assets/Plugins/Editor (make the folders if they don't exist already)
using UnityEditor;
using UnityEngine;
public class NoDXT : AssetPostprocessor
{
void OnPreprocessTexture() {
var importer = (TextureImporter)assetImporter;
importer.textureCompression = TextureImporterCompression.Uncompressed;
}
}
@drewcassidy
drewcassidy / convertdds.sh
Last active June 15, 2019 03:28
Convert all input to DDS and replace using nvcompress or Crunch
#!/bin/bash
mkdir -p /tmp/dds > /dev/null
tool="nvcompress"
for file in "$@"
do
echo "$file"
dirname=$(dirname "$file")
basename=$(basename "$file")
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using UnityEditor;
using UnityEngine;
namespace MeshTools
{
public class MeshPostProcessor : AssetPostprocessor
{
@drewcassidy
drewcassidy / Server Arch Installation.md
Last active October 21, 2018 06:25
Steps taken to install Arch on a machine with BIOS using LVM and GRUB

Server Arch Installation

many steps taken from this tutorial

Connect to wifi

wifi-menu

(way easier than using wpa_supplicant)

Setup drive