Page 1 of 1

On Connection callback got: False (error : <>) for uni

Posted: 16 Dec 2010, 03:39
by netstabber
HI
MY SFS sometimes print
"On Connection callback got: False (error : <>)"

i don't know why ?In sfs1.6 I never have this error

In sfs2X when I use FPS DEMO sometime On Connection sometime false
if I edit new sence it always have this error
Now I Let my unity project 3.0 update 3.1 it have the error when 3.0 have true I can know why ?! please help me

Posted: 16 Dec 2010, 06:37
by ThomasLund
If its true - then good!

If false, then your connection attempt failed.

Code: Select all

   public void OnConnection(BaseEvent evt) {
      bool success = (bool)evt.Params["success"];
      string error = (string)evt.Params["error"];
      
      Debug.Log("On Connection callback got: " + success + " (error : <" + error + ">)");


But there is a bug here - will be fixed in next release. the error parameter is not called "error", but "errorMessage". So try and repalce the above with

Code: Select all

   public void OnConnection(BaseEvent evt) {
      bool success = (bool)evt.Params["success"];
      string error = (string)evt.Params["errorMessage"];
      
      Debug.Log("On Connection callback got: " + success + " (error : <" + error + ">)");


and see what it writes

/Thomas