Giter VIP home page Giter VIP logo

rectball's Introduction

Rectball

Get it on Google Play

Rectball is a colorful puzzle game for Android. Make selections, clear rectangles and make points before the time runs out. Rectball is open source and runs on Android 4.0.3+.

You can join the beta on your mobile phone or visiting this link in your computer.

Contributing

Thank you for your interest in helping to make Rectball better!

Have a suggestion or an idea? Hold it temporally to yourself. Or carry it to the discussions, but keep in mind that I won't be addressing feedback until the current roadmap is finished and version 1.0 is finally released.

Development requirements

Currently, JDK 17 is required. Older versions will not work, newer versions will not work. The plugins will look for any JDK 17 in the system. It is suggested that you use the Temurin JDK, but the decision on the vendor is yours.

(In the future, I'd like to change this behaviour and test the Java versions I accept in my build.gradle files because I honestly still don't know)

To build Android versions, the Android SDK is required and it should be configured. You should not need to install the Android SDK to build the desktop or HTML 5 version; if it fails, it is a bug. The build process should work on most host operating systems.

Gradle projects

  • :lwjgl3 - the desktop version (powered by LWJGL 3, runs on most desktop environments)
  • :teavm - the HTML5 version (uses TeaVM since Rectball is using Kotlin)
  • :android:gpe - the Android Google Play Edition (used to deploy to Google Play)
  • :android:osp - the Android Open Source Project (does not use privative components, fully GPL)

Useful Gradle commands

PC version

  • Run: ./gradlew lwjgl3:run
  • Pack into a JAR: ./gradlew lwjgl3:jar. Generates .jar in lwjgl3/build/lib.
  • Create self-contained package: ./gradlew lwjgl3:jpackage. Generates package in lwjgl3/build/jpackage

Android version

Replace X with osp for the open source version or gpe for the Google Play version.

  • Compile open source APKs:
    • Debug: ./gradlew android:X:assembleDebug, generates .apk in android/X/build/outputs/apk/debug
    • Release: ./gradlew android:X:assembleRelease, generates .apk in android/X/build/outputs/apk/release
    • Both: ./gradlew android:X:assemble, generates .apk in both directories.
  • Install in the connected devices (use adb devices to check devices):
    • Debug version: ./gradlew android:X:installDebug
    • Release version: ./gradlew android:X:installRelease

Web version

  • Create HTML5: ./gradlew teavm:build, generates output in teavm/build/dist/webapp
  • Run server: ./gradlew teavm:run, runs in http://localhost:8080

Common and known issues

JPackage cannot pack Rectball ("The first number in an app-version cannot be zero or negative")

JPackage refuses to create an .app for macOS because macOS doesn't let apps have a zero as first version number. Until I release Rectball 1.0, the workaround is to hardcode version 1.0 when building the application:

./gradlew -PversionFamily=1.0 lwjgl3:jpackage

Application signing on Android

Verify the signatures of the app with ./gradlew android:osp:signatureReport and ./gradlew android:gpe:signatureReport. For the GPE edition, the Google Play Games will not work unless the signing key matches the one uploaded to Google Play Console.

Signing can be done interactively from Android Studio.

When using Gradle, the applications are not signed by default, and must be signed later using apksigner:

apksigner sign --ks [keychain] [path to the APK to sign]

Alternatively, the following four Gradle properties can be injected to sign automatically the generated applications:

  • keysign.storeFile for the path to the keystore file
  • keysign.storePassword for the main password of the keystore file
  • keysign.keyAlias for the key alias in the keystore to use
  • keysign.keyPassword for the password of the key alias

For instance, in your $GRADLE_HOME/gradle.properties. If these four settings are set, the signing keys will be automatically configured, and both debug and release APKs will be signed with these. Again, always check the output of the signatureReport task to confirm.

Google Play Games IDs

For the Google Play edition, the achievement and leaderboard IDs should be downloaded from Google Play Console and placed into android/gpe/res/values/game-ids.xml.

This XML file is not confidential (I assume), since these strings are public and placed in the APK anyway, but I prefer to keep this out of the repository to force myself to use fresh data.

License

Rectball is published under the terms of the GPL v3 (or later) license. Check the COPYING file.

rectball's People

Contributors

danirod avatar dependabot-preview[bot] avatar dependabot[bot] avatar hugomartin89 avatar matiuri avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

rectball's Issues

Add leaderboard support

The game has a leaderboard to display the best scores for the player. The behaviour of the leaderboard depends on the platform the game is running in. The game displays a social leaderboard if the game is running on Android, using the Google Play version and connected to Google Play Services. In any other case, it uses the fallback leaderboard.

