aboutsummaryrefslogtreecommitdiff
path: root/race/cars/keymap.js
diff options
context:
space:
mode:
Diffstat (limited to 'race/cars/keymap.js')
-rw-r--r--race/cars/keymap.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/race/cars/keymap.js b/race/cars/keymap.js
index 74cce0a..221a7ec 100644
--- a/race/cars/keymap.js
+++ b/race/cars/keymap.js
@@ -29,6 +29,7 @@ startHooks.push(() => {
car0cspeed = car0cspeed + 0.2;
}
if (document.getElementById("car0").style.transform !== "rotate(-90deg)") {
+ require('electron').ipcRenderer.send('addstats', { catalog: "ingame", key: "turns", add: 1 });
document.getElementById("car0").style.transform = "rotate(-90deg)";
car0collisionon = false;
setTimeout(() => {
@@ -41,6 +42,7 @@ startHooks.push(() => {
car0cspeed = car0cspeed + 0.2;
}
if (document.getElementById("car0").style.transform !== "rotate(90deg)") {
+ require('electron').ipcRenderer.send('addstats', { catalog: "ingame", key: "turns", add: 1 });
document.getElementById("car0").style.transform = "rotate(90deg)";
car0collisionon = false;
setTimeout(() => {
@@ -53,6 +55,7 @@ startHooks.push(() => {
car0cspeed = car0cspeed + 0.2;
}
if (document.getElementById("car0").style.transform !== "rotate(180deg)") {
+ require('electron').ipcRenderer.send('addstats', { catalog: "ingame", key: "turns", add: 1 });
document.getElementById("car0").style.transform = "rotate(180deg)";
car0collisionon = false;
setTimeout(() => {
@@ -65,6 +68,7 @@ startHooks.push(() => {
car0cspeed = car0cspeed + 0.2;
}
if (document.getElementById("car0").style.transform !== "rotate(0deg)") {
+ require('electron').ipcRenderer.send('addstats', { catalog: "ingame", key: "turns", add: 1 });
document.getElementById("car0").style.transform = "rotate(0deg)";
car0collisionon = false;
setTimeout(() => {