Wunderbyte-GmbH / moodle-mod_mooduell

Player vs. Player Game using Moodle Quiz Questions (Multiplayer Oriented Online DUELL)
Other
2 stars 4 forks source link

Students not able to play the game #85

Open fezile30 opened 5 months ago

fezile30 commented 5 months ago

have downloaded and trying out MooDuell. But I find that except for me, system administrator, who created the quiz, no other user is allowed to play the game.

After I have scanned the QR code, user details are not loaded on the app.

See attached pic.

Screenshot_20240607-222233

dasistwas commented 5 months ago

Are course participants able to see the MooDuell activity?

fezile30 commented 5 months ago

Yes. As System Admin I created the activity on Moodle. Opened the activity. Opened the QR code. Scanned the QR code. And under Welcome it shows my user details before I can continue to play the game. However, as a student/teacher, I see the activity. I can open it. I can display the QR code. But when I scan the QR code, no name of the user appears under Welcome and when I select Confirm, nothing happens from there. It just gets stuck. The Confirm button does not respond. But the Cancel button does.

I also tried creating the activity as a teacher of the course. But same thing appears. Teacher cannot see the activity they created.

fezile30 commented 5 months ago

"Teacher cannot see the activity they created." I mean, cannot play the activity they created.

georgmaisser commented 4 months ago

Hi, we are very interested in solving this. Could we make a video call to find out the problem? You can write to me directly or contact us via Wunderbyte.at

fezile30 commented 4 months ago

Please set up the meeting. I am in South Affrica

On Tue, 11 Jun 2024, 12:47 georgmaisser, @.***> wrote:

Hi, we are very interested in solving this. Could we make a video call to find out the problem? You can write to me directly or contact us via Wunderbyte.at

— Reply to this email directly, view it on GitHub https://github.com/Wunderbyte-GmbH/moodle-mod_mooduell/issues/85#issuecomment-2160434599, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGHP6GB466BBD7VBQNKJ2BLZG3IT3AVCNFSM6AAAAABI7JVWXKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNRQGQZTINJZHE . You are receiving this because you authored the thread.Message ID: @.***>

georgmaisser commented 4 months ago

We are basically in the same timezone then. Can you meet today at 14h, https://meet.wunderbyte.at/rooms/wf6-mnv-1z7-cq3/join ?

fezile30 commented 4 months ago

Sorry. Can we make it Friday @ 12:00. Same link?

On Thu, 13 Jun 2024, 12:12 georgmaisser, @.***> wrote:

We are basically in the same timezone then. Can you meet today at 14h, https://meet.wunderbyte.at/rooms/wf6-mnv-1z7-cq3/join ?

— Reply to this email directly, view it on GitHub https://github.com/Wunderbyte-GmbH/moodle-mod_mooduell/issues/85#issuecomment-2165215964, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGHP6GENITPIEZJYFZKMKJTZHFV7LAVCNFSM6AAAAABI7JVWXKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNRVGIYTKOJWGQ . You are receiving this because you authored the thread.Message ID: @.***>

georgmaisser commented 4 months ago

Yes, I'll be there!

fezile30 commented 4 months ago

Thank you. See you then.

On Fri, Jun 14, 2024 at 10:02 AM georgmaisser @.***> wrote:

Yes, I'll be there!

— Reply to this email directly, view it on GitHub https://github.com/Wunderbyte-GmbH/moodle-mod_mooduell/issues/85#issuecomment-2167473943, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGHP6GBUGXYS5WNUE3RVW7LZHKPPRAVCNFSM6AAAAABI7JVWXKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNRXGQ3TGOJUGM . You are receiving this because you authored the thread.Message ID: @.***>

--


Fezile Mlungu Interactive Multimedia e-Learning Designer and Developer

(+27) 083 863 7611

fezile30 commented 4 months ago

Thanks

On Fri, 14 Jun 2024, 10:02 georgmaisser, @.***> wrote:

Yes, I'll be there!

— Reply to this email directly, view it on GitHub https://github.com/Wunderbyte-GmbH/moodle-mod_mooduell/issues/85#issuecomment-2167473943, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGHP6GBUGXYS5WNUE3RVW7LZHKPPRAVCNFSM6AAAAABI7JVWXKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNRXGQ3TGOJUGM . You are receiving this because you authored the thread.Message ID: @.***>

georgmaisser commented 4 months ago

Hi, thanks to your access we found out that on your platform, students don't have access to this crucial right:

webservice/rest:use

To fix this, you need to go to

yoursite/admin/roles/manage.php

And give either to all authenticated users or to the students in your course this capability.

Keep us posted if it works now! We will include a check on the activity to see if students in your course actually have this right.

fezile30 commented 4 months ago

Thank you very much. Will check it out and revert back to you as soon as possible.

On Mon, 17 Jun 2024, 10:49 georgmaisser, @.***> wrote:

Hi, thanks to your access we found out that on your platform, students don't have access to this crucial right:

webservice/rest:use

To fix this, you need to go to

yoursite/admin/roles/manage.php

