FK53AOEMTSFJOB5TCHLDOE2EHAE5W5P2LV3ZNENYSGQGV3UCBWRAC
import { Rectangle, Texture } from 'pixi.js'
import { AssetName } from '../game/assets';
import { Tile } from './tilemap/tilemap_types';
import { TypesafeLoader } from './typesafe_loader';
import { C } from '../game/constants';
import { Rectangle, Texture } from "pixi.js";
// import { AssetName } from '../game/assets';
import { Tile } from "./tilemap/tilemap_types";
import { TypesafeLoader } from "./typesafe_loader";
// import { C } from '../game/constants';
public static GetTextureFromSpritesheet({ resourceName: textureName, x, y, tilewidth, tileheight, assets }: {
resourceName: AssetName;
x : number;
y : number;
tilewidth : number;
tileheight : number;
assets : TypesafeLoader<{}>;
public static GetTextureFromSpritesheet({
resourceName: textureName,
x,
y,
tilewidth,
tileheight,
assets,
}: {
resourceName: any; // AssetName;
x: number;
y: number;
tilewidth: number;
tileheight: number;
assets: TypesafeLoader<{}>;
resourceName: imageUrlRelativeToGame.slice(0, imageUrlRelativeToGame.lastIndexOf(".")) as AssetName,
x : spritesheetx,
y : spritesheety,
tilewidth : tile.tile.tilewidth ,
tileheight : tile.tile.tileheight,
assets : assets,
resourceName: imageUrlRelativeToGame.slice(
0,
imageUrlRelativeToGame.lastIndexOf(".")
) as any, // as AssetName
x: spritesheetx,
y: spritesheety,
tilewidth: tile.tile.tilewidth,
tileheight: tile.tile.tileheight,
assets: assets,