MCPcopy Create free account
hub / github.com/TimMcCool/scratchattach / current_sprite

Function current_sprite

scratchattach/editor/build_defaulting.py:28–34  ·  view source on GitHub ↗

Retrieve the default sprite from the top of the sprite stack

()

Source from the content-addressed store, hash-verified

26
27
28def current_sprite() -> sprite.Sprite | None:
29 """
30 Retrieve the default sprite from the top of the sprite stack
31 """
32 if len(_sprite_stack) == 0:
33 return None
34 return _sprite_stack[-1]
35
36
37def pop_sprite(_sprite: sprite.Sprite) -> sprite.Sprite | None:

Callers 4

__repr__Method · 0.85
add_blockFunction · 0.85
add_chainFunction · 0.85
add_commentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected