Moodle Plugins directory: Treasure Hunt | Moodle.org

Treasure Hunt
Treasurehunt
Go to the presentation page for graphical descriptions and tutorials. (Descripción y tutoriales disponible en la página en español).
Outdoor treasure-chases with geolocation.
This module for Moodle allows to organize outdoor-serious-games with your students. TreasureHunt is integrated into Moodle Mobile App and, alternatively, implements a browser-based play application (no need to install the native app) and a geographical editor for encoding the stages of the game. The game can be configured with a range of options that makes the module to be very flexible and useful in many situations: individual/team, moving/desktop-marking, scoring from time, position, completion, etc.
"Availability" Companion plugin
Treasure hunt allows to create infinite, flexible workflows with any Moodle's activity when used in combination with Availability Treasurehunt and Moodle's completion conditions.
Create learning trips using outdoor activities or indoor map-based routes!
Installation
- Install from the plugins menu or manually unzip, and copy into Moodle's /mod folder
- visit administration page to install module
- configure default settings for your site
- use in any course as wished
Operation
- create an instance of the activity
- create one or more roads to be followed by your "hunters"
- create a set of stages in each road.
- draw the location of the stages with the built-in GIS editor. Optionally enter or generate a QR code to be scanned to discover that location.
- write smart and educational clues that point to the next stage. Optionally, write a multiple-choice question to double-check the discovery of the stage or lock a stage until another Moodle's activity is completed. You can also lock other activities until the student reach a particular milestone in Treasurehunt with
Availability Treasurehunt.
- select the modality of the treasure hunt: individual or team (you will need to create the groups and groupings of students).
- adjust the grading method and penalisations.
- let your students play the game.
- monitor the game from your teacher dashboard.
Troubleshooting of game play
One of the main issues affecting the functionality of TreasureHunt stems from users not granting geolocation or camera permissions during gameplay.
These permissions are essential for enabling location tracking and QR code scanning, which are core features of the experience.
On Android devices, users can enable these by going to Settings > Apps > TreasureHunt > Permissions, and then allowing access to Location and Camera.
On iPhone, the process involves opening Settings, scrolling down to TreasureHunt, and toggling on Location (set to “While Using the App” or “Always”) and Camera access. Without these permissions, the game cannot operate as intended, leading to incomplete stages or failed interactions.
Grading of the module
The module will produce a grade for every student (or team) running the hunt. The implemented schemas are the following:
Choose from:
- Grade from time (absolute or relative): the winner of the hunt marks the best time. The grade is calculated by interpolating the finishing time being 50 the end time of the hunt and 100 the best finishing time. The players that did not finish the hunt receive a grade under 50 calculated just by the number of riddles solved.
- Grade from riddles: each player (or team) scores proportionally by number of riddles solved, being 100 when a road is completely solved, and 0 when no riddle is solved.
- Grade from position: The score is calculated by interpolating the position in the ranking, being 100 the score for the first player and 50 for the last player. The players that did not finish the hunt receive a grade under 50 calculated just by the number of riddles solved.
For all these schemas optionally it can penalize by location failures and wrong answers.
Penalization is expressed in % of the grade. Per example, if penalization is 5, a player with 3 failures will penalize his grade by 15%, that is, will receive 85% of the grade calculated by the rest of the criteria.
Note on QR Codes support
- The stages can be solved by marking a location or by scanning a QRCode. This is useful indoor or where the GPS gives a bad precission.
- Treasurehunt includes a browser-based code scanner that works at least in the major browsers in Android and iPhone devices. As with location, it is very important that users give camera permissions upon request from the gaming screen.
- The module includes a pre-test procedure if the game includes QRcodes.
- You can use existent QR labels or generate your own directly from the edit-stage page.
Enjoy.
Releases summary
- v2.0.0 New QR Scanner library. Correctly supports both cameras on IOS devices.
- v1.9.0 Support availability/treasurehunt (https://github.com/juacas/moodle-availability_treasurehunt). Support stage hints (direction, distance, "insideness").
- v1.8.2 Trigger Clue dialog after each notification. Preview mode for teachers.
- v1.8.1 Fix compatibility with some themes and fix deprecated code in moodle and php 8.
- v1.8.0 Moodle 5.0 release. Add support for overview api.
- v1.7.1 Improve SVG static images. Fix aspect ratio of images to ensure that SVG are rendered vectorial.
- v1.7.0 Add XYZ Tiled layers. Fancy style deprecated (jquerymobile is not supported anymore).
- v1.6.1 Moodle 4.5 compatibility. Player style classic deprecated.
- v1.6.0 Support of Freeze contexts.
- v1.5.8 Fix polyfill obsolete library.
- v1.5.7 Change deprecated QR generation from chart.googleapis.com to quickchart.io (Issue #61 thanks to @idograca)
- v1.5.6 Remove get_legacy_log function deprecated by 4.1.5. #60 Small UI changes.
- v1.5.4 Fixes about accesibility (color-blinded), allow filters in texts and better visualization of play page on Moodle 4.
- v1.5.0 Integration into Moodle Mobile App and some minor improvements.
- v1.4.0 Choice between 3 different playpage styles. New bootstrap-based play page more compatible and light-weight. Street view link from play page.
-
v1.3.0 Dates and times update in real-time. Interface pulishment. Workaround to Babel compiler conflict in player page.
- v1.2.22 UI for QR Scanner in edit form improved. QR scanner fixed for Xiaomi Redmi S2. Player UI improved in question section.
- v1.2.18 Fixed compatibility of GIS editor with Edge browser when using jqueryui > 1.11.
- v1.2.17 Auto update timer in GPX tracker.
- v1.2.15 Full compatibility of QRScanner with IOS 11 (iPhone && iPad).
- v1.2.14 Fix camera preview sizes. Implement switching cameras.
- v1.2.13 Change QR scanning library to fix the firefox regression.
- v1.2.12 Fix for compatibility with Moodle 2.9.x.
- v1.2.11 Link to online tutorial added to edit page.
- v1.2.10 Fix support to long texts in clues. Left panel shows a truncated text.
- v1.2.7 Compatibility with MSSQL
- v1.2.6 Custom image maps. Validation form fixed.
- v1.2.5 Non-geographic images as base of the game.
- v1.2.3 Custom image maps. Support for WMS and uploaded images.
- v1.2.1 SVG images render with vector quality.
- v1.2.0 Custom uploaded images. Now the map can be customized in several ways:
- Custom overlays from uploaded images or WMS layers.
- Custom base maps from uploaded images or WMS layers.
- Override default base maps with uploaded imgaes or WMS layers.
- Disable geographical tools to use images not related to the terrain.
- Release v1.1.0 includes support for QR codes. It is very useful indoor (i.e. museums).
- Release v1.0.0 first production-ready release.
I hope I am posting in the right place and not being too trivial!
I thought that the results of the scavenger hunt were known only to me as the administrator, but instead other students can see the performance of fellow students as well.
Is there any way to avoid this?
Thank you.
Regards.
David
I've just released v1.5.5 with a new setting for enabling/disabling the progress board for students.
Thank you for your reply.
I installed the update, but it seems to me that the current games have not been changed (possibility to hide the ranking), I guess it can be normal. I will check now with a new game.
Another interesting feature could be to have hints available to reach a stage. It is possible that in some cases the hints may not be found by the participants and it would be a shame to stop the game. A hint system with penalties could be thought of.
I am testing the plugin for territory knowledge, but I would like the participant to have more attempts available, would that be possible? At least for the game without moving.
The plugin is really wonderful, I think with these tweaks it would become stellar!
Muchas gracias y buen trabajo.
What you are looking for is a conditional availability based on GPS (like https://moodle.org/plugins/availability_gps) or a course format (like https://moodle.org/plugins/format_gps).
Of course, you can combine Treasure Hunt with the other.
I have installed the versión 1.6.0 on Moodle 4.1 with PHP 7.4 and de upgrade of this plugin crashed. Where can i find the php minimun requirements for this plugin? I think that if a plugin is published as compatible with Moodle 4.1, it would be compatible with PHP 7.4. Is not this true?
Thanks!
But I have a problem I'd like to mention: I'm making a game with locations from all over the world.
This creates problems because the "street" layer, which is the only one that actually has location labels, changes language depending on the country...
And it's difficult for a young person in Mexico to learn Middle Eastern languages to locate specific locations.
I wanted to add maps, like OSM, but I haven't been able to. Any ideas on how to do that?
Thank you very much.
Luca
You can define a custom background map configuring a WMS service of you election as shown in https://juacas.github.io/moodle-mod_treasurehunt/custom_maps.html
¡Saludos desde España!
I was missing that update! XYZ works like a charm!
I have a few other questions I'd like to address:
1. Is there a way to disable the search button located at the top (left or right) of the map? This would make it a little more complex and force students to compare images from other apps.
2. Out of nowhere, starting today, the screen styles menu only shows BOOTSTRAP. For both existing and new games...
Any thoughts on this? Because I didn't change any settings.
Thank you so much!! I'm writing in English so everyone on the forum can read it!
https://drive.google.com/file/d/1FGMMareVxwEBiYwpQtVHfaSE-AWL7FnS/view?usp=sharing
https://drive.google.com/file/d/1F97FuNddUXtyX8LpYZAvQF_y5l8C2AJe/view?usp=sharing
https://drive.google.com/file/d/1FGTxehYLMUtnDQvQXwuMx4V9KeB86s-U/view?usp=sharing
Currently I can't support them anymore while improving the plugin.
However, the old code are still there if you wanna experiment whiti it, you can remove the comments at https://github.com/juacas/moodle-mod_treasurehunt/blob/4ea1e8e72052b6a95ead2f5d937071cbee7d67ed/locallib.php#L2940
If somebody contribute new player styles I'll be more that happy to include it in the project.
Sorry for the inconveniences.