- 论坛徽章:
- 0
|
回复 6# 七夜
我也很喜欢lua。其实其他语言号称的优雅都是自吹自擂的,lua的语言那才叫真正的优雅。我们最近在用lua的一个移动开发框架做手机应用,彻底被其代码折服。- display.setStatusBar( display.HiddenStatusBar ) -- hide status bar
- -- Displays App title
- title = display.newText( "Accelerator / Shake", 0, 20, "Verdana-Bold", 20 )
- title.x = display.contentWidth/2 -- center title
- title:setTextColor( 255,255,0 )
- -- Determine if running on Corona Simulator
- --
- local isSimulator = "simulator" == system.getInfo("environment")
- -- Accelerator is not supported on Simulator
- --
- if isSimulator then
- msg = display.newText( "Accelerometer not supported on Simulator", 0, 55, "Verdana-Bold", 13 )
- msg.x = display.contentWidth/2 -- center title
- msg:setTextColor( 255,255,0 )
- end
复制代码 |
|