[dismiss]
This wiki is a copy of the original Oblivion CS wiki created and maintained by the UESP.net. See CSwiki:Copy Notice for more info.
Difference between revisions of "IsFormValid"
Jump to navigation
Jump to search
Added a note about deleted ESM forms
imported>UDUN (New page: <!-- Begin Search Terms Form Valid End Search Terms --> A command for Oblivion Script Extender '''Syntax:''' (valid:bool) IsFormValid refVar:var ...) |
imported>QQuix (Added a note about deleted ESM forms) |
||
Line 11: | Line 11: | ||
==Notes== | ==Notes== | ||
When you activate a reference in the gameworld to pick it up the reference remains in the gameworld, but is disabled and marked for deletion from the savegame (unless it is a dynamic ref with mod index 0xFF, in which case it is deleted immediately). | *When you activate a reference in the gameworld to pick it up the reference remains in the gameworld, but is disabled and marked for deletion from the savegame (unless it is a dynamic ref with mod index 0xFF, in which case it is deleted immediately). | ||
When you save, quit, and reload, what happens depends on the persistence of the reference: | :When you save, quit, and reload, what happens depends on the persistence of the reference: | ||
* if non-persistent, the reference no longer exists (isFormValid returns false). | :* if non-persistent, the reference no longer exists (isFormValid returns false). | ||
* if persistent, the reference still exists (isFormValid returns true). | :* if persistent, the reference still exists (isFormValid returns true). | ||
* A similar result occurs if an ESM reference (or any form) is deleted from an ESP and you have that FormID stored. IsFormValid will return true because when the master is loaded, the original REFR record is deserialized into a form object. The override record in the ESP file only serves to set the deleted flag in that object. For references, [[IsRefDeleted]] does detect this scenario and will return true. |