Forums

OverviewV-Play 1 Support › GameNetwork Error

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #7085

    wimmer92

    Hy everybody !,

     

    I’ve got a problem with the WebStorage.

    Want i want to do basically is to transfer all my data from an existing Storage into a new WebStore and then delete the old value on the Storage.

    Like this:

        Storage
        {
            id:localStorage
        }
    
        WebStorage
        {
            id:webStorage
        }
    
        property alias storage: webStorage
    
        function initWebstorage(key)
        {
            var localData = localStorage.getValue(key);
    
            if(localData !== undefined)
            {
                webStorage.setValue(key,localData);
                localStorage.clearValue(key);
            }
    
           var webData = webStorage.getValue(key);
    
            return webData;
        }
    
        property variant firstTimeCompleted : initWebstorage("firstTimeCompleted");
        onFirstTimeCompletedChanged:
        {
            webStorage.setValue("firstTimeCompleted", firstTimeCompleted);
        }

     

    By doing this for the very first time, when there is no webstorage for the user (clearAllUserDataAtStartup of the VPlayGameNetwork is set to true) i got the following error:

    ERROR: VPGN: error received from GameNetwork Server!

    request that failed: {“action”:”set_user_data”,”callback”:{“length”:2,”name”:”handleResponse”},”ignoreToken”:false,”key”:”defaultDBName_firstTimeCompleted”,”requestTimeStamp”:1394199765760,”timestamp”:1,”token”:”QWIGR0wQFmaN1OJfGrmrbokJsblYoY9″}

    response with error info: {“data”:{“code”:101,”message”:”parameter value missing”},”status”:”error”}

     

    …also a dialog with the following message occurs:

    GameNetwork Error

    An error with code 101 occured when connecting to the GameNetwork Server. Please try again later.

    Error Messsage: parameter value missing

     

    Can anybody tell me what’s the problem ? I’m on the actual daily build.

     

    Greets,

    Thomas

    #7086

    wimmer92

    Edit:

     

    Fixed the problem by doing the initialization of my properties in the WebStorage onCompleted:

     

     WebStorage
        {
            id:webStorage
            Component.onCompleted:
            {
                firstTimeCompleted = initWebstorage("firstTimeCompleted");
        }
    }

     

    Greets,

    Thomas

Viewing 2 posts - 1 through 2 (of 2 total)

RSS feed for this thread

You must be logged in to reply to this topic.

Voted #1 for:

  • Easiest to learn
  • Most time saving
  • Best support

Develop Cross-Platform Apps and Games 50% Faster!

  • Voted the best supported, most time-saving and easiest to learn cross-platform development tool
  • Based on the Qt framework, with native performance and appearance on all platforms including iOS and Android
  • Offers a variety of plugins to monetize, analyze and engage users
FREE!
create apps
create games
cross platform
native performance
3rd party services
game network
multiplayer
level editor
easiest to learn
biggest time saving
best support