Math game question

freneticzfreneticz SwedenMember, PRO Posts: 779
edited June 2017 in Working with GS (Mac)

Instead of making every level so its the same every time i want a random function, lets say you get the number 1,1,2 and a plus sign......then you must drag them in order 1 plus 1 = 2....can you somehow check so its give you OK for that but if you set them 2 plus 1 = 1 its fail.

Hard to explain :) but maybe someone can help me here.

///Micke

Comments

  • HopscotchHopscotch Member, PRO Posts: 2,782

    @freneticz

    I would start by building a text representation of the correct order.

    Then do the same with the actions from the user, and compare the two.

    Does the user have to drag the actors into a specific location, or just roughly move them around the screen into the right order?

  • freneticzfreneticz SwedenMember, PRO Posts: 779

    Drag into a specific location.

    How do you build a text representation? and how to do it when there can be some random numbers & plus or minus and so on

  • HopscotchHopscotch Member, PRO Posts: 2,782

    I may have something lying around, hang on...

  • HopscotchHopscotch Member, PRO Posts: 2,782

    @freneticz sorry, don't have anything isolated enough to send right now and got called away, but will dig something up later if you have not been helped yet.

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    edited June 2017

    Here's a hastily thrown together demo. Click the green square to generate an expression. Then drag a number, drag an operator, and drag a second number to match (or not) the generated expression. I didn't add the right side of the equation so you'd have to do that but this is really just a starting point anyway.

    Caveat: I'm sure there are much more elegant ways to do this!

    Edit: bah... it doesn't work very well. =(

  • HopscotchHopscotch Member, PRO Posts: 2,782

    @freneticz

    Project attached, have a look, should be close to what you need.

  • freneticzfreneticz SwedenMember, PRO Posts: 779

    @Hopscotch Thanks alot :) i will look & see if i understand anything (never worked with table)

  • HopscotchHopscotch Member, PRO Posts: 2,782

    @freneticz my pleasure, just ask if there is something unclear. The example does use a few "tricks".

Sign In or Register to comment.