Git Product home page Git Product logo

ccanimatedtmxtiledmap's Introduction

CCAnimatedTMXTiledMap

Adds animation support to the CCTMXTiledMap class.

Features

  • Keeps all functionality of existing CCTMXTiledMap class.
  • Optimised by using CCTMXTiledMap's functions.
  • Only animates tiles that have animations set.

Limitations

  • Only supports a single interval for all tile animation changes.

Usage

Simply drop the source files in your project and include the .h file.

See the example directory for source code.

Animations are specified in the TMX editor by adding meta-data to tile sets.

To add animation to a tile:

  • Right click the tile in the tile set.
  • Select 'Tile Properties'
  • Add the following key / value pairs:
  • animate_enabled : YES, NO
  • animate_next_tile : GID of next tile (1 indexed)

The map then specifies the time between animations in a global map property.

  • Select the 'Map' menu
  • Select 'Map Properties'
  • Add the following key / value pairs:
  • animate_delay : Time between animations. 0.016 for 60 fps.

Dependencies

  • cocos2d-iphone (or Kobold2d)

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.