Stairs.GetDestinationFloor C# (CSharp) Метод

GetDestinationFloor() публичный Метод

public GetDestinationFloor ( ) : int
Результат int
    public int GetDestinationFloor()
    {
        // if the destination is above us, we go to the floor above, and vice versa
        return (destination.transform.position.y > transform.position.y) ? (floor + 1) : (floor - 1);
    }