BATTLEZONE 1.5.2 BUILD NOTES

Version 1.5.2.24
Preview 2014-08-10
Update 2014-08-11
Re-update 2014-08-12

I've added enough stuff since the 1.5.2.23 preview that it warrants a new version number.  The update and re-update fix a few bugs reported in the original preview and add a couple new features.  I'm hoping this release will be the one that sticks.  :)

What's New

Scripting

* Integrated LuaBitOp 1.02 into Lua
	- Automatically enabled as part of Lua
	- Provides a variety of bit operations (hence the name)
	- Might be useful for packing data into network packets
	- http://bitop.luajit.org/index.html

* Added Lua "warning" function
	- Works like "print" but outputs yellow text to the console window
	- Changed error messages to red
	- Changed panic messages to magenta

* New Lua script event handler
	- GameKey: called when a game key gets pressed

* New Lua script utility functions
	- SetLabel: change the label of a game object
	- IsLocal: returns true if the game object is local
	- IsRemote: returns true if the game object is remote
	- GetTimeNow: get local system time in milliseconds (good for profiling)
	- GetTimeStep: get the simulation time step in seconds
	- SelectedObjects: get iterator returning selected objects
	- GetTeamSlot: get the handle of the object in a team slot
	- GetRecyclerHandle: get the Recycler handle
	- GetFactoryHandle: get the Factory handle
	- GetArmoryHandle: get the Armory handle
	- GetConstructorHandle: get the Constructor handle
	- SetLocal: sets a game object as local, transferring ownership

* New Lua global variables
	- GameVersion: contains current build version (e.g. "1.5.2.24 Preview")
	- LastGameKey: holds the most recently pressed game key
	- TeamSlot: maps between team slot numbers and names

* Enhanced LuaMission Send and Receive
	- Can send an arbitrary number of data values
	- Preserves data types instead of converting to string
	- Converts game object handles

Gameplay

* Fixed Building::DamageAlloc rounding damage down
	- Particularly noticeable with low damage-over-time values

* DayWrecker supports direct-impact damage

[DayWreckerClass]
damageBallistic = 0
damageConcussion = 0
damageFlame = 0
damageImpact = 0

* Torpedo supports direct-impact damage

[TorpedoClass]
damageBallistic = 0
damageConcussion = 0
damageFlame = 0
damageImpact = 0

* Tweaked PowerUp landing logic slightly
	- Check terrain height, not floor height
	- This makes DayWrecker collision work properly

* APC can reload at an undeployed Recycler again
	- Restores original 1.4 behavior

* Disabled code in Building constructor snapping it the ground
	- It's redundant and interferes with some custom maps

* SetCurHealth and SetMaxHealth update health ratio (returned by GetHealth)
	- Only AddHealth did this before

* SetCurAmmo and SetMaxAmmo update ammo ratio (returned by GetAmmo)
	- Only AddAmmo did this before

* Fixed Mines not snapping themselves to the ground
	- Turns out the Mine constructor had never done it right...
	- Update Mine position after it snaps itself to the ground

Multiplayer

* Remote damage packet supports damage types and team
	- Not used for anything (yet)

* Added support for team-based spawn points
	- Zero team allows any player team to spawn there (like before)
	- Non-zero team allows only that player team to spawn there

* CommandPanel shows Factory, Armory, Constructor, and Satellite entries again
	- These had gone missing due to changes in initialization order

* Added /help command to in-game chat

Shell

* Fixed Version and Mission CRC labels overlapping "READY TO LAUNCH" label

Editor

* Fixed current working directory when saving terrain
	- The file requester modified it and made the save fail

Load/Save

* Show an error for missing mission, save, or terrain file
	- Provides better feedback about which file is missing
	- Avoids showing a series of unhelpful error messages
		. "Error Loading pallete"
		. "Error loading luminance table"
		. "Translucency table not found; disabled"
		. "Alpha table not found; disabled"
		. "Zone Loader Error"

* Removed LuaMission "started" flag from mission file (BZN)
	- Missions by definition have not started when loaded from BZN
	- Bumped save version to 1045
	- BZN version 1045 is equivalent to version 1043
	- SAV version 1045 is equivalent to version 1044

* Use LuaMission as a substitute for missing mission classes
	- Print a red error notification in the console when this happens

* Basic support for Red Odyssey mission files
	- BZN version 2003 and 2004
	- Skip over Craft cloak values
	- Skip over Portal state values
	- Skip over ConstructionRig lastRecycled value
	- Don't try to read Scavenger scrap held (added in BZN version 1039)

Debugging/Logging

* DEBUG_systemWarning and DEBUG_systemError also output to console
	- DEBUG_systemWarning outputs red text indicating a non-fatal error
	- DEBUG_systemError outputs magenta text indicating a fatal error

* Fixed MonoDebug pushing additional consoles onto the console stack
	- This prevented it from restoring the debug console

* Missing transparency and alpha table messages include file names
