using openspace and red box

Post here your questions about the OpenSpace 2.x or notify bugs and suggestions.

Moderators: Lapo, Bax

kuzniz
Posts: 19
Joined: 05 Jan 2012, 07:21

using openspace and red box

Postby kuzniz » 13 Apr 2012, 16:55

Hello,

How do I use the openspace and the redbox in the same application ( using the same zone) ?

I have notice that in SFS2X we can use only one extention

regards

Shachar
User avatar
Bax
Site Admin
Posts: 4390
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Re: using openspace and red box

Postby Bax » 18 Apr 2012, 09:50

This is not possible out-of-the-box. As you said, you can't have two Extensions attached to a Zone.
What you can do is get the RedBox Extension source code and port its methods to your custom Extension which, also, extends the OpenSpace Extension.
Paolo Bax
The SmartFoxServer Team
kuzniz
Posts: 19
Joined: 05 Jan 2012, 07:21

Re: using openspace and red box

Postby kuzniz » 09 Mar 2014, 18:51

can you put here please a sample code how to do it ?
User avatar
Bax
Site Admin
Posts: 4390
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Re: using openspace and red box

Postby Bax » 11 Mar 2014, 08:20

1) Create an OpenSpace Extension as described in the documentation (SFS2X or SFS Pro).
2) Open the RedBox server-side source code and copy all the classes in your project, except the RedBoxExtension.java file.
3) Open the RedBoxExtension.java file and copy all its methods and properties to the Extension you created before (step 1). Just pay attention to the init method. In fact you will need to merge it with the _init method you are supposed to create in the OpenSpace Extension.
Hope this helps.
Paolo Bax
The SmartFoxServer Team

Return to “OpenSpace v2 discussions and help”

Who is online

Users browsing this forum: Bing [Bot] and 3 guests