Tasks

  • Rethink the scores API.
  • Implement local leaderboard as a platform API.
  • Add support for Google Play Services.
  • Integrate Google Play leaderboards with Rectball.

Botón de ayuda bugeado

El boton de ayuda se bugea y marca un rectángulo falso. Para hacer el bug basta con darle al botón ayuda de forma continua mientras al mismo tiempo lo resuelves, al 3 o 4 rectángulo resuelto se bugeara y mostrara la forma del antiguo rectángulo, esta forma también se marca como correcta al acabar el tiempo, aunque no lo sea.

Navigation bar doesn't dissapear on inmersive mode

This issue is imported from Twitter: https://twitter.com/falvarez/status/663984923775254529

Navigation bar in inmersive mode

When the game is minimized by pressing HOME and then restored there is a chance on inmersive phones that the navigation bar will stay sticky and hide part of the board. It is reproducible. I can test this by opening the Development settings on my phone and checking "Don't keep activities" so that they are destroyed when they go to background. I can see it happening on my phone after opening Rectball a second time. Should check this.

java.lang.InstantiationException

Reported on Nexus 5, running Android 6.0. Reported on versions 0.4.4 and 0.4.5. Reporting date: November 2015.

java.lang.RuntimeException: Unable to start activity ComponentInfo{es.danirod.rectball.android/es.danirod.rectball.android.AndroidLauncher}: com.badlogic.gdx.utils.SerializationException: Class cannot be created (missing no-arg constructor): es.danirod.rectball.model.Bounds
Serialization trace:
wiggledBounds (es.danirod.rectball.model.GameState)
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)
    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
    at android.app.ActivityThread.-wrap11(ActivityThread.java)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:148)
    at android.app.ActivityThread.main(ActivityThread.java:5417)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Caused by: com.badlogic.gdx.utils.SerializationException: Class cannot be created (missing no-arg constructor): es.danirod.rectball.model.Bounds
Serialization trace:
wiggledBounds (es.danirod.rectball.model.GameState)
    at com.badlogic.gdx.utils.Json.newInstance(Json.java:1019)
    at com.badlogic.gdx.utils.Json.readValue(Json.java:875)
    at com.badlogic.gdx.utils.Json.readFields(Json.java:780)
    at com.badlogic.gdx.utils.Json.readValue(Json.java:902)
    at com.badlogic.gdx.utils.Json.fromJson(Json.java:714)
    at es.danirod.rectball.android.AndroidLauncher.onCreate(AndroidLauncher.java:93)
    at android.app.Activity.performCreate(Activity.java:6237)
    at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
    ... 9 more
Caused by: com.badlogic.gdx.utils.reflect.ReflectionException: Could not instantiate instance of class: es.danirod.rectball.model.Bounds
    at com.badlogic.gdx.utils.reflect.ClassReflection.newInstance(ClassReflection.java:70)
    at com.badlogic.gdx.utils.Json.newInstance(Json.java:1001)
    ... 17 more
Caused by: java.lang.InstantiationException: java.lang.Class<es.danirod.rectball.model.Bounds> has no zero argument constructor
    at java.lang.Class.newInstance(Native Method)
    at com.badlogic.gdx.utils.reflect.ClassReflection.newInstance(ClassReflection.java:68)
    ... 18 more

Sugerencia para puntuación

Se me ocurren dos ideas para la cantidad de puntos de una combinación:

  1. Que se añadan puntos extras por cada bola dentro de la combinación que tenga el mismo color que las esquinas.
  2. Que se cuenten también las combinaciones COMPLETAS que se encuentren dentro del área de combinación, incluyendo las esquinas. Algo así como combinaciones anidadas.

Add a tutorial

Feedback from my Facebook friends is suggesting me that I should add a tutorial. People who have watched the livestream sessions might know how to use the game, but this is not very usable to someone who hasn't ever heard about Rectball.

Game wrongly resumes on Android when activity changes during pause

Source:

Reproducible steps: During the game press BACK to show the leave dialog. Now, go press HOME to go back your home screen to hide Rectball. Show Rectball again. The game is resumed, while the "leave dialog?" is still visible.

Expected behaviour: the game should not resume because the leave dialog is still visible.

Portar los estilos a un Skin

Qué StyleFactory ni qué niño muerto, lo que hay que hacer es mover los estilos a un Skin pero ya. Skin tiene dos formas de mantener recursos. Los puedes agregar por medio de archivos externos (archivos atlas y JSON), o de forma programática mediante código usando los métodos add, get...

