——- problem 1
change android:configChanges="orientation|screenSize|smallestScreenSize"
to android:configChanges="orientation"
screenSize and smallestScreenSize do not seem to exist anymore (yet?)
——- problem 2
import org.cocos2dx.lib.Cocos2dxLuaJavaBridge; cannot be resolved
in file /TestLua/src/com/cocos2dx/sample/LuaJavaBridgeTest/LuaJavaBridgeTest.java
Solutions:
#
copy
E:\cocos2d-x\cocos\2d\platform\android\java\src\org\
to
E:\cocos2d-x\samples\Lua\TestLua\proj.android\src\org\
Note: probably only 2dx\lib\Cocos2dxLuaJavaBridge.java is needed
this should have fixed the problem but it did not work.
#
delete the import line
import org.cocos2dx.lib.Cocos2dxLuaJavaBridge;
re-enter the line.
Actually I re-enter import org.cocos2dx.lib.
and I use eclipse completion to enter Cocos2dxLuaJavaBridge
(/) compile and run this all works.
——————————————
This new version is great thank you for all the work
Next steps
* I have to compile in window.
* Add my bindings
* Upgrade my apps etc
I will post my problems and hopefully my solutions stay posted :;ok
Andre
Recompiling testlua on window will not work because duplicate files exist.
The following changes to the android-build.py file will fix the problem.
The changes are in the function copy_files.
The duplicates come from the resources which are needed to test on window.
The change make the resource files override other files.
Should not cause any problems I hope.
for item in os.listdir(src):
path = os.path.join(src, item)
dstfile = os.path.join(dst, item)
# Android can not package the file that ends with ".gz"
# On window the files
if not item.startswith('.') and not item.endswith('.gz') and os.path.isfile(path):
if os.path.isfile(dstfile):
print('warning duplicate file:', dstfile)
else:
shutil.copy(path, dst)
if os.path.isdir(path):
new_dst = os.path.join(dst, item)
if not os.path.isdir(new_dst):
os.mkdir(new_dst)
copy_files(path, new_dst)
——- problem 1
change android:configChanges="orientation|screenSize|smallestScreenSize"
to android:configChanges="orientation"
screenSize and smallestScreenSize do not seem to exist anymore (yet?)
——- problem 2
import org.cocos2dx.lib.Cocos2dxLuaJavaBridge; cannot be resolved
in file /TestLua/src/com/cocos2dx/sample/LuaJavaBridgeTest/LuaJavaBridgeTest.java
Solutions:
copy
E:cocos2d-xcocosdplatformandroidjavasrcorg\n> to
E:cocos2d-xsamplesLuaTestLuaproj.androidsrcorg
Note: probably only 2dx\lib\Cocos2dxLuaJavaBridge.java is needed
this should have fixed the problem but it did not work.
delete the import line
import org.cocos2dx.lib.Cocos2dxLuaJavaBridge;
re-enter the line.
Actually I re-enter import org.cocos2dx.lib.
and I use eclipse completion to enter Cocos2dxLuaJavaBridge
(/) compile and run this all works.
——————————————
This new version is great thank you for all the work
Next steps
I have to compile in window.
Add my bindings
Upgrade my apps etc
I will post my problems and hopefully my solutions stay posted :;ok
Andre
problem 1:In the samples,screenOrientation is assigned landscape.So here is to eliminate the need to consider the screen orientation.
problem 2:Please try clean all project and rebuild them