Überarbeitet
This commit is contained in:
parent
1af256dd53
commit
9c196843ef
396
static/games/3ds/index.html
Normal file
396
static/games/3ds/index.html
Normal file
File diff suppressed because one or more lines are too long
@ -1,21 +0,0 @@
|
|||||||
(function() {
|
|
||||||
function myExtension() {}
|
|
||||||
|
|
||||||
myExtension.prototype.connectToWiFi = function(networkName, password) {
|
|
||||||
// Überprüfe, ob die "navigator.connection" API unterstützt wird
|
|
||||||
if ('connection' in navigator && 'wifi' in navigator.connection) {
|
|
||||||
// Verbinde mit dem WLAN
|
|
||||||
navigator.connection.wifi.associate({ ssid: networkName, password: password })
|
|
||||||
.then(function() {
|
|
||||||
console.log("Verbindung hergestellt");
|
|
||||||
})
|
|
||||||
.catch(function(error) {
|
|
||||||
console.log("Fehler bei der Verbindung:", error);
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
console.log("Die WLAN-Verbindung wird von dieser Plattform nicht unterstützt.");
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
Scratch.extensions.register(new myExtension());
|
|
||||||
})();
|
|
Loading…
x
Reference in New Issue
Block a user