Blitz3D+ Command Reference

FreeWorldDocument document

Parameters

document - world document handle

Description

Releases a world document handle and its retained diagnostics.

JSON snapshots and validation reports already returned to the caller remain caller-owned.

For the full story, see the Debug World Editor guide.

Requires Extended mode.

See also: CreateWorldDocument, LoadWorldDocument.

Example

; FreeWorldDocument Example
; -------------------------
; Requires Extended mode.

; Create a short-lived document, then release it
document=CreateWorldDocument("temporary","Temporary")
If document=0 Then RuntimeError WorldDocumentError()

Print "Created document at revision "+WorldDocumentRevision(document)

; Handles are generational: after freeing, the old handle is invalid
FreeWorldDocument document
Print "Document released - snapshots already returned stay caller-owned"

Print ""
Print "Press any key to close the example"
WaitKey

End

Index