Skip to content

How can I give sprites properties? #2023

Closed Answered by GarboMuffin
MagentaDude asked this question in Q&A
Discussion options

You must be logged in to vote

If you don't need it to save when the project is saved and loaded again:

  • you can do target.whatever = bwah; and it will probably be okay
  • to avoid collisions you can make a symbol instead const whatever = Symbol(); then use as target[whatever] = bwah;
  • or you can use a WeakMap

If you need it to save when the project is saved and loaded again:

  • target.extensionStorage.yourExtensionID.whatever = bwah; and this will be saved for you

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by MagentaDude
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants