Ejemplo n.º 1
0
        public bool DeleteBeacon(int id)
        {
            var controller      = new BeaconController();
            var buddyController = new BuddyController();

            buddyController.DeleteBuddiesByBeacon(id);
            return(controller.DeleteBeacon(id));
        }
Ejemplo n.º 2
0
    private void activateBuddy()
    {
        if (buddyReference == null)
        {
            buddyReference = Instantiate(player, player.transform.position + (new Vector3(0, 0, 50)), Quaternion.identity);
            buddyReference.transform.localScale = new Vector3(0.3f, 0.3f, 0.3f);
            Destroy(buddyReference.GetComponent <PlayerController>());
            Destroy(buddyReference.GetComponent <GestureInputController>());
            BuddyController buddyController = buddyReference.AddComponent <BuddyController>();

            ShotController shotController = buddyReference.GetComponent <ShotController>();
            buddyController.shotController = shotController;
            //shotController.shot.transform.localScale = new Vector3(0.3f, 0.3f, 0.3f);

            buddyController.GetComponent <DestroyController>().health = ITEM_BUDDY_HEALTH;

            OrbitantMovement orbitantMovement = buddyReference.AddComponent <OrbitantMovement>();
            orbitantMovement.center            = player.transform;
            orbitantMovement.destroyController = buddyReference.GetComponent <DestroyController>();
        }
    }
Ejemplo n.º 3
0
        public bool EditBuddy(int id, int?status, int?drinks)
        {
            var controller = new BuddyController();

            return(controller.PutBuddy(id, status, drinks));
        }
Ejemplo n.º 4
0
        public bool SaveBuddy(Buddy buddy)
        {
            var controller = new BuddyController();

            return(controller.PostBuddy(buddy));
        }
Ejemplo n.º 5
0
        public IEnumerable <BuddyDTO> GetBuddiesByBeacon(int id)
        {
            var controller = new BuddyController();

            return(controller.GetBuddiesByBeacon(id));
        }