FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
moai-dev/samples/blocking/main.lua at develop · moai/moai-dev · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
moai
/
moai-dev
Public
Notifications
You must be signed in to change notification settings
Fork
312
Star
963
Code
Issues
161
Pull requests
4
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
moai-dev
/
samples
/
blocking
/
main.lua
Copy path
More file actions
More file actions
Latest commit
History
History
History
45 lines (31 loc) · 1.04 KB
Breadcrumbs
moai-dev
/
samples
/
blocking
/
main.lua
Copy path
File metadata and controls
45 lines (31 loc) · 1.04 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
----
------------------------------------------------------------
--
Copyright (c) 2010-2017 Zipline Games, Inc.
--
All Rights Reserved.
--
http://getmoai.com
----
------------------------------------------------------------
MOAISim
.
openWindow
(
"
test
"
,
320
,
480
)
viewport
=
MOAIViewport
.
new
()
viewport
:
setSize
(
320
,
480
)
viewport
:
setScale
(
320
,
480
)
layer
=
MOAIPartitionViewLayer
.
new
()
layer
:
setViewport
(
viewport
)
layer
:
pushRenderPass
()
gfxQuad
=
MOAIGfxQuad2D
.
new
()
gfxQuad
:
setTexture
(
"
moai.png
"
)
gfxQuad
:
setRect
(
-
64
,
-
64
,
64
,
64
)
prop
=
MOAIProp
.
new
()
prop
:
setDeck
(
gfxQuad
)
prop
:
setPartition
(
layer
)
function
threadFunc
()
local
action
action
=
prop
:
moveRot
(
180
,
3
)
MOAIThread
.
blockOnAction
(
action
)
action
=
prop
:
moveLoc
(
64
,
0
,
2
)
MOAIThread
.
blockOnAction
(
action
)
action
=
prop
:
moveScl
(
-
0.5
,
-
0.5
,
1
)
MOAIThread
.
blockOnAction
(
action
)
action
=
prop
:
moveRot
(
-
180
,
3
)
MOAIThread
.
blockOnAction
(
action
)
end
thread
=
MOAIThread
.
new
()
thread
:
run
(
threadFunc
)
Back
|
FazBrowse Home
|
New Git URL