0
|
1 using UnityEngine;
|
|
2 using System.Collections;
|
|
3
|
|
4 // Player Enemy どちらもここで制御する
|
|
5 public class CharactorManager : MonoBehaviour {
|
|
6
|
|
7 // Use this for initialization
|
|
8 void Start () {
|
|
9
|
|
10 }
|
|
11
|
|
12 // Update is called once per frame
|
|
13 void Update () {
|
|
14 // Playerの制御
|
3
|
15 PlayerController();
|
|
16 }
|
|
17
|
|
18 public void PlayerController () {
|
4
|
19 Player.Instance.Move (Input.GetKey(KeyCode.P));
|
0
|
20 Player.Instance.EyeMove (new Vector3 (InputManager.Instance.InputX, InputManager.Instance.InputZ, 0));
|
3
|
21 if (Input.GetKeyDown (KeyCode.Space)) {
|
|
22 Player.Instance.GetItem ();
|
|
23 }
|
|
24
|
|
25 if (Input.GetMouseButtonDown(1)) {
|
|
26 Player.Instance.SetItem ();
|
|
27 }
|
0
|
28 }
|
|
29 }
|