メモ:グリースペンシル
①レンダー設定 Eevee ブルーム <チェック カラーマネージメント: フィルミック→標準 ・ワールドプロパティ 色を白
・グリースペンシルオブジェクト ー>ブランク
・タイムライン ー>0にセット
プリふぁれんす:スペース以外に
①レイヤー設定 オブジェクトデータプロパティ ーレイヤ ライトの使用<チェックを外す
②マテリアル マテリアルプロパティ サーフェス」ストローク<チェック フィル ベースカラー ③ドローモード ドロー ブラシ:ラフ:太さ:強さ ④ストローク ランダム化 チェックをon/off 味がでる ⑤ストロークの基準の設定 上のアイコン 3Dカーソル
ビューポートオーバーレイ
メモ「Power Query M 式言語」について分析
文字列型→数値型 Number.FromText("4")
数値型→文字列型 Number.ToText(number as number) as text
Text.From(3) Text.From(value as any) as text
文字列の長さ Text.Length("Hello World")
文字列の置換 Text.Replace("abcdefga", "a", "x")
文字列のトリム Text.Trim(" a b c d ")
文字列の大文字・小文字 Text.Lower("AbCd") Text.Upper("aBcD")
文字列型→日付型 Date.FromText("2010-12-31")
日付型→文字列型 Date.ToText(#date(2010, 12, 31))
数値を日付型にする Date.From(#datetime(1899, 12, 30, 06, 45, 12))
すでにゲーム開発休憩中
ゲーム開発を休憩して、Blenderを勉強中。。。
C#の知らない機能。デリゲート・ラムダ式(アロー関数)<まったく分かっていないのでメモ書き
まったく分かっていないがメモで書きます
見たこともない、記述式について勉強中
x => a = a + 2
のような書き方
検索結果以下のものに関係あるらしい。。。ところまではわかった
続きはまたあとで。
ラムダ式=?=アロー関数
デリゲート
DOTweenでシーケンス(順番制御)(学習中)
サンプル
txt1はカウントアップ
oj1は、スケールを小さくして、戻す。
OnStartで初めて
.Appendで処理する順番を追記する。
public Transform ob1; public Text txt1; void Start() { DG.Tweening.Sequence sequence = DOTween.Sequence() .OnStart(() => { txt1.DOCounter(0, 9999, 5, true); }) .Append( ob1.gameObject.GetComponent<RectTransform>().DOScale(new Vector3(0f, 1f, 0f), 2f) ) .Append( ob1.gameObject.GetComponent<RectTransform>().DOScale(new Vector3(1f, 1f, 0f), 2f) ); sequence.Play();
DoTweenで数字をアップ・文字を記載(学習中)
今日はテキストの操作
カウントアップ
public Text txt1; IEnumerator Start() { txt1.DOCounter(0, 1000, 10f, true); }
文字を入れていく
public Text txt1; IEnumerator Start() { txt2.DOText("DOTween", 4f); }
文字を書き換える
public Text txt1; IEnumerator Start() { txt2.DOText("こどもちゃれんじ NEXT", 13, scrambleMode: ScrambleMode.Custom, scrambleChars: "しまじろう").SetEase(Ease.Linear); }
DOTweenでさらに色々と遊ぶ(学習中)
例:ジャンプして、スケールを変更
- DOLocalJumpジャンプ<かわいい
- DOScaleスケール変更<横に伸びる
public Transform ob1; IEnumerator Start() { Debug.Log("DOLocalJump"); ob1.gameObject.GetComponent<RectTransform>().localPosition = Vector3.zero; ob1.gameObject.GetComponent<RectTransform>().DOLocalJump(new Vector3(500f, 0f, 0f), 300f, 10, 5f); yield return new WaitForSeconds(3.0f); Debug.Log("DOScale"); ob1.gameObject.GetComponent<RectTransform>().localPosition = Vector3.zero; ob1.gameObject.GetComponent<RectTransform>().DOScale(new Vector3(500f, 0f, 0f), 5f); yield return new WaitForSeconds(3.0f); }
例2
- DORotate=90度回転
- DOPunchScale=サイズを指定して、伸びたり、縮んだり
- DOShakeScale=ランダムな変化?<こっちの方が面白い
※WaitForSecondsを入れて、処理中に次の処理を実行しないようにしないと、並列に処理されてしまう
※並列な割り込みのせいか、DOPunchScaleとDOShakeScaleをやったら、1.5倍のまま戻らなくなった<バグでは?
Debug.Log("DORotate"); ob1.gameObject.GetComponent<RectTransform>().localPosition = Vector3.zero; ob1.gameObject.GetComponent<RectTransform>().DORotate(new Vector3(0f, 0f, 90f), 5f); yield return new WaitForSeconds(3.0f); Debug.Log("DOPunchScale"); ob1.gameObject.GetComponent<RectTransform>().localPosition = Vector3.zero; ob1.gameObject.GetComponent<RectTransform>().DOPunchScale(new Vector3(1.5f, 1.5f), 5f); yield return new WaitForSeconds(3.0f); Debug.Log("DOShakeScale"); ob1.gameObject.GetComponent<RectTransform>().localPosition = Vector3.zero; ob1.gameObject.GetComponent<RectTransform>().DOShakeScale( 5f); yield return new WaitForSeconds(3.0f);