# Is a list of all tiles possible?

**URL:** https://forum.makecode.com/t/is-a-list-of-all-tiles-possible/31237
**Category:** Help
**Created:** [October 18, 2024, 2:33am UTC](https://forum.makecode.com/t/is-a-list-of-all-tiles-possible/31237 "2024-10-18T02:33:57Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![WoofWoof](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/woofwoof/32/32523_2.png) [@WoofWoof](https://forum.makecode.com/u/WoofWoof)
#### Post date: [October 18, 2024, 2:33am UTC](https://forum.makecode.com/t/is-a-list-of-all-tiles-possible/31237/1 "2024-10-18T02:33:57Z")

</div>

[Generating Empty Tilemaps in Runtime!](https://arcade.makecode.com/S49644-21461-46519-33187)  
Ok, so, I’ve been working on this for a bit, but to use a tile in the tilemap, it must be added to the list on line 23. I don’t want to have to do that. That’s the problem:  
Is there a way to get all constants defined in the namespace “myTiles”? (myTiles.tile1…2… etc, but only if they exist)  
I’ve tried a few things, but the docs for pygame are… interesting, to say the least. I like the old look, even though it hurts my eyes.  
It doesn’t look like dir() exists. Though I would like to say I have only recently started coding with… code instead of blocks, so please don’t just give an answer cause I need an explanation if I’m ever gonna learn anything.  
I have a feeling this would be possible if I made an extension… just based on the fact that the arcade-tile-util extension literally modifies this code to add myTiles.transparency8… yeah… a big thanks to anyone with a solution!!

---

<div class="post-metadata">

### Author: ![randomuser](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/randomuser/32/32505_2.png) [@randomuser](https://forum.makecode.com/u/randomuser)
#### Post date: [October 24, 2024, 9:43pm UTC](https://forum.makecode.com/t/is-a-list-of-all-tiles-possible/31237/2 "2024-10-24T21:43:00Z")

</div>

I’m confused; pygame?  
Are you trying to make a list of every tilemap location or every type of tile?

---

<div class="post-metadata">

### Author: ![WoofWoof](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/woofwoof/32/32523_2.png) [@WoofWoof](https://forum.makecode.com/u/WoofWoof)
#### Post date: [October 25, 2024, 12:31am UTC](https://forum.makecode.com/t/is-a-list-of-all-tiles-possible/31237/3 "2024-10-25T00:31:37Z")

</div>

Sorry, this is an impossible thing to do because Makecode does not support it. I was trying to get a list of all tile types (myTiles.tile1… etc).

---

<div class="post-metadata">

### Author: ![redSprite](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/redsprite/32/34262_2.png) [@redSprite](https://forum.makecode.com/u/redSprite)
#### Post date: [October 25, 2024, 4:49pm UTC](https://forum.makecode.com/t/is-a-list-of-all-tiles-possible/31237/4 "2024-10-25T16:49:34Z")

</div>

I think so, there is a certain block in the tile util extension, maybe you could use it.

---

<div class="post-metadata">

### Author: ![ADM\_F](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/adm_f/32/19808_2.png) [@ADM\_F](https://forum.makecode.com/u/ADM_F)
#### Post date: [October 25, 2024, 6:08pm UTC](https://forum.makecode.com/t/is-a-list-of-all-tiles-possible/31237/5 "2024-10-25T18:08:08Z")

</div>

why not this?

 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/3X/a/a/aa393ab3aca0cb30d9b5f11cec4a5a1f8f3a144c.png)  
Depending on what tile you got returned you could do diffrent things?

---

<div class="post-metadata">

### Author: ![WoofWoof](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/woofwoof/32/32523_2.png) [@WoofWoof](https://forum.makecode.com/u/WoofWoof)
#### Post date: [October 25, 2024, 7:01pm UTC](https://forum.makecode.com/t/is-a-list-of-all-tiles-possible/31237/6 "2024-10-25T19:01:17Z")

</div>

Omg I love how you’re all trying to help! Unfortunately, as I said, it is IMPOSSIBLE in Makecode. [This is the topic where Richard explains that it’s impossible](https://forum.makecode.com/t/weekly-topic-most-challenging-coding-task-or-concept/31290/15)  
You can scroll down a bit to see Richard’s explanation.
