I want to install cocos2d-x on my windows8 but i download this "http://bit.ly/18xmkJ9" from "http://cocos2d-x.org/download" in the tutorial says that i must execute a .bat in there or in some other pages says that i neet to create a project in VS, but when i try to do what they say in the tutorial i dont see anithing that is shown.
I'm very lost and help needed.
Could anybody say me hoy to createand start a project on cocos2d?
I have answer the similar question here.
Before cocos2d-x 2.1.2, you can still use templates in VS. However, you can only use python to create project
Install python 2.7
Open command line in Windows
Go to your cocos2d-x-2.1.5\tools\project-creator folder
Run create_project.py. Usage:
create_project.py -project YourProjectName -package com.example.PakcageName -language cpp
-language option:[cpp | lua | javascript]
Your project will be created in cocos2d-x-2.1.5\projects
Then find the win32.proj , open ***.sln
Related
I'm trying pyqtdeploy for the first time, following the docs.
I'm getting the following error when running build-demo.py:
C:\Users\Administrator\AppData\Local\Programs\Python\Python36-32\Lib\site-packag
es\pyqtdeploy\demo>python build-demo.py
pyqtdeploy-sysroot: Unable to detect MSVC2015 or MSVC2017.
The py file seems to be getting Environment variables from the os module, as running the same command in python console it works fine. Somehow pyqtdeploy is having a problem with this.
I have the build tools installed in the system; what am I missing here?
You must search the location of the vcvars64.bat in your Build Tools' folder location and copy it. It depends on your system environment and the version of Visual Studio installed.
Before run pyqtdeploy script, paste that location in the command prompt. This will initialize the Environment and enable the detection of MSVC x64.
Step 1 : Download all the required packages ....
pic1
Step 2 : Browse to the directory where Micosoft Visual Studio is installed
pic2
Step 3: Search for vcvars64.bat in that directory
pic3
Step 4 : Run vcvars64.bat and if it successful, run pyqtdeploy-sysroot sysroot.json
pic4
I installed Cocos Studio v2.3.3 to C:\Cocos using the link to a non-framework included package on the cocos2d-x.org site. I then unpacked cocos2d-x v3.9 using the zip file provided into the C:\Cocos\frameworks\cocos2d-x-3.9 - but Cocos Studio doesn't recognize that the Cocos2d-x framework is installed.
When I look in the Platform section of the Preferences menu item under the Edit menu, it show this:
And as expected, when I try to modify an already created project options, I see this:
I've tried all the suggestions posted in the Cocos2d-x forums, including but not limited to editing the Frameworks\FrameworksVersionList.xml to include the entry for cocos2d-x-3.9 (it was already there), editing the cocos2d.ini file in tools\console\bin, removing various combinations and then all cocos environment variables and quite a few others. None of the solutions either by themselves or in combination with one another worked.
Has anyone gotten Cocos Studio to work with a separate installation of Cocos2d-x framework?
Details of the solution with various things I tried are listed in this blog post: http://vijay.tech/talks/solved-cocos-studio-cocos-framework-is-not-installed-error/ Note that the post has a registry edit script (.REG file) attached for convenience.
But the essential steps are listed here:
Download and install Cocos for Windows V2.3.3 (the one without framework) to C:\Cocos
Download and unzip cocos2d-x-3.9.zip to C:\Cocos\frameworks\cocos2d-x-3.9
Manually create the following registry entries on Windows (64 bit):
HKLM\Software\Wow6432Node\CocosFramework\InstallDir as a REG_SZ and set it to C:\Cocos
HKLM\Software\Wow6432Node\CocosFramework\3.9\EngineVersion as a REG_SZ and set it to cocos2d-x-3.9
HKLM\Software\Wow6432Node\CocosFramework\3.9\Path as a REG_SZ and set it to C:\Cocos\frameworks\cocos2d-x-3.9
Create a file named version with the contents cocos2d-x-3.9 in C:\Cocos\frameworks\cocos2d-x-3.9
If you also want to do Android development, then Android SDK, Android NDK, Ant and JDK paths should be set in the Platform section of the Edit/Preferences menu item, else skip this step.
I changed to new versions of Android SDK and NDK.
When I execute the command "cocos run -p android" in any cocos project directory, also a newly created one, then it compiles all sources correctly, but stops trying to build an apk, with the message:
Can't find right android-platform for project : "/Applications/MAMP/htdocs/42words/frameworks/runtime-src/proj.android". The android-platform should be equal/larger than 10
The Env-Variables are set to:
ANDROID_SDK_ROOT=/Applications/adt-bundle-mac-x86_64-20140702
NDK_ROOT=/Applications/android-ndk-r10
ANT_ROOT=/usr/local/Cellar/ant/1.9.3/bin
And they are correct. At
/Applications/adt-bundle-mac-x86_64-20140702/sdk/platforms
there is a android-20 folder. If I call cocos with
cocos run -p android --ap 20
Then the message is
The directory "android-20" can't be found in android SDK
What am I missing?
I had the same problem when I replaced my old copy of the Android SDK with the one from the Cocos Store.
Can't find right android-platform for project : "/Users/CurrentUser/ProjectName/frameworks/runtime-src/proj.android". The android-platform should be equal/larger than 16
Easy fix! Run android found at /android-sdk/tools/android and make sure that the Android version (in this case API 16) is downloaded.
here is my android_sdk_root, you lose /sdk?
export ANDROID_SDK_ROOT=/Project/adt-bundle-mac-x86_64-20131030/sdk
if not this reason, you can find this log in tools/cocos-console/plugins/project_compile/build_android.py
def check_android_platform(self, sdk_root, android_platform, proj_path, auto_select):
if you use python ,it's easy to find the reason by log
To me, the problem can be solve by installing the older version of android sdk. Open your android ndk folder and check for the newest version of the NDK. If it is android-21 for example, then you open AndroidSDK Manager, and install AndroidSDK Build tools 21. After that, try again to run your project.
In addition, depend on your target device, you may also want to install an equivalent Android SDK platform.
I am developing a game in xcode using cocos2d-x i want to convert the .xcodeproj file to .apk file for that i use the Stella SDK. after download the package I try to configure it. But i am getting the following error, I typed in terminal.Please help me.
mac-man:~ srikanthreddy$ cd / opt
mac-man:/ srikanthreddy$ git clone https://github.com/morningtec/StellaSDK.git
fatal: could not create work tree dir 'StellaSDK'.: Permission denied
You are trying to clone the git project into /opt which is a directory that you may not have write permission for.
Usually you'd create such projects in your home directory, so try this instead:
mkdir ~/StellaSDK
cd ~/StellaSDK
git clone https://github.com/morningtec/StellaSDK.git
Note that this step is only cloning the StellaSDK project, it has nothing to do with the task you described (creating an .apk file). From that I take it you haven't fully understood that StellaSDK is a game engine / framework just like cocos2d-x, so you can't use that to create an .apk file unless you start a new project. In particular you can't just convert a .xcodeproj to work with Stella SDK, there is no automatism like that.
While at the same time cocos2d-x is a cross-platform engine capable of creating Android .apk apps. The reason why you're trying to use Stella for (or in place of?) an already existing cocos2d-x project is a bit of a mystery to me.
Using Flash Builder 4.6, I exported an Adobe Air file from my mobile project.
I'm trying to get it packaged into an EXE (that would include the Adobe Air Runtime)
The project was compiled with Air 3.1. I looked online and there are some ADT commands that people recommend using but the problem is that the command throws errors in Air 3.1
If i use air 3.0 ADT:
AIR file at [app path]/app.air could not be converted.
The error was ""
If I use air 3.1 or air 3.2 sdk
SDK is missing file [my path to air]\lib\nai\bin\naip.exe
I'm running
java -jar [path to air]\lib\adt.jar" -package -target native app.dmg app.air
I've also tried
java -jar [path to air]\lib\adt.jar" -package -target native app.exe app.air
I've also looked into projects like this one: http://bishoponvsto.wordpress.com/2010/02/23/adobe-air-2beta-2-to-exe-packaging-air-app-in-windows-executable/ , but it is for Air 2.0.
Any ideas? Apparently there is an integrated Flash Builder 4.6 tool, but for some reason the option under export release doesn't exist for mobile projects - strange...
Why do you want to do this? Air files -- when exported for a specific platform -- are executables.
If you are looking for an "installer" that will create directories, run the Air installation, and move auxiliary files to specific locations (docs, icons, etc.), then try Inno Setup.
EDIT:
The code you provided works for me to create a Windows EXE. But it seems a bit unecessary . . . why not just export the EXE file from Flash Builder ("Export Release Build" button in the top toolbar)? If you can't or won't, then here are some suggestions:
I am using Java version 1.6.0_29. Make sure your Java is not only up to date, but that you are actually calling the correct version (java -version).
Check the JAR directory text carefully .
Check that you are actually calling to the right Air version.
Make sure that the quotation marks are on both sides of the JAR path.
You should be able to do a "Export Release Build" (though I am using FB 4.5). Instead of selecting "Export as: Signed packages for each target platform", select "Export as: Signed AIR packages for installation on the desktop". (You may have to create a certificate, but you can create one through this export feature, too.)
(If you happen to be able to use the Flash IDE, the exported Air file has to support both "Desktop" and "Extended Desktop".)
Hopefully, this will allow you to both produce an Air program that can be converted to EXE, and actually convert it using the command line.
I know this question is a little old, but a co-worker just ran into the same error message using the command line tools and FlashDevelop. It turns out that he was accidentally packaging some source files into the .air package, an extra copy of the app descriptor and one of the swc's was getting packaged in the .air file. I removed those and repackaged the .air file, then used this command:
adt.bat -package -target bundle kiosk kiosk.air
This successfully created a captive runtime exe. Of course there's no need to create a .air file first, you can package right to native or captive runtime, but since my co-worker was creating .air files I did it that way too just to be sure it would work.