This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class iTweenMethod : MonoBehaviour | |
{ | |
void Start() | |
{ | |
// パターン2 Addで追加していき、最後に適用することもできる。 | |
Hashtable moveHash = new Hashtable(); | |
moveHash.Add("x", 3f); | |
moveHash.Add("delay", 1f); | |
iTween.MoveTo(gameObject, moveHash); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class iTweenMethod : MonoBehaviour | |
{ | |
void Start() | |
{ | |
// positionを指定して移動 | |
iTween.MoveTo(gameObject, iTween.Hash("position", new Vector3(3f, 2f, -3f), "delay", 1f)); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class iTweenMethod : MonoBehaviour | |
{ | |
void Start() | |
{ | |
// アニメーションに緩急をつけるeasetype | |
iTween.MoveTo(gameObject, iTween.Hash("x", 2f, "easetype", "easeInOutElastic", "delay", 1f)); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class iTweenMethod : MonoBehaviour | |
{ | |
void Start() | |
{ | |
// 相対的に動くMoveBy | |
iTween.MoveBy(gameObject, iTween.Hash("x", 2f, "delay", 1f)); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class iTweenMethod : MonoBehaviour | |
{ | |
void Start() | |
{ | |
Hashtable hash = new Hashtable(); | |
hash.Add("x", 2f); | |
hash.Add("delay", 1f); | |
hash.Add("oncompletetarget", gameObject); // メソッドがあるオブジェクトを指定 | |
hash.Add("oncomplete", "EndAnimation"); // 実行するタイミング、実行するメソッド名 | |
iTween.MoveTo(gameObject, hash); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class iTweenMethod : MonoBehaviour | |
{ | |
void Start() | |
{ | |
Hashtable hash = new Hashtable(); | |
hash.Add("x", 2f); | |
hash.Add("loopType", "loop"); | |
iTween.MoveTo(gameObject, hash); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class iTweenMethod : MonoBehaviour | |
{ | |
void Start() | |
{ | |
Hashtable hash = new Hashtable(); | |
hash.Add("x", 2f); | |
hash.Add("loopType", "pingPong"); | |
iTween.MoveTo(gameObject, hash); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class iTweenMethod : MonoBehaviour | |
{ | |
void Start() | |
{ | |
Hashtable hash = new Hashtable(); | |
Vector3[] _path = new Vector3[3]; | |
_path[0] = new Vector3(2f, 1f, -3f); | |
_path[1] = new Vector3(2f, 4f, -3f); | |
_path[2] = new Vector3(0f, 2f, -3f); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class PostEffectController : MonoBehaviour { | |
// 「using UnityEngine.PostProcessing」の追加を忘れずに | |
void Start () { | |
var behaviour = GetComponent<PostProcessingBehaviour>(); | |
var Settings = behaviour.profile.bloom.settings; | |
Settings.bloom.intensity = 10f; | |
behaviour.profile.bloom.settings = Settings; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public float intensity; | |
PostProcessingBehaviour behaviour; | |
BloomModel.Settings bloomSettings; | |
void Start () { | |
behaviour = GetComponent<PostProcessingBehaviour>(); | |
} |