New editor commands: Resize Outdoors and Import Sector

This includes the following changes (mostly related to the above):
- Move loc_compare functor to location.hpp
- Add reattach() function to rebind a town or outdoor section to a different scenario object. (I don't think this is strictly necessary, as the scenario reference is only used in limited situations in the game itself, not in the editor, but it's better not to keep a reference to freed memory around when importing a town or sector from another scenario, even if the reference is never accessed.)
- Fix imported towns not being officially "loaded" until you explicitly use Load a New Town to reload them
- Fix Choose button in Load New Sector dialog
- More functions in the vector2d implementation
This commit is contained in:
2015-06-25 23:55:55 -04:00
parent 8a4e7a7a72
commit ef0cdebec4
22 changed files with 403 additions and 55 deletions

View File

@@ -348,6 +348,14 @@
<reference key="NSOnImage" ref="229763992"/>
<reference key="NSMixedImage" ref="909111550"/>
</object>
<object class="NSMenuItem" id="872790335">
<reference key="NSMenu" ref="399390342"/>
<string key="NSTitle">Resize Outdoors</string>
<string key="NSKeyEquiv"/>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="229763992"/>
<reference key="NSMixedImage" ref="909111550"/>
</object>
<object class="NSMenuItem" id="610226442">
<reference key="NSMenu" ref="399390342"/>
<bool key="NSIsDisabled">YES</bool>
@@ -457,6 +465,14 @@
<reference key="NSOnImage" ref="229763992"/>
<reference key="NSMixedImage" ref="909111550"/>
</object>
<object class="NSMenuItem" id="327378958">
<reference key="NSMenu" ref="399390342"/>
<string key="NSTitle"> Import Outdoor Sector</string>
<string key="NSKeyEquiv"/>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="229763992"/>
<reference key="NSMixedImage" ref="909111550"/>
</object>
<object class="NSMenuItem" id="580939217">
<reference key="NSMenu" ref="399390342"/>
<string key="NSTitle"> Edit Saved Item Rectangles</string>
@@ -1267,6 +1283,8 @@
<reference ref="963208893"/>
<reference ref="1072664025"/>
<reference ref="368560496"/>
<reference ref="872790335"/>
<reference ref="327378958"/>
</array>
<reference key="parent" ref="741259600"/>
</object>
@@ -1635,6 +1653,16 @@
<reference key="object" ref="1044668105"/>
<reference key="parent" ref="720053764"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">891</int>
<reference key="object" ref="872790335"/>
<reference key="parent" ref="399390342"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">892</int>
<reference key="object" ref="327378958"/>
<reference key="parent" ref="399390342"/>
</object>
</array>
</object>
<dictionary class="NSMutableDictionary" key="flattenedProperties">
@@ -1744,12 +1772,14 @@
<string key="888.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<string key="889.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<string key="890.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<string key="891.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<string key="892.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
</dictionary>
<dictionary class="NSMutableDictionary" key="unlocalizedProperties"/>
<nil key="activeLocalization"/>
<dictionary class="NSMutableDictionary" key="localizations"/>
<nil key="sourceID"/>
<int key="maxID">890</int>
<int key="maxID">892</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes"/>
<int key="IBDocument.localizationMode">0</int>