Esempio n. 1
0
        public static void LogPlate()
        {
            ClientPlate plate = Object.FindObjectOfType <ClientPlate>();

            Logger.Log($"Plate location: {Logger.FormatPosition(plate.transform.position)}");

            Logger.Log("Before method call");

            Component component = ComponentUtil.GetPlateLocationComponent(plate);

            Logger.Log("After method call");

            Logger.Log($"Component name: {component.name}");
        }
Esempio n. 2
0
        public PlateHoldingAction(PlayerControls player)
        {
            this.player = player;

            plate = ComponentUtil.GetClosestComponent <ClientPlate>(PlayerUtil.GetChefPosition(player));
            state = 0;

            if (ComponentUtil.IsPlateOnComponent(plate))
            {
                currentAction = new PathFindAction(player, ComponentUtil.GetPlateLocationComponent(plate));
            }
            else
            {
                currentAction = new PathFindAction(player, plate);
            }
        }
Esempio n. 3
0
        public PlateHoldingAction(PlayerControls player, ClientPlate plate)
        {
            this.player = player;
            this.plate  = plate;
            state       = 0;

            Logger.Log("PlateHoldingAction instantiated");

            if (ComponentUtil.IsPlateOnComponent(plate))
            {
                currentAction = new PathFindAction(player, ComponentUtil.GetPlateLocationComponent(plate));
                Logger.Log("Pathfinding component?");
            }
            else
            {
                currentAction = new PathFindAction(player, plate);
                Logger.Log("Pathfinding plate?");
            }
        }