Skip to content

Commit 603c11f

Browse files
Create removeScenePushHandler.md
1 parent ab2e7c8 commit 603c11f

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
## removeScenePushHandler
2+
Removes a scene push handler.
3+
4+
## Example
5+
Remove a new sprite when the handler is removed.
6+
``` ts
7+
let mySprite = sprites.create(img`509509505950950`, SpriteKind.Player);
8+
game.removeScenePushHandler(() =>
9+
sprites.destroy(mySprite);
10+
})
11+
12+
game.pushScene(); // push the scene to register it
13+
```

0 commit comments

Comments
 (0)