"Hello world" tutorial
Options
Hi,
[NEW PROBLEM]
I'm trying the "Hello World" blank project, and there is a problem with the PhotonServer.Config
The photon tries to start for 15secs and then turns off.
The socketServer (trying to debug it) says that something made it stop because there is a remote host already running it (the photon server is off).
[/NEW PROBLEM]
[SOLVED]
I'm doing the "Hello World" blank project tutorial but there is one problem when I try to compile
Error 1 The type or namespace name 'Concurrency' does not exist in the namespace 'ExitGames' (are you missing an assembly reference?) C:\Users\User\Documents\Unity Projects\Photon Server SDK\deploy\Test\TestServer\TestClient\Program.cs 8 17 TestClient
the compiler can't understand the "using ExitGames.Concurrency" which is used for "PoolFiber".
Any ideas?
(using Visual Studio 2010 Ultimate - Windows Vista 32 bits Home Premium)
I've received this warning message
Warning 1 The referenced assembly "ExitGamesLibs" could not be resolved because it has a dependency on "System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" which is not in the currently targeted framework ".NETFramework,Version=v4.0,Profile=Client". Please remove references to assemblies not in the targeted framework or consider retargeting your project. TestClient
[/SOLVED]
[NEW PROBLEM]
I'm trying the "Hello World" blank project, and there is a problem with the PhotonServer.Config
<Application Name="Test" BaseDirectory="Test\TestServer" Assembly="Test" Type="TestServer.MyApplication" EnableAutoRestart="true" WatchFiles="dll;config" ExcludeFiles="log4net.config"> </Application>
The photon tries to start for 15secs and then turns off.
The socketServer (trying to debug it) says that something made it stop because there is a remote host already running it (the photon server is off).
[/NEW PROBLEM]
[SOLVED]
I'm doing the "Hello World" blank project tutorial but there is one problem when I try to compile
Error 1 The type or namespace name 'Concurrency' does not exist in the namespace 'ExitGames' (are you missing an assembly reference?) C:\Users\User\Documents\Unity Projects\Photon Server SDK\deploy\Test\TestServer\TestClient\Program.cs 8 17 TestClient
the compiler can't understand the "using ExitGames.Concurrency" which is used for "PoolFiber".
Any ideas?
(using Visual Studio 2010 Ultimate - Windows Vista 32 bits Home Premium)
I've received this warning message
Warning 1 The referenced assembly "ExitGamesLibs" could not be resolved because it has a dependency on "System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" which is not in the currently targeted framework ".NETFramework,Version=v4.0,Profile=Client". Please remove references to assemblies not in the targeted framework or consider retargeting your project. TestClient
[/SOLVED]
0
Comments
-
Please look at / post the photon log.0
-
I've tried the PhotonServer.config with "Test\TestServer" and with "Test\TestServer\TestServer" in the application thing.
5976: 19:27:32.997 - Server Starting... 5976: 19:27:32.998 - Current directory is: C:\Windows\system32 5976: 19:27:32.998 - Changing current directory to: C:\Users\User\Documents\Unity Projects\Photon Server SDK\deploy\bin_Win32 5976: 19:27:32.998 - Config File: C:\Users\User\Documents\Unity Projects\Photon Server SDK\deploy\bin_Win32\PhotonServer.config 5976: 19:27:33.033 - About to load runtime: PhotonHostRuntime.PhotonDomainManager from PhotonHostRuntime, Version=2.0.0.0, Culture=neutral, PublicKeyToken=02C301B61B060C4D 5976: 19:27:33.034 - About to load CLR - versions available: 5976: 19:27:33.034 - v2.0.50727 5976: 19:27:33.034 - v4.0.30319 5976: 19:27:33.034 - No preference in configuration file, will load latest. 5976: 19:27:33.034 - About to load version: "v4.0.30319" 5976: 19:27:33.036 - Loaded version: "v4.0.30319" 5976: 19:27:33.766 - Photon host runtime loaded 5976: 19:27:49.182 - License is valid. 5976: 19:27:49.182 - Licensed for 100 concurrent connections. 5976: 19:27:49.183 - Max Reliable Data In Transit (awaiting ACKs) per peer : 16384 bytes 5976: 19:27:49.183 - Per peer bandwidth limit 5976: 19:27:49.183 - Transmit Rate Limit: 128 KB/Sec 5976: 19:27:49.183 - Limit period: 250ms 5976: 19:27:49.183 - Limit per period: 32768 bytes 5976: 19:27:49.183 - Max queued data for transmission per peer: 65536 bytes 5976: 19:27:49.183 - Minimum retransmit timeout: 200 5976: 19:27:49.183 - Minimum ENet timeout: 5000ms 5976: 19:27:49.183 - Maximum ENet timeout: 30000ms 5976: 19:27:49.183 - ENetHost: Using Timer Wheel 5976: 19:27:49.183 - About to load application: Test from Test 5976: 19:27:49.183 - Auto restart is enabled for application 5976: 19:27:49.183 - Application will restart 10000ms after the last change detected 5976: 19:27:49.183 - Application will restart if files matching the following are changed: "dll;config" 5976: 19:27:49.183 - Application will NOT restart if files matching the following are changed: "log4net.config" 5976: 19:27:50.089 - ERROR: Failed to start application: "Test" in app domain: 2 5976: 19:27:50.090 - CService::OnException() - Exception: CManagedHost::StartApplication() - Failed to start application in AppDomain: 2 - Não foi possível carregar arquivo ou assembly 'Test' ou uma de suas dependências. O sistema não pode encontrar o arquivo especificado. 5976: 19:27:50.090 - Server shutting down... 5976: 19:27:50.090 - Shutting down ENet host...
0 -
My guess would be that Photon can't find assembly at "C:\Users\User\Documents\Unity Projects\Photon Server SDK\deploy\Test\TestServer\Bin\Test.dll" (taken config in your first post is accurate)0
-
Is this log for the new problem?
I don't get this error message, but it will be the cause of your issues:
"Não foi possível carregar arquivo ou assembly 'Test' ou uma de suas dependências. O sistema não pode encontrar o arquivo especificado."
Maybe theres a config issue. You need to name the class (complete with namespace) to run in the application node. Compare "The Application Node":
http://developer.exitgames.com/photonse ... pandconfig0 -
did you change the output path to compile to that folder?0
-
Boris wrote:did you change the output path to compile to that folder?
Well, its compiling at
C:\Users\User\Documents\Unity Projects\Photon Server SDK\deploy\Test\TestServer\TestServer\binTobias wrote:Is this log for the new problem?
I don't get this error message, but it will be the cause of your issues:
"Não foi possível carregar arquivo ou assembly 'Test' ou uma de suas dependências. O sistema não pode encontrar o arquivo especificado."
yes, its for the new problem
this error message means something like:
- Was not possible to load the file or assembly Test or one of its dependencies. The system could not find the specified file0 -
your config file is set to load from "Test\TestServer\bin" - but your binaries are at "Test\TestServer\TestServer\bin"0
-
removed the second testServer from the game...
this happens3268: 03:25:17.321 - Max queued data for transmission per peer: 65536 bytes 3268: 03:25:17.321 - Minimum retransmit timeout: 200 3268: 03:25:17.321 - Minimum ENet timeout: 5000ms 3268: 03:25:17.321 - Maximum ENet timeout: 30000ms 3268: 03:25:17.322 - ENetHost: Using Timer Wheel 3268: 03:25:17.322 - About to load application: Test from Test 3268: 03:25:17.322 - Auto restart is enabled for application 3268: 03:25:17.322 - Application will restart 10000ms after the last change detected 3268: 03:25:17.322 - Application will restart if files matching the following are changed: "dll;config" 3268: 03:25:17.322 - Application will NOT restart if files matching the following are changed: "log4net.config" 3268: 03:25:17.843 - ERROR: Failed to start application: "Test" in app domain: 2
0 -
Anything else? These are just info messages.0
-
Nope, nothing else, the log stops there, then the server stops running.0
-
for some reason the last line was not displayed on my phone...
3268: 03:25:17.843 - ERROR: Failed to start application: "Test" in app domain: 2
the last time these lines were followed by5976: 19:27:50.090 - CService::OnException() - Exception: CManagedHost::StartApplication() - Failed to start application in AppDomain: 2 - Não foi possível carregar arquivo ou assembly 'Test' ou uma de suas dependências. O sistema não pode encontrar o arquivo especificado. 5976: 19:27:50.090 - Server shutting down... 5976: 19:27:50.090 - Shutting down ENet host...
I expected something similar again.
is it maybe assembly name "TestServer" and not "Test" ?<Application
Name="Test"
BaseDirectory="Test\TestServer"
Assembly="Test"
Type="TestServer.MyApplication"
EnableAutoRestart="true"
WatchFiles="dll;config"
ExcludeFiles="log4net.config">
</Application>0 -
thats it, working fine now, this tutorial working will help me alot from now on.
thanks!0 -
Having the same issue. Will not work no matter what I set the assembly to to.
8828: 03:46:21.322 - CService::OnException() - Exception: CManagedHost::StartApplication() - Failed to start application in AppDomain: 2 - Could not load file or assembly 'Test' or one of its dependencies. The system cannot find the file specified.
<Application> Name="Test" BaseDirectory="Test\TestServer" Assembly="TestServer" Type="TestServer.MyApplication" EnableAutoRestart="true" WatchFiles="dll;config" ExcludeFiles="log4net.config"> </Application>
0 -
I have been at this all night long. I have restarted the tutorial thinking I missed something four times now. This is very very very annoying.0
-
Could you attach a directory listing? Your app's dlls have to be in deploy\test\testserver\bin\.
The application's dll: deploy\test\testserver\bin\TestServer.dll must include the namespace TestServer and the app class is MyApplication.
Is everything at it's place?0 -
TestSever.dll is located in
C:\Dev\MyPhotonServer\deploy\Test\TestServer\bin
The contents of my config:<Applications Default="TestServer"> <Application Name="Test" BaseDirectory="Test\TestServer" Assembly="TestServer" Type="TestServer.MyApplication" </Application>
0 -
Ok finally got it running. Long story short, I need to pay more attention when editing the .config file. Left out a > to close the properties of Application Tag.
Now to flesh out the server with goodies.0 -
Oh, that's mean.
Thanks for the feedback. We will look into checking the XML first and provide a error, if it's buggy. That should help here...
Sorry for the inconvenience.0 -
-
Everything I see on the screenshot looks good. No idea..0
-
well I did some testing and Lite and Litelobby work fine as well as MMO. Photon starts up fine with all of those.
I just can not figure out why my application does not start. I even used .NET Reflector to make sure AreaOfEffect.AreaOfEffectApplicaion is there in my dll, and it is. Am I missing a file somewhere like a config file?0 -
did you copied the lite or litelobby folder and put your files in? if so make sure you rename all the folders properly.
How I did it:
1. ctrl +c & ctrl + v lite
2. rename /lite/lite to /myApp/myApp
3. go to /deploy/myApp/myApp/bin and delete everything in here
4. edit visual studio to output any builds to /deploy/myApp/myApp/bin/
thats how it worked for me0 -
yeap I have done all of that (didnt copy/paste, I just made Visual studio make the files for me ... but they are all there and in proper order)0
-
Here is an example of Lite working and my application not working.
3340: 15:18:54.797 - --- 3340: 15:18:54.797 - Server Starting... 3340: 15:18:54.797 - Photon Version: 2.6.7.525 3340: 15:18:54.797 - Not using performance counters as they are not currently installed. Run the service with /InstallCounters to install them. 3340: 15:18:54.797 - About to load runtime: PhotonHostRuntime.PhotonDomainManager from PhotonHostRuntime, Culture=neutral, PublicKeyToken=02C301B61B060C4D 3340: 15:18:54.797 - About to load CLR - versions available: 3340: 15:18:54.797 - v2.0.50727 3340: 15:18:54.797 - v4.0.30319 3340: 15:18:54.797 - No preference in configuration file, will load latest. 3340: 15:18:54.797 - About to load version: "v4.0.30319" 3340: 15:18:54.797 - Loaded version: "v4.0.30319" 3340: 15:19:01.094 - Photon host runtime loaded 3340: 15:19:02.266 - License is valid. 3340: 15:19:02.266 - Licensed for 100 concurrent connections. 3340: 15:19:02.266 - Max Reliable Data In Transit (awaiting ACKs) per peer : 16384 bytes 3340: 15:19:02.266 - Per peer bandwidth limit 3340: 15:19:02.266 - Transmit Rate Limit: 128 KB/Sec 3340: 15:19:02.266 - Limit period: 250ms 3340: 15:19:02.266 - Limit per period: 32768 bytes 3340: 15:19:02.266 - Max queued data for transmission per peer: 65536 bytes 3340: 15:19:02.266 - Minimum retransmit timeout: 200 3340: 15:19:02.266 - Minimum ENet timeout: 5000ms 3340: 15:19:02.266 - Maximum ENet timeout: 30000ms 3340: 15:19:02.266 - ENetHost: Using Timer Wheel 3340: 15:19:02.266 - About to load application: Lite from Lite 3340: 15:19:02.266 - Auto restart is enabled for application 3340: 15:19:02.266 - Application will restart 10000ms after the last change detected 3340: 15:19:02.266 - Application will restart if files matching the following are changed: "dll;config" 3340: 15:19:02.266 - Application will NOT restart if files matching the following are changed: "log4net.config" 3340: 15:19:08.063 - Application: "Lite" started in app domain: 2 3340: 15:19:08.063 - About to load application: AreaOfEffect from AreaOfEffect 3340: 15:19:08.063 - Auto restart is enabled for application 3340: 15:19:08.063 - Application will restart 10000ms after the last change detected 3340: 15:19:08.063 - Application will restart if files matching the following are changed: "dll;config" 3340: 15:19:08.063 - Application will NOT restart if files matching the following are changed: "log4net.config" 3340: 15:19:13.579 - ERROR: Failed to start application: "AreaOfEffect" in app domain: 3 3340: 15:19:13.579 - CService::OnException() - Exception: CManagedHost::StartApplication() - Failed to start application in AppDomain: 3 - Object "AreaOfEffect.AreaOfEffectApplication" not found in assembly "AreaOfEffect" 3340: 15:19:13.579 - Server shutting down... 3340: 15:19:13.579 - Shutting down ENet host... 3340: 15:19:13.579 - Disconnecting all peers... 3340: 15:19:13.579 - Shutting down socket servers... 3340: 15:19:13.579 - Shutting down ENet thread pool... 3340: 15:19:13.579 - Shutting down business logic thread pool... 3340: 15:19:13.579 - Shutting down I/O thread pool... 2552: 15:19:13.594 - CManagedHost::OnDomainUnload() - 3 3340: 15:19:13.594 - Flushing ENET buffer allocator... 3340: 15:19:13.594 - Flushing TCP buffer allocator... 3340: 15:19:13.594 - Flushing stream socket allocator... 3340: 15:19:13.594 - Flushing datagram socket allocator... 3340: 15:19:13.594 - Destroying ENet thread pool 3340: 15:19:13.594 - Destroying TCP inactivity timer 3340: 15:19:13.594 - Destroying Business logic thread pool 3340: 15:19:13.594 - Destroying servers 3340: 15:19:13.594 - Destroying ENet host 3340: 15:19:13.594 - Destroying CLR dispatcher 3340: 15:19:13.594 - Destroying CLR applications 3340: 15:19:13.610 - CManagedHost::OnCLRDisabled() 3340: 15:19:13.875 - Destroying I/O thread pool 3340: 15:19:13.875 - Destroying ENet buffer allocator 3340: 15:19:13.875 - Destroying TCP buffer allocator 3340: 15:19:13.875 - Destroying TCP socket allocator 3340: 15:19:13.875 - Destroying ENet socket allocator 3340: 15:19:13.875 - Destroying performance counters 3340: 15:19:13.875 - Shutdown complete...
0 -
"/deploy/myApp/myApp/bin"
you have /deploy/myApp/bin
tried that before? is the only thing I can see from the screenshot0 -
Yea I tried deploy/myapp/myapp/bin and i got the same results. the level of folder should not matter beyond deploy/myapp/bin though. Either way I have it as deploy/AreaOfEffect/AreaOfEffect/bin now and still the same results.
Also, here is my AreaOfEffectApplication file if that helps anyone figure this out ...using System; using AreaOfEffect.Models.Base; using ExitGames.Logging; using FluentNHibernate.Cfg; using FluentNHibernate.Cfg.Db; using NHibernate; using Photon.SocketServer; namespace AreaOfEffect { public class AreaOfEffectApplication : Application { protected override IPeer CreatePeer(PhotonPeer photonPeer, InitRequest initRequest) { return new AreaOfEffectPeer(photonPeer); } protected override void Setup() { } protected override void TearDown() { } } }
It is all very basic ... I got the project from here (https://github.com/dragagon/AegisBornPhoton) if anyone can download it and let me know if it works for them. Even trying to impliment the downloaded project did not work for me. Although it had worked the first time I downloaded it. But now it is not working.0 -
just a wild guess.. which .net target framework do you have configured?0
-
have you rebuild it at least one time after you've renamed everything? otherwise it will still look in the assembly AegisBorn which will fail cause it does not contain AreaOfEffectApplication. Also make sure that you renamed everything properly, otherwise it will fail as well.0
-
.net 4
Yea I have rebuilt it about once every 10 min after making minor tweeks to different settings to try different things out including things like rnaming the classes or renaming the whole assembly.0 -
mh.. lite is compiled to use .net 3.5 - not that it really should make a difference, but maybe worth a try.
and you did probably already double-check that the build output directory is your deploy\...\bin folder as well... at least it looked like it from the screenshot..0