Skip to content

Instantly share code, notes, and snippets.

@tanakaedu
tanakaedu / cluster-creator-kit-manifest.txt
Created October 21, 2021 02:35
ClusterCreatorKitをmanifest.jsonに加えるためのコード
"scopedRegistries": [
{
"name": "Cluster",
"url": "https://registry.npmjs.com",
"scopes": [
"mu.cluster"
]
}
],
@tanakaedu
tanakaedu / makeusers.php
Created February 13, 2020 14:09
MySQLにユーザーを作成して、そのユーザー専用のデータベースの作成とGRANT設定をするPHPスクリプト。
<?php
define("user", "root");
// TODO: rootpassを実際のrootユーザーのパスワードに変更
define("passwd", "rootpass");
// TODO: 設定したいユーザー名とパスワードを以下に設定
$Users = array(
array('uid'=>'user_01', 'passwd'=>'pwd1'),
array('uid'=>'user_02', 'passwd'=>'pwd2'),
@tanakaedu
tanakaedu / ProTexImageBinderInspector.cs
Created July 24, 2019 06:29
ProTexImageBinder用のエディタースクリプト
using System;
using UnityEditor;
using UnityEditor.SceneManagement;
using UnityEngine;
namespace ProTex
{
[CustomEditor(typeof(ProTexImageBinder))]
public class ProTexImageBinderInspector : UnityEditor.Editor
{
@tanakaedu
tanakaedu / EnemyBehaviour.cs
Created April 1, 2018 14:38
降りる処理のスタブメソッド
public bool MakePlatformFallthrough()
{
print("降りる");
return true;
}
int action = Random.Range(0, 2);
if (action == 1)
{
// ジャンプ
m_MonoBehaviour.SetVerticalMovement(m_MonoBehaviour.jumpPower);
}
@tanakaedu
tanakaedu / EnemyBehaviour.cs
Last active April 1, 2018 13:55
ジャンプ力変数の宣言
public float jumpPower = 8.5f;
@tanakaedu
tanakaedu / EnemyBehaviour.cs
Created April 1, 2018 07:23
ジャンプ力を設定するコード(2D Game Kit)
public void SetVerticalMovement(float newVerticalMovement)
{
m_MoveVector.y = newVerticalMovement;
}
@tanakaedu
tanakaedu / sousa.cs
Created March 22, 2018 12:02
デジタルアーツ東京 体験入学の雛形プログラムです。
/**
* デジタルアーツ東京 体験入学用プログラム
* copyright 2015-2018 YuTanaka@AmuseOne
*/
using UnityEngine;
using System.Collections;
public class sousa : MonoBehaviour {
/** カメラからの距離*/
@tanakaedu
tanakaedu / Form1.cs
Created February 7, 2017 06:11
オブジェクトの実装に備えて、機能を全て削除した状態のForm1
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
@tanakaedu
tanakaedu / Form1.cs
Created February 5, 2017 10:02
オブジェクト指向練習:オブジェクトを使わないベタな実装例
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;