Orderly Behaviors
February 3, 1999
by Alex Zavatone
Here's a quick tip that will help you separate and organize your behaviors. I'm sure you've seen the "endless popup of behaviors" in the score and behavior inspector when you try to add a behavior to a sprite. One of my current projects has over 500 scripts and this gets a bit well, less than effective. As it turns out, with a few creatively named scripts this problem can be turned into a nice organization layout of your scripts as in the illustration below:
The trick here is to use behaviors that contain nothing. They only need to be named what you need them to be named. For example, to generate a horizontal line in the popup, name your behavior "--" (sans quotes). To create an empty space, just name an empty behavior with one or two spaces. If you're wondering what this looks like in the cast, it's as simple as this:
This way, you can use horizontal divider lines and empty spaces to separate the scripts from different castlibs and find them in a snap when confronted with the "behavior popup from hell" in the behavior inspector.
Copyright 1997-2024, Director Online. Article content copyright by respective authors.