ERROR Photon.Hive.Plugin.PluginManager - System.IO.FileNotFoundExceptio
How to fix below error, I followed this URL https://doc.photonengine.com/en-us/server/current/plugins/getting-started to create my 1st plugin.
2022-03-24 17:10:20,356 [21] ERROR Photon.Hive.Plugin.PluginManager - System.IO.FileNotFoundException : The system cannot find the file specified. (Exception from HRESULT: 0x80070002)
Stack Trace:
at MyFirstPlugin.MyPluginFactory.CreatePlugin(String pluginName)
at Photon.Hive.Plugin.PluginFactoryBase.Create(IPluginHost gameHost, String pluginName, Dictionary`2 config, String& errorMsg)
at Photon.Hive.Plugin.PluginManager.CreatePluginWithFactory(IPluginHost sink, String pluginName)
at Photon.Hive.Plugin.PluginManager.GetGamePlugin(IPluginHost sink, String pluginName)
2022-03-24 17:10:20,356 [21] DEBUG Photon.Hive.Plugin.CreateGameCallInfo - Fail: System.IO.FileNotFoundException : The system cannot find the file specified. (Exception from HRESULT: 0x80070002)
Stack Trace:
at MyFirstPlugin.MyPluginFactory.CreatePlugin(String pluginName)
at Photon.Hive.Plugin.PluginFactoryBase.Create(IPluginHost gameHost, String pluginName, Dictionary`2 config, String& errorMsg)
at Photon.Hive.Plugin.PluginManager.CreatePluginWithFactory(IPluginHost sink, String pluginName)
at Photon.Hive.Plugin.PluginManager.GetGamePlugin(IPluginHost sink, String pluginName)
Comments
-
@chvetsov Thanks for the response, I have fixed the assembly files, But In the next step I am getting another error. Could you please help me on this?
code
using Photon.Hive.Plugin;
namespace MyFirstPlugin
{
public class MyFirstPlugin : PluginBase
{
public override string Name => "MyFirstPlugin";
private IPluginLogger pluginLogger;
public override bool SetupInstance(IPluginHost host, Dictionary<string, string> config, out string errorMsg)
{
/*this.pluginLogger.InfoFormat("*********");*/
this.pluginLogger = host.CreateLogger(this.Name);
return base.SetupInstance(host, config, out errorMsg);
}
public override void OnCreateGame(ICreateGameCallInfo info)
{
this.pluginLogger.InfoFormat("OnCreateGame - ********this is custom code ************ {0} by user {1}", info.Request.GameId, info.UserId);
info.Continue(); // same as base.OnCreateGame(info);
}
}
}
0