Best performance for lacewing server

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • Hey everyone. I'm using lacewing to run a server for a SWF/flash game I'm building and I was wondering how I can achieve best performance for it.

    I heard the best way to do a bigger server is to split it up into different functions (i.e. a login server, world server, mob server, etc). I have the server set up that way.

    One more important note is that (unless I'm doing something wrong) I've discovered that only one server application can use lacewing. For example if I open a login server and host lacewing, it's all good. But if I then try to host a world server on the same computer, the server never opens.

    I got around this by creating a main server that has the lacewing extension, and this server is responsible for all sending and receiving. But that's all it does. The rest of the work is routed to the other servers (login, world, mob) via the shared data object.

    So for example when the user opens his client app and tries to log in this is what happens...
    a. the main server receives the player's request through lacewing
    b. the main server routes the request to the login server
    c. the login server interprets this request
    d. the response is routed back to the main server
    e. the main server forwards the response to the client and logs him in to lacewing

    I handle all of the routing by using the shared data object.

    So my question is....
    1. Is there a better way to split my server into smaller parts so that I don't have to have so much inefficiency with the routing?
    2. Can I somehow host 3 separate servers instead of only hosting one and routing all traffic through that one server?
    3. For the most part this system seems to be okay. However, I'm starting to get worried because I'm going to be working on the mob server soon. The mob server could potentially have hundreds of mobs and these positions would need to be sent to players every few seconds. How can I even route that much data between applications? The shared data object only holds 2048 bytes of data....


    Thanks so much, sorry for so much text.

  • all those steps can be condensed in to

    Player logs in to lacewing.

    Can you not create a log in system that uses a database instead? Which the player would log in to and then receve the ip of the main server and log in to that?
    Just on mobile so i cant check, i would imagine this would be doable.

    8 bytes per enemy for each position update so try to keep the enemys below 200 ;)

  • Thanks Scilya151. I tried your suggestion originally but I still cannot have multiple servers ALL running lacewing, as I said only one app can run lacewing at a time. The reason for this I'm pretty sure is that lacewing for flash requires port 843 or whatever, and you cannot change that.

    But anyway, if you figure out a solution to that please let me know.

    Also, I was going to send probably 5 bytes for enemies: a short for X, a short for Y, and a byte for direction.

    So my next question is.... if my main server runs lacewing, and my mob server simply handles mobs (no lacewing) then the mob server needs to communicate with the main server. What's the best way to do this?
    Some ideas:
    -shared data obj
    -ini file
    -text file
    -database
    -any other ideas?

  • Do you need different servers or will channels work fine?
    It would be much easier to do channels, unless you want the the login server to be located on a different computer than the world server etc.
    Since you are using Shared data object, I guess you are planning to run all of the servers on one computer?
    Then using channels instead is a much better option

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!