Category:Sprites

Gets a specific sprite from an event.

Using the costume block, you can program with events to check for interactions involving any sprite with the same costume(s). This block allows you to program an action to only affect the sprite that triggered the event. In an event that involves two sprites, “this” refers to first sprite in the event, and “other” refers to the second sprite. Using this block makes it possible to apply actions to specific sprites after an event without having to use a sprite name or affect the whole costume group.

Parameters

Name Description
this/other Two options: this or other. Default is this.

Tips

  • “This” sprite can be used in any action that is triggered by an event with a sprite. However, “other” only works with two sprites. Like the names suggest, there is “this” main sprite and a secondary “other” sprite.

Found a bug in the documentation? Let us know at documentation@code.org