What's Wrong With SmartFoxServer Pro's API?

Need help with SmartFoxServer? You didn't find an answer in our documentation? Please, post your questions here!

Moderators: Lapo, Bax

User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

What's Wrong With SmartFoxServer Pro's API?

Postby coolboy714cp » 21 Mar 2010, 02:33

I think something is wrong with SmartFoxServer Pro, or is it Flash? Everytime I download and install SFS Pro or SFS Basic, I get the same error:

-------------WARNING! API is obsolete-------------

or something like that. How can I fix this error? Im using an old version of Flash, Flash MX 2004. I like it better than CS4. :) Anyway, I have used SFS Pro many times before this error, and it has happened to me before actually. It seems to fix on it's own, but I don't think it will this time.

I have the correct API installed, and everything. I don't know what the problem is.

Someone please tell me how to fix this.

Thanks,
CoolBoy714CP
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 21 Mar 2010, 21:37

Make sure you read the API usage instruction, first:
http://www.smartfoxserver.com/docs/docP ... alling.htm

Also, you probably have older SmartFoxServer API installed via the Adobe/Macromedia Extenion Manager which you can safely uninstall.
Lapo
--
gotoAndPlay()
...addicted to flash games
User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

Postby coolboy714cp » 22 Mar 2010, 00:30

Okay, I will check out the link and follow the instructions. Ill post if it works or not, which it should. :D Thanks Lapo!

~CoolBoy714CP
User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

Postby coolboy714cp » 22 Mar 2010, 00:39

When I tried what you said to do in that link, I got a total of 6 errors. They are as followed:

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Flash API\Actionscript 2.0\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 1555: There is no method with the name 'Delegate'.
httpConnection = new HttpConnection(Delegate.create(this, handleHttpConnect), Delegate.create(this, handleHttpClose), Delegate.create(this, handleHttpData), Delegate.create(this, handleHttpError))

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Flash API\Actionscript 2.0\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 1702: There is no method with the name 'Delegate'.
configLoader.onLoad = Delegate.create( this, onConfigLoadSucceeded )

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Flash API\Actionscript 2.0\it\gotoandplay\smartfoxserver\SmartFoxClient.as: There is no property with the name 'ex'.

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Flash API\Actionscript 2.0\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 2898: There is no property with the name 'ex'.
trace(ex.name + " : " + ex.message + " : " + ex.at + " : " + ex.text)

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Flash API\Actionscript 2.0\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 4702: There is no method with the name 'Delegate'.
socketConnectionTimeoutThread = setInterval( Delegate.create(this, socketTimeoutHandler), socketConnectionTimeout )

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Flash API\Actionscript 2.0\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 5022: There is no method with the name 'Delegate'.
this.pollingThread = this.pollingDelayFn( Delegate.create( this, this.handleDelayedPoll ), this._httpPollSpeed )

Total ActionScript Errors: 6 Reported Errors: 6

What's wrong with it now?

Please reply asap.

Thanks,
CoolBoy714CP
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 22 Mar 2010, 18:18

The Delegate class is part of the Flash packages --> mx.utils.Delegate
It seems very strange that your compiler is not able to find the class. I would suspect your current Flash installation is corrupt. Or maybe it's just too old.
You said you use MX2004. Make sure that you have the 2nd update for tha version installed. If I remember correctly it was version 7.2
I cannot guarantee it will work with that but at least you can try.
Lapo

--

gotoAndPlay()

...addicted to flash games
User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

Postby coolboy714cp » 22 Mar 2010, 21:44

I will try to reinstall Flash. It should work because I used to have Pro version and not have any errors. So thanks for all your help! :D

~CoolBoy714CP
User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

Postby coolboy714cp » 23 Mar 2010, 00:21

Well, I uninstalled, then reinstalled Flash, and that didn't do anything. So, I uninstalled and reinstalled SmartFoxServer and got these errors: (in AvatarChat.fla)

**Error** Scene=Scene 1, layer={ code }, frame=9:Line 60: The class 'SmartFoxClient' could not be loaded.
var smartfox:SmartFoxClient = new SmartFoxClient()

**Error** Scene=Scene 1, layer={ code }, frame=16:Line 136: The class 'User' could not be loaded.
var user:User = userList[i]

**Error** Scene=Scene 1, layer={ code }, frame=16:Line 235: The class 'User' could not be loaded.
smartfox.onUserVariablesUpdate = function(user:User)

