예제 #1
0
        public void update(IDoor obj)
        {
            if (obj.getControllerType() != DoorControllerType.Standalone)
                return;

            if(CrossPlatformInputManager.GetButtonDown("Use")){

                switch(obj.getState()){
                    case DoorState.Closed:
                        obj.openDoor();
                        break;
                    case DoorState.Locked:

                        break;
                    case DoorState.Opened:
                        obj.closeDoor();
                        break;
                }

            }
        }