Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var SpriteConstants = (function () {
- 'use strict';
- // public api
- var _constants = {};
- // constants
- _constants.SIZE = 100;
- _constants.Animation = getAnims();
- _constants.Anchor = getAnchor();
- _constants.Direction = getDirections();
- return _constants;
- function getAnims() {
- return {
- STILL_UP: 'still-up',
- STILL_DOWN: 'still-down',
- STILL_SIDE: 'still-side',
- WALKING_UP: 'walking-up',
- WALKING_DOWN: 'walking-down',
- WALKING_SIDE: 'walking-side'
- };
- }
- function getAnchor() {
- return {
- X: 0.5,
- Y: 1
- };
- }
- function getDirections() {
- return {
- UP: 'up',
- RIGHT: 'right',
- DOWN: 'down',
- LEFT: 'left'
- };
- }
- })();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement