2022-03-22 20:46:16 +01:00
|
|
|
|
using LibHac.Ncm;
|
2019-09-10 11:55:28 +02:00
|
|
|
|
|
2019-09-19 02:45:11 +02:00
|
|
|
|
namespace Ryujinx.HLE.HOS.Services.Arp
|
2019-09-10 11:55:28 +02:00
|
|
|
|
{
|
|
|
|
|
class ApplicationLaunchProperty
|
|
|
|
|
{
|
2020-01-12 12:15:17 +01:00
|
|
|
|
public ulong TitleId;
|
2019-09-10 11:55:28 +02:00
|
|
|
|
public int Version;
|
|
|
|
|
public byte BaseGameStorageId;
|
|
|
|
|
public byte UpdateGameStorageId;
|
2020-04-20 23:59:59 +02:00
|
|
|
|
#pragma warning disable CS0649
|
2019-09-10 11:55:28 +02:00
|
|
|
|
public short Padding;
|
2020-04-20 23:59:59 +02:00
|
|
|
|
#pragma warning restore CS0649
|
2019-09-10 11:55:28 +02:00
|
|
|
|
|
|
|
|
|
public static ApplicationLaunchProperty Default
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return new ApplicationLaunchProperty
|
|
|
|
|
{
|
|
|
|
|
TitleId = 0x00,
|
|
|
|
|
Version = 0x00,
|
2022-03-22 20:46:16 +01:00
|
|
|
|
BaseGameStorageId = (byte)StorageId.BuiltInSystem,
|
2019-09-10 11:55:28 +02:00
|
|
|
|
UpdateGameStorageId = (byte)StorageId.None
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public static ApplicationLaunchProperty GetByPid(ServiceCtx context)
|
|
|
|
|
{
|
|
|
|
|
// TODO: Handle ApplicationLaunchProperty as array when pid will be supported and return the right item.
|
|
|
|
|
// For now we can hardcode values, and fix it after GetApplicationLaunchProperty is implemented.
|
|
|
|
|
|
|
|
|
|
return new ApplicationLaunchProperty
|
|
|
|
|
{
|
2023-03-31 21:16:46 +02:00
|
|
|
|
TitleId = context.Device.Processes.ActiveApplication.ProgramId,
|
2019-09-10 11:55:28 +02:00
|
|
|
|
Version = 0x00,
|
2022-03-22 20:46:16 +01:00
|
|
|
|
BaseGameStorageId = (byte)StorageId.BuiltInSystem,
|
2019-09-10 11:55:28 +02:00
|
|
|
|
UpdateGameStorageId = (byte)StorageId.None
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|