Cocos2dx - Setup
Embed Size (px)
Transcript of Cocos2dx - Setup
-
8/10/2019 Cocos2dx - Setup
1/13
Bc 1: Download v gii nn cocos2d-x
Bc 2: Ci t cocos2d-x
M th mc cocos2d-x, tm !il" #$ild-win%2atClic' () "build-win32.bat"* ch+ n, .$/ t0nh ci t s1 mt g3n %4 )h(t&
Bc 3: Download v gii nn 5D6
Bc 4: Download v ci t cgwin
M s"t$)&"x"
5"xt
-
8/10/2019 Cocos2dx - Setup
2/13
Ch7n "Install from Internet",
-
8/10/2019 Cocos2dx - Setup
3/13
Ch7n th mc * l$ )h3n 8 ci t&
-
8/10/2019 Cocos2dx - Setup
4/13
Ch7n th mc * l$ )h3n down v9&
-
8/10/2019 Cocos2dx - Setup
5/13
Ch7nDirect Connection
-
8/10/2019 Cocos2dx - Setup
6/13
Ch7n host * down v9, c/i no cng ;c&
-
8/10/2019 Cocos2dx - Setup
7/13
-
8/10/2019 Cocos2dx - Setup
8/13
Bgain ma'" s$0" o$0 )"0missions a0" !ix"d in cgwin
chmod EEF G -H
-
8/10/2019 Cocos2dx - Setup
9/13
Bc 5: Ci wiIa0d cho Jis$al Kt$dio
C/c #+n tm Ln th mc msvc&
Hi ch7n )hiNn #n ci t )hO h;), nh mnh dOng vs24P4 th ci?QnstallRiIa0dSo0JK24P4&Ts?
Ch$Ut )hi, o)"nwith -V mic0oso!t windows #as"d host&
Bc 6: H$n )0oT"ct thW t0Nn win
M ?cocos2d-win%2&vc24P4&sln?
Bc 7:
Jo th mc gXc cocos2d-x
M c0"at"-and0oid-)0oT"ctat #Yng not")adZZ v ch[nh l+i \ng d]n cgwin,sd', nd'& Ch[nh xong sav" l+i&
Cod"::: modify it to work under your environmentset_CYGBIN=D:\All_Cocos2d-x\cygwin_install\binif not exist !_C"#$%&! ec'o Couldn(t find Cygwin at!_C"#$%&! ) *ause ) exit +
:: modify it to work under your environmentset_ANDROIDTOOLS=C:\,rogram iles.x/01\Android\android-sdk\toolsif not exist !_A&D3%D43356! ec'o Couldn(t findandroid sdk tools at !_A&D3%D43356! ) *ause ) exit 7
:: modify it to work under your environmentset_NDKROOT=D:\All_Cocos2d-x\android-ndk-r/cif not exist !_&D8334! ec'o Couldn(t find ndk at!_&D8334! ) *ause ) exit 0
Clic' () vo c0"at"-and0oid-)0oT"ctat&
Bc 8: KWa \ng d]n t0ong !il" #$ild^nativ"&sh
-
8/10/2019 Cocos2dx - Setup
10/13
M #$ild^nativ"&sh #Yng not")adZZKWa d_ng sa$:
9 *at's
if -; aaa? @t'enec'o *lease define &D8_334exit Bfi
thnh
Cod":
9 *at'sNDK_ROOT="/cygdrive/e/All_Cocos2d-/!droid-d#-r$c"
if -; aaa? @t'enec'o c'i din' ndk rootexit Bfi
`t l+i \ng d]n cho 5D6^H
-
8/10/2019 Cocos2dx - Setup
11/13
M windows "x)lo0"0, co) \ng d]n&&&&&&&&&&&&)0oT&and0oid
vo Cgwin Cod":s% '(ild_!)ive*s%
Bc 11:Qm)o0t )0oT"ct vo "cli)s"&
Port win32 project to android
-
8/10/2019 Cocos2dx - Setup
12/13
P& Ma'" s$0" o$ hav" an availa#l" pand0oid^sd'Zand0oid^nd'Z"cli)s"q"nvi0om"nts, and cgwin is also a m$st
2& Ma'" a win%2 )0oT"ct , add o$0 cod", com)il"r0$n , ma'" s$0" "v"0thing
is o'&
%& edit create-android-project.bat po$ sho$ld modi!_ANDRID!#
_C$%&IN _ND'R! to wo0' $nd"0 o$0 "nvi0onm"ntq, "s, th" '" isth"s" th0"" va0ia#l"&
u& H$n c0"at"-and0oid-)0oT"ctat, do acco0ding to th" )0omotion& i! som"
)"0mission "00o0 occ$0s, googl" pcgwin !il" )"0missionq will h"l)&
5avigat" in th" cgwin consol" to cgd0iv"cD"v and s"t th" )"0missions!o0 all !il"s in that !old"0 to EEF
K"tting th" 0ights !o0 "v"0thing in C:D"v
chmod EEF G -H
-
8/10/2019 Cocos2dx - Setup
13/13
y& )"n ecli)s" and im)o0t "xisting )0oT"ct & with 2&4&2 th"0" is an "00o0 a#o$ticon in mani!"st&xml, co00"ct it &
Una!e to "dd #ew Project $sin% &'2010 Pro ( )indows 7
Q! o$ a0" having t0o$#l" installing 2dx t"m)lat"s o$ can t0 th" !ollowing st")s&
P& Download th" attach"d !il", "xt0act it jcocost"m)lat"s&Ii)&
2& )"n th" !il" CCB))RiI&win%2&vsI
%& 5ow ch"c' !o0 za0am{[email protected]|