I am trying to connect to SmartFoxServer.
I am able to connect to it with default settings. (on local machine)
The problem is it works fine in the FLA.
But when i run the swf it gives an error in the LoaderFactory constructor.
After searching the forum for answers i came across a few things. I was able to resolve the issue by just turning of BlueBox.
My question is can i use BlueBox. If yes how.
As for details, can't give much specifics except that i m just connecting to the server, adding 2 listeners (onConnection and onLogin).
This is the error -
cannot load data from
http://127.0.0.1:8080/BlueBox/HttpBox.do.
at it.gotoandplay.smartfoxserver.http::LoaderFactory()
at it.gotoandplay.smartfoxserver.http::HttpConnection()
at it.gotoandplay.smartfoxserver::SmartFoxClient()
I have seen that there is a bug in the as2 code that you have mentioned in another post. But i am using the as3 version. Is the bug prevalent there.
Most importantly the error appears only in html or swf and not in FLA.
The simulation procedure is simple -
DO NOT run the server
Try to connect through an swf.
The normal connection fails and is followed by an attempt for BlueBox connection.
At this point, FLA gives no issues and works as expected.
But swf/html throws up a security error as given above.
I though it might have something to do with policy files but if no server is available there are no concerns about a policy file ? or am I wrong?
Please help
P.S. Will try to provide a demo swf to simulate the issue
Blue Box giving bug
-
- Posts: 46
- Joined: 28 Nov 2009, 04:30
-
- Posts: 46
- Joined: 28 Nov 2009, 04:30
http://www.filefactory.com/file/a15ac1e ... _Issue.zip
Check this link for the swf to simulate the issue
Details inside
The source code is also provided alongwith the fla.
Check this link for the swf to simulate the issue
Details inside
The source code is also provided alongwith the fla.
-
- Posts: 46
- Joined: 28 Nov 2009, 04:30
All details are provided in the uploaded file.
Also i am having trouble updating version 1.6.6 to version 1.6.7
I have downloaded the update. Can someone help me on how to use the downloaded package.
Should i just replace the api packages.
Also the jar file does not seem to run
Where to run it from? (I don't have much experience with java)
Also i am having trouble updating version 1.6.6 to version 1.6.7
I have downloaded the update. Can someone help me on how to use the downloaded package.
Should i just replace the api packages.
Also the jar file does not seem to run
Where to run it from? (I don't have much experience with java)
-
- Posts: 46
- Joined: 28 Nov 2009, 04:30
Sorry for the delayed response.
I tried the mentioned line on browser.
It gives me a page with following text
BlueBox
v 1.0.5
copyright info.
so i guess that means BlueBox is running fine.
Anything else i need to try.
And still no luck with the update.
Replaced the API files with the new ones. That helped in one case.
But don't know what to do with the jar file.
I tried the mentioned line on browser.
It gives me a page with following text
BlueBox
v 1.0.5
copyright info.
so i guess that means BlueBox is running fine.
Anything else i need to try.
And still no luck with the update.
Replaced the API files with the new ones. That helped in one case.
But don't know what to do with the jar file.
-
- Posts: 46
- Joined: 28 Nov 2009, 04:30
Another observation
The swf is set to "network only access". (required for creating sockets)
So if i am trying to access a bluebox connection on the same machine then it gives a null error (only in swf not in fla).
But when i try the same swf in another locally connected machine, it just hangs on first screen. I have put in a check for connection error and it displays right if smartconnect is false. So i think when the swf is running on another machine, it keeps trying to connect with a bluebox but is never able to detect that the connection cannot be made or am i missing something.
All i want is to detect the fact that bluebox is unable to connect. what should i do?
So if i am trying to access a bluebox connection on the same machine then it gives a null error (only in swf not in fla).
But when i try the same swf in another locally connected machine, it just hangs on first screen. I have put in a check for connection error and it displays right if smartconnect is false. So i think when the swf is running on another machine, it keeps trying to connect with a bluebox but is never able to detect that the connection cannot be made or am i missing something.
All i want is to detect the fact that bluebox is unable to connect. what should i do?
Ok,
let's go in steps.
Please test with your browser the following:
http://xx.xx.xx.xx:8080/BlueBox/HttpBox.do.
where xx.xx.xx.xx is the IP where SFS is running.
Does this work without any problems?
If so it's just a problem with your client, maybe related to the Flash Player security sandbox.
Let me know.
p.s. = as regards the patch you should copy the jar file to {sfs-folder}/Server/lib and restart.
let's go in steps.
Please test with your browser the following:
http://xx.xx.xx.xx:8080/BlueBox/HttpBox.do.
where xx.xx.xx.xx is the IP where SFS is running.
Does this work without any problems?
If so it's just a problem with your client, maybe related to the Flash Player security sandbox.
Let me know.
p.s. = as regards the patch you should copy the jar file to {sfs-folder}/Server/lib and restart.
-
- Posts: 46
- Joined: 28 Nov 2009, 04:30
I replaced the jar file with the one with same name in /Server.
Hope thats ok.
Ya. the above step works fine. And everything so far has been working fine until BlueBox is off. Also the problem appears only when BlueBox is on and server is down.
Another problem. I am unable to read Room variables from client. I use the following.
More details in the Serverside extension development. (as this doesn't seem the right place for it).
Hope thats ok.
Ya. the above step works fine. And everything so far has been working fine until BlueBox is off. Also the problem appears only when BlueBox is on and server is down.
Another problem. I am unable to read Room variables from client. I use the following.
More details in the Serverside extension development. (as this doesn't seem the right place for it).
-
- Posts: 46
- Joined: 28 Nov 2009, 04:30
-
- Posts: 46
- Joined: 28 Nov 2009, 04:30
Ok.
I have a running mmultiplayer application, which works fine at all times.
Now if the server goes down for some reason, any one who tries to connect to the server gets a null error in flash.
After debugging the error i realise that it has something to do with BlueBox.
In essence i want to catch the fact that the server is down and display a page for reconnection attempt.
If Bluebox is turned off, I am using the onConnection Listener to get that connection cannot be made and give the user the option to try again.
This works fine.
But now if i turn on BlueBox, the client is not able to gracefully handle the situation that the server is down. I am not sure how i catch this error because it throws up in the constructor of SmartFoxClient.
To simulate the error, just run the client provided in the zip on a system without the server running.
I have a running mmultiplayer application, which works fine at all times.
Now if the server goes down for some reason, any one who tries to connect to the server gets a null error in flash.
After debugging the error i realise that it has something to do with BlueBox.
In essence i want to catch the fact that the server is down and display a page for reconnection attempt.
If Bluebox is turned off, I am using the onConnection Listener to get that connection cannot be made and give the user the option to try again.
This works fine.
But now if i turn on BlueBox, the client is not able to gracefully handle the situation that the server is down. I am not sure how i catch this error because it throws up in the constructor of SmartFoxClient.
To simulate the error, just run the client provided in the zip on a system without the server running.
Now if the server goes down for some reason, any one who tries to connect to the server gets a null error in flash.
After debugging the error i realise that it has something to do with BlueBox.
If the server is down you should get a connection failed in the onConnection event, from client side.
Try connecting your client to a machine in your network that doesn't run SFS and you'll get that. You can even point the client to an address where no machine is actually running on.
For example if I run the AS3 template provided with SFS 1.6.x I get this:
--> SmartFoxClient API version: 1.6.1
--> Click the CONNECT button to start
--> Connecting...
--> Connection failed!
But now if i turn on BlueBox, the client is not able to gracefully handle the situation that the server is down. I am not sure how i catch this error because it throws up in the constructor of SmartFoxClient.
Sorry I don't understand where you turn the BlueBox on and off. If the server is down the BlueBox can only be off. Maybe you are referring to the smartConnect flag in SmartFoxClient?
Who is online
Users browsing this forum: No registered users and 11 guests