Code Monkey home page Code Monkey logo

js-turtle's Introduction

Thanks to HTML5's Canvas element, we were able to create an implementation of Turtle Graphics programming in pure JavaScript. Now with improved UI including the ability to move forward and backward in the interactive command box, Turtle programming in JavaScript is easy enough for beginners and modifiable by advanced users thanks to its open-source nature. You can access this live by clicking here

js-turtle's People

Contributors

athi223 avatar bjpop avatar jeremysinger avatar rudxain avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

js-turtle's Issues

command history - feature request

it would be very nice if one could navigate his previous commands with the "up" and "down" keys, instead of typing again and again.

Add a project license

That's a nice project you've created here!

Unfortunately, from a legal point of view, it's illegal for us to use, modify or redistribute your code, even without a commercial purpose.

I don't think that you intend these restrictions, but this is the common way for all GitHub repositories which do not include a license file.

Therefore, I'd suggest you to add a LICENSE file to this repository. If you want to leave it free to everyone, I'd suggest you the OSI-approved 0-clause BSD License: https://tldrlegal.com/license/bsd-0-clause-license

You can then just add this to your LICENSE file:

Copyright (C) <year(s)> <copyright holder(s)>

Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted.

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

Thanks!

Some examples don't work

Tested Browsers

MS Edge & G Chrome (both non-beta/nightly and up-to-date)

Steps to reproduce

  1. Go to the website, or download the repo and open the root index.html
  2. Select all the text within the examples/bounce.js file, and copy
  3. Paste it on the "Definitions" box in the website (while removing the prepopulated text)
  4. Run demo() command and hit "Enter"
  5. The canvas goes blank, and the turtle is nowhere to be found

About the other files

  • clock is fine
  • randstripe has the same problem as bounce
  • sierpinski works as expected
  • spiral: same problem

Etc

I'm currently trying to pinpoint the cause of the bug

Command doesn't run if it's repeated

If a command is executed, and the user uses the command history to re-run the cmd again, the command doesn't execute. I suspect this is because the event listener uses change instead of keydown.

I'll fix this now in #9 PR

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.