内容简介:Actix-lua : 适用于Actix的安全Lua脚本编写环境 新特性: Lua actor : 使用LuaActor用于将Lua脚本actor模型集成到您的系统。 在actor模型中,actor用消息进行通信。LuaMessage是LuaActor唯一接受的消息类型: Lu...
Actix-lua : 适用于Actix的安全 Lua 脚本编写环境
新特性:
Lua actor : 使用
LuaActor用于将Lua脚本actor模型集成到您的系统。在actor模型中,actor用消息进行通信。
LuaMessage是LuaActor唯一接受的消息类型:LuaMessage可以使用原始类型LuaMessage::from()转换。Lua类型(例如 number, table等)将自动转换为
LuaMessage。
extern crate actix_lua;
use actix_lua::{LuaActorBuilder, LuaMessage};
fn main () {
let addr = LuaActorBuilder::new()
.on_handle_with_lua(r#"return ctx.msg + 42"#)
.build()
.unwrap()
.start();
let res = addr.send(LuaMessage:from(100));
// return: 142
}【声明】文章转载自:开源中国社区 [http://www.oschina.net]
以上所述就是小编给大家介绍的《Actix-lua 0.3.5/0.4 发布,集成 Lua 与 Actix 游戏开发利器》,希望对大家有所帮助,如果大家有任何疑问请给我留言,小编会及时回复大家的。在此也非常感谢大家对 码农网 的支持!
猜你喜欢:- 码云 Jenkins 插件重构出炉 —— 码云的持续集成利器
- Actix-lua 0.3.5/0.4 发布,集成 Lua 与 Actix 游戏开发利器
- JMockit:单元测试利器
- 利器+
- Go 调试利器:delve
- go调试利器-delve
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
The Everything Store
Brad Stone / Little, Brown and Company / 2013-10-22 / USD 28.00
The definitive story of Amazon.com, one of the most successful companies in the world, and of its driven, brilliant founder, Jeff Bezos. Amazon.com started off delivering books through the mail. Bu......一起来看看 《The Everything Store》 这本书的介绍吧!