Sprite-data extension

The arcade-sprite-data extension (https://github.com/microsoft/arcade-sprite-data) adds blocks to store/read numbers and strings in sprites. Read the manual

To use it,

6 Likes

bruh, I just complained about this. goes to rewrite post

1 Like

@Blobiy not sure i get your comment.

1 Like

@peli he’s remarking on how quickly you added this extension :smile:

2 Likes

Updated repo to point to Microsoft version…

1 Like

This is terrific!

1 Like

I’ve also added the ability to store a sprite reference. We needed that to track the “shadow” sprite in the skeet game.

2 Likes

Hello there, sorry to bother you, but is it possible to view the sprite data in the debug console thingamabob?

1 Like

You should be able to drill into the “data” field of a sprite; are you looking for a block that does console.log(sprite.data) ?

1 Like

No, I don’t need the console.log command, I just want it to appear in the debugger, like how you can open a sprite and see it’s x, y, vx, vy, etc. I want to see the sprite data with the x, y…,

It would make life a bit easier…

1 Like

Sounds like a bug to raise at https://github.com/microsoft/pxt-arcade

2 Likes

Done :slight_smile: (I hope it’s sufficient!)

1 Like

I have found this extension very useful. I am revising several programs to use it. In my use, I have wanted a slightly different user interface, which is shown below. Changes include “mySprite” instead oh “item,” an image specification that allows any kind of image, and a couple of corrections in the comments. The changed code is on GitHub at https://github.com/WeCodeMakeCode/sprite-data-revised
image

2 Likes

Oh nice… I’ll look into porting those into sprite-data!

1 Like