local s = selection.room(); */
| 429 | |
| 430 | /* local s = selection.room(); */ |
| 431 | staticfn int |
| 432 | l_selection_room(lua_State *L) |
| 433 | { |
| 434 | struct selectionvar *sel; |
| 435 | int argc = lua_gettop(L); |
| 436 | struct mkroom *croom = NULL; |
| 437 | |
| 438 | if (argc == 1) { |
| 439 | int i = luaL_checkinteger(L, -1); |
| 440 | |
| 441 | croom = (i >= 0 && i < svn.nroom) ? &svr.rooms[i] : NULL; |
| 442 | } |
| 443 | |
| 444 | sel = selection_from_mkroom(croom); |
| 445 | |
| 446 | l_selection_push_copy(L, sel); |
| 447 | selection_free(sel, TRUE); |
| 448 | |
| 449 | return 1; |
| 450 | } |
| 451 | |
| 452 | /* local rect = sel:bounds(); */ |
| 453 | staticfn int |
nothing calls this directly
no test coverage detected