I have had this problem/question for a while…
This should not be happening, there is a Sprite but somehow there is no column for the sprite. There is a tile map as well. HOW DOES ROW NOT EXIST ON THE SPRITE?!?!?!
ITS ON THE 5TH ROW AND 2ND COLUMN I CAN CLEARLY SEE IT! (that was just an example)
Like WHY DOES THIS NOT WORK?!?!?!?
I think its a problem with the website rather than my code. (maybe I’m wrong) Makecode devs PLZ fix this.
PROPERTY ROE EXISTS ON THE TYPE SPRITE BUT IT DOESN’T WORK!
Here is the link ----> LINK
(Sorry for all the caps I just though it would be more fun to read
[/quote]
1 Like
I think the important bit to know here is that a sprite can exist on a tilemap, but is not part of one. For example, if you change tilemaps, you could change from a tilemap with 8x8 tiles to one with 16x16 tiles; in that case, the ‘column’ the sprite is on would change.
In this case the fix is rather easy though; you have to call something to get the current location the sprite is on. This can be done with the tilemap location of [mySprite]
block:

it’s a bit more code to write, but it clears up the issue:

(if having such long blocks annoys you, you can always store the current location in a temporary variable right before using it, so it’s not recalculated every time)
3 Likes
Thanks I allways knew you could tilemap location block but I didn’t know about the tilemap col row block. Thanks!
1 Like