|
@@ -1,6 +1,7 @@
|
|
|
using System;
|
|
|
using XGame.Framework.Quality;
|
|
|
using XGame.Framework.Time;
|
|
|
+using XGame.Framework.UI;
|
|
|
|
|
|
namespace XGame.Framework.Map
|
|
|
{
|
|
@@ -13,6 +14,7 @@ namespace XGame.Framework.Map
|
|
|
public ITimeProxy Time => _timeProxy ?? (_timeProxy = new TimeProxy(_timeModule));
|
|
|
|
|
|
public IMapModule Map { get; private set; }
|
|
|
+ public IUIModule UI { get; private set; }
|
|
|
|
|
|
/// <summary>
|
|
|
/// 资源加载模块,需要时才创建
|
|
@@ -20,16 +22,17 @@ namespace XGame.Framework.Map
|
|
|
private IMapAssetModule _assetModule;
|
|
|
public IMapAssetModule Asset => _assetModule ?? (_assetModule = new MapAssetModule(this));
|
|
|
|
|
|
- public MapContext(IQualityModule quality, ITimeModule time, IMapModule map)
|
|
|
+ public MapContext(IQualityModule quality, ITimeModule time, IMapModule map, IUIModule ui)
|
|
|
{
|
|
|
Quality = quality;
|
|
|
_timeModule = time;
|
|
|
Map = map;
|
|
|
+ UI = ui;
|
|
|
}
|
|
|
|
|
|
public MapContext Clone()
|
|
|
{
|
|
|
- return new MapContext(Quality, _timeModule, Map);
|
|
|
+ return new MapContext(Quality, _timeModule, Map, UI);
|
|
|
}
|
|
|
/// <summary>
|
|
|
/// 取消定时器、清理资源加载监听等
|