Skip to content

Instantly share code, notes, and snippets.

View halby24's full-sized avatar
🐣
チーヨ

HALBY halby24

🐣
チーヨ
View GitHub Profile
@halby24
halby24 / .clang-format
Last active February 16, 2024 08:59
.clang-format
BasedOnStyle: Google
PointerAlignment: Left
IndentWidth: 4
# ColumnLimit: 200
BinPackArguments: true
BinPackParameters: true
AlignAfterOpenBracket: Align
AllowShortBlocksOnASingleLine: Always
AllowShortCaseLabelsOnASingleLine: true
AllowShortIfStatementsOnASingleLine: true
@halby24
halby24 / LookAtIKInEditMode.cs
Created July 6, 2019 03:28
Unityのエディタ上で視線IKが動かせるスクリプトだよ
using UnityEngine;
[ExecuteInEditMode]
public class LookAtIKInEditMode : MonoBehaviour
{
[SerializeField] private bool active;
[SerializeField] private Transform target;
[SerializeField, Range(0f, 1f)] private float lookAt;
[SerializeField, Range(0f, 1f)] private float body;
[SerializeField, Range(0f, 1f)] private float head;
@halby24
halby24 / brush_quickset.py
Last active April 12, 2023 15:01
Blenderのブラシサイズを右クリックで変えるやつ (3.5対応)
# ***** BEGIN GPL LICENSE BLOCK *****
#
# Copyright © 2019 Jean Ayer(vrav)
#
# 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 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
@halby24
halby24 / .gitattributes
Last active January 15, 2023 08:08 — forked from nemotoo/.gitattributes
.gitattributes for Unity3D with git-lfs
## Unity ##
*.cs diff=csharp text
*.cginc text
*.shader text
*.hlsl text
*.glsl text
*.mat merge=unityyamlmerge eol=lf
*.anim merge=unityyamlmerge eol=lf
@halby24
halby24 / hack.hlsl
Last active October 21, 2022 04:24
視界ハック用頂点シェーダーメモ
v2f vert (appdata v)
{
v2f o;
o.uv = v.uv;
o.vertex = float4(v.uv.x * 2 - 1, 1 - v.uv.y * 2, 0, 1);
return o;
}
@halby24
halby24 / DBController.cs
Last active November 13, 2020 11:39
ダイナミックボーン 一括制御するやつ
using System.Collections.Generic;
using System.Linq;
using UnityEngine;
public class DBController : MonoBehaviour
{
public Transform[] Bones;
[Range(0f, 1f)] public float Damping, Elasticity, Stiffness, Inert;
public float Radius;
public AnimationCurve DanpingDistrib, ElasticityDistrib, StiffnessDistrib, InertDistrib, RadiusDistrib;
@halby24
halby24 / MetallicSmoothnessTextureGenerator.cs
Last active February 7, 2020 11:49
Smoothness TextureからUnity Standard Shader用MetallicSmoothnessテクスチャを作ります(複数枚対応)(Metallicは固定値)
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text.RegularExpressions;
using UnityEditor;
using UnityEngine;
public class MetallicSmoothnessTextureGenerator : EditorWindow
{
const num = 0;
const str = 'あ';
const bool = true;