Login
Remember
IF Answers
Ask a Question

# How do I bookmark code I use that is too tricky to remember?

–1 vote
51 views
asked Mar 23 in Authoring by AndrewS (250 points)
recategorized Mar 27 by Alex
I need that memory space for my writing! I'd rather have favorite text to cut and paste.

- authoring-tips

commented Mar 24 by Alex (486 points)
A bit of an unclear question, and presumably specific to Inform?

## 1 Answer

0 votes
answered Mar 23 by AndrewS (250 points)
I generally use comments, especially for something I forgot twice.
[forgot] is useful code to remember something, as is, even more succinctly, [!]. You can also put [! (description)] to remember what it's for.
You may need recursive text search on all the story.ni files to find this, but it can help a lot for precise syntax.
The sort of thing I often forget is
definition: a person (called x) is y-ish:
to decide what number is palace-let:
to decide whether below-is-wrong:
to decide whether you-can-advance:
to decide which person is the suspect:
to decide which direction is the psgdir of (gu - a guardian):
commented Mar 24 by anonymous
I usually put TODO into a comment , e.g. [TODO: blah blah remember this later blah blah.] as it's easy to then search/grep the source code for TODO to find them all. The same couls be applied to blocks of reusable syntax.
This might also be of use: https://inform7.uservoice.com/forums/57320-general/suggestions/751562--ide-add-bookmarks-in-the-source-text
commented Mar 24 by AndrewS (250 points)
Oh, that'd be a neat feature if it got implemented. It seems kind of tricky, though.
TODO is really handy. I suppose any text that doesn't pop up in a word works well for a quick search, so you don't even need the bracket unless your game has lots of mastodons.

## Related questions

- How do I update code to use version 5 of Glulx Text Effects?
- In a Gamebook, how do I fix that the text processor is not working properly on my version of Quest (I think)?
- The inform IDE is only so flexible for text editing. Do I have to use it?
- I want to make a verb that requires to things at once. How do I do this this? [internet version]
- How do I use code formatting in posts on IF Answers?

...