OpCustom in Flash SDK

Options
hanuman
hanuman
edited January 2015 in Flash (deprecated)
Can't find how to send CustomOperation(OpCustom in .NET SDK) to server? And generally is Flash SDK works with custom Photon Server, written from scratch(not Lite or LiteLobby)?

Comments

  • vadim
    Options
    I think you need PhotonCore object with raiseCustomEvent or raiseCustomEventWithCode method and CustomEvent listener. Please refer DemoChat and DemoScribble for usage example.
    Just realized that PhotonCore is not in documentation yet. To be fixed.
  • hanuman
    Options
    Hi vadim,
    thanks for reply.

    I have found out that I need to call sendOperation method of PhotonCore. It works but i can't pass any parameters to server with dataObjects:Array method parameter. It is not documented and no matter what i try to pass in this array i have 0 parameters on server. Please help me - what pattern of parameters i need to pass in this method?
  • vadim
    Options
    Why raiseCustomEvent/raiseCustomEventWithCode does not work for you?

    If you really need sendOperation, pack parameters in array like this:
    var op: Array = [];
    op.push(ParamCode1);
    op.push(paramValue1);
    op.push(ParamCode2);
    op.push(paramValue2);
    ...