Lacewing - Fatal Crashes

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.
  • The Flash version of Lacewing is a bit of a mess. It has a number of issues that cause a Flash swf to completely lock up, which is pretty disastrous. I don't even think the errors are that hard to fix, just involving a check for a null value every now and then.

    The following errors are the ones that pop up when I'm running in the debug version of Flash, and only when I've got somewhere around 18 or so connections.

    This is the most common one:

    Code
    TypeError: Error #1009: Cannot access a property or method of a null object reference. 
        at lacewing::Client/handleMessage()
        at lacewing::Client/process()
        at lacewing::Client/onSocketReceive()


    Occasionally I also get these:

    Code
    Error: Error #2030: End of file was encountered.
        at flash.utils::ByteArray/readBytes()
        at lacewing::Client/readBinary()
        at lacewing::Client/handleMessage()
        at lacewing::Client/process()
        at lacewing::Client/process()
        at lacewing::Client/process()
        at lacewing::Client/process()
        at lacewing::Client/onSocketReceive()
    Code
    TypeError: Error #1009: Cannot access a property or method of a null object reference.
        at lacewing::Client/getPeer()
        at lacewing::Client/handleMessage()
        at lacewing::Client/process()
        at lacewing::Client/process()
        at lacewing::Client/process()
        at lacewing::Client/process()
        at lacewing::Client/onSocketReceive()

    I'm not sure what kind of ritual one must perform to get a fix for Lacewing, but Mathias and Looki (who aren't even the authors!) have patched the flipping thing before, so I'm posting this here with the hope that my last few months of work haven't been completely wasted.

    Making games at Please login to see this link..
    Please login to see this link. on Twitter.

  • Hey Dizzy,

    have you this version from lacewing?
    Please login to see this link.

    Interessting bug.. I hope it comes a lacewing-patch for flash very soon (I'm working on a lacewing-flashgame too) :-/

    Please login to see this link.

  • I'm using that version with an extra fix or three from Looki. Please login to see this link.

    Oooh, but I'm now realising that it's a very similar problem to the one Mathias was fixing last time, with numbers being read as much, much higher than they should be. As soon as the number of connections goes past 16, everything crashes, because 2^17 > 65535, the capacity for a short. That would explain the various stack overflows, null values when it comes to player ids, etc.

    Making games at Please login to see this link..
    Please login to see this link. on Twitter.

  • The issues seem to be with server-sent player left channel and player joined channel messages. So one way to get around the catastrophic crashing errors is to just not use channels in your app. For people who code their own servers with pyLacewing or something else, like me, this isn't a massive problem, since we can use the server to relay a clients messages to other clients ourselves.

    Just to help out other Lacewing-Flash developers, I'll spell out the two choices you have: 1) Use channels, but you can only have a maximum of 16 players in a channel. Any one joining or leaving after that will cause every other player's app (or sometimes even browser tab) to crash. 2) Don't use channels, but you'll have to write your own server to relay messages.

    Making games at Please login to see this link..
    Please login to see this link. on Twitter.

Participate now!

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