**Error** Scene=Scene 1, layer={ code }, frame=16:Line 264: The class 'Room' could not be loaded.
smartfox.onUserCountChange = function(roomObj:Room)

**Error** Scene=Scene 1, layer={ code }, frame=16:Line 274: The class 'User' could not be loaded.
smartfox.onPublicMessage = function(msg:String, user:User)

**Error** Scene=Scene 1, layer={ code }, frame=16:Line 294: The class 'User' could not be loaded.
smartfox.onAdminMessage = function(msg:String, user:User)

**Error** Scene=Scene 1, layer={ code }, frame=16:Line 483: The class 'Room' could not be loaded.
var room:Room = smartfox.roomList[roomId]

Total ActionScript Errors: 7 Reported Errors: 7


:(

Any help would be appreciated.

Thanks,
Cool Boy 714
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 23 Mar 2010, 07:40

It's the same problem as before:
Make sure you read the API usage instruction, first:
http://www.smartfoxserver.com/docs/docP ... alling.htm
Lapo

--

gotoAndPlay()

...addicted to flash games
User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

Postby coolboy714cp » 23 Mar 2010, 21:41

Thanks again Lapo. Ill try it out later. I got baseball practice now. Cya!

~CoolBoy714CP
User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

Postby coolboy714cp » 24 Mar 2010, 22:58

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Examples\AS2\01_simpleConnect\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 1555: There is no method with the name 'Delegate'.
httpConnection = new HttpConnection(Delegate.create(this, handleHttpConnect), Delegate.create(this, handleHttpClose), Delegate.create(this, handleHttpData), Delegate.create(this, handleHttpError))

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Examples\AS2\01_simpleConnect\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 1702: There is no method with the name 'Delegate'.
configLoader.onLoad = Delegate.create( this, onConfigLoadSucceeded )

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Examples\AS2\01_simpleConnect\it\gotoandplay\smartfoxserver\SmartFoxClient.as: There is no property with the name 'ex'.

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Examples\AS2\01_simpleConnect\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 2898: There is no property with the name 'ex'.
trace(ex.name + " : " + ex.message + " : " + ex.at + " : " + ex.text)

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Examples\AS2\01_simpleConnect\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 4702: There is no method with the name 'Delegate'.
socketConnectionTimeoutThread = setInterval( Delegate.create(this, socketTimeoutHandler), socketConnectionTimeout )

**Error** C:\Program Files\SmartFoxServerPRO_1.6.6\Examples\AS2\01_simpleConnect\it\gotoandplay\smartfoxserver\SmartFoxClient.as: Line 5022: There is no method with the name 'Delegate'.
this.pollingThread = this.pollingDelayFn( Delegate.create( this, this.handleDelayedPoll ), this._httpPollSpeed )

Total ActionScript Errors: 6 Reported Errors: 6



Ive done everything youve said, and it still comes up with the same errors above. :( Is it because my Flash is too old?

Please reply asap again.

Thanks,
CoolBoy714CP
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 24 Mar 2010, 23:37

Yes, the problem is with your Flash.
I highly recommend to use Flash 8 at least.
Lapo

--

gotoAndPlay()

...addicted to flash games
User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

Postby coolboy714cp » 25 Mar 2010, 22:04

Okay, Ill use CS4. If I installed Flash MX2004 on a different computer, do you think it would work? Is it even a possibility of it working with Flash MX2004?

Thanks,
CoolBoy714CP
User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

Postby coolboy714cp » 27 Mar 2010, 03:58

I'm now using Flash CS4, and there is now only one error... In the SmartFoxClient.as file. It's deals with line 511 in it. I'm in version 1.6.6.

Please help me with this if you can. :)

Also, tell me if you need the exact output error.

Thanks,
CoolBoy714CP
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 27 Mar 2010, 12:10

Please do report the version of the API (which is not 1.6.6, the API have their own version, see the getVersion() method)
and the error message

thanks
Lapo

--

gotoAndPlay()

...addicted to flash games
User avatar
coolboy714cp
Posts: 323
Joined: 06 Feb 2010, 02:45
Contact:

Postby coolboy714cp » 27 Mar 2010, 17:47

Flash Components Version
6.0_r24
03.07.02

:)

Thanks,
CoolBoy714CP

Return to “SmartFoxServer 1.x Discussions and Help”

Who is online

Users browsing this forum: No registered users and 60 guests