Eric Chu Eric Chu - 3 years ago 98
Javascript Question

Is it safe to build a game with javascript + electron + three.js?

Nothing really massive like the scale of a MMORPG, but a small game like faster than light.

Anyone can open dev tools, so I was wondering if its possible to add protection against cheat engine or if I can implement something that would prevent users from running their own javascript into the game.

I also understand that writing games in javascript is probably not the best solution because its very inefficient, but this is something I want to try.

Answer Source

According to this thread in the developer forum, there is a way to force the dev tools to close whenever they open using the following code:

win.webContents.on("devtools-opened", () => {
  win.webContents.closeDevTools();
});
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download