unsuccessful script fields
Revert "unsuccessful script fields"

This reverts commit 34eee09b988d7cb57a11c0ee11fc485cf6f73b68.
add comments and license header
remove custom MemoryIndex, it is never reset anyway