Merged accelerometer with GameView (the old class can still be accessed like before). Added acceleration formula to decide the ball's movement, which can be tweaked or dropped depending on what we need. Added interaction with edges of the screen (ball no longer disappears from view).
Added a debug controller for testing the application on an emulator without accelerometer. Originally I made changes on Ball and GraphicsObject, but the new changes interfered with my code, so created Graphic; a generic class for graphical objects (GraphicObject is mostly Ball code to be honest). Graphic.contains() still needs some work, but works for now.
Mini bugfix, debug controller doesnt show up when DEBUG_CONTROLS = false.
Added true full screen to the game view and friction to the ball. Movement in x-axis might be reversed on an actual android as far as I know. Anyone is welcome to test and potentially fix this by using the other line given for accelerationX in Ball.
A quick update adding a feature of ignoring minor acceleration. The value I gave must be tested later and tweaked until it's big enough to keep the ball still when the phone is left lying around, but small enough to not make the user have to tilt their phone too much to get a response from the ball.
First iteration of settings page (mostly cosmetic)
Saves setting changes using the radiobutton ID
Changed to save settings based on radiobutton ID (to make the saved values more readable). Also added a message when a change has been saved.
A couple of small changes; replaced the float Points with int Points in the Controller and correct calculation of relative position in Graphic class.
66843: Added a first version of the Map with basic collision detection, the call to Map.parseCollisions() could later be moved to initial loading stage and saved for later usage. Added getPosition() and handleCollision() to Ball, which both needs work from the front end developers. The Map class might still need performance adjustments (like skipping 5px after added collision point) and the map needs to be rotated with the screen etc etc.
Changing ball from settings now gives a different looking ball in-game (balls 1-3 have different images, the rest default to ball 1). I also moved some buttons on the main screen up since settings for some reason was too low for my emulator to display. Even now it's drawn more to the right than it shows in preview, but at least I can click it.
Added functionality for different game modes.
Rotated map mask file (mask1.jpg), replaced 0x010101 pixels with 0x000000. Make sure all new map mask files ONLY contain 0x000000 for the collision points, and the less points the better (hollow borders increase performance atm). Added Map padding as the GameView seems to have a 20px border, might change according to phone? Added collision for top,right,bottom,left corners for the ball. The physics when handling the collision is still flawed; enough speed and the ball breaks through the walls. Something for the front-end/Ball developers to fix?
Some minor changes including:
1) Changing the text of the splash screen and removing the unnecessary button
2) Locking the screen in portrait mode so it doesn't auto-rotate
3) Keeping the Game screen always on (doesn't "go to sleep")
Minor changes; RectF -> Rect, PointF -> Point, decreased the "backbouncing" of the collisions. Fixed the Graphic resize to also update the hitbox correctly.
67709: Ball starts at pixel-group with color 0x00FF00. Goal is created at pixel-group with color 0xFF0000. Tokens are created at pixel-groups with color 0x0000FF. Map now resizes according to screen width. The methods isCompleted and findsToken are implemented in game loop for further usage (call them triggers or whatever).
Added score counting with multiplier (dummy values)
The ball should no longer move in reverse on the X-axis. Added a "* (-1.0)"  in its movement
Removed the -1 in the game loop accelerometer x axis.
Ball is still a rectangle, but now handles points for collision like a circle. Reduced size of ball down to 11 x 11, since the map was updated to fit entirely to the screen, but the ball didn't rescale at the same time (at least not for my emulator, this might not be a problem for real android users). This should be a temporary change, but if the ball is too small for you, just change ballWidth = 11, ballHeight = 11 in GameView to something more suitable for you (default is 51). Keep in mind the formula determining collision points for the ball works best with an odd number where that extra pixel in width and height is used as middle point. Additionally I've added a system for detecting collision during movement of the ball before the actual movement happens, which means the ball never should land on a wall anymore or straight up fly through one. Bouncing back from walls is not yet implemented, meaning the ball will just instantly freeze whenever it hits a wall. If you put this aside though, a labyrinth can now technically be fully completed even if nothing happens when you hit the goal area just yet.