Rework ansi file display in lua
This commit is contained in:
parent
78f21e9740
commit
ced7a4e2cf
@ -44,11 +44,13 @@ int l_bbsRChar(lua_State *L) {
|
|||||||
int l_bbsDisplayAnsiPause(lua_State *L) {
|
int l_bbsDisplayAnsiPause(lua_State *L) {
|
||||||
char *str = (char *)lua_tostring(L, -1);
|
char *str = (char *)lua_tostring(L, -1);
|
||||||
char buffer[256];
|
char buffer[256];
|
||||||
|
|
||||||
sprintf(buffer, "%s/%s.ans", conf.ansi_path, str);
|
|
||||||
|
|
||||||
s_displayansi_pause(buffer, 1);
|
if (strchr(str, '/') == NULL) {
|
||||||
|
sprintf(buffer, "%s/%s.ans", conf.ansi_path, str);
|
||||||
|
s_displayansi_pause(buffer, 1);
|
||||||
|
} else {
|
||||||
|
s_displayansi_pause(str, 1);
|
||||||
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user