对象构造函数
| 1784 | |
| 1785 | // 对象构造函数 |
| 1786 | static int NewColor(lua_State* L)LNOEXCEPT |
| 1787 | { |
| 1788 | fcyColor c; |
| 1789 | if (lua_gettop(L) == 1) |
| 1790 | c.argb = luaL_checkinteger(L, 1); |
| 1791 | else |
| 1792 | { |
| 1793 | c = fcyColor( |
| 1794 | luaL_checkinteger(L, 1), |
| 1795 | luaL_checkinteger(L, 2), |
| 1796 | luaL_checkinteger(L, 3), |
| 1797 | luaL_checkinteger(L, 4) |
| 1798 | ); |
| 1799 | } |
| 1800 | *ColorWrapper::CreateAndPush(L) = c; |
| 1801 | return 1; |
| 1802 | } |
| 1803 | static int NewRand(lua_State* L)LNOEXCEPT |
| 1804 | { |
| 1805 | RandomizerWrapper::CreateAndPush(L); |
nothing calls this directly
no outgoing calls
no test coverage detected