MCPcopy Create free account
hub / github.com/TASEmulators/fceux / gui_line

Function gui_line

src/lua-engine.cpp:4018–4034  ·  view source on GitHub ↗

gui.line(x1,y1,x2,y2,color,skipFirst)

Source from the content-addressed store, hash-verified

4016
4017// gui.line(x1,y1,x2,y2,color,skipFirst)
4018static int gui_line(lua_State *L) {
4019
4020 int x1,y1,x2,y2;
4021 uint32 color;
4022 x1 = luaL_checkinteger(L,1);
4023 y1 = luaL_checkinteger(L,2);
4024 x2 = luaL_checkinteger(L,3);
4025 y2 = luaL_checkinteger(L,4);
4026 color = gui_optcolour(L,5,LUA_BUILD_PIXEL(255, 255, 255, 255));
4027 int skipFirst = lua_toboolean(L,6);
4028
4029 gui_prepare();
4030
4031 gui_drawline_internal(x2, y2, x1, y1, !skipFirst, color);
4032
4033 return 0;
4034}
4035
4036// gui.box(x1, y1, x2, y2, fillcolor, outlinecolor)
4037static int gui_box(lua_State *L) {

Callers

nothing calls this directly

Calls 5

luaL_checkintegerFunction · 0.85
gui_optcolourFunction · 0.85
lua_tobooleanFunction · 0.85
gui_prepareFunction · 0.85
gui_drawline_internalFunction · 0.85

Tested by

no test coverage detected