Ben Los, Jurgen van Schagen, Nick Cleintuar, Martijn Gribnau, Jean de Leeuw
- See 'Build'.
Ben Los, Jurgen van Schagen, Nick Cleintuar, Martijn Gribnau, Jean de Leeuw
All our assets are stored in the Android module, in the /assets/ folder.
When I'm testing, file handles created using the libgdx: Gdx.files.internal("path/to/file.ext") do not seem to work.
However, in the normal source code used while running the application itself, the file handle is created correctly and the file actually can be found.
Example stack trace (TextureFactoryTest):
Couldn't load file: images/wooden_sign.png com.badlogic.gdx.utils.GdxRuntimeException: Couldn't load file: images/wooden_sign.png at com.badlogic.gdx.graphics.Pixmap.(Pixmap.java:140) at com.badlogic.gdx.graphics.TextureData$Factory.loadFromFile(TextureData.java:98) at com.badlogic.gdx.graphics.Texture.(Texture.java:100) at com.badlogic.gdx.graphics.Texture.(Texture.java:92) at cg.group4.container.image.TextureFactory.getWoodMenuTexture(TextureFactory.java:23) at cg.group4.container.image.TextureFactoryTest.testGetWoodMenuTexture(TextureFactoryTest.java:52) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44) at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17) at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26) at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27) at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70) at cg.group4.GdxTestRunner.render(GdxTestRunner.java:50) at com.badlogic.gdx.backends.headless.HeadlessApplication.mainLoop(HeadlessApplication.java:125) at com.badlogic.gdx.backends.headless.HeadlessApplication$1.run(HeadlessApplication.java:90) Caused by: com.badlogic.gdx.utils.GdxRuntimeException: File not found: images\wooden_sign.png (Internal) at com.badlogic.gdx.files.FileHandle.read(FileHandle.java:137) at com.badlogic.gdx.files.FileHandle.readBytes(FileHandle.java:223) at com.badlogic.gdx.graphics.Pixmap.(Pixmap.java:137) ... 20 more
Our current implementation has a separation between the local activities and the multiplayer activities.
This also means, different ways to storage of achieved rewards.
Locally the progression is stored as a serialized file.
On the server, the group progression is stored as a sqlite database.
The idea is to remove the local storage completely (along with other client<>server separated components).
Instead we will use a local server on the device; which will store, for example, the offline user progression in a local sqlite database.
###################### #####################################
# device (Local) # ----------- # local file system (progression) #
###################### #####################################
|
|
| net
|
|
############### #####################################
# server # ----------- # sqlite (group progression) #
############### #####################################
#########################
# device (local) #
# ################ #####################################
# # server # ----------- # sqlite (personal progression) #
# ################ #####################################
#########################
|
|
| net
|
|
############### #####################################
# server # ----------- # sqlite (group progression) #
############### #####################################
Background music was removed for now (because of the refactoring, in which we refactored the WorldRender).
It should be re-added.
06-17 15:52:41.070 11209-11228/cg.group4.android E/AndroidRuntime﹕ FATAL EXCEPTION: GLThread 983 java.lang.NullPointerException at cg.group4.game_logic.stroll.events.fishevent.FishingStrollEvent.update(FishingStrollEvent.java:51) at java.util.Observable.notifyObservers(Observable.java:138) at cg.group4.data_structures.subscribe.Subject.update(Subject.java:27) at cg.group4.game_logic.StandUp.update(StandUp.java:131) at cg.group4.Launcher.render(Launcher.java:152) at com.badlogic.gdx.backends.android.AndroidGraphics.onDrawFrame(AndroidGraphics.java:422) at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1531) at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1248) 06-17 15:52:45.210 11209-11209/cg.group4.android E/AndroidGraphics﹕ waiting for pause synchronization took too long; assuming deadlock and killing
When in an event and the Timer for that event is finished, the game crashes.
When text does out of the boundaries of the stage it is not being wrapped. This results in the text not being completely visible.
Writing tests for stroll events is currently impossible, due to not being able to instantiate a concrete StrollEvent. This because of something with the ScreenStore
Instead consider using rewards / tasksperformed.
As of now the server can only change data in the db, but not add new data.
Extending tests for RewardGenerator
If we don't clean it up from time to time it will at some point be completely full and multiplayer will no longer function.
Even when an event is stopped because the timer ends, the player still receives all the rewards.
We need to determine what we want to do with a 'running' stroll. Do you restart the stroll, do you continue from where you left or is the stroll thrown away?
We will try to add AccelLibAndroid (By Job Becht, Wouter Groen, Olivier Hokke, Eric Rijnboutt) so we can more easily determine whether a player is either "Resting", "Walking", "Running" or "Cheating".
Currently we use the local time (time on the device) when we award a reward.
It might be worth to use a server time (if available, where availability is a con).
When a player plays the game and receives rewards, he/she wants to keep this data available after exiting the application. This data, a game save should be stored on the local file system.
requirements
nice to have
literature
problems
solutions
current implementation
We are redoing the setup of the project to Gradle instead of Maven.
The most important reason for this is libgdx, since its support of Maven is not good enough (it takes a lot of time to setup and maintain).
06-17 15:44:30.000 10759-10777/cg.group4.android E/AndroidRuntime﹕ FATAL EXCEPTION: GLThread 974 java.lang.NullPointerException at cg.group4.view.screen.CollectiblesScreen.constructContents(CollectiblesScreen.java:235) at cg.group4.view.screen.CollectiblesScreen.rebuildWidgetGroup(CollectiblesScreen.java:94) at cg.group4.view.screen_mechanics.ScreenStore.rebuild(ScreenStore.java:139) at cg.group4.view.screen_mechanics.WorldRenderer.resize(WorldRenderer.java:165) at com.badlogic.gdx.Game.resize(Game.java:51) at com.badlogic.gdx.backends.android.AndroidGraphics.onSurfaceChanged(AndroidGraphics.java:247) at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1520) at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1248)
We managed to successfully build for Android from the command line (using Java SE 7 (Do not use 8 for this)).
We also managed to successfully build for Android from IntelliJ (using Java SE 8, not sure how, since it is unsupported by Android, and this computer did not contain Java JDK 7 at that time.).
For some reason Eclipse does not want to build.
We are working on solving this issue.
[2015-05-04 17:23:32 - standup-android] Dx UNEXPECTED TOP-LEVEL EXCEPTION: com.android.dx.cf.iface.ParseException: bad class file magic (cafebabe) or version (0034.0000) at com.android.dx.cf.direct.DirectClassFile.parse0(DirectClassFile.java:472) at com.android.dx.cf.direct.DirectClassFile.parse(DirectClassFile.java:406) at com.android.dx.cf.direct.DirectClassFile.parseToInterfacesIfNecessary(DirectClassFile.java:388) at com.android.dx.cf.direct.DirectClassFile.getMagic(DirectClassFile.java:251) at com.android.dx.command.dexer.Main.processClass(Main.java:665) at com.android.dx.command.dexer.Main.processFileBytes(Main.java:634) at com.android.dx.command.dexer.Main.access$600(Main.java:78) at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:572) at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:170) at com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:229) at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:158) at com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:229) at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:158) at com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:229) at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:158) at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:144) at com.android.dx.command.dexer.Main.processOne(Main.java:596) at com.android.dx.command.dexer.Main.processAllFiles(Main.java:498) at com.android.dx.command.dexer.Main.runMonoDex(Main.java:264) at com.android.dx.command.dexer.Main.run(Main.java:230) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.android.ide.eclipse.adt.internal.build.DexWrapper.run(DexWrapper.java:188) at com.android.ide.eclipse.adt.internal.build.BuildHelper.executeDx(BuildHelper.java:813) at com.android.ide.eclipse.adt.internal.build.builders.PostCompilerBuilder.build(PostCompilerBuilder.java:597) at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:734) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:206) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:328) at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:403) at org.eclipse.core.internal.resources.Project$1.run(Project.java:618) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2313) at org.eclipse.core.internal.resources.Project.internalBuild(Project.java:597) at org.eclipse.core.internal.resources.Project.build(Project.java:124) at com.android.ide.eclipse.adt.internal.project.ProjectHelper.doFullIncrementalDebugBuild(ProjectHelper.java:1143) at com.android.ide.eclipse.adt.internal.launch.LaunchConfigDelegate.launch(LaunchConfigDelegate.java:155) at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:885) at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:739) at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:1039) at org.eclipse.debug.internal.ui.DebugUIPlugin$8.run(DebugUIPlugin.java:1256) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54) ...while parsing cg/group4/StandUp.class [2015-05-04 17:23:32 - standup-android] Dx 1 error; aborting [2015-05-04 17:23:32 - standup-android] Conversion to Dalvik format failed with error 1
A test in TimeKeeperTest.java sometimes fails randomly. Guessing it happens because of the System.currentTimeMillis used? It concerns the update test.
The accelerometer is currently only working in landscape. Since we are going to support both landscape and portrait this needs to be more dynamic.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.