• Content Count

  • Joined

  • Last visited

About MaskedPixel

  • Rank

Contact Methods

  • Twitter

Recent Profile Visitors

778 profile views
  1. The situation: I have an update loop where I "fixed the timestep". Physics is running at ta fixed 30fps and my render loop is completely independent. However, on a mobile device with a framerate that jumps around between 20-35 fps, there seems to be stuttering with the camera. Now, I know how to approach the issue, I'm just trying to figure out how to do it off the mobile device. What I want to do: I would like to simulate the irregular fps within the browser on desktop. Is there a way to do that via debug tools or with an extension on any browser? Does anyone know of a solution here? Fix your timestep:
  2. @ivan.popelyshev You are correct. I was exporting it using the Cocos2d/BMFont exporter in BMGlyph. The correct exporter is the Sparrow/Starling exporter. According to the loader documentation, it would take the fnt file. However, both the Cocos2d and Sparrow exporters use the fnt extension.
  3. And in case it is needed: here is the font file and png... hudScoreFont.fnt
  4. Sure, this is written in haxe using a custom game engine though. Where the font is loaded: class PreloaderScene extends Scene { public function new() { super(); } override public function onBegin():Void { var loader = new Loader(); loader.add("hudScoreFont", "assets/fonts/hudScoreFont.fnt"); loader.load(onLoaded); } private function onLoaded(loader:ResourceLoader):Void { Turbo.director.unwindToScene(new GameplayScene()); } } Where the font is created: class GameplayScene extends Scene { public function new() { super(); } override public function onBegin():Void { _txtScore = new BitmapText("00", {font: "288px hudScoreFont", align: "center"}); container.addChild(_txtScore); } } So the PreloaderScene is loaded elsewhere. The onBegin funciton is called when the scene starts. The loader is created and load is called. onLoaded is passed to the load function of the loader and is called after the the loader is complete (I have verified that the fnt file is in fact stored in the loader object via console.log). Finally, the Gameplay scene is started and the bitmap text object is created. I have also verified that the font object is never created by doing console.log(BitmapText.fonts) and there are no fonts. So the error is somewhere in the loader and I'm unsure how to debug it beyond this point.
  5. Hi, I am trying to load a bitmap text font with PixiJS and I get this error: Uncaught TypeError: Cannot read property 'size' of undefined at e.updateText (BitmapText.js:99) at new e (BitmapText.js:99) The font is created with BMGlyph using the Cocos2d/BMFont settings with the font face forced to be "hudScoreFont". Here is how I load the font: loader.add("hudScoreFont", "assets/fonts/hudScoreFont.fnt"); And here is how I create the BitmapText object: let txtScore = new BitmapText("00", {font: "288px hudScoreFont"}); I can see that the fnt file has been downloaded, but the png of the font is never downloaded. If you have any insight as to what I might be doing wrong, please let me know! EDIT: I am using Pixi v. 4.4.2
  6. Just to confirm, this update will not allow batching using texture atlases correct? It will only batch per tileset, per layer.