Skip to content

Instantly share code, notes, and snippets.

@neuneu9
neuneu9 / MecanimCheckPanel.cs
Created Nov 5, 2020
【Unity】Animatorのステートを自動取得してモーションを確認できるUIパネル(Editor only)
View MecanimCheckPanel.cs
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
#if UNITY_EDITOR
using UnityEditor.Animations;
#endif
/// <summary>
/// Mecanimモーション確認用のUIパネル
/// </summary>
@kasari
kasari / Undersea_volumetric_for_twigl_geekerMRT.frag
Last active Aug 8, 2020
純粋なVolumetricが重すぎて敗北したのでポスプロで実装したバージョン(Twigl の geeker(MRT)で動作します)
View Undersea_volumetric_for_twigl_geekerMRT.frag
// https://www.shadertoy.com/view/4sfGzS
float hash(vec3 p) // replace this by something better
{
p = fract( p*0.3183099+.1 );
p *= 17.0;
return fract( p.x*p.y*p.z*(p.x+p.y+p.z) );
}
float noise( in vec3 x )
{
View microbit-receive_analog_pin.hex
// 送信側
radio.setGroup(1)
input.onButtonPressed(Button.A, () => {
radio.sendString("A")
})
input.onButtonPressed(Button.B, () => {
radio.sendString("B")
})
input.onButtonPressed(Button.AB, () => {
radio.sendString("AB")
@JohannesMP
JohannesMP / LICENSE
Last active Jul 25, 2021
[Unity3D] A Reliable, user-friendly way to reference SceneAssets by script.
View LICENSE
/*******************************************************************************
* Don't Be a Jerk: The Open Source Software License.
* Adapted from: https://github.com/evantahler/Dont-be-a-Jerk
*******************************************************************************
* _I_ am the software author - JohannesMP on Github.
* _You_ are the user of this software. You might be a _we_, and that's OK!
*
* This is free, open source software. I will never charge you to use,
* license, or obtain this software. Doing so would make me a jerk.
*
@Flafla2
Flafla2 / Perlin_Tiled.cs
Last active Jul 17, 2021
A slightly modified implementation of Ken Perlin's improved noise that allows for tiling the noise arbitrarily.
View Perlin_Tiled.cs
public class Perlin {
public int repeat;
public Perlin(int repeat = -1) {
this.repeat = repeat;
}
public double OctavePerlin(double x, double y, double z, int octaves, double persistence) {
double total = 0;
@katsuhide
katsuhide / FileManagerTest.m
Created Jun 16, 2013
FileManager(ファイル操作)周り
View FileManagerTest.m
// ファイルマネージャを作成
NSFileManager *fileManager = [NSFileManager defaultManager];
// ファイルが存在するか?
if ([fileManager fileExistsAtPath:filePath]) { // yes
NSLog(@"%@は既に存在しています", filePath);
} else {
NSLog(@"%@は存在していません", filePath);
}