summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjacob1 <jfu614@gmail.com>2012-08-08 01:52:45 (GMT)
committer jacksonmj <mj-pt@jacksonmj.co.uk>2012-08-09 20:15:56 (GMT)
commitf568bf21355d6845bc32869a2a8af052d08f5790 (patch)
treebbad279399b5cd78f53c797ddc3fd4e6d31c435b
parent9bb4fbce3af8fe8b3e1e3aa81921f9e9ec63975b (diff)
downloadpowder-f568bf21355d6845bc32869a2a8af052d08f5790.zip
powder-f568bf21355d6845bc32869a2a8af052d08f5790.tar.gz
actually add dcolor getting, implement tpt.display_mode
-rw-r--r--src/luaconsole.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/luaconsole.c b/src/luaconsole.c
index 85dfb6b..13cdc3b 100644
--- a/src/luaconsole.c
+++ b/src/luaconsole.c
@@ -1478,7 +1478,7 @@ int luatpt_get_property(lua_State* l)
lua_pushnumber(l, parts[i].y);
return 1;
}
- if (strcmp(prop,"dcolour")==0){
+ if (strcmp(prop,"dcolour")==0 || strcmp(prop,"dcolor")==0){
lua_pushinteger(l, parts[i].dcolour);
return 1;
}
@@ -1950,7 +1950,9 @@ int luatpt_heat(lua_State* l)
}
int luatpt_cmode_set(lua_State* l)
{
- return luaL_error(l, "Not implemented");
+ int cmode = luaL_optint(l, 1, CM_FIRE);
+ set_cmode(cmode);
+ return 0;
}
int luatpt_setfire(lua_State* l)
{