-
Content Count
22 -
Joined
-
Last visited
Everything posted by SamYan
-
Hi, Can anyone tell me please what the best way to hide a "BETTING CONFIGURATION" container by clicking anywhere on the screen other than that container? Actually i'm detecting the mouse coordinates and comparing with the window / container coordinates, but it's good practice? public static isColliding(mouse: any, object: any): boolean { return !(mouse.x < object.x || mouse.x > (object.x + object.width) || mouse.y < object.y || mouse.y > (object.y + object.height)); } this.baseContainer.interactive = true; this.baseContainer.addListener('pointerdown', () => {
-
Finally i got it! Thank you friend!
-
Thank you friend! It's working!!
-
Ivan, Do you know any way to manage the diferentes screen in pixijs ?
-
https://codesandbox.io/s/n5pkq5vjpj?moduleview=1
-
Thank you very much!
-
i dont understand, why resizing canvas, its not resizing the stage and children containers correcty.
-
It's background: desktop screen: mobile screen:
-
Thanks for response but not working. I have tried to give the max size of the background to my view and now it's working, but when i try in mobile screen, fails again. http://jsfiddle.net/om0hskfy/
-
Thanks for response but still not working. I'm looing and it's the stage scale problem (app.stage.scale). I can't calculate the aspect ratio for stage. IVAN I NEED YOUR HELP. 😅
-
Nobody can help please?
-
Thanks for response but i get the same result. Not working.
-
Hi, i'm looking to get any solution form resizing the 'game' correctly in desktop and mobile screens but no way. I get the background image (sprite) non centralized and zoomed stage. Anyone can tell me please what's the wrong? CSS body { background-color: rgb(0, 0, 0); width: 100%; height: 100%; overflow: hidden; } #pixi-canvas { position: absolute; top: 0; left: 0; right: 0; bottom: 0; margin: auto; } JS const logicalWidth = 1280 // window.innerWidth; const logicalHeight = 720 // window.innerHeight; // Init Application let app:
-
The solution was moving the constant array of textures into generateSymbols() method. But why ??? import * as PIXI from 'pixi.js' export default class Symbol { /** * Generate random symbol tables * * @static * @param {number} reelsCount * @param {number} symbolsCount * @param {(symbolTables: Array<any>) => void} resolve * @memberof Symbol */ public static generateSymbols(reelsCount: number, symbolsCount: number, resolve: (symbolTables: Array<any>) => void): void { const symbols = [ { id: 0, img:
-
Hi, I'm trying to load 4 images, and then generate array of random sprites, but i get In chrome console: Debug: GET http://localhost:8081/dist/symbol_2 404 (Not Found) BaseTexture.js:795 BaseTexture added to the cache with an id [symbol_1] that already had an entry addToCache @ BaseTexture.js:795 fromLoader @ Texture.js:478 textureParser @ textureParser.js:9 (anonymous) @ Loader.js:614 (anonymous) @ async.js:35 Texture.js:508 Texture added to the cache with an id [symbol_1] that already had an entry addToCache @ Texture.js:508 fromLoader @ Texture.js:479 textureParser @ texturePa