corrections
continuous-integration/drone/push Build is passing Details

ServeurDeTest
johan 2 years ago
parent 84018b19f4
commit f826bc8aed

@ -8,7 +8,6 @@ class UserController
global $dsn, $rep, $vues, $error, $server;
$action = $_REQUEST['action'];
echo $action;
require $rep . $server;
switch ($action) {
case NULL:
$this->goToHome();
@ -207,7 +206,8 @@ class UserController
$model = new UserModel();
$model->addToQueue();
$userGroup = $model->findUserGroup();
$io = get_io();
$server = require 'server.js';
$io = $server->io;
$io->to($userGroup)->emit("launchGame");
} catch (Exception $e) {
$error = $e->getMessage();

@ -19,10 +19,9 @@ io.on('launchGame' , function () {
console.log('launch the game');
location.reload();
})
module.exports = {
get_io: function() {
return io;
}
};
io: io
};
console.log('iolisten');
Loading…
Cancel
Save