aboutsummaryrefslogblamecommitdiff
path: root/src/Ryujinx.HLE/HOS/Tamper/Conditions/InputMask.cs
blob: 6c72eb5c8ea1de3a8e13e4ef4758e64ad529b204 (plain) (tree)
1
2
3
4
5
6


                                           
                                                







                                                          
                                                   

         
namespace Ryujinx.HLE.HOS.Tamper.Conditions
{
    class InputMask : ICondition
    {
        private readonly long _mask;
        private readonly Parameter<long> _input;

        public InputMask(long mask, Parameter<long> input)
        {
            _mask = mask;
            _input = input;
        }

        public bool Evaluate()
        {
            return (_input.Value & _mask) == _mask;
        }
    }
}