ParaWorld_Apps

a central place per application for selling and buying tradable items.

Title a central place per application for selling and buying tradable items.
Author(s) LiXizhi锛孋YF
Date 2008/1/21
File script/kids/3DMapSystemApp/API/paraworld.apps.lua

Description

TIP Sample Code

NPL.load("(gl)script/kids/3DMapSystemApp/API/ParaworldAPI.lua");

Member Functions

paraworld.apps.GetUserApp

create class commonlib.setfield("paraworld.apps", {});

syntax

function paraworld.apps.GetUserApp() 

paraworld.apps.AddApp

[[

if(operation = "add") //鏂板涓€涓狽PLApp锛岃繑鍥炶NPLApp鐨凨ey

msg = {

"operation" = ["add"],(*)

"sessionKey" = string,(*)

["appKey"] = string, 鎸囧畾姝ゅ簲鐢ㄧ▼搴忓敮涓€閿€傚鏋滄病鏈夋寚瀹氭鍊硷紝鍒欑郴缁熶細闅忔満鍒嗛厤涓€涓?

"nplAppName" = string,(*)

"userID" = string,(*)

"userName" = string,

"desc" = string,

"downloadURL" = string,(*)

"size" = int (*)

}

if(operation = "add")

{

msg =

{

isSuccess = boolean //鎿嶄綔鏄惁鎴愬姛

appKey = string

[ info ] = string 鍙戠敓寮傚父鏃舵湁姝よ妭鐐?

}

}

]]

syntax

function paraworld.apps.AddApp() 

paraworld.apps.RemoveApp

syntax

function paraworld.apps.RemoveApp() 

paraworld.apps.GetDirectory

[[

if(operation = "get") //杩斿洖鎵€鏈夊凡寮€鍙戝畬鎴愮殑搴旂敤绋嬪簭锛圢PLApp锛?鎴?渚濅富閿彇寰椾竴涓簲鐢ㄧ▼搴忕殑淇℃伅锛圢PLApp锛?

msg = {

"operation" = ["get"],(*)

"sessionKey" = string,(*)

"appID" = string //濡傛灉鏈夊€硷紝琛ㄧず鈥滀緷涓婚敭鍙栧緱涓€涓簲鐢ㄧ▼搴忕殑淇℃伅锛圢PLApp锛夆€濓紝鍚﹀垯锛屸€滆繑鍥炴墍鏈夊凡寮€鍙戝畬鎴愮殑搴旂敤绋嬪簭锛圢PLApp锛夆€?

}

if(operation = "get")

{

if(appID is null)

msg =

{

apps[list]

{

nplAppID(string)

nplAppName(string)

userID(string)

userName(string)

desc(string)

downloadURL(string)

size(int)

approved(boolean)

showInDirectory(boolean)

finished(boolean)

installedCount(int)

}

}

]]

syntax

function paraworld.apps.GetDirectory() 
Topic revision: r1 - 2008-02-29 - LiXizhi
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback