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
#pragma strict | |
// 生成したいPrefab | |
var Prefab : GameObject; | |
// クリックした位置座標 | |
private var clickPosition : Vector3; | |
// スクリーンの座標をワールド座標に変換したクリックした位置座標 | |
private var screenToWorldPointClickPosition : Vector3; | |
private var collition2d : Collider2D; |
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
using UnityEngine; | |
using System.Collections; | |
public class 3DCharaControlScript : MonoBehaviour { | |
public Vector3 SPEED = new Vector3(0.05f, 0.05f, 0.05f); | |
// Use this for initialization | |
void Start () { | |
} | |
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
using UnityEngine; | |
using System.Collections; | |
public class RigidBody3DObjectControlScript : MonoBehaviour { | |
private bool isRotateLeft = false; | |
private bool isRotateRight = false; | |
private bool isForward = false; | |
private bool isBack = false; | |
// Use this for initialization | |
void Start () { |
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
#pragma strict | |
// 前輪 | |
var WheelFrontRight : WheelCollider; | |
var WheelFrontLeft : WheelCollider; | |
// 後輪 | |
var WheelRearRight : WheelCollider; | |
var WheelRearLeft : WheelCollider; | |
// 速度 |
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
#pragma strict | |
var clip : AnimationClip; | |
function Start () { | |
animation.AddClip(clip, clip.name); | |
animation.Play(clip.name); | |
} | |
function Update () { |
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
using UnityEngine; | |
using System.Collections; | |
public class LifeScript : MonoBehaviour { | |
public int life = 3; | |
public GUISkin skin; | |
public GUIContent contents; | |
// Use this for initialization |
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
using UnityEngine; | |
using System.Collections; | |
/// <summary> | |
/// Lifeを生成し管理するクラス | |
/// </summary> | |
public class LifeManager : MonoBehaviour { | |
/// <summary> | |
/// 現在のLife数 | |
/// </summary> |
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
using UnityEngine; | |
using System.Collections; | |
public class InputForm : MonoBehaviour { | |
private string text = ""; | |
public GameObject targetGUIText; | |
private Rect rectTextField; | |
private float textFieldWidth = 100; | |
private float textFieldHeight = 30; |
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
using UnityEngine; | |
using System.Collections; | |
public class CreateNewAnimationClipScript : MonoBehaviour { | |
public Vector3 addCurrentPosition; | |
void Start() { | |
CreateMoveAnimation(gameObject.transform.position, addCurrentPosition); | |
} | |
void CreateMoveAnimation(Vector3 currentPosition, Vector3 addCurrentPosition){ |