La misión es clara. Todos los estilos usados para representar títulos, botones, checkboxes y demás, se deben introducir en la Skin por el momento de forma programática para no sufrir mucho mientras se hacen las modificaciones. Luego se puede entrar a debatir si es buena idea mover eso a archivos. No tiene por qué ser necesario, si se deja limpio se puede dejar en código.

Posibles Power up - Sugerencia

Te paso algunos posibles power ups:

  • Hace que salga una combinación en sus cuatro diagonales.
  • Te dice una posible combinación.
  • Explota alrededor los lados y sale nueva combinación al azar.
  • Tiempo más rápido.
  • Tiempo más lento.
  • Segundo extras en el tiempo.
  • Te cambia la horizontal y la vertical de un color.
  • Te pone las cuatro esquinas del tablero del mismo color.
  • Durante un tiempo, una cantidad de segundos, algunas posiciones, por ejemplo el centro, las esquinas o determinadas coordenadas, cambian al azar, cada segundo o cada medio segundo.
  • El tablero cae o sube, o se mueve a izquierda o derecha, una fila o una columna, apareciendo nuevas combinaciones en el hueco restante.

Algunas son peligrosas en el sentido de que pueden que se haga un tablero imposible de resolver. Si se me ocurren más te cuento, y por supuesto, si te apetece usar alguna de estas, bien y si no también :D

No hay High Score

En estadísticas no se muestra la puntuación más alta; solo se ve la total.

Bug con tecla back

Al pulsar la tecla back en la pantalla de Game Over, el juego se cierra en su totalidad en vez de quedarse en la pantalla principal.

Botón de ayuda bugeado 2

Este causa que Rectball se vuelva loco. Como hacerlo, se inicia un juego nuevo, hay que esperar a que la barra del tiempo este justo debajo del botón de ayuda, cuando pase esto le empezamos a dar a la ayuda sin parar hasta que salga la ventana de perdiste el juego y le damos repetir, entonces se volverá loco. Ojo, no le debemos dar al botón ayuda ninguna sola vez antes de que llegue la barra del tiempo a donde dije. En android.

Board detection issues are still a thing

Source: https://twitter.com/ikanian/status/654183382956552192

I know a way for dealing with this:

Usually:

  1. The user has selected a combination.
  2. The selected balls are hidden.
  3. New balls are generated.

Now:
4. Check the board for valid combinations.
5. Check if the game has only one combination possible.
6. Check if that combination is on the same spot than the combination the user has just done.
7. If it is, then you are probably on an infinite loop.

What to do:
8. STOP THE TIMER!
9. Fade the screen to gray.
10. Shake the screen (shaking action has just been introduced on tutorial)
11. Regenerate the board.
12. Fade the screen to color.
13. Resume the timer.

Fix the crappy Action system

I'm using Actions to schedule the most random events ingame. I should reconsider what I do with Actions and clean it properly because all this runnables and all these threads and all these race conditions are harmful.

Sharing support

Abstract

Sharing support is finally expected to arrive on Beta 4. With sharing, users can share screenshots and scores of the games that they play. This can be used to show to friends or other people how well they play Rectball.

Objective: Let users share their scores using a Share button in the game over screen.

Tasks

  • Add Platform API. Create an API for letting side projects (desktop, android...) run their own code.
  • Add share button. The share button is visible in game over screen.
  • Add desktop action. When pressed on desktop, share button will ask the user for a location in the file system for saving a screenshot to the computer.
  • Add Android action. When pressed on Android, share button will show a sharing intent using Android SDK for sharing the screenshot and some text to another Android app (SMS, Twitter, Facebook, WhatsApp...)

Captures

screenshot_2015-10-18-03-01-52
filedialog

Bug con la tecla back

Al apretar la tecla back en la pantalla de Game Over, se inicia una nueva partida en vez de volver al menú.

Sugerencia en Estadísticas

Los _Datos por colores_ y los _Datos por tamaño_ deberían ordenarse según el valor de la estadística.
Ejemplo:

  • Verde 23
  • Azul 19
  • Rojo 16
  • Amarillo 16

Si tienen el mismo valor, da igual cual va antes o después.

Display help on settings screen

Settings in settings screen should have a help button or the labels should be clickable. When triggered, you should be able to see information about that setting in a dialog, so that it helps the user to know what does that checkbox.

Sugerencia para logros

Se me ocurre que el juego (desde su nueva actualización) escanee las stats para ver si se pueden aplicar determinados logros así no jode al usuario.

`scores` file should move to a more private location

At the moment the scores file is generated as a local file scores and stored in the same folder as the JAR file. Should be a better idea to move this file to a private location where is less accessible by the user. For instance:

  • Windows: ~/AppData/Local/.rectball/scores
  • MacOS X: ~/Library/Application Support/.rectball/scores
  • Linux ~/.rectball/scores

Instalacion de versiones.

Esto es una sugerencia, no un bug.
Otras aplicaciones cuando se instalan, si encuentran una version anterior, avisan que esta instalada esa version por si no quieres "actualizar".
Yo al instalar la nueva version, se instalo y no me pregunto nada y tenia otro rectball instalado anteriormente

marcador de tiempo

He notado que cuando pides ayuda y estas muy cerca de acabar el tiempo este se sale del rectángulo amarillo.

Bolas grises en Game Over

Si le das a salir juego (si/no) el tiempo sigue y si da game over, las bolas de ultima sugerencia salen en gris.

Pause has a bug

Try this: create a new game. Quickly change to another window on desktop. After a few seconds, the game is still in pause because you aren't looking at the game window, but the balls will be coloured. This should not happen.

Hint doesn't always substract time

Imported issue.

Play a game. Ask for a hint. Let the time run out. Start another game. Ask for a hint. That second hint won't substract time.

Tercera sugerencia del día

Se me ocurre que las stats puedan ser compartidas con otras personas para poder presumir. Si no se puede todo, entonces que sean las stats más importantes.

Splash screen

añadir un splash para que no salga la barra de carga

Blurry fonts on Android using v0.4.5

Fonts are looking terrible since TTF fonts were replaced by BitmapFont.

It is understable why the change from TTF to BitmapFont was made: as of libGDX 1.7, HTML5 backend does not support TTF fonts, therefore if the game wants to be ported to HTML5, it is required to change TTFs to BitmapFont.

However, alternative methods for providing high definition fonts should be investigated. At the moment, the fonts looks terrible when used in phones with high DPI value.

Tiempo mal mostrado en estadísticas

El tiempo total jugado, en la pantalla de estadísticas, aparece solo en minutos y segundos, y me parece que estaría bien que se dividiera también en horas. Así, en vez de mostrar 61:15, que se muestre 1:01:15.

UI: Diagonal selection

Imported from: https://twitter.com/josecodfacilito/status/665138528985182208

Game could allow the user to select just the diagonals of the rectangle and check by pressing only two balls and guessing whether the other two balls form already a rectangle. The user loses less time.

The fun thing about this issue is that this could be merged with the work I'm doing with the drag and drop selection mode. This is: the user drags one corner to the other one. It can be used in a new "fast mode" (for instance, less time, but more score for each combination).

Game over sugerencia

En el game over se queda la ultima recomendacion y caen el resto de bolas.
Mi sugerencia:
Mostrar la ultima sugerencia unos instantes y luego hacer que caigan todas las bolas, incluidas las de la sugerencia.
Es decir, hacer en 2 pasos el game over, primero la sugerencia, poniendo todas las bolas en grises menos las de la sugerencia y luego la sugerencia tambien en gris y que desaparezca todas las bolas.

Android: Crash when press Back during loading screen

I've seen this bug in Google Analytics being reported by the automatic crash reporter over and over.

captura de pantalla 2015-11-20 14 16 54

By looking at the source code I probably know what is the source. The pointed line is the one that plays a sound. It could be that if the user presses BACK on the Loading screen, the game will try to play the Back sound, but since we are in loading screen, the player isn't actually ready yet. The fact that I can reproduce this on my phone by opening Rectball and quickly pressing Back during the Loading screen makes this more suspicious.

Jugada final

La jugada que te muestra al finalizar el tiempo no siempre es la mejor o la más amplia. Parece ser que es la primera que encuentra.

Caso de prueba: encontrar una combinación bastante grande y pulsar solo tres esquinas, esperar a que finalice el tiempo, a veces mostrará la combinación que tenemos medio pulsada y otras una más pequeña.

PD: Me extraña que nadie lo haya visto antes por eso no se si realmente que muestre la primera que encuentre sea el comportamiento programado o de verdad es un bug.
PD2: Perdón por molestar al creador estando en clase xD.

Instalacion de versiones.

Esto es una sugerencia, no un bug.
Otras aplicaciones cuando se instalan, si encuentran una version anterior, avisan que esta instalada esa version por si no quieres "actualizar".
Yo al instalar la nueva version, se instalo y no me pregunto nada y tenia otro rectball instalado anteriormente

Sugerencia con animación de puntuación

Se me ocurre que el +X que aparece al hacer una combinación bonificada sea de un color distinto a blanco o que tenga otra animación, así es más fácil reconocerlas y no shockea tanto ver un número primo como 11 o 13

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.