createjs

CreateJS / EaselJS Strange Performance with certain size shapes

寵の児 提交于 2019-12-05 04:47:06
I am currently developing a game, it uses a large tiled map, that can be dragged around, and moves quickly with your character. I have created a simple version of the problem JSFiddle Example Each tile is a Shape and is cached . All shapes go inside a container , the container is moved based on camera position. I am noticing weird drops in fps at certain zoom levels. The zoom simply adjusts the size of the shapes. If you adjust the zoom you will see what i mean. Chrome zoom 1 = good fps zoom 3 = bad fps zoom 5 = good fps What would be the reason for this frame rate problem? Note i have i

How to set position correctly in SoundJS for Firefox, IE

我是研究僧i 提交于 2019-12-04 18:28:47
I'm trying to use SoundJS to play sn mp3 file and seek to a specific position. I'm using: instance.setPosition(10000); which works correctly in Google Chrome. But in Mozilla Firefox I hear the sound playing from the correct position, and a second instance of the sound also playing from another position. In Internet Explorer, the sound starts playing again from the beginning. Here's a jsFiddle (with autoplaying sound) and here is the complete javascript: createjs.Sound.registerPlugins([createjs.WebAudioPlugin, createjs.HTMLAudioPlugin, createjs.FlashPlugin]); createjs.Sound.addEventListener(

Animation rendering using Nodejs on backend server side

谁说我不能喝 提交于 2019-12-04 18:15:25
I have simple animation created using create js and ffmpegserver.js. ffmpegserver.js. This is a simple node server and library that sends canvas frames to the server and uses FFmpeg to compress the video. It can be used standalone or with CCapture.js. Here is repo: video rendering demo . on folder public, I have demos eg test3.html and test3.js Test3.html <!DOCTYPE html> <html> <head> <title>TweenJS: Simple Tween Demo</title> <style> canvas { border: 1px solid #08bf31; justify-content: center; display: flex; align-items: center; margin: 0px auto; margin-bottom: 40px; } a { width: 150px; height

Using Adobe Animate CC in HTML5 canvas mode with external JavaScript files

若如初见. 提交于 2019-12-04 16:19:55
I'm transitioning a large FLA AS3 project into Canvas/JS. I have a large external folder structure of AS files and many library objects associated with classes. I've converted FLA into a canvas mode but I can't find a way to associate JS files to the objects. I've seen online examples about including JS in frame scripts but I really hope to find a way to do it with external files and library objects association. I'd appreciate any direction or example of how it can be done. Thank you What I do is adding all my JS utilities to the html on-the-fly from Animate with appenChild like this: frame

Easeljs game project

假如想象 提交于 2019-12-04 06:36:14
问题 I'm working on a game project but I have a a problem i received this error: NS_ERROR_NOT_AVAILABLE: ctx.drawImage(this.image, 0, 0); //Bitmap.js in Easeljs lib. I used the bitmap in the next codes. Please tell me if in this there is a problem and how to fix it. Thanks for collaboration. Code 1 : p.initialize = function(x,y ,stage, world){ var bmp = new Bitmap('../assets/blackBall.png'); //console.log(bmp) //alert(bmp) bmp.regX = radius; bmp.regY = radius; bmp.x=x; bmp.y=y; this.skin = bmp;

render a tile map using javascript

人走茶凉 提交于 2019-12-03 04:30:43
问题 I'm looking for a logical understanding with sample implementation ideas on taking a tilemap such as this: http://thorsummoner.github.io/old-html-tabletop-test/pallete/tilesets/fullmap/scbw_tiles.png And rendering in a logical way such as this: http://thorsummoner.github.io/old-html-tabletop-test/ I see all of the tiles are there, but I don't understand how they are placed in a way that forms shapes. My understanding of rendering tiles so far is simple, and very manual. Loop through map array

render a tile map using javascript

我是研究僧i 提交于 2019-12-02 17:43:05
I'm looking for a logical understanding with sample implementation ideas on taking a tilemap such as this: http://thorsummoner.github.io/old-html-tabletop-test/pallete/tilesets/fullmap/scbw_tiles.png And rendering in a logical way such as this: http://thorsummoner.github.io/old-html-tabletop-test/ I see all of the tiles are there, but I don't understand how they are placed in a way that forms shapes. My understanding of rendering tiles so far is simple, and very manual. Loop through map array, where there are numbers (1, 2, 3, whatever), render that specified tile. var mapArray = [ [0, 0, 0, 0

Easeljs game project

旧街凉风 提交于 2019-12-02 09:57:06
I'm working on a game project but I have a a problem i received this error: NS_ERROR_NOT_AVAILABLE: ctx.drawImage(this.image, 0, 0); //Bitmap.js in Easeljs lib. I used the bitmap in the next codes. Please tell me if in this there is a problem and how to fix it. Thanks for collaboration. Code 1 : p.initialize = function(x,y ,stage, world){ var bmp = new Bitmap('../assets/blackBall.png'); //console.log(bmp) //alert(bmp) bmp.regX = radius; bmp.regY = radius; bmp.x=x; bmp.y=y; this.skin = bmp; stage.addChild(bmp); var fixDef = new b2FixtureDef(); fixDef.density = 1.0; fixDef.friction = 0.5; fixDef

FlashDevelop, Haxe import CreateJS?

此生再无相见时 提交于 2019-12-01 21:38:26
I just started trying out Haxe to make a web-app, and I would like to use CreateJS, which has a Haxe extern lib thingy. I'm using FlashDevelop as my IDE. So I created a new Haxe JS project in FlashDevelop, and installed CreateJS with "haxelib install createjs". Thougg now I try to add an import to my Main.hx, but it doesn't work. My import looks like: "import createjs.easeljs.Ticker;" (got that from an example, just copied it but didn't work :s) I also added a new map "lib" to my project, in which I added the createjs stuff. The error I get is: src/Main.hx:3: characters 0-31 : Class not found

Drag and drop with easeljs in Animate CC 2017

对着背影说爱祢 提交于 2019-12-01 09:26:12
问题 I've been using an HTML Canvas project in Adobe Animate CC 2015.2 to drag around a movieClip on the stage, using the method recommended in the creatjs Mouse Interaction Tutorial. I was doing this on a MacBook Pro running OS X Yosemite at work. Here is the code I used and it worked fine. The movieClip is on the stage in the first frame of the timeline and the actions are in that same frame. The movieClip instance (my_mc) follows the mouse around - so far so good. this.my_mc.on("pressmove",