Entries from 2015-04-20 to 1 day

【Unity エラー】CS1061 存在しないクラスやメソッドにアクセス

CS1061:存在しないメソッド、クラス、メンバーにアクセスしようとしたときに生じる。 書き間違えの可能性あり! エラー内容 error CS1061: Type `UnityEngine.GameObject' does not contain a definition for `Image' and no extension method `Image' of t…

UIのCamera

「UI Scale Mode」を「Scale With Screen Size」にすることによって、UIが画面の大きさ、に依存しない。定位置に表示されるようになる。[uGUI][Unity3d]Screen Space – Camera現状わかった事Memoblog.psychologames.com

【Unity】経過時間とカウントダウン

経過時間とカウントダウン using System; using UnityEngine; using System.Collections; public class GameManager : MonoBehaviour { private DateTime _startTime; private readonly int _limitTime = 10; void Start () { this._startTime = DateTime.No…

【Unity】Debug.Log() : 色付きで出力

Debug.Log("<color=green>setting</color> /boss id = "+ id+ "boss type = "+type ); Debug.Log・print 相違点については、機能的な違いはないが...。 Debug.Log(); or print();? What's the difference and when to use what? - Unity Answers

Rigidbody2Dで spriteを固定する。

RigidbodyのFixedAngleで固定する。

アニメーションクリップの変更

アニメーション 使い方、コンポーネントを獲得する。 private bool _isJumping; private bool _isLeftMove; private bool _isStop; private Animator _animator; void Start (){ // コンポーネントを確保する。 this._animator = this.GetComponent<Animator>(); this.</animator>…

C#の型「var」

varは使える。でも、動作が遅くなるのかな。連載! とことん C#: 第 10 回 型を書かなくても強い型付け! (var とジェネリック) in C#code.msdn.microsoft.com

アニメーションを作るとき

アニメーションを作るとき、オブジェクトを選択してアニメーションウィンドウから設定する。「Add Curve」→「create new clip」を選択してアニメーションクリップを作る。アニメーションクリップを複数作って、animatorで関係を整理する。 デフォルトは、静…