Naming Labels: How do you do it?

Hey!


I was just curious, how do you guys name your labels? Do you think of a fitting name for the piece of code that comes after it, or do you simply give them numbers or letters? Do you mark them in some way?


I must say I have tried a few different approaches, but I ended up just giving them numbers at one point. Which I realize can be quite bad in terms of overview, but I rarely use events with a whole lot of labels anyway. But maybe one of your ideas actually inspires me. 🙂
I name them after the NPC or event that triggers the label.
Errr, wait. Labels are bound to their event, or are they not? Is my mind about to be blown?
For simple things I just number them starting with 1. For more complex stuff I give them fitting names.
For simple things i go with numbers, for complicated things i use a fitting name. 


For even more complicated things, (Lets say i have a common part of an event that will run no matter what is chosen, damage calculation in an evented battle system for example. I'd use labels like this: in event action 1: @return="action1end" and at the end of the common part i jump to label @return, if a different action was called i just have to change the value of @return then) i use comments before the label call to have an idea of where to look at, and comments after the label to tell me what the following part is supposed to do.


It really helps when you have to go back to work on an event over the course of several months... (so it's just like commenting your code i guess...)

Original thread: https://forums.rpgmakerweb.com/threads/naming-labels-how-do-you-do-it.56146/