mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2026-04-21 14:11:59 +00:00
hle: fix: TargetInvocationException when initializing IParentalControlService
Some checks are pending
Canary release job / Create tag (push) Waiting to run
Canary release job / Release for linux-arm64 (push) Waiting to run
Canary release job / Release for linux-x64 (push) Waiting to run
Canary release job / Release for win-arm64 (push) Waiting to run
Canary release job / Release for win-x64 (push) Waiting to run
Canary release job / Release MacOS universal (push) Waiting to run
Some checks are pending
Canary release job / Create tag (push) Waiting to run
Canary release job / Release for linux-arm64 (push) Waiting to run
Canary release job / Release for linux-x64 (push) Waiting to run
Canary release job / Release for win-arm64 (push) Waiting to run
Canary release job / Release for win-x64 (push) Waiting to run
Canary release job / Release MacOS universal (push) Waiting to run
The original implementation was a little overengineered (and didn't work). I suppose the games I tested simply didn't init the service.
This commit is contained in:
parent
1d4928e859
commit
e1c0b3acab
1 changed files with 3 additions and 5 deletions
|
|
@ -56,15 +56,13 @@ namespace Ryujinx.HLE.HOS.Services.Pctl.ParentalControlServiceFactory
|
||||||
|
|
||||||
// TODO: Call nn::arp::GetApplicationControlProperty here when implemented, if it return ResultCode.Success we assign fields.
|
// TODO: Call nn::arp::GetApplicationControlProperty here when implemented, if it return ResultCode.Success we assign fields.
|
||||||
|
|
||||||
int[] tempRatingAge = new int[32];
|
_ratingAge = new int[context.Device.Processes.ActiveApplication.ApplicationControlProperties.RatingAge.Length];
|
||||||
|
|
||||||
for (int i = 0; i < 32; i++)
|
for (int i = 0; i < _ratingAge.Length; i++)
|
||||||
{
|
{
|
||||||
tempRatingAge[i] = Convert.ToInt32(context.Device.Processes.ActiveApplication.ApplicationControlProperties.RatingAge[i]);
|
_ratingAge[i] = Convert.ToInt32(context.Device.Processes.ActiveApplication.ApplicationControlProperties.RatingAge[i]);
|
||||||
}
|
}
|
||||||
|
|
||||||
Array.Copy(tempRatingAge, _ratingAge, tempRatingAge.Length);
|
|
||||||
|
|
||||||
_parentalControlFlag = context.Device.Processes.ActiveApplication.ApplicationControlProperties.ParentalControlFlag;
|
_parentalControlFlag = context.Device.Processes.ActiveApplication.ApplicationControlProperties.ParentalControlFlag;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue