Trouble with local connection

Post here your questions about the Unity / .Net / Mono / Windows 8 / Windows Phone 8 API for SFS2X

Moderators: Lapo, Bax

Questionairre
Posts: 16
Joined: 07 Mar 2011, 21:08

Trouble with local connection

Postby Questionairre » 18 Mar 2011, 00:31

I am having the hardest time connecting to a localhost server.

I am using the 32bit version of SFS2X with the RC2 patch applied. I am trying to connect with the FPS demo which was upgraded to Unity 3.0, exported as assets, imported into a fresh project, and has the security policy thing applied.

The SFS2X log has this looping when I try to start a game in the demo :

Code: Select all

17 Mar 2011 19:30:07,655 WARN  [com.smartfoxserver.v2.controllers.ExtensionController-1] v2.controllers.ExtensionController     -
com.smartfoxserver.v2.exceptions.SFSExtensionException: No extensions can be invoked: { Zone: SimpleChat }, RoomId: 4
   com.smartfoxserver.v2.controllers.ExtensionController.processRequest(ExtensionController.java:120)
   com.smartfoxserver.bitswarm.controllers.AbstractController.run(AbstractController.java:96)
   java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
   java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   java.lang.Thread.run(Unknown Source)



My server.xml file is as follows :

Code: Select all

<serverSettings>
  <socketAddresses>
    <socket address="127.0.0.1" port="9933" type="TCP"/>
    <socket address="127.0.0.1" port="9339" type="TCP"/>
    <socket address="127.0.0.1" port="9933" type="UDP"/>
  </socketAddresses>
  <ipFilter>
    <addressBlackList>
      <string>100.101.102.103</string>
    </addressBlackList>
    <addressWhiteList>
      <string>192.168.0.16</string>
    </addressWhiteList>
    <maxConnectionsPerAddress>9999999</maxConnectionsPerAddress>
  </ipFilter>
  <flashCrossdomainPolicy>
    <useMasterSocketPolicy>true</useMasterSocketPolicy>
    <policyXmlFile>crossdomain.xml</policyXmlFile>
  </flashCrossdomainPolicy>
  <systemControllerThreadPoolSize>1</systemControllerThreadPoolSize>
  <extensionControllerThreadPoolSize>1</extensionControllerThreadPoolSize>
  <systemControllerRequestQueueSize>20000</systemControllerRequestQueueSize>
  <extensionControllerRequestQueueSize>20000</extensionControllerRequestQueueSize>
  <schedulerThreadPoolSize>1</schedulerThreadPoolSize>
  <protocolCompressionThreshold>1024</protocolCompressionThreshold>
  <protocolMode>BINARY</protocolMode>
  <remoteAdmin>
    <administrators>
      <adminUser>
        <login>sfsadmin</login>
        <password>sfsadmin</password>
      </adminUser>
    </administrators>
    <allowedRemoteAddresses>
      <string>127.0.0.1</string>
      <string>192.168.0.7</string>
      <string>10.0.0.1</string>
    </allowedRemoteAddresses>
    <adminTcpPort>9933</adminTcpPort>
  </remoteAdmin>
  <bannedUserManager>
    <isAutoRemove>true</isAutoRemove>
    <isPersistent>true</isPersistent>
    <customPersistenceClass></customPersistenceClass>
  </bannedUserManager>
  <extensionRemoteDebug>true</extensionRemoteDebug>
  <useFriendlyExceptions>false</useFriendlyExceptions>
  <mailer>
    <mailHost>test.mail.com</mailHost>
    <mailUser>foo</mailUser>
    <mailPass>pippo</mailPass>
    <smtpPort>25</smtpPort>
    <workerThreads>1</workerThreads>
  </mailer>
  <webServer>
    <isActive>true</isActive>
    <cfgFile>config/jetty/jetty.xml</cfgFile>
  </webServer>
  <startExtensionFileMonitor>true</startExtensionFileMonitor>
  <useFriendlyLogging>true</useFriendlyLogging>
  <useDebugMode>true</useDebugMode>
  <sessionMaxIdleTime>20</sessionMaxIdleTime>
  <userMaxIdleTime>300</userMaxIdleTime>
</serverSettings>


I have not changed any code in the demo. Nor have I changed anything else on the Server, aside from the above file.
appels
Posts: 464
Joined: 28 Jul 2010, 02:12
Contact:

Postby appels » 18 Mar 2011, 05:01

when you change ports in the server config, you will need to change the demo to connect on those ports.
The demo connects on 9933 TCP & UDP.
There is also a pdf where you downloaded th demo on how to setup the server.
ThomasLund
Posts: 1297
Joined: 14 Mar 2008, 07:52
Location: Sweden

Postby ThomasLund » 18 Mar 2011, 09:45

Definitely looks like you didnt follow the document. Need to copy the extension jar file to the server as described!

/Thomas
Full Control - maker of Unity/C# and Java SFS API and indie games
Follow on twitter: http://twitter.com/thomas_h_lund
Questionairre
Posts: 16
Joined: 07 Mar 2011, 21:08

Postby Questionairre » 18 Mar 2011, 16:36

Alright guys, call me stupid but I can't find the documentation that you are talking about. There is no PDF, or anything similar, in the actual file and I can't find any link to any documentation.

Could you point me in the right direction?
ThomasLund
Posts: 1297
Joined: 14 Mar 2008, 07:52
Location: Sweden

Postby ThomasLund » 19 Mar 2011, 10:57

No worry - you are not the only one who has missed the download.

Its right underneath the download link for the FPS project itself:

http://www.smartfoxserver.com/2X/download.php
Full Control - maker of Unity/C# and Java SFS API and indie games

Follow on twitter: http://twitter.com/thomas_h_lund

Return to “SFS2X C# API”

Who is online

Users browsing this forum: No registered users and 24 guests