Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

PHP

Mike Mitchell
PLUS
Mike Mitchell
Courses Plus Student 27,026 Points

The best tools to build a learning game - html5/css/js/jquery/php?

Hey there!

I recently created a simple educational web site that is pretty static. It tells a story while teaching users how to use multimedia in their online courses.

What would be really cool is if I could make the site interactive. I want users to learn four things and each thing gives them control of an element - wind, water, earth, and fire.

They need all four elements to cast a spell and destroy the final boss. Typical gaming structure, right?

Question - I'm most comfortable with html and css and a little javascript and jquery. I'm also moving through the php track here.

Are these the best tools to use for this kind of project?

What I'm struggling to figure out is how to track progress. I want the structure to be open. Choose your own path. But I want users to earn their elements and then use those elements in the last segment.

Any rough ideas of where to look would be most helpful.

Thanks!

Mike

3 Answers

Mike, will this be an actually game, with characters and keyboard controls? If so all you would really need to do is build each level as a separate mini game, and then if they pass the level have the browser pass the complete info back to the server to be saved as part of their user account. If you could flesh out your idea a little more and I might be able to point you in a more concrete direction.

Mike Mitchell
PLUS
Mike Mitchell
Courses Plus Student 27,026 Points

Andrew, what you've described sounds like a smarter way to approach this project.

I want the learner to have a character and to progress through four or five different levels using point and click rather than keyboard controls.

I stumbled upon MongoDB yesterday. Probably need to learn more about persistence to get this project working.

Think I'll start with what you suggest - build the first mini game and see how I'm going to store the learner's progress.

Thanks for the advice, Andrew!

If you take the mini game approach, then you don't need to use MongoDB. You could use and database you want, and once they complete the mini-game you can simple have AJAX pass a value back to the server. That value could then be stored in the server in the user's row in the user table of the db. I picture the user table having a column for ID, Username, Password, Email, and a column for each mini-game. You could set the column to hold only a boolean value of true or false.

Mike Mitchell
PLUS
Mike Mitchell
Courses Plus Student 27,026 Points

Awesome.

I've never worked with AJAX, so I'm going to go check out the library and see what's up.

Really appreciate all the help, Andrew. Thanks!