-1

I am new to LTI and I want to try to create a Tool Service Provider for an existing Unity game which shall be integrated into Moodle. I build the Unity game as a WebGL-Application without any issues but now I don't know how to integrate the Tool Provider the proper way. When launching the game with the corresponding files needed for the OpenID-Connect, I get a 404 error on Moodle. Without these files, the game starts fine.

Because Moodle already provides a library for LTI (see https://github.com/packbackbooks/lti-1-3-php-library), I tried to follow their guidance. I wrote a login.php, a jwks.php and a launch_tool.php file including the described steps. From the login.php file I used the php-function readFile(...) to lead to the "index.html" file after validating. Furthermore, I implemented the IDatabase Interface in Database.php. I integrated these 4 files inside the ZIP-Folder containing the WebGL-Application and uploaded it to itch.io, because this I got this site recommended for uploading my game.

Inside of the Moodle course I configured an "External Tool" and provided the needed links to the platform. Now when starting the game, I get a 404 error. To integrate the itch.io game into Moodle, I used the embed link, but I'm not sure if I put in the links to the other files correctly. With the example of login.php, I tried these things: <embed_link>/login.php and <direct_link_to_game>/login.php and both options don't work.

Considering I'm very unexperienced in this field, I don't know if the problem comes from the links or if my php-Files are missing something. I don't try to receive any data from the game just yet, I just want to setup the connection first.

I am using LTI 1.3 for this.

LJᛃ
  • 7,655
  • 2
  • 24
  • 35
Peerius
  • 9
  • 4
  • We cannot fix descriptions alone. A [mre] of the issue would be needed too - see also [ask]. But a 404 simply means the resource doesn't exist. Check that the URL you provided actually points to a real file. – ADyson Aug 22 '23 at 14:54
  • Might be easier to convert Unity to a Scorm file - https://assetstore.unity.com/packages/tools/integration/scorm-api-53523 - then upload the scorm file to Moodle - https://docs.moodle.org/402/en/SCORM_activity – Russell England Aug 22 '23 at 23:41

0 Answers0