// application initialization void Initialize() { // Get reference to gun animation sprite plane = OT.ObjectByName("TileMap") as OTTileMap; CreateObjectPools(); // set our initialization notifier - we only want to initialize once initialized = true; }
// Use this for initialization void Start() { // find the tilemap object from this scene tilemap = GameObject.Find("TileMap").GetComponent<OTTileMap>(); tilesSprite = OT.Sprite("TilesSprite") as OTTilesSprite; tilesSprite.visible = false; OT.Sprite("cover-h").visible = tilesSprite.visible; OT.Sprite("cover-v").visible = tilesSprite.visible; }
public void FillFromTileMap(OTTileMap map, IVector2 offset, Rect fillRect) { FillFromTileMap(map,offset,fillRect,null,true); }
public void FillFromTileMap(OTTileMap map, IVector2 offset, Rect fillRect, OTTileMapLayer layer, bool checkTileset) { FillTiles(fillRect,map.GetTiles( new Rect(offset.x, offset.y, fillRect.width, fillRect.height), map.TileSetFromImage(spriteContainer.GetTexture()), layer, checkTileset)); }