Search the Community
Showing results for tags 'answered'.
-
Hey ? I am trying to update a game, it's essentially a map and it's essentially a `number[][][]`. This is not real data, but a good example. const myMap = [ [ [16383, -3784, -13, -12], ], [ [-251, -91, -5, -2, 3], [4483, -115, 0, -5], ] ] Lets look at the current code which is v4. pixiTextureByName.polygons = new Graphics(); pixiTextureByName.polygons.beginFill(); let countTotal = 0; let lastX = 0; let lastY = 0; let points: number[]; for (let itrA = 0; itrA < myMap.length; itrA++) { let counterA = 0; for (let itrB = 0; itrB < mapResponse[itrA].length; itrB++) { points = []; for (let itrC = 0; itrC < mapResponse[itrA][itrB].length; itrC = itrC + 2) { const curX = mapResponse[itrA][itrB][itrC] + lastX; const curY = mapResponse[itrA][itrB][itrC + 1] + lastY; points.push(parseFloat(curX.toString()), -parseFloat(curY.toString())); lastX = curX; lastY = curY; countTotal++; } pixiTextureByName.polygons.drawPolygon(points); if (0 != counterA) { pixiTextureByName.polygons.addHole(); } counterA++; } } pixiTextureByName.polygons.endFill(); pixiContainerByName.map.addChild(pixiTextureByName.polygons); pixiContainerByName.map.mask = pixiTextureByName.polygons; Looking at the following page: https://github.com/pixijs/pixijs/wiki/v5-Migration-Guide I have tried every combination (that seems logical) to use `beginHole` and `endHole` between the polygon points to failed results. Anyway I appreciate this is incredibly specific so no worries if no one has the time to check it out :)! Kind regards.
-
On my website, I have levels. But, suddenly they have changed to a blank empty screen. I didn't even change the script or anything. It is just blank. Cityworld.16mb.com/levels/ Cityworld.16mb.com/levels/1/play Cityworld.16mb.com/levels/2/play Please help! Thank you, Borislav.
-
I'm having issues with parts of my model not showing when it extends beyond the bounding box at the edge of the screen. I tried using the extendSize property, but it doesn't seem to have any effect. Has anyone had any success with updating the size of the bounding box?