error when initilaize appwarp and app42api corona both in my game

0 votes
I am using APP42API - Corona and AppWarp both in one game with real turn based multiplayer. here is error create when initialize both AppWarp and APP42API. Error is connection failed!!!! See below code which i have added in main.lua. appWarpClient = require "AppWarp.WarpClient" appWarpClient.initialize(API_KEY, SECRET_KEY) local App42API = require("App42-Lua-API.App42API") local App42Log = require("App42-Lua-API.App42Log") App42Log:setDebug(true) App42API:initialize(API_KEY,SECRET_KEY) Question2: How can I get opponent player score ,name and photo.?
asked Mar 2, 2015 in AppWarp by panarasavan (11 points)

1 Answer

0 votes
Hi,

Are you using same API key and Secret Key for initialising both App42 and AppWarp?
You need to create two different apps in AppHQ. Create one app of type App42 and other of type AppWarp. Then use different keys for initialising both

Thanks
answered Mar 3, 2015 by Suyash Mohan (900 points)
Hello,

How can I get opponent player score ,name and photo.?

thanks.
Hi,

AppWarp is a real time communication system. It can exchange any information you want in real time. But it does not store any data permanently like score, name and photo. You can use App42 for this. App42 has services like Leaderboard, User Managment, Storage, etc that can be used to store such data.

Thanks
Hello,

I using below initialize in main.lua.

local App42API = require("App42-Lua-API.App42API")
local App42Log = require("App42-Lua-API.App42Log")
App42Log:setDebug(true)
App42API:initialize(API_KEY_APP42,SECRET_KEY_APP42)

_W = display.contentWidth
_H = display.contentHeight

-- create global warp client and initialize it
appWarpClient = require "AppWarp.WarpClient"
appWarpClient.initialize(API_KEY, SECRET_KEY)


When i use App42Api like sign up or any app42api then coming error like below:

Runtime error
e:\dropbox\linewarv1\AppWarp\WarpUtilities.lua:200: attempt to concatenate local 'user' (a nil value)
stack traceback:
    e:\dropbox\linewarv1\AppWarp\WarpUtilities.lua:200: in function 'calculateSignature'
    e:\dropbox\linewarv1\App42-Lua-API\Util.lua:134: in function 'sign'
    e:\dropbox\linewarv1\App42-Lua-API\UserService.lua:53: in function 'createUser'
    e:\dropbox\linewarv1\signUp.lua:162: in function <e:\dropbox\linewarv1\signUp.lua:150>
    ?: in function <?:221>
Hello ,

Can you give me answer of this question?


I using below initialize in main.lua.

local App42API = require("App42-Lua-API.App42API")
local App42Log = require("App42-Lua-API.App42Log")
App42Log:setDebug(true)
App42API:initialize(API_KEY_APP42,SECRET_KEY_APP42)

_W = display.contentWidth
_H = display.contentHeight

-- create global warp client and initialize it
appWarpClient = require "AppWarp.WarpClient"
appWarpClient.initialize(API_KEY, SECRET_KEY)


When i use App42Api like sign up or any app42api then coming error like below:

Runtime error
e:\dropbox\linewarv1\AppWarp\WarpUtilities.lua:200: attempt to concatenate local 'user' (a nil value)
stack traceback:
    e:\dropbox\linewarv1\AppWarp\WarpUtilities.lua:200: in function 'calculateSignature'
    e:\dropbox\linewarv1\App42-Lua-API\Util.lua:134: in function 'sign'
    e:\dropbox\linewarv1\App42-Lua-API\UserService.lua:53: in function 'createUser'
    e:\dropbox\linewarv1\signUp.lua:162: in function <e:\dropbox\linewarv1\signUp.lua:150>
    ?: in function <?:221>
Download Widgets
Welcome to ShepHertz Product line forum, where you can ask questions and receive answers from the community. You can also reach out to us on support@shephertz.com
...