本文整理汇总了C#中IEnvironmentInfo类的典型用法代码示例。如果您正苦于以下问题:C# IEnvironmentInfo类的具体用法?C# IEnvironmentInfo怎么用?C# IEnvironmentInfo使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IEnvironmentInfo类属于命名空间,在下文中一共展示了IEnvironmentInfo类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: CSharpScriptExecutor
/// <summary>
/// A simple constructor that initializes the object with the given values.
/// </summary>
/// <param name="p_gmdGameMode">The game mode currently being managed.</param>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
/// <param name="p_csfFunctions">The proxy providing the implementations of the functions available to the C# script.</param>
/// <param name="p_tpeBaseScriptType">The type of the base script from which all C# scripts should derive.</param>
public CSharpScriptExecutor(IGameMode p_gmdGameMode, IEnvironmentInfo p_eifEnvironmentInfo, CSharpScriptFunctionProxy p_csfFunctions, Type p_tpeBaseScriptType)
{
m_gmdGameMode = p_gmdGameMode;
m_eifEnvironmentInfo = p_eifEnvironmentInfo;
m_csfFunctions = p_csfFunctions;
BaseScriptType = p_tpeBaseScriptType;
}
示例2: Initialize
/// <summary>
/// Initializes the singleton intances of the mod manager.
/// </summary>
/// <param name="p_gmdGameMode">The current game mode.</param>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
/// <param name="p_mrpModRepository">The mod repository from which to get mods and mod metadata.</param>
/// <param name="p_dmrMonitor">The download monitor to use to track task progress.</param>
/// <param name="p_frgFormatRegistry">The <see cref="IModFormatRegistry"/> that contains the list
/// of supported <see cref="IModFormat"/>s.</param>
/// <param name="p_mrgModRegistry">The <see cref="ModRegistry"/> that contains the list
/// of managed <see cref="IMod"/>s.</param>
/// <param name="p_futFileUtility">The file utility class.</param>
/// <param name="p_scxUIContext">The <see cref="SynchronizationContext"/> to use to marshall UI interactions to the UI thread.</param>
/// <param name="p_ilgInstallLog">The install log tracking mod activations for the current game mode.</param>
/// <param name="p_pmgPluginManager">The plugin manager to use to work with plugins.</param>
/// <returns>The initialized mod manager.</returns>
/// <exception cref="InvalidOperationException">Thrown if the mod manager has already
/// been initialized.</exception>
public static ModManager Initialize(IGameMode p_gmdGameMode, IEnvironmentInfo p_eifEnvironmentInfo, IModRepository p_mrpModRepository, DownloadMonitor p_dmrMonitor, ActivateModsMonitor p_ammMonitor, IModFormatRegistry p_frgFormatRegistry, ModRegistry p_mrgModRegistry, FileUtil p_futFileUtility, SynchronizationContext p_scxUIContext, IInstallLog p_ilgInstallLog, IPluginManager p_pmgPluginManager)
{
if (m_mmgCurrent != null)
throw new InvalidOperationException("The Mod Manager has already been initialized.");
m_mmgCurrent = new ModManager(p_gmdGameMode, p_eifEnvironmentInfo, p_mrpModRepository, p_dmrMonitor, p_ammMonitor, p_frgFormatRegistry, p_mrgModRegistry, p_futFileUtility, p_scxUIContext, p_ilgInstallLog, p_pmgPluginManager);
return m_mmgCurrent;
}
示例3: ModBuilder
/// <summary>
/// A simple construtor that initializes the object with the reqruied dependencies.
/// </summary>
/// <param name="p_gmiGameModeInfo">The environment info of the current game mode.</param>
/// <param name="p_futFileUtility">The file utility class.</param>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
public ModBuilder(IGameModeEnvironmentInfo p_gmiGameModeInfo, IEnvironmentInfo p_eifEnvironmentInfo, FileUtil p_futFileUtility)
{
GameModeInfo = p_gmiGameModeInfo;
EnvironmentInfo = p_eifEnvironmentInfo;
FileUtility = p_futFileUtility;
OverallProgressMaximum = 4;
}
示例4: XmlScriptExecutor
/// <summary>
/// A simple constructor that initializes the object with the required dependencies.
/// </summary>
/// <param name="p_modMod">The mod for which the script is running.</param>
/// <param name="p_gmdGameMode">The game mode currently being managed.</param>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
/// <param name="p_igpInstallers">The utility class to use to install the mod items.</param>
/// <param name="p_scxUIContext">The <see cref="SynchronizationContext"/> to use to marshall UI interactions to the UI thread.</param>
public XmlScriptExecutor(IMod p_modMod, IGameMode p_gmdGameMode, IEnvironmentInfo p_eifEnvironmentInfo, InstallerGroup p_igpInstallers, SynchronizationContext p_scxUIContext)
{
m_scxSyncContext = p_scxUIContext;
Mod = p_modMod;
GameMode = p_gmdGameMode;
EnvironmentInfo = p_eifEnvironmentInfo;
Installers = p_igpInstallers;
}
示例5: HelpInformation
/// <summary>
/// A simple constructor that initializes the object with its dependencies.
/// </summary>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
public HelpInformation(IEnvironmentInfo p_eifEnvironmentInfo)
{
EnvironmentInfo = p_eifEnvironmentInfo;
List<HelpLink> lstLinks = new List<HelpLink>();
foreach (KeyValuePair<string, string> kvpLink in p_eifEnvironmentInfo.Settings.HelpLinks)
lstLinks.Add(new HelpLink(kvpLink.Key, kvpLink.Value));
HelpLinks = lstLinks;
}
示例6: ModInstallerFactory
/// <summary>
/// A simple constructor that initializes the factory with the required dependencies.
/// </summary>
/// <param name="p_gmdGameMode">The game mode for which the created installer will be installing mods.</param>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
/// <param name="p_futFileUtility">The file utility class.</param>
/// <param name="p_scxUIContext">The <see cref="SynchronizationContext"/> to use to marshall UI interactions to the UI thread.</param>
/// <param name="p_ilgInstallLog">The install log that tracks mod install info
/// for the current game mode.</param>
/// <param name="p_pmgPluginManager">The plugin manager to use to work with plugins.</param>
public ModInstallerFactory(IGameMode p_gmdGameMode, IEnvironmentInfo p_eifEnvironmentInfo, FileUtil p_futFileUtility, SynchronizationContext p_scxUIContext, IInstallLog p_ilgInstallLog, IPluginManager p_pmgPluginManager, ModManager p_mmModManager)
{
m_gmdGameMode = p_gmdGameMode;
m_eifEnvironmentInfo = p_eifEnvironmentInfo;
m_futFileUtility = p_futFileUtility;
m_scxUIContext = p_scxUIContext;
m_ilgInstallLog = p_ilgInstallLog;
m_pmgPluginManager = p_pmgPluginManager;
m_mmModManager = p_mmModManager;
}
示例7: PluginSorter
/// <summary>
/// A simple constructor that initializes the object with the given dependencies.
/// </summary>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
/// <param name="p_gmdGameMode">The game mode for which plugins are being managed.</param>
/// <param name="p_futFileUtility">The file utility class.</param>
/// <param name="p_strMasterlistPath">The path to the masterlist file to use.</param>
public PluginSorter(IEnvironmentInfo p_eifEnvironmentInfo, GamebryoGameModeBase p_gmdGameMode, FileUtil p_futFileUtility, string p_strMasterlistPath)
{
EnvironmentInfo = p_eifEnvironmentInfo;
GameMode = p_gmdGameMode;
FileUtility = p_futFileUtility;
string strSorterAPIPath = Path.Combine(Path.Combine(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location), "data"), p_eifEnvironmentInfo.Is64BitProcess ? "loot64.dll" : "loot32.dll");
m_ptrSorterApi = LoadLibrary(strSorterAPIPath);
if (m_ptrSorterApi == IntPtr.Zero)
throw new SorterException(String.Format("Could not load BAPI library: {0}", strSorterAPIPath));
LoadMethods();
m_ptrSorterDb = CreateSorterDb();
if (m_ptrSorterDb == IntPtr.Zero)
m_booInitialized = false;
else
{
MasterlistPath = p_strMasterlistPath;
string strUserList = Path.Combine(Path.GetDirectoryName(p_strMasterlistPath), "userlist.yaml");
if (File.Exists(strUserList))
UserlistPath = strUserList;
else
UserlistPath = null;
if (!String.IsNullOrEmpty(MasterlistPath) && File.Exists(MasterlistPath))
Load(MasterlistPath, UserlistPath);
m_booInitialized = true;
}
}
示例8: OblivionGameModeDescriptor
/// <summary>
/// A simple constructor that initializes the object with the given dependencies.
/// </summary>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
public OblivionGameModeDescriptor(IEnvironmentInfo p_eifEnvironmentInfo)
: base(p_eifEnvironmentInfo)
{
}
示例9: Fallout3ToolLauncher
/// <summary>
/// A simple constructor that initializes the object with the given dependencies.
/// </summary>
/// <param name="p_gmdGameMode">>The game mode currently being managed.</param>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
public Fallout3ToolLauncher(IGameMode p_gmdGameMode, IEnvironmentInfo p_eifEnvironmentInfo)
{
GameMode = p_gmdGameMode;
EnvironmentInfo = p_eifEnvironmentInfo;
SetupTools();
}
示例10: CreateConditionStateManager
/// <summary>
/// Creates a <see cref="ConditionStateManager"/> to use when running an XML script.
/// </summary>
/// <param name="p_modMod">The mod being installed.</param>
/// <param name="p_gmdGameMode">The game mode currently bieng managed.</param>
/// <param name="p_pmgPluginManager">The plugin manager.</param>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
/// <returns>A <see cref="ConditionStateManager"/> to use when running an XML script.</returns>
public override ConditionStateManager CreateConditionStateManager(IMod p_modMod, IGameMode p_gmdGameMode, IPluginManager p_pmgPluginManager, IEnvironmentInfo p_eifEnvironmentInfo)
{
return new SkyrimConditionStateManager(p_modMod, p_gmdGameMode, p_pmgPluginManager, p_eifEnvironmentInfo);
}
示例11: Fallout3GameMode
/// <summary>
/// A simple constructor that initializes the object with the given values.
/// </summary>
/// <param name="p_eifEnvironmentInfo">The application's environment info.</param>
/// <param name="p_futFileUtility">The file utility class to be used by the game mode.</param>
public Fallout3GameMode(IEnvironmentInfo p_eifEnvironmentInfo, FileUtil p_futFileUtility)
: base(p_eifEnvironmentInfo, p_futFileUtility)
{
}
示例12: DragonAgeToolLauncher
/// <summary>
/// A simple constructor that initializes the object with the given dependencies.
/// </summary>
/// <param name="p_gmdGameMode">>The game mode currently being managed.</param>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
public DragonAgeToolLauncher(IGameMode p_gmdGameMode, IEnvironmentInfo p_eifEnvironmentInfo)
{
GameMode = p_gmdGameMode;
EnvironmentInfo = p_eifEnvironmentInfo;
SetupTools();
}
示例13: XRebirthSetupVM
/// <summary>
/// A simple constructor that initializes the object with the given values.
/// </summary>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
/// <param name="p_gmdGameModeInfo">The descriptor for the game mode being set up.</param>
public XRebirthSetupVM(IEnvironmentInfo p_eifEnvironmentInfo, IGameModeDescriptor p_gmdGameModeInfo)
:base(p_eifEnvironmentInfo, p_gmdGameModeInfo)
{
}
示例14: ModScriptUIUtil
/// <summary>
/// A simple constructor that initializes the object with the given values.
/// </summary>
/// <param name="p_gmdGameMode">The current game mode.</param>
/// <param name="p_eifEnvironmentInfo">The application's envrionment info.</param>
/// <param name="p_scxSyncContext">The synchronization context to use to marshall calls to the UI thread.</param>
public ModScriptUIUtil(IGameMode p_gmdGameMode, IEnvironmentInfo p_eifEnvironmentInfo, SynchronizationContext p_scxSyncContext)
: base(p_gmdGameMode, p_eifEnvironmentInfo, p_scxSyncContext)
{
}
示例15: GrimrockGameModeFactory
/// <summary>
/// A simple consturctor that initializes the object with the given values.
/// </summary>
/// <param name="p_eifEnvironmentInfo">The application's environement info.</param>
public GrimrockGameModeFactory(IEnvironmentInfo p_eifEnvironmentInfo)
{
EnvironmentInfo = p_eifEnvironmentInfo;
m_gmdGameModeDescriptor = new GrimrockGameModeDescriptor(p_eifEnvironmentInfo);
}