Цитата Сообщение от naryv Посмотреть сообщение
хорошо, буду ждать уточнение, постараемся исправить.
Вот такая ошибка

Скрытый текст:
Код:
=================================================
System.Runtime.Serialization.SerializationException: Type 'XCmHVL2XxNBIYasUAhA.m
5wJuI2TCJecIAJ6C2k' in assembly 'maddox, Version=1.0.0.0, Culture=neutral, Publi
cKeyToken=8b6839725e48404f' is not marked as serializable.

Server stack trace:
   at maddox.game.GameServerDef.get_game()
   at maddox.game.world.Strategy.Init(IGamePlay gamePlay) in C:\Users\Small_Bee\
Documents\Visual Studio 2010\Projects\Strategy\Strategy\Strategy.cs:line 29
   at maddox.game.ScriptRemote.loadBattleScript(String assemblyFileName, IGamePl
ay gamePlay)
   at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(
IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInCont
ext, Object[]& outArgs)
   at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMes
sage msg, Int32 methodPtr, Boolean fExecuteInContext)

Exception rethrown at [0]:
   at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage req
Msg, IMessage retMsg)
   at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgDa
ta, Int32 type)
   at maddox.game.IScriptRemote.loadBattleScript(String assemblyFileName, IGameP
lay gamePlay)
   at 5gH4oknoo5EY5CgCVcx.0YwoYOnr3vYskAKoCh6.yxDI29fawsP()
=================================================

=================================================
System.Runtime.Serialization.SerializationException: Type 'XCmHVL2XxNBIYasUAhA.m
5wJuI2TCJecIAJ6C2k' in assembly 'maddox, Version=1.0.0.0, Culture=neutral, Publi
cKeyToken=8b6839725e48404f' is not marked as serializable.

Server stack trace:
   at maddox.game.GameServerDef.get_game()
   at maddox.game.world.Strategy.Init(IGamePlay gamePlay) in C:\Users\Small_Bee\
Documents\Visual Studio 2010\Projects\Strategy\Strategy\Strategy.cs:line 29
   at maddox.game.ScriptRemote.loadBattleScript(String assemblyFileName, IGamePl
ay gamePlay)
   at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(
IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInCont
ext, Object[]& outArgs)
   at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMes
sage msg, Int32 methodPtr, Boolean fExecuteInContext)

Exception rethrown at [0]:
   at 5gH4oknoo5EY5CgCVcx.0YwoYOnr3vYskAKoCh6.yxDI29fawsP()
   at MW1vr45kkDswEmVZaHH.nYyHpA5yJ8g95O4DLEa.f3jWCkg4F3(vjbTQEEtEVyjgU6D54J )
=================================================

=================================================
System.Runtime.Serialization.SerializationException: Type 'XCmHVL2XxNBIYasUAhA.m
5wJuI2TCJecIAJ6C2k' in assembly 'maddox, Version=1.0.0.0, Culture=neutral, Publi
cKeyToken=8b6839725e48404f' is not marked as serializable.

Server stack trace:
   at maddox.game.GameServerDef.get_game()
   at maddox.game.world.Strategy.Init(IGamePlay gamePlay) in C:\Users\Small_Bee\
Documents\Visual Studio 2010\Projects\Strategy\Strategy\Strategy.cs:line 29
   at maddox.game.ScriptRemote.loadBattleScript(String assemblyFileName, IGamePl
ay gamePlay)
   at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(
IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInCont
ext, Object[]& outArgs)
   at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMes
sage msg, Int32 methodPtr, Boolean fExecuteInContext)

Exception rethrown at [0]:
   at MW1vr45kkDswEmVZaHH.nYyHpA5yJ8g95O4DLEa.f3jWCkg4F3(vjbTQEEtEVyjgU6D54J )
   at MW1vr45kkDswEmVZaHH.nYyHpA5yJ8g95O4DLEa.VaIifIGEbs1lvhe8qWB(Object )
   at MW1vr45kkDswEmVZaHH.nYyHpA5yJ8g95O4DLEa.Yi0WiwFXpL(vjbTQEEtEVyjgU6D54J )
   at MW1vr45kkDswEmVZaHH.nYyHpA5yJ8g95O4DLEa.EpqW0os9d1(String )
   at XCmHVL2XxNBIYasUAhA.m5wJuI2TCJecIAJ6C2k.MissionLoad(String )
