BATTLEZONE 1.5.2 CHANGELOG

1.5.2.3 (2013-03-08)
* LuaMission updates
- Call Setup from the constructor so it gets done in LoadDefaultMission too
- Fixed the Lua script asset not getting unlocked when it failed to load or run
- Made the absence of a Lua script a trace message instead of a dialog warning
- Load but discard any saved Lua values when the script has no Load function
* Removed LuaMission::PostLoad since it was useless
- Mission PostLoad functions only do handle conversion
- Most script functionality didn't work when called from PostLoad
* Re-parented Inst04XMission, MultDMMission, and MultSTMission from AiMission to LuaMission
- These are the three mission scripts that user-created maps are likely to use
- They can now run Lua scripts in addition to their normal fixed-function logic
- MP-related Init and Respawn functions have no Lua script hooks (yet)
* Added .odf and .lua to the misson extensions that crc32mission checks
* Display the Zoom Factor in the Editor (submitted by Dx)
* Strategic AI update
- Replaced 32m "scheduler tiles" with standard 10m terrain grid
- Manages the Construction Rig as an infinitely-reusable construction crew
- Can build buildings in semi-reasonable locations
- Doesn't know about power requirements yet :(
- Continuously updates team base position
* Added all-in-one CMD_BUILD to Construction Rig
- This makes it easier for the strategic AI to control
* Path Display (shift-F9) shows AI goals as colored borders
- No goal: none
- Defend base: bright green
- Attack troops: dark red
- Siege: bright red
- Exploration: blue
- Scripted (scrap): white
- Perimeter: dark green
- Recon: cyan
- Resource: white
- Other: black
- Escort: dark grey
* More ScriptUtility functions
- GetCurrentWho
- HopOut
- KillPilot
- RemovePilot
- HoppedOutOf
- IsNetGame
- IsHosting

1.5.2.2 (2013-03-02): emergency hotfix...
* Fixed AISchedule stuff crashing on starup in multiplayer
* Fixed incompatibility with older save games
* Howitzers check the flight path of their projectile

1.5.2.1 (2013-02-28): 15th Anniversary Build!
* Misn09Mission: made turret setup around the CCA base reliable (submitted by Dx)
* Changed the horrible STRUCTURE2 audio to something better (submitted by Dx)
* Return focus back to the MapList for host selection (submitted by Dx)
* Updated Save/Load Shell (submitted by Dx)
- Requires new "saveload.bmp"
* Updated Pop Up Shell window buttons (submitted by Dx)
- Enabled WM_MOUSEMOVE
* NameDlgProc InvalidateRect IDC_EDIT_NAME (submitted by Dx)
* SaveDlgProc InvalidateRect IDC_EDIT_GAMEDESC (submitted by Dx)
* Made the selected paths a bit easier to read in the editor. (submitted by Dx)
* Improved game object selection
- Uses the larger of bounding radius and collision radius
- These correspond to the circles drawn around objects
- Picks the object closest to the cursor
* Enhanced Edit Object mode
- Show labels above objects that appear as an oriented box with circles
- Highlight the object under the mouse cursor (rollover)
- Reduced unintentional movement when clicking game objects
- Use the point clicked on the game object as a "handle" when moving it
* Enhanced Edit Path mode
- Show the path label over the first node (also with Show Paths)
- Reduced unintentional movement when clicking path nodes
- Use the point clicked on the path node as a "handle" when moving it
* Support getting team players
- Assign remote players to TEAM_SLOT_PLAYER
- Added GetPlayerHandle variant that takes a team
* Back-ported some ScriptUtils from BZ2
- Set object team number
- Modify and query team alliances
- Get and set current health
- Get and set maximum health
- Get and set current ammo
- Get and set maximum ammo
- Add ammo
* Fixed up some scripting weirdness with Misn08Mission
- AddObject was assigning objects to the wrong handles
* Updated ScriptUtil
- Use TeamNum typedef more consistently for team numbers
- Most functions taking a path name also take an optional point index
- Added path variants of GetNearestObject, GetNearestBuilding, and GetNearestEnemy
* Preliminary implementation of LuaMission
- AiMission framework for user-created mission scripts
- Matches any mission file starting with "lua"
- Reads the .lua script named after the mission (e.g. luatest.bzn reads luatest.lua)
- Supported script functions: Load, PostLoad, Save, AddObject, Update
- This has not been thoroughly tested yet...
* Revised LuaMission
- Fixed problems with Handle lightuserdata
- Now works with a real .lua mission script
* Added more ScriptUtils functions from BZ2
- GetWhoShotMe
- GetLastEnemyShot
- GetLastFriendShot
* Added LuaCheckStatus to consolidate error reporting
* Added basic Lua serialization and deserialization
- Supports nil, boolean, lightuserdata (handles), string, and table
- Does not preserve complex reference structures like lua-marshal
* More LuaMission tweaks
- Only call script Save and Load for save games
- Added some comments to code
- Debug build enables Lua os and io libraries
* LuaMission displays a message when it can't find a Lua script
* Switched to Lua 5.1.5
- Lua 5.1 has better tool support than 5.2
* Spiffied up PathDisplay (Shift-F9 view)
- Made it easier to click on small objects
- Show menu item keys with sprites instead of [text]
- Show item keys only for currently-selectable items
- Show menu selection state using color
- Use translucent backgrounds for unselected labels
* More PathDisplay tweaks
- Hold right mouse button to rotate the selected object
. It turns to face the mouse position
. This was actually in the previous commit...
- Placing a game object makes it the selected object
. This makes it easy to rotate
* LuaMission matches any mission with a corresponding .lua script
- For example, it matches misn02l.bzn if misn02l.lua exists
- This only applies when creating the mission in the first place
- CAVEAT: it uses the msn_filename value (like Inst04XMission)
* Improved DistributedObject bandwidth throttling
- Take reliable packets into account
- Take UDP packet header overhead (40 bytes) into account
* SetAIP takes a team number argument
- It defaults to 2 for backwards compatibility
* AIPs can control any team, not just team 2
- This has not been thoroughly tested yet...
- Controlling a player team will have unknown effects
* Fixed LuaMission::Save dropping the last data value
* Added more ScriptUtils functions from BZ2
- GiveWeapon
- IsDeployed
- Deploy
- IsSelected
* Made HasCargo safe to use with non-Tug units
- Returns false in that case
* Improved how LuaMission gets and pushes Handle values
- Push nil for a zero handle so Lua logic can test for it
