Warning: session_start(): open(/var/lib/php/sessions/sess_l94h148mokok1fscg0nprq548n, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
!7
module TurnOnWebCamRandomly > DynPrintLogAndEnabled {
start {
doLater(random(5.0, 20.0), r startCam);
}
void startAgain {
doLater(random(180.0), r startCam);
}
void startCam enter {
// TODO: choose favorite web cam
if (enabled) pcall {
printWithTime("Starting web cam");
dm_startWebCam();
BufferedImage img = dm_waitForWebCamImage(10.0);
if (img != null) {
printWithTime("[showing image]");
showAnim(img, printWithTime("You look so stupid dude"), 5.0);
doLater(5.0, r { infoBox("(just kidding)") });
}
}
doLater(random(20.0, 30.0), r stopCam);
}
void stopCam enter {
if (enabled) pcall {
printWithTime("Stopping web cam");
dm_stopWebCam();
}
startAgain();
}
}