• Content Count

  • Joined

  • Last visited

About AntoniaChimp

  • Rank

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. I tried to draw a rectangle like this: graphics.lineStyle(2, 0xFF00BB, 1); graphics.beginFill(0xFF00BB, 0.25); graphics.drawRoundedRect(150, 450, 300, 100, 15); graphics.endFill(); But it does not show up on my screen. I use pixi layers and I guess it is on the lowest layer so it gets covered by my background image. How can I make it be drawn on top ? Can I assign a pixi parentgroup as well?
  2. Hallo! Ich benutze Charm js in meinem Projekt. Jedoch bin ich auf ein Problem gestossen. Meine Tweens werden abgebrochen, sobald ich eine onComplete function für walkPath benutze. let mix = charm.walkPath( card, //The sprite waypoints, //Array of waypoints 80, //Total duration, in frames "deceleration" ); mix.onComplete = function(){ card.interactive = true; }; Ist jemand auch auf dieses Problem gestossen oder kann mir weiterhelfen ?
  3. function openFullscreen() { if (document.documentElement.requestFullscreen) { document.documentElement.requestFullscreen(); } else if (document.documentElement.mozRequestFullScreen) { document.documentElement.mozRequestFullScreen(); } else if (document.documentElement.webkitRequestFullscreen) { document.documentElement.webkitRequestFullscreen(); } else if (document.documentElement.msRequestFullscreen) { document.documentElement.msRequestFullscreen(); } } function lock() { if (!document.fullscreenElement){ openFullscreen(); } screen.orientation.lock(screen.orientation.type); } Tried it like that as well without async and awaits and I got a : Uncaught (in promise) TypeError: fullscreen error and a Uncaught (in promise) DOMException
  4. app.stage.interactive = true; app.stage.on('pointerdown', function(){ lock(); app.stage.interactive = false; app.stage.onpointerdown = null; }); async function fullScreenCheck() { if (document.fullscreenElement) return; return document.documentElement.requestFullscreen(); } function lock() { try { await fullScreenCheck(); } catch (err) { console.error(err); } screen.orientation.lock(screen.orientation.type); } That is my code. Thats the error: "Uncaught (in promise) DOMException" I read that its maybe not working with chrome. But I tried it on my phone not in Chrome and I was able to rotate it.
  5. I tried to lock it after first click on the stage, but I get the same exceptions as before 😕
  6. I was working on a game and I dont want the player to change the device orientation. If the player starts in portrait, lock portrait and vice versa. I was looking into screen.orientation.lock and requesting fullscreen, but I always get "(index):994 TypeError:" or "Uncaught (in promise) DOMException". I was testing this in a Chrome Browser. Does anyone have any tips for me?
  7. Damn it last time you said you are working on an example for playable ad, you said its gonna be done in 2-4 weeks. And that was 2 weeks ago Ok well here we go me trying to make the spritesheet work UPDATE: It works. Apparently you have to call spritesheet.parse(()=>{}) yourself, which I didnt know (Parse takes a callback). And the meta data of the json, does not need any field for image.
  8. So why I cant find an example of that no one ever posted their code for this issue
  9. Ok will try that tomorrow, never heard of sourcemaps before 😂 So theoretically that should work with the base64 ?
  10. What kind of info do you need ? Thats mostly everything I have. An image base64 encoded creating a sprite with fromImage to use its basetexture in the spritesheet a sprite sheet json created from shoebox not sure about the json meta part because it says "image": "sprites.png" and instead of that I put the base64 again so to be sure here is my json: { "frames": { "banner.png": { "frame": {"x":0, "y":2089, "w":465, "h":144}, "spriteSourceSize": {"x":0,"y":7,"w":465,"h":158}, "sourceSize": {"w":465,"h":158} },... }, "meta": { "image": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAA.....", "size": {"w": 2231, "h": 2234}, "scale": "1" } } and concerning the debug.. Where should I do the debug ? in Pixi code ? because mine goes through without error its just that spritesheet.textures is empty. I have around 40 images, so I dont think parsing should be the problem.
  11. I just want to have a single html file. so images should be inline as well as json. So I cant use the loader with urls
  12. so there is no chance to use PIXI.spritesheet at all ? or just the basetexture needs to be done manually ?
  13. So I already investigate further. I dont want to use the pixi loader for reasons. I want to create the spritesheet myself so I can use base64 image. So thats my current progress. let sprite = PIXI.Sprite.fromImage(base64); let spritesheet = new PIXI.Spritesheet(sprite.texture.baseTexture, spritesheetJSONdata); It creates the spritesheet, but the textures are empty. In the json it says: "meta": { "image": "sprites.png", "size": {"w": 2231, "h": 2234}, "scale": "1" } Obviously "image": "sprites.png" is not working so I tried to either delete the image entry or replace it with the base64 image string. But that didnt change anything. The textures of the spritesheet remains empty.
  14. Hey ! I dont want a call from javascript to look for my "sprites.json", so I thought that I put the json within the js and then tell the loader it should read from there. Like that: let json = { ....... } PIXI.loader .add(json) .load(setup); But its not working that way. Can anyone help me ?
  15. Hey ! Whats the status on that ? I finished my project in pixi and my big problem now is how to convert in into 1 single html file. I read that its possible with webpack but I am not able to make it work. And I am using a spritesheet with using the json file, so I am not sure how to solve that with the pixi loader.