Would like to help, but I don't know that game. Could you post some screenshots to explain?
As far as I understand it now, I would combine the first two decisions in one decision, since they are just the opposite of each other. Moreover I suspect that the toggle command which you put at this moment in a separate mimicked standard action (your third decision) can be included in that first decision. The second decision could then check the value of 'matches_removed' variable and show the message. But I don't know what has to happen more when already 4 matches have been removed?
Moreover I would recommend using shared actions, since you use this action over and over again. Which event do you use to trigger the action: click box over both images, or shape buttons with the images?
Here is the matchstick puzzle i am trying to do - remove 6 matchsticks to make 10.
I had not thought of showing the message when they removed the 6th matchstick (as per example in image above). That is possible.
But i think a more complete solution would be to show the message when they click the 7th match, because this allows them to replace the 6th match
without getting the message.
FYI: Nothing happens when 6 matches are removed but I want an error message displayed when the user clicks a 7th match.
I could include a new decision at the start
IF “matches removed” = 6
Show click box (to remove msesage)
I'm just not sure how you deal with the visibility, match count, and toggle?
i.e. don't allow removing a 7th match but do allow the replacing of the 6th match.
I am using a click box over the two images.
I plan to use shared actions once i get my scaled down model working (i.e. just using 3 matches instead of 15 at the moment)
Approach with shared actions is different, would start right away with them. If you first try it out with advanced actions, the setup will not necessarily be the most usable.
It would take some time to work this out, thinking about not using one click box over two images but using two shape buttons, one with the match and one with the outline. It could prove more efficient when using shared actions. Especially if you want to use this for other situations with another number of matches, total as well as to allow removal. Another approach could be using two identical slides, switching back and forth between them.
I think i worked it out - AA for each match below (for remove 6 matchsticks to make 10).
I added an "AttemptsExceeded" variable.
Re: Shared actions - Can you explain why two shape buttons are better than using one click over two images?
Decision 1: Message
IF “v_Matchstick_visible” = 1 AND “v_matches removed” = 6
Show click box (that will remove message)
Assign "v_AttemptsExceeded" = 1.
Decision 2: Visible
IF “v_Matchstick_visible” = 1 AND "v_AttemptsExceeded" = 0
Hide matchstick image
Show matchstick outline image
Increment “v_matches removed” counter by 1
Decision 3 - Invisible:
IF "v_Matchstick_visible" = 0
Show matchstick image
Hide matchstick outline image
Decrement “v_matches removed” counter by 1
Decision 4 - Toggle1:
IF "v_Matchstick_visible = 0" OR "v_Matchstick_visible = 1" AND "v_AttemptsExceeded" = 0
Decision 5 - Toggle2:
IF "v_Matchstick_visible = 0" AND "v_AttemptsExceeded" = 1
I have a working and tested solution, with only 3 decisions in one shared action. I think you make it too complicated, why do you never use the ELSE part of a condition? Moreover you need to have a variable for each matchstick or you end up with conflicts. If you toggle your v_Matchstick_visible with one matchstick, it will remain toggled for the next one, how will you solve that?
In my solution:
- First decision will switch between image and outline, toggle the visibility var for that matchstick, increment or decrement a counter
- Second decision will check if counter reaches 6, in that case will show the Warning message, if not will hide that message
- Third decision will check if the correct matches are removed, if yes will hide the Warning message and show the Success message
A reset button is added, so that user can play again.
And I have a Success text appearing when the correct matches are removed.
Will probably post this solution on my blog, you'll be able to check it out. I tested with all matches.
Be careful with combinations AND + OR! They can often give weird results.
Oops, forgot to answer your question. I created the solution with the click box. I mentioned using two shape buttons, because they would simplify your actions, have a feeling that you don't grab totally the concept of conditional actions with multiple decisions. Sorry, I don't want to insult you, it is just the result of looking at what you showed about your projected actions. That splitting up has nothing to do with using shared or advanced actions, just about simplifying.
Hi Lieve, Yes i had planned to use a seperate variable for each match, just wanted help with the AA logic. My AA is complicated because i wanted the user to be able to replace a match even when six matches are removed, and not just display a message after 6 matches were removed. I look forward to reading your solution and learning from it. Re: your last comment - I don't have much AA experience and am totally new to shared actions. Thanks Donal.
I allow to manually reset a matchstick one by one, or to reset everything. And if the user cheats and removes a 7th matchstick, everything will be reset automatically.
Creating such a game is not that hard (for me), but having to write out all the explanations takes a lot more time.
It is published, you can have a look at: Matchstick Game - shared actions - Captivate blog
I'm only getting around to having a look at your solution now.
Yes - mine was far too complicated and yours was nice and simple.
It's nice to see how you approached it after trying it myself.
I learnt alot - e.g. showing warning message and allowing a pencil to be removed at the same time, creating two AAs (using "Else" parts as well), using a group for messages etc.
I'm trying to implement your solution and i have a problem.
I renamed two images - a pencil image and the outline image.
But the orginial names appear along with the new names when i go to save the AA as a shared action.
So i cannot create the Shared Action.
I've checked the timeline, aa, updated the aa, previewed the aa, and created a Show action to see if i could see the objects.
The orginal objects/names were not there.
Have you come across this before? Any solution? or will i just recreate the AA.
Not sure what happens but I fear a conflict between names being used twice. Captivate is very sensitive to that, on the whole I always recommend to never reuse a name at all and to develop a labeling system that will avoid duplicate names. I really plan to write a cookbook for actions (and busy writing about labeling at this moment), your game will be part of it, one of the recipes. KISS is a favorite motto of mine, but I had to create several versions of the actions to get to the final result. Making it simple is often not that simple. And I had also in mind that the shared actions could be tweaked again to make them suitable for similar match games.
Maybe it was a conflict. I had the numbering sequentially i_pencil01 to i_pencil15.
Then i changed it to block numbering for each letter of "TEN" - 10, 20, 30.
So i changed i_pencil01 to i_pencil10 in the first block.
That was going to be my next question after i had worked through this example. i.e.
1. a move matchstick game
2. a move matchstick game that included some at angles.
If you're looking for other receipes you could include a grid "recycling" question.
Put the rubbish in the correct container.
Yellow Blue Green Black
Where only 1 container is allowed per row.
To show smart shapes in action you could use smart shapes as button with variable set to blank initially and an "X" when clicked.
When one shape in the row is clicked the others in the row become blank.
Use shared actions for each row.
A Submit button would show visual indicators (X, tick) and a score.
Maybe it too "a la carte" for your cookbook : )
And I'm sure you'll come back with a simplier way : ) : )
That rubbish thing can better be done with Drag&Drop, there must be some example somewhere.
I was first thinking about setting up same matchstick game but with other configurations.
Drag&Drop has several possibilities if playing with object actions: Drag&Drop tips - Captivate blog