Code Monkey home page Code Monkey logo

games's Introduction

What is this?

Simple and responsive browser-based games.
Bringing the 1970's terminal experience to the modern day internet consumer.
Explore puzzles in math, programming, and operating systems.

new VISUAL

  • this site has pretty much joined the modern era by implementing a visual interface
  • wow!
  • type help to get started.
  • A custom terminal shell emulator with some strange options
  • this page can navigate the rest of the site through program commands
  • extends all of the color and topological functionality of gradient_phase

games's People

Contributors

boris-volkov avatar

Stargazers

Thomas Gorman avatar

Watchers

Hailey Qu avatar Keith Kaplan avatar  avatar

games's Issues

Idea for Game of Life

Something I did when I create the Game of Life was a drag and click thing. I noticed that you didn't add this feature to the Game of Life on your website. Github, for some odd reason, doesn't support .js files so here is the code.

`let drag = false, moved = false;

canvas.onmouseup = (event) => {
drag = moved;
let x = (event.clientX-rect.left)(canvas.width/rect.width);
let y = (event.clientY-rect.top)
(canvas.height/rect.height);
let col = Math.floor(x/cell_width);
let row = Math.floor(y/cell_width);
if (!drag) {
grid[row][col][0] ^= 1;
} else {
grid[row][col][0] = 1;
drag = false;
}
moved = false;
save_grid();
clear();
grid_to_canvas();
}

canvas.onmousedown = () => {
generations = 0;
print_generations();
stop();
drag = true;
}

canvas.onmousemove = (e) => {
if (drag) {
moved = true;
let x = (e.clientX - rect.left) * (canvas.width / rect.width);
let y = (e.clientY - rect.top) * (canvas.height / rect.height);
x = Math.floor(x / cell_width);
y = Math.floor(y / cell_width);
grid[y][x][0] = 1;
save_grid();
clear();
grid_to_canvas();
}
}`

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.