GithubHelp home page GithubHelp logo

isabella232 / pixi-haxe Goto Github PK

View Code? Open in Web Editor NEW

This project forked from pixijs/pixi-haxe

0.0 0.0 0.0 70.5 MB

Externs of Pixi.js for Haxe

Home Page: http://www.pixijs.com

License: MIT License

Haxe 100.00%

pixi-haxe's Introduction

Pixi.js 5 / Haxe 4 Build Status

image

-### Installation

haxelib install pixijs

Issues

Found any bug? Please create a new issue.

Demos

Usage

package basics;

import pixi.core.Application;
import pixi.core.graphics.Graphics;
import pixi.core.textures.Texture;
import pixi.core.sprites.Sprite;
import js.Browser;

class Main extends Application {

	var _bunny:Sprite;
	var _graphic:Graphics;

	public function new() {
		
		var options:ApplicationOptions = {
			width: Browser.window.innerWidth,
			height: Browser.window.innerHeight,
			backgroundColor: 0x006666,
			transparent: true,
			antialias: false,
		};
		
		super(options);
		ticker.add(function(delta){
			_animate(delta);
		});

		_bunny = new Sprite(Texture.from("assets/basics/bunny.png"));
		_bunny.anchor.set(0.5);
		_bunny.position.set(400, 300);

		_graphic = new Graphics();
		_graphic.beginFill(0xFF0000, 0.4);
		_graphic.drawRect(200, 150, 400, 300);
		_graphic.endFill();

		stage.addChild(_graphic);
		stage.addChild(_bunny);
		Browser.document.body.appendChild(view);
	}

	function _animate(e:Float) {
		_bunny.rotation += 0.1;
	}

	static function main() {
		new Main();
	}
}

Licensing Information

MIT license

This content is released under the MIT License.

Pixi.js is licensed under the MIT License.

Contributor Code of Conduct

Code of Conduct is adapted from Contributor Covenant, version 1.4

pixi-haxe's People

Contributors

adireddy avatar notboring avatar modjke avatar markknol avatar mathieuanthoine avatar volkipp avatar tiago-ling avatar ikonone avatar aidangrabe avatar alamboley avatar greu avatar andrew-git avatar haxiomic avatar dendipermadi avatar gitter-badger avatar johana-star avatar fancysensei avatar prashaanp avatar pieterslsmm avatar nealr avatar waffle-iron avatar elnabo avatar blue112 avatar bitdeli-chef avatar axgord avatar

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.