raulvillares / 3sacrowd

Tic-Tac-Toe puzzle using plain javascript :video_game:
https://raulvillares.github.io/3sacrowd/index.html
35 stars 69 forks source link

Medals for achievements #24

Closed raulvillares closed 6 years ago

raulvillares commented 7 years ago

Implement the possibility to win 3 medals for every level, each one for some kind of achievement:

  1. Medal 1: Complete the level in less tan X time
  2. Medal 2: Complete the level with less than X movements
  3. Medal 3: Complete the level in a row (without undo a movement (neither with the undo button nor changing a square manually back to empty).

Achievements 1 and 2 must by configured in the levels.js file.

When the level is completed, show the number of achievements with the help of this images (medal_on is the achievement is completed, medal_off if not).

image image

This can be done incrementally (for example: one PR for changing the level.js file to configure achievements for every level, another PR to show the number of movements regarding the max movements (8/25),... and so on.

raulvillares commented 7 years ago

A prototype is worth a thousand meetings:

image

dallmanr commented 7 years ago

I am interested in trying this. Having never worked on anything open source before this seems like a fun project to start. Do you have a time in mind for the levels? I am not sure if it is specified anywhere.

raulvillares commented 7 years ago

Hi @dallmanr ! Thanks for your interest.

@michaelkoska is working on this but we think there is room for you. Maybe you both can distribute the work. I see four subissues:

  1. The logic to evaluate achievement 1 (time)
  2. The logic to evaluate achievement 2 (movements)
  3. The logic to evaluate achievement 3 (no undo)
  4. Rendering achievements when level is completed

Anyway, I'm open to suggestions. The goal of this project is to learn and have fun.

Michael is working on point 1. How do you feel about it?

Regarding max time for levels... I don't know, we have too choose a time that fits well with every level (no easy to achieve but not impossible). Since it is configured in levels.js file, will be easy to change it if we feel there is a need to. Same thing to max number of movements.

Thanks!

MhdTlb commented 7 years ago

I want to participate in this project. What part can I work on?

raulvillares commented 7 years ago

Hey @MhdTlb sorry for the delay, I've been busy these days. Thanks for your interest! What do you think about working on point 4 Rendering achievements when level is completed

You can mock 3 functions in level.js file (maxTimeAchieved, maxMovementsAchieved, noUndosAchieved) that return a fixed boolean value and use them to render the results when each level is completed.

Some other people can work on the real implementation of the 3 functions.

SharayuM commented 7 years ago

Hello. It seems a pretty interesting project. Is there anything I could help? I haven't done any open source contribution and looking forward to do this.

raulvillares commented 7 years ago

Hello @SharayuM , thanks for your interest! Sure you can help. This is a simple project to help people take their first steps in GitHub, so everybody is welcome.

Do yo want to work on this issue? I just merged a pull request by @michaelkoska that implements part of the features requested for this issue. We are going to complete it and improve it. If you're interested I can give you some directions.

Also, if you have any idea to improve the game... go for it. And I mean any idea, even rename a function or a variable.

SharayuM commented 7 years ago

Hello, Thanks for your response. I do want to work on this project. Just wanted to ask as from where should I start learning the implemented project.

Thank you. On 14-Jul-2017 4:11 am, "Raúl Villares" notifications@github.com wrote:

Hello @SharayuM https://github.com/sharayum , thanks for your interest! Sure you can help. This is a simple project to help people take their first steps in GitHub, so everybody is welcome.

Do yo want to work on this issue? I just merged a pull request by @michaelkoska https://github.com/michaelkoska that implements part of the features requested for this issue. We are going to complete it and improve it. If you're interested I can give you some directions.

Also, if you have any idea to improve the game... go for it. And I mean any idea, even rename a function or a variable.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/raulvillares/3sacrowd/issues/24#issuecomment-315221369, or mute the thread https://github.com/notifications/unsubscribe-auth/AVI1bDLhMujrlCFR8KjaaH5qN_BahjIgks5sNp0BgaJpZM4N93fV .

raulvillares commented 7 years ago

Hi again @SharayuM ,

I don't know exactly what you mean. You can clone the repository and take a look at the code.

krupam commented 7 years ago

Hi, I am a first-timer and I would love to work on this project.

raulvillares commented 7 years ago

Hi, I am a first-timer and I would love to work on this project.

Great @krupam ! What about show the information about how to reach the medals? Now, info div shows this:

level number · current time · current number of moves

like

1/19 · 00:21 · 3 moves

It should show something like:

1/19 · 00:21 (max 01:00) · 3 moves (max 30)

Do you feel like working on it? Let me know if you need more informations about this.

prabodhmeshram commented 7 years ago

Hi, Is this issue still open. This seems interesting. If there is any issue or feature need to be developed, I would love to contribute. Thanks!

raulvillares commented 7 years ago

Thanks for your willing to help @prabodhmeshram

Yes, there's one more thing it would be nice to have in order to complete this new feature. See my previous message:

https://github.com/raulvillares/3sacrowd/issues/24#issuecomment-322903340

prabodhmeshram commented 7 years ago

Sure @raulvillares . Will work on it.

prabodhmeshram commented 7 years ago

Added the Changes @raulvillares

raulvillares commented 6 years ago

Merged! Thanks for your work @prabodhmeshram .