And give either to all authenticated users or to the students in your course this capability.

Keep us posted if it works now! We will include a check on the activity to see if students in your course actually have this right.

— Reply to this email directly, view it on GitHub https://github.com/Wunderbyte-GmbH/moodle-mod_mooduell/issues/85#issuecomment-2172718085, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGHP6GHIFIHRSOY3HMZARRTZH2PI7AVCNFSM6AAAAABI7JVWXKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNZSG4YTQMBYGU . You are receiving this because you authored the thread.Message ID: @.***>

fezile30 commented 4 months ago

Thanks. I went to look at the file in the back end. Meanwhile I am not a programmer but I could not find any reference to webservice/rest:use in the code as attached here. Not sure maybe I missed something.

On Mon, Jun 17, 2024 at 10:49 AM georgmaisser @.***> wrote:

Hi, thanks to your access we found out that on your platform, students don't have access to this crucial right:

webservice/rest:use

To fix this, you need to go to

yoursite/admin/roles/manage.php

And give either to all authenticated users or to the students in your course this capability.

Keep us posted if it works now! We will include a check on the activity to see if students in your course actually have this right.

— Reply to this email directly, view it on GitHub https://github.com/Wunderbyte-GmbH/moodle-mod_mooduell/issues/85#issuecomment-2172718085, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGHP6GHIFIHRSOY3HMZARRTZH2PI7AVCNFSM6AAAAABI7JVWXKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNZSG4YTQMBYGU . You are receiving this because you authored the thread.Message ID: @.***>

--


Fezile Mlungu Interactive Multimedia e-Learning Designer and Developer

(+27) 083 863 7611

<?php // This file is part of Moodle - http://moodle.org/ // // Moodle is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // // Moodle is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with Moodle. If not, see http://www.gnu.org/licenses/.

