Git Product home page Git Product logo

worm's Introduction

Worm

지렁이 움직임 소스 파일

언젠간 쓰이겠지 싶어서 꽤 오래전에 만들어둔건데 유용하게 잘 써먹음

▼ 미리보기

preview_1

▼ 관련 영상

https://youtu.be/ySWkuhN4KbY

▼ 전체적인 알고리즘

1. 지렁이의 머리 역할을 할 부분을 만들어줌

2. 지렁이 몸통 역할을 할 부분들을 만들어줌

3. 지렁이의 몸통과 머리에 각각의 넘버를 붙여줌 (머리는 0, 이후 몸통들은 1~xx)

4. 각 몸통은 자신보다 넘버값이 작은 몸통들로 향하게 함

5. 이때 자신보다 넘버 값이 작은 몸통과 나의 위치가 일정 거리 이상 가까워졌을경우 그만 따라가게 함 (거리 측정은 점과 점사이의 거리 공식으로)

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.