コード例 #1
0
 /// <summary>
 /// Logical construction of player entity. No visualization
 /// </summary>
 /// <param name="newCoordinate">Array coordinate of cell to swawn on</param>
 /// <param name="owner">LabyrinthManager, where player is</param>
 public Player(LabyrinthManager owner, Coordinate currentCoordinate) : base(owner, currentCoordinate)
 {
     coinsCollected   = 0;
     speed            = 4;
     currentDirection = Direction.INVALID;
     newDirection     = Direction.INVALID;
     Spawn();
 }
コード例 #2
0
    // Start is called before the first frame update
    void Start()
    {
        playerController     = GameObject.Find("Player").GetComponent <PlayerController>();
        lookAtMouse          = GameObject.Find("Player").GetComponent <LookAtMouse>();
        labyrinthManager     = GameObject.Find("LabyrinthManager").GetComponent <LabyrinthManager>();
        player               = GameObject.Find("Player");
        playerRb             = GameObject.Find("Player").GetComponent <Rigidbody>();
        mainCamera           = GameObject.Find("MainCamera");
        mainLight            = GameObject.Find("MainLight");
        smoothCameraTurning  = mainCamera.GetComponent <SmoothCameraTurning>();
        mainLightPointObject = GameObject.Find("MainLightPoint");
        mainLightPointLight  = mainLightPointObject.GetComponent <Light>();
        soundManager         = GameObject.Find("SoundManager").GetComponent <SoundManager>();

        lightIntensity = 0.5f;
    }
コード例 #3
0
ファイル: PlayerController.cs プロジェクト: Firyfly/PcLive
    void Start()
    {
        soundManager                 = GameObject.Find("SoundManager").GetComponent <SoundManager>();
        cubeManager                  = GameObject.Find("CubeManager").GetComponent <CubeManager>();
        labyrinthManager             = GameObject.Find("LabyrinthManager").GetComponent <LabyrinthManager>();
        followPlayerZAxis            = GameObject.Find("MainCamera").GetComponent <FollowPlayerZAxis>();
        cpuUpgradeMaschine           = GameObject.Find("CPUUpgradeMaschine").GetComponent <CPUUpgradeMaschine>();
        energyUpgradeMaschine        = GameObject.Find("EnergyUpgradeMaschine").GetComponent <EnergyUpgradeMaschine>();
        coolingUpgradeMaschine       = GameObject.Find("CoolingUpgradeMaschine").GetComponent <CoolingUpgradeMaschine>();
        playerUpgradeMaschine        = GameObject.Find("PlayerUpgradeMaschine").GetComponent <PlayerUpgradeMaschine>();
        qualityOfLifeUpgradeMaschine = GameObject.Find("QualityOfLifeUpgradeMaschine").GetComponent <QualityOfLifeUpgradeMaschine>();

        moveUp    = new Vector3(0, 1, 0);
        moveDown  = new Vector3(0, -1, 0);
        moveLeft  = new Vector3(-1, 0, 0);
        moveRight = new Vector3(1, 0, 0);

        oldPos = this.gameObject.transform.position;
    }
コード例 #4
0
 public Mummy(LabyrinthManager owner, Coordinate currentCoordinate) : base(owner, currentCoordinate)
 {
     currentDirection = Direction.North;
     speed            = 0.6f;
     Spawn();
 }
コード例 #5
0
        public LabyrinthElement(string labFile)
        {
            _labManager = new LabyrinthManager(labFile);

            SetupContext();
        }
コード例 #6
0
 protected Unit(LabyrinthManager owner, Coordinate currentCoordinate)
 {
     this.owner             = owner;
     this.currentCoordinate = currentCoordinate;
 }
コード例 #7
0
 public Enemy(LabyrinthManager owner, Coordinate currentCoordinate) : base(owner, currentCoordinate)
 {
     AIController    = new AINavigationController(this);
     speedMultiplier = 1f;
 }
コード例 #8
0
 public Coin(LabyrinthManager owner, Coordinate currentCoordinate) : base(owner, currentCoordinate)
 {
     Spawn();
 }
コード例 #9
0
 public PositiveButtonListner(LabyrinthManager d) : base("android.content.DialogInterface$OnClickListener")
 {
 }
コード例 #10
0
 protected StaticUnit(LabyrinthManager owner, Coordinate currentCoordinate) : base(owner, currentCoordinate)
 {
 }