=================================================

=================================================
System.Runtime.Serialization.SerializationException: Type 'XCmHVL2XxNBIYasUAhA.m
5wJuI2TCJecIAJ6C2k' in assembly 'maddox, Version=1.0.0.0, Culture=neutral, Publi
cKeyToken=8b6839725e48404f' is not marked as serializable.

Server stack trace:
   at maddox.game.GameServerDef.get_game()
   at maddox.game.world.Strategy.Init(IGamePlay gamePlay) in C:\Users\Small_Bee\
Documents\Visual Studio 2010\Projects\Strategy\Strategy\Strategy.cs:line 29
   at maddox.game.ScriptRemote.loadBattleScript(String assemblyFileName, IGamePl
ay gamePlay)
   at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(
IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInCont
ext, Object[]& outArgs)
   at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMes
sage msg, Int32 methodPtr, Boolean fExecuteInContext)

Exception rethrown at [0]:
   at XCmHVL2XxNBIYasUAhA.m5wJuI2TCJecIAJ6C2k.MissionLoad(String )
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.DNgTRJ0qZgs(gPJU6kIZ4shGykFNZg7 )
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.ZJ8TYghii8gjhjgJGaF.rVjXD1enz1g4TJ
NGAfGc(Object , Object )
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.ZJ8TYghii8gjhjgJGaF.lnATRrMeUxh(gP
JU6kIZ4shGykFNZg7 )
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.y72nUBeniTInHs9txyUS(Object , Obje
ct )
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.consoleInput(String )
   at 3FZcxHms5IqjoeGeo2h.F0VeDtmByYlY9Blsrhq.SFKIPXhgdov(String )
   at IE6CYH9RP8HnCFpewZx.y26yKC95JK9uMUhliYG.vc5cAq3bmR4(String , c7ZuPW9BqdyfJ
C6pStx )
=================================================
>battle start

=================================================
System.ApplicationException: Mission: Mission not loaded.
   at MW1vr45kkDswEmVZaHH.nYyHpA5yJ8g95O4DLEa.uZlW3QAC9N(Double )
   at MW1vr45kkDswEmVZaHH.nYyHpA5yJ8g95O4DLEa.OtqWYy0BF1()
   at XCmHVL2XxNBIYasUAhA.m5wJuI2TCJecIAJ6C2k.BattleStart()
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.s9DTR3ZqI4t(gPJU6kIZ4shGykFNZg7 )
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.ZJ8TYghii8gjhjgJGaF.rVjXD1enz1g4TJ
NGAfGc(Object , Object )
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.ZJ8TYghii8gjhjgJGaF.lnATRrMeUxh(gP
JU6kIZ4shGykFNZg7 )
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.y72nUBeniTInHs9txyUS(Object , Obje
ct )
   at aX2DOmhyS6kclbFDNtd.c6MannhpCKJgNfMedU4.consoleInput(String )
   at 3FZcxHms5IqjoeGeo2h.F0VeDtmByYlY9Blsrhq.SFKIPXhgdov(String )
   at IE6CYH9RP8HnCFpewZx.y26yKC95JK9uMUhliYG.vc5cAq3bmR4(String , c7ZuPW9BqdyfJ
C6pStx )
=================================================


И кусочек кода Strategy, который ее вызывает

Код:
public override void Init(IGamePlay gamePlay)
        {
            base.Init(gamePlay);
            if (gamePlay is GameServerDef)
            {
                gameServer = (GameServerDef)gamePlay;
                gameServer.EventChat += new GameDef.Chat(gameServer_EventChat);
                GameServerIterface gi = gameServer.game;
                string addinName = gameServer.addInName;
                this.GamePlay.gpLogServer(null, "Addin name is `" + addinName + "`", null);
            }   
        }

        public override void OnEventGame(GameEventId eventId, object eventArg0, object eventArg1, int eventArgInt)
        {
            base.OnEventGame(eventId, eventArg0, eventArg1, eventArgInt);
        }
А именно строка GameServerIterface gi = gameServer.game;
Похожую ошибку вызывает также строка
gameServer.EventChat += new GameDef.Chat(gameServer_EventChat);
если ее написать в скрипте миссии. В стратегии нормально.