简体   繁体   中英

Did anyone try to use websockets with Shiva3D?

Did anyone try to use websockets with Shiva3D ? I want to create communication between client and server and I think it is easier to use websockets than tcp, because overhead is not so big. Is there already library for websockets or I can use c++ and bind to lua. I am totally new to lua.

Shiva3D does not let you 'require' external modules (probably security risk). Otherwise you could use lua-websockets on github, find it easily with google. It is mentioned in another SO post: LUA Script - web socket communication .

You can write c++ plugin, which is then accessible from Lua scripts. THis requires you have a Verisign certificate to sign the plugin. So if you have a favorite c++ library for websockets (wt, websockets++, etc) you can expose that to your Lua scripts.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM