UPDATING OLDER MAPS FOR 2.1
-
@ebbe Just a warning: The fact that a map is "running" in 2.1 without errors doesn't necessarily mean that it is correctly coded for or updated to it, because there are items that are not validated or that are deprecated (or both) (and I believe the program is not giving any warning for deprecated elements).
-
If using an XML element that has been removed, chances are really good schema validation will fail, or if not, map parsing would fail.
If the element is 'deprecated' but the map still loads, then the engine is doing some backward compatibility magic to translate the 'deprecated' elements to non-deprecated variant.
-
@LaFayette said in UPDATING OLDER MAPS FOR 2.1:
If using an XML element that has been removed, chances are really good schema validation will fail, or if not, map parsing would fail.
Yes, since most is validated. I was just saying that you cannot be sure. For example, inexistent properties are simply ignored.
-
I'm not aware of any ignored properties. Either a property is going to "do the right thing" and translate itself into modern code, or the XML schema validation will throw a fit because the property is not recognized.
I'm interested in any counter-examples that you may run across @Cernel . Those are worth addressing in one manner or another.
-
@LaFayette said in UPDATING OLDER MAPS FOR 2.1:
I'm not aware of any ignored properties. Either a property is going to "do the right thing" and translate itself into modern code, or the XML schema validation will throw a fit because the property is not recognized.
I'm interested in any counter-examples that you may run across @Cernel . Those are worth addressing in one manner or another.
@LaFayette As I said, properties are never validated, as far as I know and as far as a non-developer can be sure about it. Having a wrong property simply equals not having it (which, in turn, equals having it false and non-editable). You can test it by mangling the name of a property of whatever game. The result of this should be the same as having deleted the property from the game file (xml).
-
There is a DTD, doc type definition that does enforce which XML entities and properties are allowed.
I was thinking you meant an XML property as opposed to a TripleA
<property>
tag. In XML, a property is typically a value after a tag, eg:<tag property=123>
When parsing in an enforcing mode the DTD defines which properties are valid and which are not.
Though you are right about property name values. An unrecognized one would go unused. EG:
<property name='not-recognized'>