Rom从RomLib读取后,一些Rom信息获取入口的善后工作

This commit is contained in:
ALIENJACK\alien 2024-08-16 10:29:51 +08:00
parent 417bc25fe4
commit 72a1b76ba0
2 changed files with 6 additions and 13 deletions

View File

@ -8,17 +8,6 @@ namespace AxibugEmuOnline.Client
{
public class CoreSupporter : ISupporterImpl
{
private static string RomDirectoryPath
{
get
{
#if UNITY_EDITOR
return "Assets/StreamingAssets/NES/Roms";
#else
return $"{Application.streamingAssetsPath}/NES/Roms";
#endif
}
}
public Stream OpenRom(string fname)
{
@ -38,8 +27,11 @@ namespace AxibugEmuOnline.Client
public void GetRomPathInfo(string fname, out string fullPath, out string directPath)
{
directPath = RomDirectoryPath;
fullPath = $"{directPath}/{fname}";
var romFile = AppAxibugEmuOnline.romLib.GetNesRomFile(fname);
UnityEngine.Debug.Assert(romFile != null);
fullPath = romFile.LocalFilePath;
directPath = Path.GetDirectoryName(fullPath);
}
public Stream OpenFile_DISKSYS()

View File

@ -1,4 +1,5 @@
using System;
using System.Runtime.CompilerServices;
namespace VirtualNes.Core
{