Unanimate.all

From AGI Wiki
Revision as of 18:10, 24 April 2019 by Andrew Korson (Talk | contribs) (Created page with "The '''unanimate.all''' command deactivates all screen objects. == Syntax == unanimate.all(); == Remarks == The '''unanimate.all''' command marks all screen objects as...")

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

The unanimate.all command deactivates all screen objects.

Syntax

unanimate.all();

Remarks

The unanimate.all command marks all screen objects as 'uninitialized', and 'not drawn'. All objects will no longer be updated, moved or cycled on screen. This means objects must be re-initialized before they can be used again.

Possible Errors

Although it would seem that unanimating objects would erase them from the screen, unanimate.all doesn't actually erase any objects. This appears to be a bug in AGI, because after AGI removes the background bitmaps for the objects from memory, it does not redraw the screen like it does in all other instances where the background bitmaps are deleted. A workaround is to use the show.pic command to force AGI to redraw the screen with the objects removed.

Example

Code:
#define disintegrate_all f72
if(isset(disintegrate_all))
  {
  unanimate.all();
  show.pic(); [ force a redraw to make them actually disappear
  }

Technical Information

Required Interpreter Version: Available in all AGI versions.
Byte-Code Value: 34 (0x22 hex)

See Also

animate.obj