/**

require_once(DIR . '/../../config.php'); require_once($CFG->libdir.'/adminlib.php'); require_once($CFG->dirroot . '/' . $CFG->admin . '/roles/lib.php');

$action = optional_param('action', '', PARAM_ALPHA); if ($action) { $roleid = required_param('roleid', PARAM_INT); } else { $roleid = 0; }

// Get the base URL for this and related pages into a convenient variable. $baseurl = $CFG->wwwroot . '/' . $CFG->admin . '/roles/manage.php'; $defineurl = $CFG->wwwroot . '/' . $CFG->admin . '/roles/define.php';

admin_externalpage_setup('defineroles');

// Check access permissions. $systemcontext = context_system::instance(); require_capability('moodle/role:manage', $systemcontext);

// Get some basic data we are going to need. $roles = role_fix_names(get_all_roles(), $systemcontext, ROLENAME_ORIGINAL);

$undeletableroles = array(); $undeletableroles[$CFG->notloggedinroleid] = 1; $undeletableroles[$CFG->guestroleid] = 1; $undeletableroles[$CFG->defaultuserroleid] = 1;

$PAGE->set_primary_active_tab('siteadminnode'); $PAGE->navbar->add(get_string('defineroles', 'role'), $PAGE->url);

// Process submitted data. $confirmed = (optional_param('confirm', false, PARAM_BOOL) && data_submitted() && confirm_sesskey()); switch ($action) { case 'delete': if (isset($undeletableroles[$roleid])) { throw new \moodle_exception('cannotdeletethisrole', '', $baseurl); } if (!$confirmed) { // Show confirmation. echo $OUTPUT->header(); $optionsyes = array('action'=>'delete', 'roleid'=>$roleid, 'sesskey'=>sesskey(), 'confirm'=>1); $a = new stdClass(); $a->id = $roleid; $a->name = $roles[$roleid]->name; $a->shortname = $roles[$roleid]->shortname; $a->count = $DB->count_records_select('role_assignments', 'roleid = ?', array($roleid), 'COUNT(DISTINCT userid)');

        $formcontinue = new single_button(new moodle_url($baseurl, $optionsyes), get_string('yes'));
        $formcancel = new single_button(new moodle_url($baseurl), get_string('no'), 'get');
        echo $OUTPUT->confirm(get_string('deleterolesure', 'core_role', $a), $formcontinue, $formcancel);
        echo $OUTPUT->footer();
        die;
    }
    if (!delete_role($roleid)) {
        // The delete failed.
        throw new \moodle_exception('cannotdeleterolewithid', 'error', $baseurl, $roleid);
    }
    // Deleted a role sitewide...
    redirect($baseurl);
    break;

case 'moveup':
    if (confirm_sesskey()) {
        $prevrole = null;
        $thisrole = null;
        foreach ($roles as $role) {
            if ($role->id == $roleid) {
                $thisrole = $role;
                break;
            } else {
                $prevrole = $role;
            }
        }
        if (is_null($thisrole) || is_null($prevrole)) {
            throw new \moodle_exception('cannotmoverolewithid', 'error', '', $roleid);
        }
        if (!switch_roles($thisrole, $prevrole)) {
            throw new \moodle_exception('cannotmoverolewithid', 'error', '', $roleid);
        }
    }

    redirect($baseurl);
    break;

case 'movedown':
    if (confirm_sesskey()) {
        $thisrole = null;
        $nextrole = null;
        foreach ($roles as $role) {
            if ($role->id == $roleid) {
                $thisrole = $role;
            } else if (!is_null($thisrole)) {
                $nextrole = $role;
                break;
            }
        }
        if (is_null($nextrole)) {
            throw new \moodle_exception('cannotmoverolewithid', 'error', '', $roleid);
        }
        if (!switch_roles($thisrole, $nextrole)) {
            throw new \moodle_exception('cannotmoverolewithid', 'error', '', $roleid);
        }
    }

    redirect($baseurl);
    break;

}

// Print the page header and tabs. echo $OUTPUT->header();

$currenttab = 'manage'; require('managetabs.php');

// Initialise table. $table = new html_table(); $table->colclasses = array('leftalign', 'leftalign', 'leftalign', 'leftalign'); $table->id = 'roles'; $table->attributes['class'] = 'admintable generaltable'; $table->head = array( get_string('role') . ' ' . $OUTPUT->help_icon('roles', 'core_role'), get_string('description'), get_string('roleshortname', 'core_role'), get_string('edit') );

// Get some strings outside the loop. $stredit = get_string('edit'); $strdelete = get_string('delete'); $strmoveup = get_string('moveup'); $strmovedown = get_string('movedown');

// Print a list of roles with edit/copy/delete/reorder icons. $table->data = array(); $firstrole = reset($roles); $lastrole = end($roles); foreach ($roles as $role) { // Basic data. $row = array( '' . $role->localname . '', role_get_description($role), s($role->shortname), '', );

// Move up.
if ($role->sortorder != $firstrole->sortorder) {
    $row[3] .= get_action_icon($baseurl . '?action=moveup&amp;roleid=' . $role->id . '&amp;sesskey=' . sesskey(), 'up', $strmoveup, $strmoveup);
} else {
    $row[3] .= get_spacer();
}
// Move down.
if ($role->sortorder != $lastrole->sortorder) {
    $row[3] .= get_action_icon($baseurl . '?action=movedown&amp;roleid=' . $role->id . '&amp;sesskey=' . sesskey(), 'down', $strmovedown, $strmovedown);
} else {
    $row[3] .= get_spacer();
}
// Edit.
$row[3] .= get_action_icon($defineurl . '?action=edit&amp;roleid=' . $role->id,
        'edit', $stredit, get_string('editxrole', 'core_role', $role->localname));
// Delete.
if (isset($undeletableroles[$role->id])) {
    $row[3] .= get_spacer();
} else {
    $row[3] .= get_action_icon($baseurl . '?action=delete&amp;roleid=' . $role->id,
          'delete', $strdelete, get_string('deletexrole', 'core_role', $role->localname));
}

$table->data[] = $row;

} echo html_writer::table($table);

echo $OUTPUT->container_start('buttons'); echo $OUTPUT->single_button(new moodle_url($defineurl, array('action' => 'add')), get_string('addrole', 'core_role'), 'get'); echo $OUTPUT->container_end();

echo $OUTPUT->footer(); die;

function get_action_icon($url, $icon, $alt, $tooltip) { global $OUTPUT; return '' . $OUTPUT->pix_icon('t/' . $icon, $alt) . ' '; } function get_spacer() { global $OUTPUT; return $OUTPUT->spacer(); }

georgmaisser commented 4 months ago

You don't need to program anything. It's just a setting in your Website Administration. Sorry, that my instruction was not clear. I hope this helps. Go to Website administration -> user -> Define Roles -> here you choose "student" and click on "edit". then, via the filter below, you add the right for the students.

Bildschirmfoto 2024-06-18 um 16 17 48
fezile30 commented 4 months ago

I have tried it (see attachment) but still not working. I also purged the caches. Maybe its my Moodle installation issues?

On Tue, Jun 18, 2024 at 4:19 PM georgmaisser @.***> wrote:

You don't need to program anything. It's just a setting in your Website Administration. Sorry, that my instruction was not clear. I hope this helps. Go to Website administration -> user -> Define Roles -> here you choose "student" and click on "edit". then, via the filter below, you add the right for the students. Bildschirmfoto.2024-06-18.um.16.17.48.png (view on web) https://github.com/Wunderbyte-GmbH/moodle-mod_mooduell/assets/7524621/7ad8ab0f-f1e0-4a2e-9456-9134763db1fd

— Reply to this email directly, view it on GitHub https://github.com/Wunderbyte-GmbH/moodle-mod_mooduell/issues/85#issuecomment-2176224887, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGHP6GGST3PLXZQHNUM3MTTZIA6YNAVCNFSM6AAAAABI7JVWXKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNZWGIZDIOBYG4 . You are receiving this because you authored the thread.Message ID: @.***>

--


Fezile Mlungu Interactive Multimedia e-Learning Designer and Developer

(+27) 083 863 7611