Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/lua/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Lua 如何在corona SDK的display.newCircle()中添加图像_Lua_Coronasdk - Fatal编程技术网

Lua 如何在corona SDK的display.newCircle()中添加图像

Lua 如何在corona SDK的display.newCircle()中添加图像,lua,coronasdk,Lua,Coronasdk,我想用自定义图像更改圆的颜色。有可能吗?是的,有可能。试一试 -- Create a vector rectangle local circle = display.newCircle( 200, 200, 300 ) -- Set the fill (paint) to use the bitmap image local paint = { type = "image", filename = "texture1.png" } -- Fill the circle cir

我想用自定义图像更改圆的颜色。有可能吗?

是的,有可能。试一试

-- Create a vector rectangle
local circle = display.newCircle( 200, 200, 300 )

-- Set the fill (paint) to use the bitmap image
local paint = {
    type = "image",
    filename = "texture1.png"
}

-- Fill the circle
circle.fill = paint
您可以在中找到更多信息