Ejemplo n.º 1
0
int w_CircleShape_setRadius(lua_State *L)
{
	CircleShape *c = luax_checkcircleshape(L, 1);
	float r = (float)luaL_checknumber(L, 2);
	c->setRadius(r);
	return 0;
}
Ejemplo n.º 2
0
int w_CircleShape_getPoint(lua_State *L)
{
	CircleShape *c = luax_checkcircleshape(L, 1);
	float x, y;
	c->getPoint(x, y);
	lua_pushnumber(L, x);
	lua_pushnumber(L, y);
	return 2;
}
Ejemplo n.º 3
0
int w_CircleShape_getRadius(lua_State *L)
{
	CircleShape *c = luax_checkcircleshape(L, 1);
	lua_pushnumber(L, c->getRadius());
	return 1;
}
Ejemplo n.º 4
0
int w_CircleShape_setPoint(lua_State *L)
{
	CircleShape *c = luax_checkcircleshape(L, 1);
	c->setPoint((float) luaL_checknumber(L, 2), (float) luaL_checknumber(L, 3));
	return 0;
}