Forts Progress

1/3/2003
- Insert and link nodes bridge builder style
- Implemented spring model

2/3/2003
- Delete Nodes
- Nodes bounce off walls
- Fixed bug with small delta distance
- structures can support themselves
- draws grid
- snaps to grid
- Clear entire graph
- save graph
- restore graph
- add save and restore commands
- move nodes

3/3/2003
- edit global parameters
- made viewport zoomable and scrollable
- mapped mouse between screen and world space
- fixed up some snap to grid code (and made snap toggleable)

4/3/2003

5/3/2003
- place and link ground nodes

9/3/2003
- integrated triangulation library
- move existing ground nodes
- delete existing ground nodes
- insert ground nodes on existing links

10/3/2003
- save ground to separate file
- restore ground from file
- organised key profiles for sturcture and ground editing
- added edge snap

11/3/2003
- reduced scroll speed
- add clear ground key
- prevent crash when file not found
- add support for adding, deleting, and switching ground groups
- improved stability of spring/mass sim

12/3/2003
- fixed ground load bug
- fixed gravity application (it's already an acceleration)

13/3/2003
- improve scrolling
- implement structure/ground clipping

15/3/2003
- fix bug: placed 2 ground nodes, then deleted them in reverse order, then could not place another new node (only 1 ground group)
- improve structure/ground clipping
- nodes reflect their position and velocity when their movement intersects the ground

16/3/2003
- wrote new intersection function that allows you to safely two nodes on the ground surface
- fixed bug:
    - had simulation running
    - had two ground groups, one selected
    - tried to create a new group
- added velocity damping in the direction of the spring
- make links snap if they compress or expand too much
- colour links according to stress
- infinite link bug
- links snap at the node, not the edge, so beams remain in existence

17/3/2003
- correct spring damping
- prevent PlaceNode from fixing nodes to ground
- new links created from link breakage have original link length

18/3/2003
- make spring k accessible to the console
- clamp time step
- fixed circle drawing
- put node circles on top of links
- nodes seeping through the ground (hack fix)
- made maximum compression and expansion values accessible

19/3/2003
- Fix link colouring
- make link colours configurable
- make ground colours configurable
- fix zooming (multiply, not divide)
- make scroll wheel zoom
- re-enable major grid
- make background colour configurable
- implemented Andrew's suggestion for quick line segment rejection
    - 10ms per frame saving in debug mode
- make grid colours configurable
- make grid disableable
- make node colours configurable
- save preferences file
- properly separate states into files
    - e.g. gravity into ground file
- make a separate key for toggling grid
- add version number to structure file

20/3/2003
- display simulation parameters
- let snap to grid fix nodes onto snapped ground
- Draw links only once

22/3/2003
- clean up memory
- Added springs to cvs repository
- moved explosion and explosion_cache classes from Airlock to springs

23/3/2003
- ported explosion class
    - trial run with sound effect

24/3/2003
- Better integrated effect system
- Added sparks
    - usage needs tweaking

25/3/2003
- design system for spark emission
    - have an effect manager allocate resources for sparks and sounds, using a leaky bucket
- Implemented effect allowance system
- Imposed maximum node speed
- Applied force to link nodes proportional to where the collision occured on the link

26/3/2003
- structure reflected node checks position before reflecting to help prevent ground seepage
- made max velocity configurable and part of ground file

29/3/2003
- Real-time building system
    - can't place a solitary node except for on the ground
    - mouse does not exert a force
    - nodes remain fixed for a number of seconds (indicate with a number, colour, ticks?)
    - if linked nodes move too much relative to the braced node, the braced node is destroyed (or made unbraced?)
    - need sensible snappage rules with regard to braced nodes
        - if other node is braced, then unbrace it
        - this node is braced, then unbrace it
    - indicate brace time remaining with clock like device & shockwave effect

30/3/2003
- Real-time building system
    - pause physics timer when simulation is off
    - save brace state?
- implement snap to node
- add to HUD
    - simulation enabled
    - edit mode
- nodes take on the mass of links
- disabled node reflection for anything other than singular nodes (for speed)

- Weapon system
    - add weapon placement mode
        - highlight rollover beam and connection point
        - weapon links to beams
        - remains perpendicular to the beam (facing up when placed)

31/3/2003
- Weapon system
    - add weapon control mode
        - select weapons (by connection beam)
        - select angle (follows mouse?)
        - select strength (by how far mouse is from weapon)
        - fire button launches weapon
        - retains settings from last firing

1/4/2003
- Weapon system
    - add mouse control mechanism

2/4/2003
- Made sparks use normal to orient drift velocity
- fixed bug with reattaching weapons after a link snap
- Weapon system
    - save/restore weapons
    - projectiles marked with a flag
- fix rogue weapon line bug
- fix deletion of weapon on destroyed link bug
- projectiles drawn as lines

3/4/2003
- Made bullets pass through links if they have enough damage
- Make weapons load their settings from a file

5/4/2003
- Fix weapon removal when node is deleted
- Fix toggling weapon orientation
- Select Links
- Delete Links
- Add setup tool

6/4/2003
- Indicate snap to ground
- multiplayer support
    - created server based on MFC dialog
    - merged client database/chat system from Airlock into server and client
    - connection made to server, hard coded test ground successfully loaded

7/4/2003
- multiplayer support
    - Setup secondary PC and network
    - Tested connection
    - Got chat working

8/4/2003
- set selection to null when exiting structure edit mode
- force simulation to run and build assist while online
- fixed real time usage (issue highlighted by clock sync)
- moved bracing code into PlaceNode so that message includes brace state
- Piggy backed simple case link creation on create node message
- multiplayer support
    - add Node owner ID
    - transmit version strings and reject on bad version
    - transmit node creation
    - transmit link creation

9/4/2003
- multiplayer support
    - transmit node updates
        - split over multiple packets
    - doesn't break links if not the owner

10/4/2003
- setup shortcuts to sync secondary and start server
- add a button to zero the camera
- center mouse at start
- links made over the network must have their length sent
- display performance graphs

11/4/2003
- CLO to connect and login to server
- fixed graphs

12/4/2003
- Make server listen on all interfaces
- prevent ground edit mode online
- Added SetTime method to Timer
- serialised temporary brace status
- implemented destroy node message
- implemented destroy link message
- proxy links don't break (message from owner)
- fixed input queue length bug
- fix recoil force (buildup from multiple shots gone)

13/4/2003
- add client info readout to server
- fixed buffer overrun on server (small message buffer)
- synchronises projectile spawn
- synchronises weapons
- fix late join bug (quick linking with non-existent node)
- send final weapon state when releasing mouse control
- transmit link damage
- fix stress break transmission
- change exe name to FortWars.exe
- inactive conpos non-zero online, +make noise when text arrives
- soundeffect when chat message arrive
- add key to toggle performance graphs (+disable loss/order for now)
- fixed delete all effect
- disable Ctrl-D while online
- give server map name CLO
- made readme.txt
- if in ground edit mode on connection move to structure edit

14/4/2003
- fix spawned projectile takes over selection when building
    - fixes a few stability issues
- send spawn projectile unreliably
- don't synchronise projectile nodes
- put a time limit on projectile life time
- clear auto login after use
- Transmit initial conditions
    - resets simulation if too much data to send
- destroy nodes and weapons owned by disconnected player
- add clear simulation distributed command
- built v10

15/4/2003
- Fix premature proxy projectile timeout
- Fix andrew's map bug (empty ground groups)

16/4/2003
- fix ping display bug in server
- always transmit sync messages
- add client list
- limit length of links
- add name tag to weapon and node creation

17/4/2003
- added background to clientlist
- prevent selection of other people's weapons
- add name tag size to preferences

18/4/2003
- properly span world state message
- disable new client simulation until all state messages have been received
- world sync weapon create messages should be directed towards new client
- need to make world sync fault tolerant
- fixed blank ping on server bug
- fixed weapon not appearing on secondary after world sync
- change map command
- started file transfer system

21/4/2003
- got basic file transfer working both directions between client and server, and from client to client
- started working on map synchronisation

22/4/2003
- check that maps are identical on all machines
    - when new client connects need to check that it has the same map as everyone else
        - if not then need to have the map sent from one client to another
    - when a client requests a map change
        - each client is asked if they have the right map
        - if not
            - if the server has the map cached
                - any clients that do not have the map are then sent the map by the server
            - else
                - the server gets the requesting client to send the map for caching
                - any clients that do not have the map are then sent the map by the server
        - the server tells the clients to reset game and load the map

23/4/2003
- Fixed up Audio system freeze problem
    - reinstalled NVidia drivers, removed audio device, reinstalled latest Live! drivers
- transmit client source with file parts
- clean up file transfers if disconnected

26/4/2003
- Add broadcast classes to network library
- Added server query back-end system

27/4/2003
- Experiment with remote execution/control tools

28/4/2003
- exit server gracefully when port in use
- add a send file to all command
- server list page

29/4/2003
- compressed floats in node sync and world sync messages into signed shorts
- doesn't sync position of fixed nodes
- prevented some inappropriate console commands when online
- added -map command to client
- added optional .lev file association to installer

30/4/2003
- bind view to world extents
- middle mouse button to centre view
- add world extent customisation to ground editor

26/5/2003
- tint world outside of world extents

30/6/2003
- add zoom in on selection button
    - set camera focus
        - center of extents
    - set zoom using ratio of deltas and current zoom

1/7/2003
- auto-target mode

2/7/2003
- improved targeting AI, so it can fire right to left

5/7/2003
- add align world extent to screen function (and store minimum zoom level in level)
    - HOME key to save extents and zoom limit

6/7/2003
- rationalise world extents
    - when manually setting world extents, need to calculate biggest possible zoom limit
- fix disappearing world extent panels
- clamp world extent adjustment based on minimum zoom level
- display world max zoom in ground edit mode
- display world axes in ground edit mode

7/7/2003
- rename .lev to .fwe

1/9/2003
- make projectiles that fall outside the wall get destroyed
    - only if their motion blurred position is out of the world too

7/9/2003
- put levels in separate directory
- implemented auto complete for directory and filenames

8/9/2003
- fixed bug in map name command line parsing
- have different icon to lev files
- reduce mouse strength

11/9/2003
- fixed working directory problem when clicking on isolated fwe files
- snap to world extents option

15/9/2003
- found new icon
- committed latest changes

13/10/2003
- make physics frame rate independent?
    - graphics runs as fast as possible, interpolating between two physics frames
        - each node keeps there current and previous physics positions
        - gross state changes such as linkage are based on the current frame
    - physics runs at 60 Hz
        - loop looks like:
            - calculate desired physics time
            - calculate how many phyiscs frames to get up to date
            - run physics until we get to the desired frame
            - use real time to calculate visual interpolation factor
            - calculate interpolated node positions
            - render frame using those positions

- make physics frame rate independent
    - add previous position to node structure
    - calculate desired physics frame
    - loop over physics functions with physics time step

14/10/2003
- make physics frame rate independent
    - calculate graphics interpolation parameter
    - modify render code to take interpolation parameter
    - modify create and load code to initialise the previous position

16/10/2003
- make step mode step one physics frame at a time

17/10/2003
- make step mode step one physics frame at a time
- setup second PC

20/10/2003
- write design document

2/11/2003

30/11/2003
- separated reusable libs from Airlock into engine00 folder
- reorganised interface lib so each control has its own header

14/12/2003
- fill in the tree control with the control heirarchy
- support for more than one window open at a time

21/12/2003
- Prevent background of window from being drawn

22/12/2003
- Fixed shifting background sprite when resizing
- Child windows get draw correctly when they are opened
- Make sure different chile windows draw the appropriate page
    - Get main page from document, not global page stack

1/1/2004
- Add a control bar for current selected control properties
- prevent "enter" from closing the properties dialog
- fix problems with fullscreen in fort wars

5/1/2004
- Display name of single selected control
- Modify name of single selected control

15/2/2004
- making selection in control bar changes selection in the view and properties dialog

16/2/2004
- add a toolbar
- add a create sprite button

18/2/2004
- add move control function

19/2/2004
- add resize control function

20/2/2004
- change mouse cursor based on resize/move state
- make properties dialog for all widget editing

21/2/2004
- control delete function
- fix resizing/moving of sub controls
- when escape key is pressed during a move, the operation is reverted

22/2/2004
- make escape undo current resizing
- prevent text resizing
- when control name is changed, reflect this in the control tree
- when mouse doesn't move, deselect lowest control under it
- add shift additional selection
- fix text centering

23/2/2004
- add colour editing
- prevent resizing of text from properties dialog

28/2/2004
- added basic mesh rendering for weapons

29/2/2004
- fix crash on exit (bad used files file)
- put weapon mesh filename in the weapon config file

3/3/2004
- make weapon arms and barrel face the target
- draw named submeshes for base

4/3/2004
- render all arms and barrels
- fix crash on exit bug
- fix normals for lighting

5/3/2004
- make aim pivot the same as the visual pivot
- add main menu UI screen
- package up for Dan and Sonia

8/3/2004
- fixed problem with working directory changing when browsing for a file

15/3/2004
- allow ability to select different weapon classes at run time
    - file listing number of weapons, weapon name, file, cost in metal, cost in energy
- set static control colour on restore

17/3/2004
- fix static texture change bug

22/3/2004
- add landscape props
    - properties are:
        - texture
        - position
        - width
        - height
        - angle

23/3/2004
- prop selection, deletion
- prop dragging and scaling

26/3/2004
- prop scaling working with rotation

- add tiling ground texture
- block accepted sandbox input events from reaching world object?
    - check what happens when (i.e. mouse down/up)
    - flag something to ignore input
- add stub pages for all UI screens
- make special sandbox mode in World object
- make groud edit only mode in World object
- implement map select screen

2/5/2004
- made some alpha tree props
- fixed bug with prop selection

11/7/2004
- serialise props

12/7/2004
- change default prop orientation so they face up
- add prop selection lock

22/7/2004
- add proper bounding rectangle detection to props
- draw faint outline to all props in prop edit mode
- implement minimum prop size on end resize

25/7/2004
- be able to change render order of props
- moved render order so props are rendered just after the ground

26/7/2004
- added per-group colour (not serialised yet)
- make ground group selectable by click

31/7/2004
- serialisation of ground block colour

3/8/2004
- device class drawable

8/8/2004
- weapon derives from device

9/8/2004
- add devices to the weapon list

10/8/2004
- fix up the way weapons and devices are configured from their files
- make devices load base class properties
- device selection is now an axis aligned rectangle test

11/8/2004
- make concept art for artist to work from

12/8/2004
- create all of the device types with stand-in artwork

18/8/2004
- make stand-in weapons
- give player metal and energy accounts

23/8/2004
- make devices generate/store metal and energy according to their configured rates
- make weapons require and user energy and metal when firing

24/8/2004
- make weapons cost metal and energy to build

30/8/2004
- weapons have custom effects when they fire

4/9/2004
- add bounding volume center offset to devices

6/9/2004
- add hit detection to devices
- add hit points to devices

7/9/2004
- make effect when a device is destroyed
- allow devices to be planted on the ground (according to flag in config file)

8/9/2004
- add material list
- add ability for sandbox to set the material to create
- add ability for sandbox to set edit mode

9/9/2004
- prevent build menu from affecting world

14/9/2004
- make max compression/expansion part of the material properties

16/9/2004
- add tiled/aligned sprite to link rendering with animation support
    - add animated texture class

17/9/2004
- add texture animation class
- add animated texture index to material and link structure

20/9/2004
- add methods to world to create and configure global animated textures
- add tiling per unit to links

22/9/2004
- move building materials to worlds, identify material in link with a material ID
- add armor struts
- add solar panels
- add energy shields
- add width to material params
- tweak material texture tiling

23/9/2004
- make building materials cost metal and energy
- fix mines making metal
- make energy shields drain energy
- make solar panels generate energy
- pass material ID to relink nodes function
- add full resources cheat
- add momentum reflection threshold
- make shields reflect small arms fire

25/9/2004
- make bite angle influence ricochet
- make armor reflect small arms fire (with RandNormal distribution + loss of energy)
- make per-material collision, ricochet, explode effect
- check save/restore of structures
- make v14 build

29/9/2004
- fix stress and damage rendering with textured beams

3/10/2004
- move device configs to world (like materials)
- device selection by index in sandbox

4/10/2004
- fix save/restore of devices
- prevent building devices on some materials
- add projectile type to weapon configs (bullet and beam)

5/12/2004
- revised design for beam laser

11/12/2004
- add beam laser
- weapon has a beam segment array
- while being fired, it uses projectile spawner to collide and reflect itself with the world

12/12/2004
- beam reflects off only certain materials (energy shield)
- weapon applies damage to final point of impact

15/12/2004
- ground makes effect when hit with beam
- beams exert force on weapon
- beams exert force on hit structures
- build v15

16/12/2004
- fixed reflector in front of ground bug
- beam uses energy while on

26/1/2005
- add separate beam impact effect
    - add projectile configuration data to weapon files (projectile and beam types)
        - ground impact
        - bracing impact
        - solar panel impact
        - armor impact
        - armor deflection
        - shield impact
        - shield deflection
    - projectiles are tagged with their projectile type index
    - on impact with a structure, projectile spawns effect based on given weapon

27/1/2005
- add temporary device-ground collision detection

29/1/2005
- add device out-of-map detection

3/2/2005
- mostly fix projectile reflection

4/2/2005
- fixed projectile reflection rendering, looks pretty good now

5/2/2005
- re-add sprite effect

10/2/2005
- add initial velocity to sprites
- add gravity effect to sprites
- add drag effect to sprits
    - support from particles for acceleration and drag
    - code to read variables, pass to particles
    - add to files

16/2/2005
- make projectiles into sprites
- make spark effect textured sprite
    - feed texture into spark effect
    - add drag and thickness
- add thickness to weapon projectiles
- make beam laser textured sprite
- fix projectile reflection rendering

27/2/2005
- fix physics frame advance
- fix projectiles hitting ground before being reflected properly
- fix beam texture starting point
- make beam textures scroll
- fix spark emission from beam/shield
- fix effect of when node hits shield
- add glow and blue spark emission from beam collisions

1/3/2005
- add slow/fast motion

2/3/2005
- add projectile and missile files to workspace from airlock

3/3/2005
- adapt projectile and missile classes from Airlock
    - remove base actor dependency
        - move any required data and functionality from CActor to CProjectile
        - remove projectile source actor and sim mode
        - remove target actor and replace with target position
        - remove memo code
        - decide on requirements for collision response
            - simplify collision functions

10/3/2005
- mass is not being lifted from nodes when devices are deleted from them
- fix texture state problem with text and sprites when large number of collisions occur
- remove Airlock guided missile and start new clean purpose built classes

11/3/2005
- texture not set without device being drawn?

14/3/2005
- now tests ricochet velocity to prevent nodes from falling behind beams
- fixed post ricochet placement test
- added modulator of ricochet standard deviation based on angle of impact

15/3/2005
- updates single nodes first, then linked nodes
- back tracks if a reflection would put the node past another beam

16/3/2005
- get node and link drawn in sync (maybe link pos doesn't user graphical position?)

17/3/2005
- destroy nodes that make it into the ground

19/3/2005
- fix edge/edge collision testing bug

17/4/2005
- add bounce bucket
    - destroy nodes that reach a threshold
- link mass now added and deducted from nodes
    - verify addition and deduction

11/5/2005
- nodes lose energy when they hit the ground
- destroy orphan-by-node submersion link nodes

14/5/2005
- add effect when nodes vibrate to destruction
- why do single links gain so much energy?
    - after reflection the linked node gains energy from the shift in position
    - dampen the springs more
- externalised Node class and MaterialParams
- made meshprojectile files
- meshprojectile draws mesh
- weapon spawns node and attaches it to an available meshprojectile
- world detaches meshprojectile when the node is destroyed

15/5/2005
- meshprojectile mesh transform corrected
- missile trails work
- missiles fade once they collide
- update trail pos when projectile gets reflected
- guided missiles
    - projectile class
        - attached node, mesh, trail
        - state (idle, active, fading)
        - target position for guided missiles
        - type (dumb, guided, parachute)
        - performs (mesh rendering, trail maintenance, collision/impact/effect/dud logic)
    - allocate an array of these
        - when a weapon wants to fire one, it allocates one from the pool
        - a node is created for it an attached
        - non-idle projectiles are updated per frame

6/6/2005
- make trail drift away from rocket (extension to trail)
- tweak missile behavior

8/6/2005
- uses RandNormal to calculate erratic target angle and period between erratic targets

19/6/2005
- constrain gravity to be vertical
- allow drag to be set by the projectile
- add chute opening code

20/6/2005
- add variation to weapons

21/6/2005
- adjust cannon damage, visuals, drag
- energy shields don't stop cannon shells (use deflection code)
- shields reduce speed of projectiles when they pass through

2/6/2005
- mark shields links as collided with and continue checking projectile against other links

31/7/2005
- stop metal mines colliding with the ground
- fix device bounding boxes so they properly surround the mesh

2/8/2005
- mine does not restore properly
    - they need to record their position explicitly? other devices record in reference to their parent structure
- get save/restore of complete maps (ground and structures, and seperately) figured out
    - Ctrl-S/Ctrl-R saves and restores to a temp file for ground and structure independently
    - why don't nodes move after restoration?
        - some uninitialised node parameters in store

3/2/2006
- make device get destroyed when parent link is removed
- make other nodes get deleted when they are orphaned by a vibrating node
- add device-ground collisions
- devices spawn explosion when vibrating nodes have them destroyed

8/2/2006
- patch up repository for multi-machine development
- check that server, connection, login and basic construction work

9/2/2006
- fixed build menu vanishing when net stats are visible
- link snap effect not loading

13/2/2006
- fix up device construction commands

16/2/2006
- fix up projectiles

24/8/2006
- Added bracing plate (end plates)
- Added base plate (foundations)

27/8/2006
- Made foundations inherit the normal of the ground it's placed on
- Add ground texture
- fix first prop texture coord bug

28/8/2006
- Fixed beam vertex colouring bug

3/9/2006
- Make a ground block class
- ground texture switch
- add support for ground texture scaling, rotation and translation

7/9/2006
- Move to Visual Studio 2005
- Move to a Subversion repository (separate from Biologics)

23/9/2006
- add CDataFile support
- add support for connectors and foundations store files

24/9/2006
- convert material list to use data files
- add support for multiple material textures and angle based selection of foundation
- add beam count selection of bracing plates

2/12/2006
- add level background support
    - external file defining background parameters

3/12/2006
    - move background colour to ground file
    - add background name to ground file, and hold it in World
    - add console command to switch the background
- save ground texture with ground blocks in ground file?
- draw ground normals in ground edit mode

17/12/2006
- fix ground normal with only one node
- make mouse zoom more smoothly at high end, increase min zoom level
- save/restore ground scale, rotation, etc
    - convert existing maps
- add animated background layer support

18/12/2006
- add console command to load/save a fwe file

23/12/2006
- when building, don't snap to grid lines inside of ground
- Add construction preview
    - Put link rendering into a function
    - Make a function to select node render parameters
    - Make a new function to render end point as foundation or joint
- stop links being made through the ground

24/12/2006
- give priority to node snap over ground snap
    - StructureNode, GroundNode, GroundSurface, StructureLink, Grid
- Fixed ground surface snapping (finds closest of all surfaces)
- Construction preview
    - Don't draw node if snapped to a node
    - Don't draw preview in non-structure modes
    - Draw a red line when unable to build
- Fixed bug: Joints don't get upgraded when simulation is off
- Add minimum and maximum link length to building materials
- Fixed bug: preview link and node don't match when mouse snaps to structure node
- Fixed bug: preview node gets left behind if there is no snap
- make cursor snap to intersection of ground and grid lines

26/12/2006
- Fixed Bug: inter-group ground surface snap not working
- Fixed Bug: Can't turn off ground surface snap in ground edit mode
    - Added surface/ground snap control
- Force surface snap in structure and device edit mode
    - Add accessor for m_GroundSnap
- Prevent menu button presses from taking actions with old tool
- Make bracing plates align to one of the links
- Prevent placement of nodes on fissures
    - Add ability to IsPointOnGroundSurface to check for fissures
    - Don't snap to fissure surfaces
- Fix the colour of ground normals, only draw them on the currently selected group
- If no ground group is selected, clicking in open space creates a new group
- Right mouse button can select or deselect ground groups
- Forced outline in ground edit mode
- Fixed Bug: structure mode, preview node is drawn under snapped node
    - Realtime build mode, single node
- Ground multi-select
    - Ctrl-click to add/remove nodes to selection
    - Draw multiselection
    - Click-drag on a node moves all selected nodes

30/12/2006
- Delete old preferences file if wrong version

2/1/2007
- Fix bug: disable surface snap against self group in ground edit mode
- Fix bug: disable node snap against self in ground edit mode
- Set offset to zero if there's only one ground node selected on move-drag

3/1/2007
- Ctrl is required to add ground nodes to selection (otherwise it changes the selection)
- Alt can be used to remove ground nodes from selection
- Existing ground node selection is not lost on new click unless the mouse is not dragged
- Don't insert new ground nodes unless one is selected
- Reduce mass of structure
- Increase deflect capability of armor, to withstand machinegun
- Texture draw bug with single preview node without grid enabled or any links drawn

4/1/2007
- Get screenshots working again
- Give screenshots the date and time they were taken
- If a ground node is selected already, Ctrl-click deselects it

5/1/2007
- Add Paul's new backgrounds
- Ground copy/paste
- bug fix: left click to select/drag can make a prop stick to the mouse, no other operation possible
- bug fix: first prop is not drawn properly (similar to preview node)
- device preview

8/1/2007
- Bug fix: nodes get coloured when some devices get previewed
    GL_LIGHTING is not enabled/disabled properly
- Bug fix: don't draw device preview while weapon mouse control is active
- Allow devices to be selected in structure mode with right mouse button
- Allow building materials to be selected with right mouse button
- Allow switch from device to structure mode by right clicking on part of the structure
- Allow selection of device type by right clicking
- Disable weapon firing when mouse is over menu buttons
- Bug fix: device preview gets drawn at the wrong place when near to ground

9/1/2007
- Ground properties
    - team ownership
        Keys: 1, 2
    - buildable classes (foundations, mines, oil derek, oil rig)
        Keys: F, M, D, R
    - display properties (tries to find good location for text inside ground)
- Calculate extents and center point only when ground is modified
- Use extents in hit-tests

10/1/2007
- Bug fix: weapons can fire from inside ground
- Stop device preview and construction where it would intersect ground
- Bug fix: prevent weapons being spawned beyond link extents
- Allow node snap on selected group while not dragging
- Bug fix: selected ground node (and others) jump to mouse position on selection

11/1/2007
- Bug fix: Can't deselect ground nodes normally
- Show snap options as greyed out when off
- Force link snap off in ground edit mode
- Add background ground group property

12/1/2007
- Force simulation off in ground and prop edit
- Save and restore new ground properties and convert old maps
- Add snap type and normal feedback to World::SnapPos
- Bug fix: ground surface snap jittery and ground/grid surface snap unreliable
- Collapse code that does a special pass for last link in ground groups
- Bug fix: preview and construction dodgy when grid point and ground surface close
- Checked in new build

13/1/2007
- Bug fix: creating a mine causes a crash
- Mouse offsets for dragged ground nodes are relative to base node, so the base node exactly follows the mouse
- Bug fix: normal display when there's only one ground node
- Add flip ground normals function (Ctrl-F)
- Add ability to re-order ground groups (Page Up and Page Down)
- If there's only one ground node, left click anywhere adds a new node

14/1/2007
- Draw background ground groups before grid
- Add split ground group function

15/1/2007
- Save new prop parameters
- Bug fix: Ground save or restore not working properly (nothing but first group restored properly?)
- Add merge ground group function

16/1/2007
- Bug fix: merge function crash
- Improve support for merging coincident points
- Bug fix: deleting all ground nodes didn't clear node selection, caused difficulty with making a new group

17/1/2007
- Add render order to ground group info display
- Make main foundations vertical

18/1/2007
- remove 3dmaths files from other engine directories
- Integrate shell/frontend/backend structure with thin root project

19/1/2007
- Complete refactoring
    - stop IControl from inheriting from FrontEnd
    - stop mainmenu from inheriting from Control
    - make old SandBox class the new HUD class

20/1/2007
- Get file association, command passing working

21/1/2007
- Add map index page
- Fix management of console key profiles and commands

22/1/2007
- Add loading screen
- Bug fix: effects
    - SetOrthogonalView call in RenderOldText breaks it

23/1/2007
- Fix control delete function in UIEditor
- add support for dsassert
- Replace use of MyList from explosion_cache with std::list and remove list.h from utility
- add project branch tools
    - get default repository from config.bat
- Remove Display HUD text system

24/1/2007
- Add edit and play modes in world
    - in play mode
        - prevent access to ground and prop editors
        - hide edit text
        - enforce real-time build mode

28/1/2007
- Pause menu operation
    - Add public Pause/Unpause commands to World
        - Stops simulation
        - Cancel any drags, reset keystates
        - Locks all controls
        - Stop drawing of snap aid and construction previews
    - HUD tests if paused and online and pauses appropriately
    - Add public Restart commands to World

7/2/2007
- Add edit and play modes in world
    - in edit mode
        - save filename of current map
        - ask user if he wants to save before exiting (HUD dialog)
    - in play mode
        - force all modes except grid
        - make generic dialog
            - offline: resume, restart, quit
            - online: resume, quit
            - editing: resume, revert, save, save & quit, quit
- disable link snap while controlling weapon with mouse

8/2/2007
- Make preferences data file based

11/2/2007
- clear explosions and particles in ClearSimulation()

10/3/2007
- test multiplayer
    - connection, chat, basic building works

12/3/2007
- test new brace index transmission

13/3/2007
- Add multiplayer backend
- Add server select screen
- Add commands to World to allow connection to a server

19/5/07
- done on laptop during move to Brisbane
- Save screen positions in ground files, restores on map load
- Play mode loads *.spr file corresponding with ground file
- Can get into weapon control mode by left clicking and dragging a weapon

20/5/07
- Bug Fix: foundations don't appear in loaded *.spr files
    - Add brace plate index to node and save/restore it in the .spr file
    - Save up orientation in .spr file
- Added Texture clamp on props to prevent wrap on tiled props
- Added some props to canyon01
- Bug Fix: weapons can't damage any structure

4/6/07
- Bug Fix: can't create a weapon after selected/controlled weapon has been destroyed
- Weapon is fireable once selected or created

5/6/07
- Bug Fix: missile trail penetrates ground
- Bug Fix: machine gun fire can penetrate energy shield at high speed
- Pre-load effects so that there isn't a jerk on the first time (e.g. energy shield hit)
- Bug Fix: unable to build devices after deleting one

6/6/07
- Add un-moving node optimisation

7/6/07
- Fix directory separators

12/6/07
- Committed Brisbane move laptop work to repository

17/6/07
- make multiplayer game force play mode and load initial screen positions
- raise console when World exits

Sunday, 15 July 2007
- Stop game producing file logs
- remove old backgrounds from repository
- Fix installer
- Make basic autobuild process
- Add RakNetBeta3 to repository

Saturday, 28 July 2007
- Refactor multiplayer
    - Remove Server
    - Integrate RakNet
        - Make one client the host
        - Remove constant update functions
        - Move connection into Multiplayer BackEnd, pass it to FrontEnd on creation
        - Other clients connect to the host
            - On login
                - Host BackEnd needs to
                    - communicate game configuration to connecting clients
                    - transmit new client details to existing clients (ID, username)
                    - Send BackEnd message to clients, which add player to the list

Sunday, 12 August 2007
- Client database synchronisation
- Server discovery
- Allow connecting client to abort connection, and provide timeout

Wednesday, 15 August 2007
- Add chatroom
- Create client database class, pass it to Chatroom and World
- Pass host status to chatroom
- Disable start button and change map button for non-hosts
- Transmit initial map to connecting clients
- Initialise map bgbgpath ..  with first available map

Friday, 17 August 2007
- Display client database in chatroom
- Go back to chatroom after game
- Synchronise clients at end of loading

Saturday, 18 August 2007
- Switch to storing localIndex instead of localId
- Add message queue class
- Integrate command queue

Sunday, 19 August 2007
- Refactor create node message
    - Include raw build data
        - position of node
        - owner
        - currently selected node
        - building material for link
    - Refactor PlaceNode so it can work from
        - network command
        - split node creation from stressed link
- Refactor destroy node message
- Refactor make link message
- Get simulation working again
- Refactor create/destroy device message

Monday, 20 August 2007
- Refactor fire weapon message
- Make sure m_LocalID is accurate

Tuesday, 21 August 2007
- Get single player working
- Add start and end tick
    - add command queue to non-host clients to store commands to process on a specific physics frame

Friday, 24 August 2007
- synchronise physics clocks
- improve reliability of commands
    - physics block if full tick isn't received yet
- synchronise random number generators
    - move Rand code into a class
    - make a random number generator for the World and pass it to necessary users
    - make a global generator for default use
    - add Normal and Range methods to generator

Saturday, 25 August 2007
- Add set target command for missile launcher

Sunday, 26 August 2007
- Remove use of clock in meshprojectile
- Select new node or weapon on receipt of the command if locally owned
- fix beam weapon

Monday, 27 August 2007
- Refactor resource accounting
- Pay for linked nodes not created with a node

Tuesday, 28 August 2007
- Fix map change not affecting actual non-host client maps
- Balance costs
- Show build and running costs for devices and materials

Sunday, 2 September 2007
- Add software timer for physics update clock
- Remove World::m_clients, fix up client list on HUD
- add physics checksum verification

Monday, 3 September 2007
- display sync status of each non-host client
- Fixed delete device desync
- Fixed missile trail fade desync
- backup repository

Tuesday, 4 September 2007
- Rename namespace BaseMessage to Msg
- Remove World::HandleMessage and associated data

Thursday, 6 September 2007
- Build timer
- Reload timer

Friday, 7 September 2007
- Basic music support

Saturday, 8 September 2007
- Added music manager, continuous menu playback

Sunday, 9 September 2007
- Add side Id to client database
- Set edit mode to structure if not edit mode
- Indicate inability to place in enemy territory and unbuildable territory
- Allow setting of current owner in editor
- Associate links with owner and nodes with team
- Add node teamID to spr file save/restore
- Add link clientID to spr file restore

Monday, 10 September 2007
- Client teamIds hack
- Fix device resource links on client departure

Wednesday, 12 September 2007
- Move client removal to command queue

Monday, 17 September 2007
- Save and load .spr file with ground in editor

Tuesday, 18 September 2007
- Limit targeting mouse to weapon circle
- Add mouse cursor state
- Add vcredist to installer

Wednesday, 19 September 2007
- Add win condition (reactor destroyed)

Thursday, 20 September 2007
- Allow team configuration

Sunday, 23 September 2007
- Handle no players on other team
- Add point scoring
- Add distribution of client state

Tuesday, 25 September 2007
- Add weapon platform material, prevent connection with ground
- Target reticle remains after selected device destroyed by hitting the ground
- Limit build angle of device platforms
- Draw angle limits in HUD

Sunday, 29 September 2007
- Prevent devices from being build on links attached to the ground
- Put limits on what surface angles devices can be built on (per device property)
- Always draw world limits in ground edit mode
- Add key bindings for panning (move world bound set to Ctrl-arrows)
- Add IP connect console command
- Devices float when their platform is destroyed first by hitting the ground?
- Intersect projectile line segments with devices, not just points
- allow device and material types to be disabled from rules
- add more world data to checksum

Monday, 1 October 2007
- First test session with Szymon and Jason, success!

Saturday, 6 October 2007
- add a key to save/toggle between current position and a default camera position
- Intersect beams with devices
- Add data for radius of targeting circle
- fix solar panel hit effect

Sunday, 7 October 2007
- create edit box control
- add server IP address entry
- change text on connection screen to "connecting..."
- add edit control to UIEditor
- add player name entry

Tuesday, 9 October 2007
- prevent weapons from firing if they protrude through a structure
- Add repair link function
- started adding chat to chatroom

Saturday, 13 October 2007
- finish adding chat to chatroom
- disable link snap when placing nodes
- when node snap is disabled, always snap but make threshold smaller

Sunday, 14 October 2007
- compare screen positions to avoid cycling to the same position twice
- smart bracing
- Serialise username
- prepare Jason for connection to repository
- backup repository and certificates
- Bug fix: Chat text reaching limit

Thursday, 18 October 2007
- expose initial resources
- refactor display setting configuration

Saturday, 20 October 2007
- add timeout to connection screen
- serialise link and device hitpoints by fraction of initial
- show state of players in chat room
- distribute client state
- allow solar panels to connect to temp braced nodes

Sunday, 21 October 2007
- bug fix: device purchase desync

Monday, 22 October 2007
- prevent device overlap
- display cost of materials as they are previewed
- add cost to foundation types
- display cost of foundations in node preview

Monday, 5 November 2007
- test for exhaustion of mesh projectiles or trails
- add cost to repairing links
- add windfloor flag to ground blocks
- add efficiency to wind turbines

Tuesday, 6 November 2007
- refactor weapon and device so that devices can have submeshes, build times, etc
- devices with efficiency aspect rotate their arm accordingly

Wednesday, 7 November 2007
- add nodraw flag to ground blocks
- modulate aiming circle size with height from ground

Tuesday, 13 November 2007
- add field of fire to weapons

Wednesday, 14 November 2007
- turn devices to face as before
- stop making cursor target when weapon isn't fully built
- use device preview to load level specified devices instead of loading from config file again
- draw actual targeting gizmo when placing weapon preview
- set pan angle of new and existing devices based on team of owner

Thursday, 15 November 2007
- Split HandleCollisions from ApplyForces
- Bug Fix: cannon can go through ground when structure covers it

Friday, 16 November 207
- Bug Fix: text texture goes white/wrong when many weapon hit effects trigger
    - Is font texture being freed accidentally?

Saturday, 17 November 2007
- Don't draw enemy device selection cues
- Draw preview selection cue
- Extend no-fire check beyond barrel of weapon
- Add weapon rotation duration parameter
- add cursor kickback parameters
- can build on temp braced structure
- solar panels must have line of sight to sky to produce power
- solar panels are more efficient the higher they are

Sunday, 18 November 2007
- allow solar panels to build from temp braced nodes
- solar panel: modulate efficiency with angle to vertical, apply minimum
- Bug fix: key profiles initialised
- add data for production efficiency

Tuesday, 20 November 2007
- make missile fire as soon as target is set
- fix projectile type index so impact effects are correct again
- make missile target visible again
- target is drawn by missile while homing (not by weapon)

Thursday, 22 November 2007
- make missile target more visible (draw target icon)
- add explosive tip parameter to projectiles
- reclaim from materials

Sunday, 25 November 2007
- reclaim from devices
- repair devices
- show device health when zoomed in

Monday, 26 November 2007
- show device repair cost and reclaim value
- show material health, repair cost and reclaim value on mouse hover

Tuesday, 27 November 2007
- if in device mode and delete or repair operation is executed on a selected link, switch to structure mode

Wednesday, 28 November 2007
- Bug fix: resource lost when foundations in link purchase is unaffordable
- Bug fix: desync when weapons pan
    - add 'desired pan target' to weapon
    - world checks desired pan target against actual pan target for owner
        - if they differ, send a command to switch pan targets
        - on reception, set actual pan target
- show fire cost for weapons
- make materials stiffer but less tolerant to stress

Tuesday, 4 December 2007
- Add view replay option to main menu

Thursday, 6 December 2007
- Debugged replays

Saturday, 9 December 2007
- Added file bgbgpath .. s to replay
- Added max update delta to hardware time keeper for debugging

Sunday, 10 December 2007
- Shortened size required for replay map and state bgbgpath .. s
- Make a generic file select dialog from MapSelect
    - takes bgbgpath .. , extension, title
- Add version number to replay
- Add continuous checksum to replay
- Remove device/material toolbar from obvserver
- test replay in multiplayer

- Add memory leak detection

Monday, 24 December 2007
- Make sure edit mode is set when 'mine' is selected

Wednesday, 26 December 2007
- Bug fix: some projectile textures go missing during play
- bug fix: spaces missing when chatting

Thursday, 27 December 2007
- fix layout of server select screen

Friday, 28 December 2007
- Add support for multiple fonts at multiple resolutions
- Bug fix: console param
- Console vars for font and font size

Saturday, 29 December 2007
- put the address edit contents into multiplayer options
- fix layout of link info
- Make a better looking UI background
- Fix spaces in console
- Add sound effects to UI events
- Inspect state of music enable settings

Sunday, 30 December 2007

Monday, 31 December 2007
- Add anchor support to interface control
- Generalise bounds adjustment for non-text controls
- Resave all pages and convert restore functions
- Remove interface turtle
- Make control variables private
- Remove Text::text_x
- Add anchor drop down and remove centered check

Tuesday, 1 January 2008
- Add font selection support to UI text/editor

Wednesday, 2 January 2008
- Fix Text constructor for x coordinate
- Save/restore font
- Specify font as a fontIndex to RenderText
- Add outline & shadow styles

Thursday, 3 January 2008
- Serialise text style
- Set bounds of text using actual height of font, not text size

Friday, 4 January 2008
- Add shadow and outline colour, opacity and shadow offset
- Simplify repository structure
- allow address edit to resolve domain names
- set default ground outline colour to invisible

Saturday, 5 January 2008
- Integrate LuaPlus
- Remove server folder
- Fix RakNet and memwatch intermediate directories
- Refactor World.cpp
    - Create WorldController class
        - activation
        - event handling
        - update
        - draw
    - Create CommandInterpreter class
        - receive command
    - Create WorldComponent class
        - update
        - draw
        - serialise/deserialise
    - Create stubs classes
        - Create TerrainManager, StructureManager, DeviceManager, PropManager, ClientManager, ProjectileManager, CollisionManager
        - Create TerrainController, StructureController, DeviceController, PropController, ReplayController
    - Create WorldEvent base class
    - Add manager and controller update and draw dispatch to World
    - Add WorldEvent dispatch to active controllers
    - Add command dispatch to command interpreter
    - Move data into managers, taking management functions from World
    - Move controlling code into controllers
    - Move command handling into command interpreter

Sunday, 24 February 2008
- Fix missile crash bug
- Fix replays
- Fix screen bookmarks

Saturday, 1 March 2008
- Widescreen support

Sunday, 2 March 2008
- Fixes to widescreen support

Monday, 3 March 2008
- Add a mode to render non-visible blocks always in TerrainManager, for TerrainEditor to use
- Snap configuration should be set external to CursorManager - it shouldn't inspect World edit mode
    - Add a snap config parameter to SnapPos to allow configurable snapping
    - Add a snap config member to CursorManager

Tuesday, 4 March 2008
- Allow selection of overlapping terrain with mouse
- Right clicking on terrain, structure, devices in editor switches to appropriate mode

Tuesday, 11 March 2008
- Merge worldrefactor into trunk

Saturday, 15 March 2008
- Added placeholder civilian buildings
- Add allow overlap flag for devices
- Add no delete flag for devices
- Draw selection rectangle for devices
- In weapon mouse control, disable snap
- In device editor, disable surface or link snap if current device is inappropriate

Sunday, 16 March 2008
- Stop grid snap snapping under ground in device edit
- Prevent snap to inappropriate (too vertical) links in device mode
- Draw selected link in device mode
- Fix device creation when mouse is under snapped link

Monday, 24 March 2008
- Add score weight to devices
- Wiki: setting up a working copy

Wednesday, 26 March 2008
- Add global device scale
- Fix default red ground group colour

Friday, 28 March 2008
- Basic Store library
    - key stack: push by index or string, pop
    - get value count in section, get value by index
    - set value by index or string
    - values can be boolean, integer, string
- Converted Background to use Store

Saturday, 29 March 2008
- Move device, weapon, device list, weapon list to Lua
- Move effects to Lua Store

Tuesday, 1 April 2008
- Add some more constants
- Fix max zoom calculation
- Remove some values from terrain file
- Create scale_6 test map

Wednesday, 2 April 2008
- Add scroll and zoom rates to constants
- Add ModManager
- Move maps into subdirectories
    - Update loading, listing, creation
    - Add lua files to maps, add mods table

Thursday, 3 April 2008
- Mod support
    - ModManager, loads chosen mod after original

Saturday, 5 April 2008
- Master server query

Wednesday, 9 April 2008
- Physics overhaul

Friday, 11 April 2008
- Physics overhaul

Saturday, 12 April 2008
- Fix transformation of node solution cue
- Fix colour of link highlights and limit circles
- Link snap doesn't work well when temp bracing on
- Delete orphan nodes on a deleted link

Sunday, 13 April 2008
- Fix physics step advance
- expose beam parameters
- prevent weapon fire during pause menu
- expose trail and target icon parameters
- fix weapon, device and trail copy
- expose aiming gizmo parameters

Monday, 14 April 2008
- Show Nick the game and set him up
- Fixes

Tuesday, 15 April 2008
- Download Visual Assist demo
- make inter-frame forces persist for all oversamples
- make beam force part of weapon
- make tractor beam weapon

Saturday, 19 April 2008
- Expose new autozoom parameters, tighten up panning, smooth zooming
- Lock out adjustments to camera and zoom targets while executing a ZoomTo
- Fix normal scaling
- no-collide material flags
- identify devices in files by name instead of index
- chainable material flag with max segment length

Sunday, 20 April 2008
- Fix chainable materials creation
- Chain link between existing nodes
- Fix missing construction cues in multiplayer
- Fix wrong resources in multiplayer
- bracing plates specified by material (mass/material pairs), with priority system to allow over-ride
    - construction preview configuration
        - inspect material for foundation material (check for over-riding priority)
        - angle selection for foundations
        - can over-ride node up with a fixed value
    - link addition
        - see if new material priority over-rides previous
        - lookup node material from mass/material table
- save surface up in spr file
- Remove mass from spr file and turn it into a dynamic calculation
- filter projectile and beam immune links from barrel collision check    

Tuesday, 22 April 2008
- make explicit recoil and impact properties of weapon/projectile

Wednesday, 23 April 2008
- expose missile parameters

Sunday, 27 April 2008
- add sprite support
    - Sprite record consists of
        - name
        - texture
        - coordinates and size
        - colour
    - refactor animated texture list
        - move to SpriteManager (make new project)
            - LoadSpriteSet/FreeSpriteSet
            - Sprite::Load(name)
                - could be a simple texture or a reference to a sprite to simplify config (look for extension)
                    - energy_shield
                    - mytexture.tga
                - if it's a sprite, look it up in the sprite database
            - Sprite::SetTexture() // set the right texture and colour
            - Sprite::SetTopLeft(), SetTopRight(), SetBottomLeft(), SetBottomRight() // set texture coordinates
            - Sprite::Update(dt) // keep animation state within Sprite object, update animation here
            - Sprite can load and provide a single texture

Friday, 2 May 2008
- Remake checkout system using C# and Lua and Inno Setup
- Add link to the dev web site and start fort wars to installer
- Add link to update dev environment to installer
    - Save Lua script stuff in system subfolder
- Turn new checkout system into an installer available by unsecured web server

Monday, 5 May 2008
- add background bracing
- Fix particle emitters

Tuesday, 6 May 2008
- allow projectile & beam filter to apply to friendly and enemy
- index effects by projectile and material name

Thursday, 8 May 2008
- fix device effects
- Allow animated textures to interpolate colours and coordinates over frames
- key material sprite by damage

Saturday, 10 May 2008
- make props use sprites
- allow end caps to key sprite by damage

Sunday, 11 May 2008
- Integrate DevIL
- allow sprite to be set to specific frames, and reference frames by name
    - on = { "blah" }, off = { "blah2" }

Monday, 26 May 2008
- fix crash when making cable unlinked to any node
- Move icon to Text

Friday, 30 May 2008
- HUD
    - Add cost of items to menu
    - Add buttons to cycle through item list
    - Add chained dynamic tabs
    - Highlight current tab

Sunday, 1 June 2008
- Add TabbedControl
    - consists of a header and panel (specified in externally)
    - allows addition and removal of tabs
    - sets visibility of panels, highlights tab header
    - has callbacks for
        - selection of a tab
    - get/set current tab
- Generalise HUD items framework, move tab initialisation/item handling to controllers
- Add basic ground and prop browser

Monday, 2 June 2008
- remove underscores from interface filenames
- make graphs and tags hidden by default in multiplayer
- remove parent from control constructors

Sunday, 8 June 2008
- Ground edging system

Monday, 9 June 2008
- Ground edging system, open surfaces detection
- add non-selectable node flag for rope nodes and make cables selected as one continuous unit

Tuesday, 10 June 2008
- cable end-points bracing plates
- when mouse hovers over a link or device, display a button that opens the context menu until mouse moves away

Tuesday, 24 June 2008
- add new server page
    - server name
    - max players
    - public or private

Saturday, 28 June 2008
- Setup replay from command line
- Remove filtered edge code
- Add link delete world event (WorldEvents.h), receive in StructureEditor to reset
    
- Fix open edge calculation
    - when t = 1, angles need to be calculated relative to the final start
    - reject joints parallel to surface unless t = 0 or 1 and it's overhanging an end

Sunday, 29 June 2008
- save/update chatroom while in map select
- Bugfix: team allocation on new player
- Bugfix: fix position update so devices track graphical structure

Monday, 30 June 2008
- Bugfix: missile target
- Allow weapon to point in only one direction

Tuesday, 1 July 2008
- Add splash damage to missile

Wednesday, 2 July 2008
- Splash damage to mortar (and tweak missile)
- Splash damage occurs on impact with devices and ground
- Splash damage applied to devices and weapons
- Shoot down missiles and mortars

Thursday, 3 July 2008
- Add force to nodes in splash damage radius

Saturday, 5 July 2008
- convert spr file format to include selectable flag to fix cable restore
- Bugfix: nodes are falling through the ground frequently (Z divergence)

Sunday, 13 July 2008
- assign an equal proportion of the starting capacity and resources to the players
- reactors do not have any capacity associated with them
- mark reactors as owned by the team, not a specific player
    - selectable, but can't be deleted
- reactors may have an energy output that is shared equally among team members
- materials and devices are owned by specific players, and draw from their account
- show resource rates for individual and team in HUD
- allow starting resources to be specified per map

Monday, 14 July 2008
- Fix projectile direction and crash bug when using missile in Scale_6
- Fix projectile timeout and explosion bugs

Tuesday, 15 July 2008
- 2D devices and weapons
    - make new class representing tree structure of sprites, pivots and markers
    - initially use Lua file for configuration

Thursday, 17 July 2008
- CompositeSprite work

Sunday, 20 July 2008
- Add userdata and visibility of sprites
- Add some mechanism for iterating over nodes
- implement build progress visibility

Sunday, 27 July 2008
- replace missile and mortar with sprites
    - length determined by sprite dimensions
- Destroy projectiles at low impact speeds

Monday, 28 July 2008
- team-mate preview system
    - keep a marker in each ClientData showing where player is working and flag for validity
    - when selection or deselection occurs, send a command through server to all team-mates
    - display team mate's selection position

Tuesday, 29 July 2008    
- Track and refresh selected links in device editor
- scale tags nicely
- Render team tags in friendly & enemy colours
- Don't render own client tag

Wednesday, 30 July 2008
- add scaffolding sprite to devices during construction
- Positional update of selection for placing mines and aiming
- limit client select update rate

Friday, 1 August 2008
- device locking system (only one person can use a device at any time)

Sunday, 3 August 2008
- Setup Taam's old machine
- Add states to Sprite animations
    - repeat and chain
- Add on fire sprite animation support to weapons

Monday, 4 August 2008
- Allow multiple muzzle flash nodes
- Constrain mg and sniper
- Bug fix: mortar is blocked by background bracing and cable (what else?)
- Bug fix: weapons flip upside-down when changing sides
- Design device bracket/icon/status system. info to show:

Sunday, 10 August 2008
- Bug fix: can't aim weapons left until they've been aimed right

Monday, 11 August 2008
- Bug fix: clear selected link when reverting map

Tuesday, 19 August 2008
- add Munition component that is only shown when weapon is ready to fire
- allow weapons to built on any team owned ground
- allow weapons to draw in front of ground
- Increase maximum slope of missile launcher and mine
- Bug fix: missile doesn't explode on impact
- Bug fix: editor constrained by world boundaries in ground editor

Sunday, 24 August 2008
- Bug fix: can build ground devices on ceilings
- Bug fix: weapons fire can miss ground devices (test all objects and select closest)
- Bug fix: orphan nodes not deleted when sister is
- Bug fix: sprite muzzle flash shows even if weapon isn't fired (e.g. in ground)
- Improve vertical position of item icons and detail
- Bug fix: flickering ground device preview
- Bug fix: upsidedown angles wrong, ground surface angle calculation
- Bug fix: device/device collision not detected in all cases (e.g. mine on left, missile on right)

Tuesday, 26 August 2008
- Bug fix: Cable in ray_test not easily selected
    - Cable created in sandbox - teamID == Any

Wednesday, 27 August 2008
- Bug fix: Set angle and added mass to nodes when restoring devices
- Bug fix: Ensure mass of nodes is identical (with and without devices) after restore
- Bug fix: Make sure stand-in node is deleted

Sunday, 31 August 2008
- Bug fix: building onto the ground bug
- Bug fix: weapon selection problem in laggy environment

Monday, 1 September 2008
- Don't break nodes when link or node is stand-in

Tuesday, 2 September 2008
- prevent firing the weapon from selecting the structure
- Prevent preview from selected stand-in node
- Allow node placement behind devices

Wednesday, 3 September 2008
- Fix serialisation bug
- Fix turbine bounding box
- Remove unused barrel components from some weapons

Thursday, 4 September 2008
- Fix composite sprite anchor calculation when mirrored
- make device preview translucent
- hot reload
    - save map to temp files
    - save view
    
Saturday, 6 September 2008
- hot reload
    - save world state (editor, mouse, selection, etc)

Sunday, 7 September 2008    
- Bug fix: can't select devices when editor initially starts
- Device bracket/icon/status system. info to show:
    - faint bracket on available devices when not selected
    - grey bracket on selected
    - name tag when selected by someone else

Monday, 8 September 2008
- Bug fix: it's possible to create overlapping structure-devices
- Expose bracket parameters
- Unify min up angle for structure devices, rename

Tuesday, 9 September 2008
- Fire cost taken into account when showing weapon ready status
- Add flag to disable sound effects
- Map with column down the middle

Wednesday, 10 September 2008
- Insert sounds for cannon, sniper and machinegun
- Add weapon burst parameters, add burst to mg
- Don't allow weapons to aim when paused
- Bug fix: ground surface angle for verticals

Sunday, 14 September 2008
- Add trail to sniper tower
- Fix trail position on collision
- Fix shield reflection for sniper

Tuesday, 16 September 2008
- randomisation of sprite animation
- Reload sprite database with hot reload
- represent colour as 0-255

Sunday, 21 September 2008
- effect scripting
    - each explosion needs its own state
    - don't want to re-read or clone a script
    - means that explosion objects must exist within the script state?
    - keep one state in the prototype, refer to it in the actual explosions
- Material destruction effects

Monday, 22 September 2008
- Projectiles fade out after collision at high bite angle
- Add support for build-anywhere devices (houses)

Wednesday, 24 September 2008
- Allow surface snap to be disabled in device editor (edit mode only)
- Add flag to align device to cursor normal

Thursday, 25 September 2008
- Reordering of devices

Friday, 04 October 2008
- material render order
- make default font data driven

Sunday, 12 October 2008
- add function to get sprite ID to save string lookup, get it on script load

Tuesday, 21 October 2008
- foreground materials

Sunday, 19 October 2008
- Particle scripting
    - Support for passing 3D vectors
    - give effect position and velocity to script update func

Tuesday, 21 Octover 2008
- Global render order system
    - background
    - background props (new)
    - background terrain
    - midground props (new)
    - background devices
    - terrain
    - background materials
    - fort devices
    - foreground materials (new)
    - foreground props
    - edging
    - foreground devices

Thursday, 23, October 2008
- Show out of power and absolute production on solar panel

Friday, 24 October 2008
- Show power generation for solar panel
- Show power generation for wind turbine

Sunday, 26 October 2008
- Cladding

Tuesday, 28 October 2008
- when placing a foundation node, try to link with nearest foundations on either side find closest

Thursday, 30 October 2008
- fix orientation of some foundation cladding
- make sure foundation cladding is deleted when nodes are deleted

Sunday, 2 November 2008
- Items panel auto slide, remove old left/right arrows
- Selection bracket -> arrow under devices
- bug fix: Chose closest device collision
- bug fix: Sprites not loading in UIEditor (rebuild)
- Shell ejection vector not mirrored
- prevent mouse tracking when simulator disabled
- Prevent players from destroying specific nodes and links (that hold up the reactor) - new undeletable material type
    - Add undeletable and unbuildable material flag

Monday, 3 November 2008    
- Allow item icons to be hidden on the fly -> update layout
    - disable unbuildable materials on editor activation
    
Tuesday, 4 November 2008    
- Delete any nodes that fall through the cracks
- Allow effects, weapons and device files to contain sprite definitions
- Allow materials files to contain sprite definitions

Thursday, 6 November 2008
- Test for cladding attach flag when cladding foundations

Sunday, 9 November 2008
- Add options and tutorial menu
- Add basic scripting infastructure for tutorials
    - mission script execution

Saturday, 15 November 2008
- script commands
    - resolve battle with map rotation
    - propagate event
    - text control addition, deletion
    - clear map
    - load an spr

Sunday, 16 November 2008
- Allow spr files to be loaded on top of each other
- script commands
    - stream a specific mp3, callback on completion
    - foundation created callback
    - link created callback

Saturday, 29 November 2008
- stop the standin link from switching texture directions
- Add a 'no selection' state for structure editor
- don't zoom out on new selection of a weapon
- add a control to the HUD relative to a world position

Sunday, 30 November 2008
- save a screen rectangle in the editor with a name
    - key press saves current position
    - pops up a modal edit box
    - saves name with view manager
    - console command to delete
    - can be restored by name via script
    - Esc escapes modal dialog

Sunday, 7 December 2008
- Fix device selection when no material is selected
- Get number of links of a side
- Take control of mouse
- Move mouse from point to point over a period of time
    - mouse cursor is in screen space coordinates, but script will often want to set mouse position in world coordinates
    - need to translate coordinates from world space to screen space
- Issue clicks from the mouse

Sunday, 4 January 2009
- Right mouse button script command
- Add click/deselect attributes to fort building code
- Add ability to hide and re-arrange tabs on HUD
- Add disable cursor function
- Prevent context menu clicks from being interpreted by the HUD below

Sunday, 25 January 2009
- add audio manager to
    - open and close channels
    - close audio at the end of a level
    - pause all channels
- Pause everything on pause and restore mouse position if necessary
    - mouse interpolation
    - audio channels

Sunday, 22 February 2009
- add flag to prevent construction unless prerequisite devices are built for a team
- add flag for materials
- stop ui music in options screen

Sunday, 8 March 2009
- moving mouse between interpolations has an effect
- clicking between "now you try, play around" and "that's good..." overlaps dialog
- it's possible to click during the mouse demo

Tuesday, 10 March 2009
- Add a static control relative to a child control

Wednesday, 11 March 2009
- add next tutorial button

Thursday, 12 March 2009
- add functions to add and remove buttons to pause menu

Tuesday, 17 March 2009
- minimum build height

Sunday, 22 March 2009
- add per team population cap to limit device/weapon construction
- add prop names
    - use it to work out if command tower has eye-sight to enemy base

Saturday, 4 April 2009
- serialise prop visibility and name
- add script function for prop visiblitity

Friday, 10 April 2009
- center the mouse cursor on map open
- put all maps into one directory, with scripts to specify groups
- keyboard navigation
    - need indexed control system
    - activate a key monitor to interpret arrow key strokes
        - moves/applies highlight
        - calls attached event

Sunday, 12 April 2009
- add tabstop field to ui editor
- keyboard navigation for other screens
- Add Menu button to HUD

Thursday, 16 April 2009
- Add progress bar control

Thursday, 23 April 2009
- Add health bars to devices

Sunday, 26 April 2009
- Construction progress bar
- animated particle effects must have their own copy of the animation

Sunday, 31 May 2009
- Install VS2005 SP1 on test machine

Saturday, 9 April 2011
- Boot up FortWars, run Release and Debug builds, check Tutorial (not working completely)
- Fixed paths in tutorial to get audio playback and the rest of the tutorial working

Friday, 15 April 2011
- Fix memory leaks
- Try to fix invalid memwatch wild free

Sunday, 17 April 2011
- added volume level for menu music

Monday, 18 April 2011
- add volume level for game music and sound fx
- Implemented Save method in Store class & Push can create a table if necessary
- make options persistent
- move mouse cursor away from corner at start

Sunday, 24 April 2011
- Ran debugger Very Sleepy
- Removed initialisation of values in Vector3D constructor
- Added debugging to locate instances where the assumed values are used

Wednesday, 27 April 2011
- Fix replay resource tracking for local games including team owned devices
- Test multiplayer replays
- improve load speed
- Fix cursor tracking in replays
- Fix further replay desync (when firing mg)
    - weapon was being aimed while projectiles were being emitted
- add a series of checksums for different aspects of the game state
    - check each one and report which is out of sync

Tuesday, 3 May 2011
- UIEditor: Add arrow keys to nudge controls by a pixel

Wednesday, 4 May 2011
- UIEditor: Add Ctrl to lock movement to one axis
- UIEditor: Accept x/y value when multiple controls are selected to set value for all
- Stop effects triggering at origin when world starts in editor

Wednesday, 11 May 2011
- Bugfix: two devices can be made on the same strut when clicking rapidly
- trigger an effect at an optional location/direction

Sunday, 19 June 2011
- bugfix: prevent mouseover effect & clicks when mouse cursor is invisible

Thursday, 1 Sept 2011
- Check in modified files
- Tested access to server over net using anonymous browsing
    - Ninjaproxy gave forbidden result
    - showed up in Wireshark recording on Server
    - Sent .p12 file to Nick
- Get the server set up and submit everything
    - connect using direct connection
    - need to bridge the connection to the net so Nick can check in
    - get the digitalsalvo.no-ip address back

Saturday, 3 Sept 2011
- disable space bar during tutorial

30/01/2013
- Resurrected project. Fixed a few random issues to get back into the groove:
- HUD selection highlight
- Clipping text controls to the screen
- Setup exe update and multiplayer with server
- Fixed crash bug when playing multiplayer with one client
- Fixed update of remote client selection and sync issue when firing machine gun
- Get replays working (out of sync early)
- Fixed: Multiplayer immediately out of sync (issue introduced with changes made to fix replay checksum)
- Fixed: Prevent picking of disabled devices and materials (e.g. houses in multiplayer)
- Fix music settings (menu & game)
- Fix music setting restoration

9/2/13
- Ground Editor: Don't create a new ground node when Alt, Ctrl or Shift are held (selection modes)
- Ground Editor: Don't move nodes when modifier held
    - Had to change the update order of PlayerController and TerrainEditor

10/2/13
- Add an ore prop
- level editor: Undo function (save a stack of world states & selection)

11/2/13
- Added save selection function to UndoStack (working for TerrainEditor only so far)

12/2/13
- UndoStack: save active controller with each level
- Switch player resource account between teams so that weapons can fire in editor
- Review account system
    - current
        - devices and materials are associated with a joint resource account
        - income & draw is split between account holders
        - building resources is drawn from building client's account
    - Pure team accounts only? rather than splitting resources between players - so they work together and can afford larger weapons
        - easier to administer
        - clients can easily come and go; team resources remain
    - benefit of splitting
        - a single player can't use all of the resources of the team.
        - players are likely to bottleneck at the beginning of a game with excess building
            - mitigated by communication or large starting resources
        - different gameplay; individual clients can be targeted to disadvantage them. not much of a team then.
    - drawbacks
        - harder for the team to save up for expensive items
        - complicates master control by one client (Any) during sandbox mode and level editin
        - who gets resources for salvaged material?
    - Should be:
        - a single account for each team
        - income & draw goes to and from that account
        - transactions are rejected based on that one account
    - need to
        - ClientData must be redirected to read from the team account
        - or make any reference to ClientData as an account look up the team account
        - HUD reads from team account
        - team account affects checksum
        - put digital filters in joint account

16/2/13
- Fix undo edit mode switch and selection issues
- Deselect device and node when switching team
- Save team to undostack
- Fix context menu showing up in old location when shown
- display current team in editor
- Display node context menu when selected node clicked on

17/2/13
- Fixed: Textbutton is retaining rollover highlight
- Stop drawing red line when strut is too long
- Use different coloured node graphics to indicate different teams
- Have an option to drag the screen like a hand

18/2/13
- Prevented replay from modifying the client database with superficial flag to SetLocalTeamId
- Double click middle mouse button zooms in
- Reduce minimum zoom level
- Create a series of predictable or scripted physics stress tests
- Insert ground node on edge when no nodes selected
- Explode device when stressed link breaks
- Add a nudge key for moving ground nodes
- Fix crash bug when trailed projectile is deleted
- Add sliding door material
    - opens from middle, slowly separates
    - add context menu to open/close
    - update collision detection to account for partial open states
    - 2 layers of graphics (rails and doors)
    - more expensive to build and repair and not quite as strong as armor

25/2/13
- move sound effect path into effect script, not hard coded to effects/media
- Add door end graphics and configurable limit to door retraction and door width
- Add effects for door opening, moving (looped) and closing
- Improve door placeholders and add door end sprite

27/2/13
- Fix tutorial audio paths, enabled materials and display of marker
- 'Any' team in Sandbox creates devices and nodes with team the same as existing structure
    - Remove 'Any' team as an actual team, but keep it as an flag for ground groups
    - Have a 'promiscuos mode' in the Client manager
    - When the user clicks on an object in this mode he switches identity to that team
    - subsequent creation happens for that team until another team's object is selected

28/2/13
- Increase mg spray
- longer build times for some weapons
- Increased sniper damage so it can take out other small weapons
- Reduced battery and metal store placement sensitivity
- Build limit of bracing material is longer when connecting two previously built nodes
- Cannon: less projectile damage, slightly longer reload, fewer hit points (can be destroyed by one hit from a cannon)
- Reactor: fewer hit points
- Mortar: increase reload time

1/3/13
- Devices, weapons and materials can be disabled by default
- Installed new front end background and dnk font

2/3/13
- Fixed link counting so tutorial can get to the 'build to marker' challenge
- New links to the ground get the extra link extension
- Disabled houses

4/3/13
- Fixed some issues with keyboard input/area selection during tutorial (mostly)
- Double-click toggles door state
- Clear structural item selection when selecting device from StructureEditor
- Added DDS for frontend background
- Added SpriteFrame offset to allow use on progress bars
- Added 'under construction' progress bar to devices and weapons
- Fixed double-click door activation not sending network command
- Only set the local teamID from remote selection when in replay mode

5/3/13
- Remote selection updated on a per-frame basis in one location (world.cpp)
- Multiple checksums to make it easier to debug a desync
- Mods are applied to replays
- Disabled cables in ReactorsAreCritical
- Added functions to check for invalid force in physics code
- Fixed splash damage force calculation when length to link is zero
- Prevent selection in replays
- Make devices unselectable in the HUD when unaffordable
- Reduced force applied to structure from cannon impact and recoil and projectile mass
- Increased metal cost to fire the cannon
- Disabled some persistent compiler warnings

6/3/13
- Only provide extra storage capacity when device fully built
- Make wind turbine template spin during placement
- Non-explosive projectiles can continue on through devices
- Increase minimum aiming circle for the cannon
- Decreased aiming circle for mortar and default mortar speed
- Copy debug exe to Server for testing

7/3/13
- added rapidfire mod for quick testing of weapons fire
- move client sync list on HUD, and display the host, cause of any desync or client state if not playing
- fix device repair
- tune laser and sniper aiming circles
- reduce aiming circles to angles that can be aimed through, and only the current direction
- extend aiming circle radial lines back to weapon to help placement

10/3/13
- Fix weapon aiming based on remote selection in replays
- Attached device not being deleted properly, at line 2068. maybe due to deletion at line 2047 on PhysicsManager.cpp
- Fix link reclaim crash
- Fix missile launcher firing and reduce erratic angle
- Missile launcher and mortar keep persistent marker for their last target
- Made laser into a rapid burst

11/3/13
- Added lua files to VS project
- fix power draw from shields
- factor in angle efficiency when placing solar panels
- decrease solar panel production, increase wind turbine production
- modulate solar panel colour according to efficiency
- add weapon base angle to fire angle (weapons on a slope don't fire in the right direction)
- Fixed undo/redo in level editor when projectiles are active
- Added 'Surrounded' map
- Use skirmish.lua map set for multiplayer maps

- Gameplay testing feedback:
    Brian Hay: i was having a lot of trouble selecting / deselecting
    Brian Hay: and sometimes not able to scrap
    Brian Hay: or build door (even tho in build circle
    Brian Hay: r there rules around what u can connect a door to?
    my fort was really unstable / bouncing around from the start
    replayforts stable
    Brian Hay: but somehow a rope / brace just got slung from fort to fort

12/3/13
- Simplified console texture & colours
- Disable Control input when console enabled
- Clear tabstop when mouse moves
- Capture tabstop when entering text in a textbox
- Updated to Surrounded map
- Added Abyss map
- give sniper bonus damage against weapons

13/3/13
- Moved mouse textures to ui/textures
- Fixed mortar and missile ghost target texture
- Removed some effect dds files to simplify development
- Made missile tailflame larger and offset to end of missile
- Changed missile impact sound
- Fix bug: controls freeze in Nick's level, right hand side mostly
- increase weapon barrel test ray length and show cross when trying to fire it into a strut

14/3/13
- Zoom in on next weapon
- Re-enable and test double click on doors
- key link sprites to damage level
- update damage sprite on repair
- relax constraint of not being able to build solar panels directly on the ground
- Stopped HUD sprites cycling damage

18/3/13
- stop weapons switching direction while firing
- add device snap to cursor snap system, highlight weapon under cursor and use for hard selection
- prevent placing of devices over bracing
- AllowOverlap allows devices to overlap solid structures as well as devices (now used for the reactor)
- Moved bounding box of devices to allow placement

19/3/13
- prevent placing of bracing over devices
- blocked effect for various placement errors
- SimpleDialog takes a texture name instead of having it hard coded
- SimpleDialog uses the size of the texture to size and center itself (need to update to handle dynamically sized content)
- Added x and y offset to SimpleDialog, arranged new pause menu

21/3/13
-Show highlighted state when rolling over devices

24/3/13
-Debug cursor lines are only shown in the level editor
-Added circle to display highlight of nodes
-Stopped foundations being drawn unnecessarily when highlighting an existing foundation
-Stopped redundant selection test of node (CursorManager is the master of highlighting & selection)

25/3/13
-Node sprites are rendered with their offset
-Fixed foundation offset so the circular part of the sprite is centered
- reduce mortar splash damage radius
- tuned mortar trail
- stop reactor being built when not in editor mode
- Prevent picking of device types that are unaffordable
- Fix: resources high in every map

26/3/13
- allow disabled materials and devices to be built in editor mode
- experiment with cable weight; needed to increase oversample rate to get a stable sim at low weight
- Added frame rate display
- Allow selection when context menu is up
- when node context menu is up, prevent linking when selecting a new node

27/3/13
- make aiming circle red when you can't afford the shot
- prevent picking of materials you can't build, with feedback
- fix node or link creation bug (spurious chain bug)
    - change StructureEditor selectednode from an index to an Id
    - make replacing the standin node more secure by adding an identifier to the node create message and remove the proximity test
- correct hack: scraping device in editor caused crash
- Lock weapons immediately after firing until a burst is finished

28/3/13
- Add material to remote selection and draw material construction preview
- Added console desync command to desync specific systems (Structures, Devices, Clients, Resources, etc.)
- Fix desync testing, go out of sync when too far behind, but increase cache of checksums to 1 minute worth
- Add snap state as a parameter to DrawConstructionPreview and fix ClientManager client cursors to show correct snapping
- Added bullettime effect, applied to cannon and sniper
- Added mirror ground horizontal and vertical (H and V)
- prevent building new nodes from temp braced nodes
- speed up temp bracing timeout after linking

29/3/13
- enforce length limit on receiving new node and link commands (to account for lag)
- check if linked node exists before creating a new link
- clear standin node, selection and context menu if node creation fails
- automatic background bracing
- context menu conversion to background, foreground, door and armor
- updated context menu button, fixed Button state changes

30/3/13
- Holding Alt while selecting an already linked node will change the material type
    - fails if there is an attached device
- Allow construction of links from temporary braced nodes to the ground
- Can't build foundations in isolation or from temporarily braced nodes unless in editor
- Can't build ground only devices far from foundations
- stop teams building over each other (can't build within a radius of enemy nodes)
- Allow construction from temp braced nodes when in editor
- Fix: bounding box used for recession of materials seems to be out of sync with actual for ground devices

31/3/13
- add support for different background cladding texture
- scale ground group texture coordinates so they are consistent with the world pixel size (ignores saved scale atm)
- changed ground2.tga texture to a low resolution, low contrast texture for use for invisible utility textures
- converted ground1.tga to a compressed DDS texture to improve loading/rendering speed
- ignore duplicate textures in the ground texture tab (load only tga versions)
- draw device preview bounding boxes in level editor
- fog of war: only render foreground cladding over enemy buildings
    - turn off weapon tags for the enemy
    - replays: default to being able to see inside both forts
- use mark for deletion scheme in PhysicsManager::HandleCollisions instead of instant delete (safer)
- delete foundations when their attached strut is destoyed

1/4/13
- added Middle Ground map
- copy, paste, move and mirror structures (Ctrl-C, Ctrl-V, M, H)
- switch ownership of structure when pasting
- add delete structure function (Backspace)
- reduce the amount of stress temporary bracing can handle

2/4/13
- Temporary bracing is now made relative to the first link of the source node, or straight down for foundations
    -> there's no stability given to the structure
- Increased stiffness of bracing and reduced break tolerance
- Added additional asserts and forced z values to prevent non-zero values creeping in (found some in the central ground group in Middle Ground, don't know how)
- fix: can't link temp braced nodes in editor

7/4/13
- break links when they rotate a certain angle away from their original construction position
- destroy isolated links that exceed a compression or expansion threshold (not just unlink)

8/4/13
- fix: mortar power control is not working
- Added DesyncDetectedMessage, sent from host to clients to indicate that a client has gone out of sync (tested with one client)
- fix: desync detection
- Desync: Standin RelinkNodes
- Fix: enemy structure construction preview is in local team's colour

9/4/13
- Test: sandbox replay sync

10/4/13
- Fix: enemy constructure preview doesn't snap to nodes (or ground?)
- Fix: remote client selection snapping and team graphics
- Fix: targeting reticle is not drawn while watching enemy constructure preview
- Test: replay sync (multiplayer)
- Backup

11/4/13
- Allow neutral ground devices to be claimed
- Fix ground group merge (make it the reverse of split)
- Added ReactorsClaimForts rule: structures not connected to a reactor become neutral

12/4/13
- lose control of ground devices if foundations no longer present
- detect if selection is no longer of the local team and boot if not
- delay on building
    - can't build devices on platforms while under construction
    - can't extend structure where all struts are under construction
    - no projectile impact on struts under construction
- Add a key to close the door opened by the current weapon
- make a list of doors that the door has opened and close them all
    - ignore duplicates and remove invalid links
- weapons can't fire through materials under construction
- weapons can't open doors that are under construction
- don't add inappropriate items to the context menu when link is under construction
- Integrate new HUD textures

13/4/13
- RelinkNodes: carry construction progress over from parent, fully built for stressed links
- Move HUD graphics to the top of the textures to stop mouse blocking on invisible HUD
- Make TabbedPanel deal with Buttons instead of TextButtons
- TabbedPanel centres arrangement of buttons
- Hide HUD layout controls
- Simplified re-arrangement of HUD components to aspect and gave more room in editor
- Added blank buttons as placeholders for editor only tabs
- add an experimental float var to the console for tuning values
- Fix: crash when trying to boot player off selection in replay

14/4/13
- Add a clip stack to Display to fix nested clipped controls
- make tab buttons sticky (stay pressed until another one is pressed)
- allow buttons on HUD to scroll items (but keep soft scrolling functionality)
- delay on scrap

15/4/13
- delay on repairing
    - add repair rate variable
    - show repair progress
    - check health levels
    - tune repair rate
- Fix: crash when trying to boot player off a device
- Gameplay testing 15/4/13
    - resources desync
    - structures desync
    - time desync (why did it happen? make it possible to recover from time desyncs)

17/4/13
- Add a lag desync type which can be recovered from (unable to test for other desyncs when lagged)
- calculate tick lag from host to clients. show tick lag on host
- Resurrected timesync application for testing synchronisation of remote clocks

19/4/13
- Pause and disable state changes when desync detected on all clients

20/4/13
- Display the last X number of interesting messages received and their frame numbers
- Add mouse state to the client select message
- Draw the path of each cursor with button clicks/state over the last X messages
- add keys to adjust the length of replay debugging to show to reduce clutter/show chronology
- build debug replay buffer during replay playback

21/4/13
- Add team display to create messages in desync debugging
- add a constant for enabling time sync
- add key to enter debug mode (not in multiplayer)

22/4/13
- fix: reactors claim forts rule isn't running in replays
- allow zoom to be taken into account in Display::RenderText for crisper font rendering
- Fix: debug mode frame numbers may not be accurate yet (found when replay went out of sync while shooting mg)
- Fix: client debugging not built/drawn when replay goes out of sync
- projectiles are bouncing off background bracing at low angles when they should go through
    - this happens when firing neutral weapons in sandbox mode. PhysicsManager::CollideWithLinkPossible uses Team None to indicate test with projectile or beam
    - Replaced use of None with team Any to allow None weapons to be fired properly in sandbox
- Breakage of bracing causes replay Structures desync
    - isolated foundations were not being removed in replays
- Fix: replay debug frame numbers are off within ticks
- Don't regress device's platform

23/4/13
- Allow instant building in editor
- Make link debugging optional in editor
- Fix angle of device preview bounding box for recession/collision testing
- Don't regress neighbouring struts at low angle when placing devices
- Move all device bounding boxes to close the gap with the platform
- add 'remove armor' context menu button
- increase build time for replacement links to reflect destruction time of old link
- ignore replacement of identical materials
- Fix: Can't see snap cursor in editor
- fix up edges when mirroring ground and flipping normals
- increase selection radius of weapons with increased zoom
- Fix: can't delete build-anywhere devices
- make ground device range to foundation distance configurable (Device::WithinRangeOfFoundation)
- allow placement of ground devices in editor without having a foundation nearby & show proximity status, radius
- darken neutral devices

24/4/13
- Make separate folders for different users under new users directory, outside of data
- Fix: crash when pasting in terrain editor and clipboard is empty
- Screenshots go to user's folder with fortwars prefix and map name suffix
- Fix: config utility doesn't run when no user configuration exists

25/4/13
- FileSelect screen can now be scrolled up and down

26/4/13
- Move multiplayer.ini into user's directory
- Prevent creation of nodes linked to nodes owned by other teams
- Fix desync: Prevent creation of chains when not editing to prevent structure desync
    - repro: create isolated node. after temp bracing is gone but before it breaks off and becomes neutral, create a new node.
        - in multiplayer this will cause a structure desync
        - in sandbox the first node will break off and elongate the link to the second node.
            - second (standin) node remains fixed with original team (must not have a reference link?)
- don't advance standin link build progress
- Fix crash: create new node, link back to other node, delete second link
- Desync: create a link from a standin node causes a resource desync
- Structures Desync: when client lagged, create a link after the host has released a single link node
    - Cause: host: breaks off, rejects link creation. client: standin link changes the way structures are destroyed by vibration or stress
    - Solution: ignore standin links when making decisions about destroying nodes and links by vibration or stress
- Structures Desync: when client lagged, create a link after the host has released and broken off a single link node
    - Cause: different stress reactions when the link hits the ground

27/4/13
- Allow building of foundations from temp braced nodes
- Make missile penetrate one layer of bracing then explode 

29/4/13
- Victory/defeat screen & game over mode (re-enable reactors are critical)
- Screenshots not working on Laptop screen (had to make FortWars.exe run on NVidia card, not integrated Intel)
- Fix: mirror horizontal structure

30/4/13
- Updated image library (much faster load times)
- Turn off fog of war in debug & game over modes
- Make minimum mortar power higher
- Added optional material Icon to use in the Items and Detail panels (still some fix-up work to go)

1/5/13
- Fix: Items panel scrolling and layout, take into account disabled items
- Add pin/unpin button on HUD

2/5/13
- fix: deselect node when selecting a device (currently builds from old selection when left clicking from weapon/device)
- Automatically background a link when building over a device
- Automatically background a link when building a new node over a device
- Preview automatic backgrounded material placement
- Show where a non-recessible material collides with devices
- Fix: disabled devices can't be selected from structure editor, or show details in device editor
- Fix: no click when in structure editor and selecting a device
- Fix: no device highlight when reactor is selected and mouse is over a device
- Draw link highlight graphics instead of debug line
- Fix: solar panel and door damage sprites

3/5/13
- Fix: tuturial building is prevented by the inability to place isolated nodes, changed tutorial map and speech to update tutorial
- Fixed automatic targeting of ballistics weapons (tested with T key), iterates over several speeds if available to find a good solution
- Set damage key before rendering instead of updating when it changes
- Removed unused braceplate textures

4/5/13
- Fix: take weapon angle into account when automatically targeting ballistics weapons
- FireWeapon will open a door and fail to shoot
- Added functions to get device savename, position, and to close weapon doors
- Broadsides script fires weapons round robin, and closes them if they successfully fire

5/5/13
- Run script in replays

6/5/13
- Separate AI script from level script
    - requirements
        - have an AI script that receives its team identity from the game
        - can have the same script running concurrently but on different teams (for testing)
        - map script can override the ai script
    - solution
        - have a default ai script
        - map script can over-ride the default ai script using a mod (ai can be contained in the mod itself)
        - game creates a new instance of the ai script and sets the teamId and enemyId variables, calls Update on them as normal

7/5/13
- Add check boxes to enable AI in both teams in multiplayer

9/5/13
- record AI config in replay
- moved ai script to ai/ai.lua instead of mods folder (so it can be modded)
- added result codes for firing to give AI information on what went wrong
- AI fires weapon soon after opening a door, then closes again, with some random variation

10/5/13
- Allow text control text to be changed in script
- Allow script to decide victory and end the game
- Add localTeamId query script function before starting it (so weapons can be enabled/disabled on a per team basis, for example)

12/5/13
- Fix context button clicking
- Fix alt-material replacement in editor

13/5/13
- Make a ListBox control
- Allow ListBox control to be added in the editor (Static with prototype text and scroll arrows)

14/5/13
- ListBox control used in MapSelect and FileSelect screens
- Improve collision test between projectiles and meshprojectiles (e.g. mg & mortar)
- Removed use of random in ai script (throws out replays for unknown reason)

15/5/13
- Replay desync (Resources) - to do with use of lua random function - seems to vary between executions
    - removing calls to random removes the desync
- Allow ListBox to insert Text controls
- Add end and home function to ListBox
- Use ListBox control for chatroom chat text
- Add mouse-wheel support to ListBox

16/5/13
- Use ListBox for console
- Add rule: snipers with LOS to enemy act as spotters for other weapons (increase all aiming circles), increase in proportion to height
    - add spotter efficiency float to JointResourceAccount
    - zero before updating devices
    - snipers contribute to this up to a maximum depending on
        - a line of sight to the enemy reactor (ignoring the structure)
        - height above the view floor

17/5/13
- add SpotTarget flag to device file
- add MaxSpotterFactor to weapon
- Require a spotter for missile launcher and mortar
- Add no line of sight icon

18/5/13
- Can't delete perma-bracing in editor
- deleting link deletes nodes
- Fix: no destroy device effect sometimes (splash damage destroying gun platform)
- Fix: orphan devices
    - crash to do with device tags. code testing for zero health may never have run before so could be buggy

20/5/13
- background bracing not drawn properly in fog of war
- Fix: mirror structure
- Allow building unsupported nodes in editor
- Add sniper for AI

21/5/13
- Report to AI when a device is destroyed
- Make AI rebuild destroyed devices
- Fix: Material repair sometimes fails even when there are resources
    - was testing for the resources to completely repair something

22/5/13
- Fix: Duplicate missile launcher graphics and missing munition
- Fix: shield animation
- Fix: shield caps not being drawn

23/5/13
- Make cannon explode on impact with shield and apply splash damage
- Make option for non-explode on impact projectiles to go through shields
- Fix: Missile launcher changes direction
- Fix: devices don't explode when platform destroyed
    - DeleteAttachedDevice was being called when damage was applied. reverted to default unattached device destruction
- Fix: vibrating platforms don't explode their device
- Fix: don't trigger device/projectile effect if projectile is going to continue on

24/5/13
- Fix: disparity between cursor target and projectile trajectory
    - CompositeSprite node:
        - Pivot shifts the current node relative to the parent (excluding current angle, based on parent node's sprite size)
        - Offset shifts the current node relative rotates around the pivot at the current node's angle, based on the node's sprite size
    - Barrel base should be taken after the Pivot of the head is applied but not before the angle & offset are
- Fix: disable snap to devices in terrain editor
- Fix: spacebar doesn't cycle between all views in editor
- Fix: can't select a device in editor when non is already selected

25/5/13
- Fix: Under construction icons not showing up
- Fix: Mortar doesn't give off an effect when it collides with a wind turbine

26/5/13
- Fix: Missile launcher becomes non-neutral when team 2 reactor is destroyed in sandbox
- Fix: ground/grid intersection snapping doesn't work well (non-zero z value)

28/5/13
- Change the way snipers work as spotters (cast out rays - not aimed at reactor, just clear view up to a certain distance)
- Calculate clear angles up to barrel length plus min fire clearance
- Display clear angles when placing a weapon
- Fix: stray angle bracket when weapon placed in a box

3/6/13
- Only draw weapon visible angles when able to build
- Make an angle bracket set for left and right (recalculate the hardpoint position for left)
- Preview recession of links when placing devices
    - mark recessed links and draw them as recessed when previewing construction (avoids state change)
- Reproduce door state & damage when breaking structure off
- make foundations at ground corners default to the more vertical normal
- Don't preview background struts that are within angle tolerance of platform
- Fix: angle incorrect when platform is created right to left
- Fix: ground devices don't snap to ground properly when cursor snaps to node?
- Preview background materials when ground device buildable
- Don't zoomto when cycling ready to fire weapons (spoils aim)

4/6/13
- Fix: DrawArc angles wrong
- Moved ChangeDisplaySettings to before CreateWindowEx to hopefully fix Nick's display problems
- Fix: crash in Broadsides just after destroying enemy AI reactor (looks like dereferencing NULL pointer in PhysicsManager::BreakStructure at new code, unknown why)

6/6/2013
- Fix: aiming gizmo has wrong angle when weapon facing right and angle is offset from horizontal (is opposite)
- Added second ray coming out the back of spotters so it's not so fiddly managing them, choses the best for visibility calculation
- Fix: Cable material broken, need to prevent breakage for some materials
- Fix: device selection (broken closest distance to item comparison)
- Fix: high resources are carried over from editor to sandbox? mods in singleton were not cleared when World destroyed

7/6/2013
- Make AI rebuild destroyed links
- Make AI attempt to shoot down mortars and missiles

8/6/2013
- Write script compile errors to console

9/6/2013
- Fix: prevent cannon from colliding with small arms fire
- Fix: check length of struts built by AI

10/6/2013
- Spotters pan to face target
- Constrain lasers to aiming angles
- Don't use selected spotters
- Aim/Draw spotter lasers for other clients
- Fix: structure desync when firing missile

11/6/2013
- Select spotters when aiming missile
    - If a client has a missile selected, aim unselected spotters at the mouse position
    - Divide spotters up based on order in team
    - Spotters try to divide themselves among targets so that as many as possible are painted
- Record which client spotters are painting for, and track them directly locally

12/6/13
- Allocate any spotters that don't have a direct line to a target round robin
- Increase target painting tolerance
- Fix: spotters not distributed evenly when possible

13/6/13
- Add option to allocate only one spotter per target
- Prevent unallocated spotters from facing targets
- Fix: Never allocate a spotter that doesn't get past the end of the barrel
- Optimise Device::UnderLineSeg by adding a cicle pretest
- Add Device::UnderLineSegQuick for a course test
- Fix: work out the actual radius of the bounding circle of devices

14/6/13
- When no clear line of site, allocate the spotter who gets closest to the target

16/6/13
- Re-arrange creating window and changing display settings to hopefully fix Nick's display issue
- Increase mortar hit points to 70

17/6/13
- Reduce depth buffer to 0 bits & log out pixel formats
- Desync: Weapon facing wrong way when firing
    - Update weapon panning immediately after receiving pan weapon message
    - Send weapon pan angle when firing and update immediately before firing (should be redundant)
- Add minigun weapon & initial tuning
- Added FireDelay weapon parameter to allow the minigun to spin up
- Fade in motion blurred projectiles to prevent drawing on top of weapon
- Prevent the selection of weapons when mouse in aiming reticle

18/6/13
- DeviceManager::EnableDevice should use savename instead of display name
- Upgrades
    - weapons can have a list of upgrades with specific costs and build times, and can be disabled
    - upgrades can be enabled and built independent of their parent weapon

19/6/13
- Move spinning minigun barrel into device sprite
- Add float pointer console var type so that console variables can directly affect values without a callback
- Register cvars for device sprite pivot positions to allow tuning at run time
- Add AnimationLength over-ride value to animated texture configuration so that loops can be limited
- Renamed root nodes of all devices and weapons to allow differentiation in the console vars
- Moved minigun flash into weapon sprite, with delay

20/6/13
- Overhaul Explosion::SpriteEffect particle sizing
    - base it on texture size and pixel to world conversion
    - add initial size multiplier
    - add expansion rate
    - check parameters passed to particle emitters
- Fix: lock weapon before spawning any projectiles for all clients to avoid desync with delayed fires
- Fix: local player's node selection can be set by a remote player (at least when on the same team)
- Add an AI difficulty setting
- Fix: AI shoots in the air and ground with machineguns sometimes (needed to update fire angle again after panning)
- AI leads projectiles by a second, greatly improving shoot down rate
- Add an extended ray cast in front of barrels for AI to prevent it shooting own fort
- Add script function for AI to check if a device is selected by a team mate

21/6/13
- New map Defiance
- Sniper able to shoot from zoomed in
- disable solar panel
- avoid turning weapons when they will face a wall

23/6/13
- Make AI build fort patterns in map directory for each team
    - trigger a 'record building to script' mode, which starts an array
    - each node, link, device construction and deletion is added to the array, with details of position, node ids, type
    - ai starts at the beginning and tries to build each in turn
        - if resources insufficient it tries again later
        - if too far it tries to build an intermediate node, connected to another nearby node?
    - if it takes too long then try to skip the current item?

24/6/13
- Rebuild nodes by running through Fort table from the beginning, and executing actions involving the node
    - if node is destroyed
        - find reverse mapping in OriginalToActual array
        - if found, pause normal construction (reference counting by reconstruction threads?)
            - run all create & link commands involving that node in chronological order
- Name fort files with team number
- Filter commands carried out by team not in record mode

25/6/13
- Fix: Door rail goes into the background
- Fix: Highlight icon of selected tool
- Load AI Fort script from game based on team number
- Added sandbags device
- Fix: device upgrade incorrectly showing in context menu
- Can create a door from armor
- AI can rebuild miniguns

26/6/13
- Fix: can't fire missile even with a painted target

28/6/13
- Randomly select the AI fort from directory
    - host keeps own copy of fort paths
    - read selected forts into local buffers
    - pass to World when WorldOpenMap command is passed

29/6/13
- Fix: minigun flash starts from loading
- Fix: Use the original rest length as the new rest length when replacing materials to prevent slight collapse
- Add second (graphical, horizontal) context menu
- Fix: support for tiling sprites in WindowFrame::Draw

1/7/13
- disable ground snap in structure editor unless a node is selected
- left click off context menu disables menu
- Right click to select & bring up context menu
- Left click to select or build
- hide device context menu when zoomed out too far
- left click on a selection hides the context menu
- left click to pick material

4/7/13
- Devices store a pointer to their config lua state to allow calling of functions at runtime
- Beam thickness made a function of time

5/7/13
- Made InterpolateTable function in effect_util
- Beam damage keyed by time
- M, D, W to select and cycle different tools, change shut door key to S
- Record device efficiency height once on construction instead of every frame

6/7/13
- Deselect device when cycling tools
- Fix: stop drawing spotter visibility angles when switching sides during missile launcher aiming

7/7/13
- Add 4x time speedup
- Add pause_at_frame debug assistant
- Fix: forts vanish sometimes. m_CreationAngleToLink0 was undefined when links aligned perfectly.
- Added trace_commands console command to trace network commands as they arrive
- Fix: remove cladding darkening
- Fix: particle size corrected so they are consistent with world pixel size (has the effect of halving particle sizes on screen)
- Adjusted device explosion, light impact, heavy impact effects for particle engine changes

8/7/13
- Fix: temp braced node shifts when deleting node below during AI fort construction, or connecting link destroyed
    - recalculate m_CreationAngleToLink0 if reference link is goes
- Fix: screenshots when using laptop screen
- Destroy projectiles that are raining down

12/7/13
- Sparks overhaul
    - provide angle brackets or mean/std dev
    - put keyframe angles into degrees
    - interpolate spark parameters with angle from reference angle
        - key initial radial offset, speed mean/std dev, drag, rotation by angle from a reference angle
    - add 4 keyframe control of fade in/out
    - add 4 keyframe control of scale multiplier
    - add effect of gravity    
    - Default to keep texture's aspect, with stretched along velocity alternative; native at zero
- Added data/effects/sparks_test.lua and docs/fileformats/SparkEffectConfiguration.lua as examples of how to use sparks
- Removed old sparks files to prevent them interfering with intelli-sense of new files in the FortWarsLib project
- Fix: memwatch showing up in Dropbox data folder

13/7/13
- add animated sprite support to SparkSet
- allow sparks to have a trail effect
    - when spark ends its life its trail effect must be managed and deleted by the effect manager
        - continuously add time to the lifespan of the traileffect so that it is destroyed after the last effect expires
- allow sparks to be released over a period of time
- allow attach spark set to mesh projectile
- add life span to sparksets after which they disable themselves

14/7/13
- integrate new missile tail animated texture
- adjust missile launch position and effect to obscure appearance of missile

15/7/13
- Fix: background bracing selection
- second row for context menu

17/7/13
- integrated new device health bar graphics
- only show health bar when device is highlighted or selected

21/7/13
- Allow effects to be sorted
    - zero is the ground & structures, positive into the screen, negative out of the screen
    - free particles and effects need to be sorted together
    - keep particle list system and effect system
    - new SortableItem list
        - callback interface pointer, userdata (for index into particle list), z depth
        - clear before each update
        - each effect or particle adds itself to the list each update
        - draw background items, game layer, foreground items
- Draw effects with positive z in the background and negative in the foreground

23/7/13
- Add a midground layer between the structure and ground for effects

24/7/13
- turn mesh projectile trail into an explosion effect
- remove old single purpose Trail from Weapon
- Move Trail code from mesh into FortWarsLib
- remove mesh project
- Sort effects by texture and don't switch textures unnecessarily while rendering

27/7/13
- Fix: replays break immediately for sandbox; ai configuration not written

28/7/13
- Fix: sometimes sniper trail not reflected with an extra keypoint at the inflection
- Fix: allow placement of isolated foundations in editor; ground snap was turned off
- shift frame rate and other rendertext info when console drops down
- report an error when duplicate sprite names are detected

30/7/13
- radial progress bar support
- radial progress bar for device and link construction, repair
- repair and deletion of devices takes time
- specify time to scrap each device
- prevent use of weapon while scrapping
- deleting a node causes attached links to go into scrap mode
- prevent deletion of a node when any of the links has a device on it, with error signal
- delete orphan node when scrapping struts
    - Sandbox
    - Replay

31/7/13
- Fix: crash when deleting orphaned nodes
- Fix: crash when selecting device or weapon tabs
- Fix: construction icon not appearing when building a device or weapon

2/8/13
- Revert laser cost
- Reduced repair cost for all weapons and devices (metal 10% of cost, energy 50% of cost) to make maintaining more attractive
- Allow surface layers to be switched on and off
- Turn off layers depending on ability to build mines or not

3/8/13
- Add RandomStartFrame flag to animation state to make miners to be out of sync

4/8/13
- Added animation script to devices with a single registered function SetNodeAngle
- Moved InterpolateTable function to effects/intepolate.lua
- Missile launcher has animated door

8/8/13
- add support for persistent effects associated with devices/composite sprite nodes    
    - add a vector of explosions associated with nodes
    - setup from config, then copy/clone explosions when creating actual devices
    - update/draw explosions with device, based on position/direction of associated composite sprite node
    - don't update explosions on prototype
- Fix: sorting of effects (removed sort by texture, wasn't working - don't know why)

9/8/13
- Agreed on Fort Commander name
- FortCommander.com domain name registered
- Fort Commander Facebook page claimed

12/8/13
- Fix: crash when reactor is deleted (need to remove related effects from mSortedEffects)
- don't background bracing when it's in line with the platform
- calculate x, y extents of each team in pm update
- Fix: bounding rectangle test of structure against incoming line segment
- use extents to avoid testing for collisions with line segs (projectiles, beams, isolated nodes, etc.)
- prevent weapons switching direction if enemy and enemy projectiles are all on one side
- Hide miners when neutral
- Added Columns map with team 1 AI
- Fix: AI fort recording delete node records junk node Id

13/8/13
- Fix: Meshprojectile resources not freed leading to inability to fire some weapons. In perpetual fading state.

14/8/13
- Shields can be temporarily disabled by projectiles
- Cannon and missile disable shields
- Shields can be disabled and re-enabled by the context menu
- If a shield's power need can't be met it is temporarily disabled

27/8/13
- Weapons and devices can have HUD icons

28/8/13
- Fix: Adjust size of HUD icons for proper aspect
- multiply material costs by standard length (100) to display in HUD

1/9/13
- Fix: scrapping a node twice resets the strut destruction clocks
- Fix: map script load is called in Editor (when there is never AI)
- Fix: Avoid map script load/update when editing

4/9/13
- Added DeviceGroup class and temporary/current groups
- Add weapons of same type as current selection to device group
- update fire angle/speed and send fire messages simultaneously
- Fix: release temp device group when selecting another weapon
- Fix: can turn team 1 weapons to the left in Broadsides Sandbox
- Fix: destroy nodes or loose struts when they fall outside of the bounds of the world

5/9/13
- Fix: apply direction constraints to grouped weapons
- Don't allow projectiles of the same type on the same team to collide with each other (e.g. mortars)

6/9/13
- Fix: pan new weapons added to a group
- Allow single device to be their own group
- Draw device brackets on grouped devices
- Draw faint aiming gizmos on group slaves
- Avoid grouping devices on different teams
- Added grouping sound effect
- Fix: changing master of a group when selecting another weapon
- Select a device under the cursor instead of firing
- Highlight weapon under cursor when inside aiming reticle
- Apply weapon direction constraints on restore

7/9/13
- Fix: didn't forget a slave when switching selection to another device (on team 2, Simple)
- Added weapon group tabs to HUD, with highlights and transitions
- Clicking on a weapon group tab selects the weapon group

8/9/13
- Fix: unable to restore groups when not in device mode
- Fix: weapon group 9 tab not showing up
- Fix: weapon group 0 showing temporary group members
- Fix: missile launcher not firing
- Fix: apply splash damage when a projectile is shot down

9/9/13
- Fix: crash when restoring a group after reverting map
- Fix: clicking on friendly device fires missile at it (L365 device editor)
- Send active slave selection to other clients, tag slaves, aim remote weapons based on the master
- Locked devices can't be selected and used as slaves, but once the lock is released the slave is used instantly
- Update group icons when a slave weapon has been lost
- Ctrl-left mouse on slave removes it from the group

10/9/13
- Clicking on a group weapon icon makes that weapon the master
- Allow switching of master and slave (normal left mouse selection of slaves)
- Removing the master from the group makes the next slave the master
- Fix: include devices when testing for fire clearance
- Restoring a group when the master is locked makes the first available slave the master
    - when the entire group is locked make an error noise
- Don't fire weapons when the cursor is over one of the group tabs

11/9/13
- Add and update the weapon group health bar
- HUD weapon group buttons are added and removed with the userdata representing their Id
- Max weapon group size is in rules.lua, and layout is in constants.lua
- When saving a group associate the screen with the group
- Restore view when restoring an already selected group, don't use the default ones

12/9/13
- Repair acts on entire group
- Delete does not work when a group is selected (single weapons only, to avoid large mistakes)
- Fix: pan slaves without having to be in aiming circle
- ReactorsAreCritical won't end the game if there were no reactors at the beginning

16/9/13
- Weapon and material details
- Fix: red line visible under weapon group health bar
- Increase min fire clearance of sniper
- Fix: apply direction constraints to weapon preview
- Fix: don't use enemy structures to shadow visibility
- Fix: don't obstruct fire with enemy structures
- New Fort Commander icon and exe/process name

17/9/13
- Fix: crash. mg selected when it collapsed and was destroyed. broke on line 366 in deviceeditor.cpp
    - second instance: 2 mg in group, mouse not in aiming circle. supporting strut destroyed and master mg was spinning over.
- Fix: Group selection lost when the master is destroyed
- Don't pan, aim or draw the aiming gizmo of slaves until they are fully built
- If group members are neutral remove them from the group

8/10/13
- Fix: grouped weapon desync
    - Slaves were aiming while being locked, leading to a difference in fire angle
- Fix: machine gun/mortar fire desync
    - Preview weapon was modifying the local resource account when team id was set
    - No longer change the resource account for preview devices
- ReactorClaimsForts rule doesn't change device Ids unnecessarily

11/10/13
- Show the appropriate detail panel of upgrade when hovering over the upgrade panel

12/10/13
- add splash damage from device explosions
- device splash damage can be delayed
- mortar, cannon, battery and reactor have splash damage

18/10/13
- materials can catch fire and spread along the length
    - links can have a vector of fire segments
    - only certain materials have fire segments and have one direction of their link initialised with FireSegments
    - FireSegments are initialised at zero temperature and not alight, sprite initialised but on invisible state
    - Execute UpdateFire pass:
        - increase or decrease temp of FireSegments, faster when moving up
        - light fire if above threshold of material,
        - put out fire if below threshold,
        - apply damage if on fire
    - Execute Draw Fire pass
        - draw sprites of all FireSegments
    - Repair sets temperature of all segements to zero
    - Laser ignites point of contact or neighbouring bracing
- Fix: crash on incendiary projectile impact
- Added randomised fire layers to mix it up
- Added vertical offset to align flames with struts
- Added random perpendicular offset to flames
- Force projectile impact flames to be foreground to avoid them being initially hidden

19/10/13
- Fix: invalid fire layers making invisible flames
- incendiary projectiles ignite the neighbours of the hit segment

21/10/13
- Fix: updated mDebugBufferStart after writing AI configuration
- Fix: fire segments copied to new links when the structure breaks
- Fix: Neighbours lit properly

25/10/13
- Don't fire if any of the weapons has to wait for a door to open (not machinegun)
- Attach smoke effect emitters to each link with smoke segments
- disable smoke effects when the link is removed

2/11/13
- Desync: desync when deleting a weapon. The delete was occuring in DeviceManager::Update(), when it should have happened in DeviceManager:UpdateDevices().

3/11/13
- Desync: Desync in Simple map when laser hits the top of the team 2 fort, with additional structure and laser built on top
    - Conditions identical at start of beam hit
    - Second frame (very slightly) different.
        - Options
            - Mass of nodes are different (which should desync well before firing laser)
            - Force not applied in the same physics frame, with different time step
            - Uninitialised variable referenced (why would it suddenly be used?)
    - Only happens when force > 0. Damage can be >= 0
    - Other weapons don't seem to cause the desync, only beams
    - Cause: remote clients did not have the laser locked, so movements of the mouse caused the beam to move for only the remote clients, creating a desync

4/11/13
- Desync:
    - Nick built a door
    - First missile destroyed it
    - Rebuilt the door and it never finished building
    - Second hit caused a desync and it was revealed that it was in the stand-in state
    - Cause: door probably failed to build because the structure moved and it was too short at the time the message was received
    - Solution: When a link fails, destroy the standin link

5/11/13
- Desync: Missile caused desync in Vanilla while persistent stand-in link existed
    - Could the garbage stand-in link cause a desync?
    - test it by preventing one team from actually creating links, leaving just stand-in links
    - Stand-in links are damaged by splash damage and a force is applied to its nodes away from the impact (shouldn't happen)
    - Prevent desync when the thing happens to normal short-lived stand-in links

6/11/13
- Additive property for spark sets
- Fix: material construction preview flashing on & off (in multiplayer), GL_TEXTURE_2D not cleared for circles
- Don't draw construction preview for enemy players
- Desync: Resources desync while team 1 and team 2 were building bracing in Columns
    - Random resources desync also happened on Twin Silos with no building immediately beforehand, but wind turbine had been built
    - Wind turbine efficiency had not been set consistently on different clients
- Reduced sniper reload time to 1.8s

12/11/13
- Laser lights a few segments when it hits armor

14/11/13
- Fix: turbines apparently unable to reach full efficiency (wasn't setting efficiency if there was no collision with wind floor)
    - caused resources desync when a turbine starts at max efficiency
- Fix: friendly missile launchers drawn behind terrain
    - order should be
        - terrain background
        - enemy ground devices
        - terrain foreground
        - friendly ground devices
- Fix: unable to reach full energy capacity when using shields
- Fix: incendiary mortar does not set platforms alight when hitting devices

15/11/13
- Replace any instance of perma-bracing with bracing (phase it out)
- Devices can be upgraded
- Added workshop, upgradecentre, factory, super turbine, super mine
- Upgrade button disabled if prerequisite for upgrade doesn't exist
- Only add composite sprite tuning parameters in editor
- Make cvar test case insensitive
- Prevent turbine blade from spinning if simulation not running
- Tune position of sandbags
- Fix: Fog of war not working for enemy weapons
- Screenshot can be taken while console is active

18/11/13
- show altered firing arc when building in front of weapons
- Fix: draw construction timers over ground devices
- Fix: prevent devices from flipping directions

19/11/13
- Fix: construction preview sometimes failes to recess
- Fix: devices sometimes fail to recess struts (e.g. mine over link that is completely inside)

22/11/13
- Fix: prevent console typing when Alt is pressed
- don't show enemy cursor, name tags or material cost previews

24/11/13
- Added PenetrationMomentumThreshold to stop AP sniper round when it slows down enough
- Made armor piercing sniper upgrade to sniper

25/11/13
- Fix: cannon projectile doesn't detonate properly; slow down of projectiles is now based on mass of projectile vs. per unit weight of the material
- Fix: Crash in editor when upgrading when simulation not running
    - OnMasterLost now calls DeselectDevice() instead of SelectDevice(NULL), which doesn't clear the context menu (commands are executed immediately when paused)
- Added core-anti-air Impact effect in weapon_list.lua

30/11/13
- Fix: infinite loop allocating memory when minigun is fired at shield in guntest

2/12/13
- Slightly increase reticle of AP sniper
- Increase min field of fire for laser and minigun
- increase height of missile cruise altitude
- Reduce drag of AP sniper projectile
- increase paint tolerance
- Fix: MG impact on armor not showing
    - change to reflection momentum threshold meant that the projectile was being absorbed instead of reflecting
    - increased mass of mg projectile
- Fix: Team 1's bounding box extends to the right (maybe to x = 0) in Vanilla
    - isolated, invisible nodes found in some maps (editing bug?)
- resize team home screen to the size of the fort plus a skirt, take HUD into account

6/12/13
- Fix: unexpected state change when scrapping strut under construction?
    - unable to destroy shield due to state change to disabled?
- Don't show main link or draw energy when shield is being scrapped
- Fix: Presing Delete will remove a node instantly (should be instant only in editor)
- make materials solid when upgrading from one to the other
- don't over-extend preview strut when connecting to the ground
- set fire on platform when some weapons are destroyed
- make building material limits consistent
- add link snap to midpoints with higher priority than nodes
- ignore background bracing and bracing with existing devices when trying to place a device
- Fix: failed to background a low angle brace when building over it with a weapon

7/12/13
- always make first and last fire segment on a link foreground
- shift fire segments away from the nodes so they don't overlap the node and each other so much
    - make the first and last segment a proxy for the next one in
    - they alway have equal temperature, but the end segments don't show a flame
- modulate fire speed over nodes by direction
- add population cap to buildings
- add ground edges to visibility calculation
- let wind pass through shields
- doors block wind to their current position, but construction previews are as if all doors are 100% open
- Desync: Target weapon button accidentally pressed causes projectile desync
- Desync: standin link affecting resource accumulation by turbines
- Fix: crash when destroying cannon on weak link in Guntest with mortar, first line of PNode::IgniteAt
    - strut was destroyed by splash damage during the same impact, so did not exist to be set alight
BACKED UP
- Fix: increase minimum size of shield so the ends don't overlap
- Allow single nodes to be deleted instantly
- Cycling material, device or weapon tool after a short period sends user back to the first tool

8/12/13
- disable clicking on selected device changing zoom
- make weapon autozoom optional (in constants)

9/12/13
- Fix: can't select/build from nodes from structures when reverting map in sandbox
- Fix: Midpoints of links are selected in preference to devices

10/12/13
- Add missile swarm weapon (upgrades to missile launcher)
- Fix: missile launcher bug, laser not drawn locally
    - may have to do with having the missile in a group?
    - device to create was not changed when restoring group, which was needed to draw painted targets locally
- Fix: number keys restore previously cleared weapon group
- Fix: weapon group number interfere with ground block owner control in editor (disable in edit mode)
- Fix: NULL dereference in Device::IntersectsStructure
- Default wind angles non-zero
- Wind is affected by neutral team structures
- Console error when weapon has efficiency aspect (suspected crash)

11/12/13
- allow selection of startup resolution in options (add list control)
- if config screen res is not supported default to current screen res & 32 bits
- Fix: TextButton rollover and activation are clipped by a parent (fixes Menu music options screen issue when items are clipped above the list)
- Fix: prevent device editor actions during area select
- Weapon is not ready to fire during fire delay
- Don't target missiles when they're not ready to fire

16/12/13
- Allow some different weapon types to be grouped together (mortars & missiles)
- Keep groups when upgrading a member, as long as the upgraded weapon is compatible
- prevent missile from colliding with friendly swarm
- intersect laser with mesh projectiles
- Don't block lasers from firing into friendly shields
- Fix: auto-home screen inverts out after reactor goes (parts below ground?)
- Fix: double clicking anywhere while a door's context menu is open will open or close as the selection is kept

17/12/13
- Fix: prevent chatroom text with no characters

20/12/13
- add target effect for missiles
- Add PlayForEnemies to avoid playing construction noises for enemy players

21/12/13
- AI has a list of target priorities for small arms, and casts a ray to the target to see if there is a clear shot
- Reset the node numbers on revert, to prevent AI forts being out of sync with the map

24/12/13
- AI can fire missiles
    in script
    - select a spotter
    - cast ray from sniper to heavy arms targets - hit anything except terrain & nothing, get position of surface
    - open doors for spotter, prevent it being used for shooting
    - set AI aim target for missile launcher(s)
    - wait, check if game has marked the target (could be with a different sniper), then launch missile at target
    - clear AI aim target, close spotter doors
    - close missile doors
    - add AI aim targets from weapons that require spotters in ClientManager::Draw(), mark as AI targets
    - ignore additional targets if they are very close together
    - if mark was successful, then set a flag in the weapon for the AI to query

26/12/13
- Added EnumerateLinks script function
- Added GetRepairCost and RepairLink functions
- AI repairs fire & damaged struts
- AI repairs devices

30/12/13
- Analyse existing fort and append to beginning of AI Fort pattern
- Don't upgrade a link if the material is identical
- repair a device repairs the platform and anything behind it
- Hover + R consistent between structure and devices
- AI built weapon face the right way
- Fix: AI uses human controlled sniper for painting missile targets
- Fix: AI fires sniper while it's in use as a spotter
- Fix: AI takes over spotting sniper while human is using it to spot for another missile
    - only happens when the spotter can't get a LOS to the target
- Add verbosity levels to ai.lua trace statements
- Blocked spotters are allocated on first come first serve basis, instead of distance to target, for a stable allocation

31/12/13
- Don't show construction icons for the enemy
- Fix: AI spotting laser fails to draw when human enemy is firing an mg
- Fix: AI stops building if there's a device obstructing it

2/1/14
- Fix: console texture was set to the left HUD button texture when AI log level was set at Enumeration and the AI enemy's reactor was destroyed
- AI can build any upgraded device
- Fix: mg fires at friendly structure built behind
    - happens when delayed projectiles pass a zero node id (tracks stand-in node instead of projectile)
- Added script functions to query the team's current resource level, capacity and rate
- Prevent weapons from aiming/opening doors when they can't afford to be fired
- Stop AI once the game is finished
- Prevented dumping of cyclic loops (_G and loaded tables) in LuaPlus
- Added GenerateCrashDump function which catches all exceptions in the WinMain function
    - Creates a mini-dump in the user's crashdumps folder
    - Creates a dump of the current script states
- AI will attempt shoot down all mortars and missiles
- Mini-gun can be used as an anti-air weapon by the AI

3/1/14
- automate desync debugging: take screenshot of both forts, console, and current screen
- Record multiple screenshots when a desync is detected, saved to user's desync directory
- Fix: Sandbox replays end instantly. Now only writes Ai config once (now optional), added markers to sanity check command writing/reading
- Fix: crash when reporting weapon is destroyed before projectile crosses target plane (removed this functionality entirely)
- Added dump console command to take scene screenshots, dump Lua states and copy Log file
- Copy log file to desync or crashdump folder
- Save replay to desync or crashdump folder when desync or crash happens
- Fix: AI will stop attempting to rebuild a device if the platform didn't exist when it tried
- Fix: devices can be scrapped instantly (Sandbox)

4/1/14
- Created new reactor_steam.lua effect and put that into the midground
- Added second foreground layer for effects
- Put device explosion effects so they are in the second foreground layer
- Fix: sniper trail extends past point of collision
- Fix: replacing an auto-recessed strut with bracing results in an unmoving construction icon
    - should just reject the replacement in structure editor
- PNode::UnlinkFrom removes all links, not just the first (to clear out lingering StandIn links)
- If the CommandInterpreter receives a create link message and the links are already connected with that material
    - it removes any StandIn links connecting the two nodes
    - This may occur during a race with another client
- If a link has a StandIn link, draw that material instead of the actual one
    - so that replacement shows immediately

4/1/14
- Always remove standin links at the start of CommandInterpreter::ReceiveCreateLinkMessage
- Fix: prevent doors from being controlled with double click during construction
- prevent players from operating doors or changing materials via context menu while being scrapped or repaired
- Allow strut scrapping to be cancelled
- add cost for building and shooting to details panel
- Player can shake a device type selection by right clicking in mid air
- don't allow picking of a disabled device
- don't apply the WeaponSelectionZoomBias if the mouse is in an aiming circle
- increase turbine minimum angles
- Allow some power production if a large part of one side is exposed
- BACKED UP

6/1/14
- Devices can have detail panels
- Integrated new weapon and device detail panels
- Fix: memory leaks
    - Control was removing all children instead of deleting them
    - EdgingSet layers
    - UndoStack instance
    - HUD m_WorldPage
    - Replay client data

7/1/14
- Fix: AI configuration not transmitted to new members of the chatroom
- Fix: Show all construction icons to observers
- Fix: Dead clients don't drop out
- Fix: LogCommand not showing actual commands when a desync happens
- Fix: Crash in RebuildNode/ExecuteFortAction-CREATE_DEVICE? Run replay
- Fix: Log.txt not copied during crashdump?

8/1/14
- Fix: AI was not inspecting the team resources correctly
- Fix: AI was able to change the target of a weapon when shooting down projectiles
- Fix: if AI tries to fire weapon after opening doors and can't afford it, abort and close doors
- Fix: Non-determinism of spotting laser in render frames may change decisions made by the AI
    - exacerbated by watching in fast motion
    - Solution:
        - Have one actual painting per physics frame
        - For spotters painting for humans, cast a ray to draw the laser (interpolated by client selection)
    - Fix: Player can't launch missiles
    - Fix: Player's laser does not follow the exact mouse position
- Fix: AI upgrades weapon while it's being used by human

9/1/14
- Record which game functions were called by the AI to see what was most recently changed, see AI call differences between original game and replay
- Fix: AI repair link was not setting the parallel link to repair, and was setting it when scrap was in progress
- Fix: occasional replay desync
    - Use of math.random
    - Now replaced by GetRandomFloat and GetRandomInteger, which uses the physics' random number generator
- Fix: Updating PhysicsTimeKeeper outside of PhysicsManager::Update; more consistent use of time
- Fix: crash when exiting the game after a long period sitting paused in debug mode of a replay
    - void Explosion::Disable() called from void MeshProjectile::Reset(), m_TrailEffect->Disable();
    - Trail effect aging may be running on real time and the effect was expired
    - Maybe this always happens if there is an active trail on exit due to the shutdown order of managers?
- Fix: crash: if operate_door.lua effect naturally ends before PhysicsManager::UpdateDoors has an opportunity to detect the finish
    - it will crash when it tries to cancel the effect, ditto for closing
    - investigate how effects relate to real time (e.g. debris sprites shrink when paused)
- Fix: crash: ai.lua OnLinkDestroyed had been passed a nodeB that did not exist in ActualToOriginal
    - Node creation was not reported to the AI
        - New nodes are created when the structure breaks at a node
- Fix: RealTimeKeeper is paused along with PhysicsTimeKeeper, avoiding non-zero manager time deltas while app is paused
- In single player Alt-Tab will pause/resume the game correctly
- In multiplayer Alt-Tab will allow the game to continue running

10/1/14
- Fix: poorly reflected trail when sniper bounces off the shield
- multiplayer pause
- Fix: prevent non-host clients adjusting AI settings, rolling over other buttons they can't affect
- Fix: clients that quit mid-game show up in the Loaded state, rather than Chatting
- Fix: Client physics clock is synchronised with server clock
    - Enabled RakNet occassional ping
    - Moved SetSyncState so it actually took effect
    - Tuned adjustment rate and min/max rate

12/1/14
- Added time sync parameters to constants script
- Ping and clock adjustment are filtered to reduce erratic reaction to ping/temporary lockups

15/1/14
- Fix: projectiles do not move smoothly. This is exacerbated when latency is high.
    - m_GraphicsInterpolationFactor was not being updated at the start of rendering
- Fix: simulation speed controls not working in replays
- Fix: Debug mode not available in replays
- MeshProjectile'd nodes can be drawn as a normal motion blurred projectile (so snipers can have trails and a normal projectile)
    - DrawBlurredProjectile added to weapon_list.lua
    - WeaponTypeIndex replaces (dangerous) OwnerWeapon carried by the node
- Fix: stop projectiles vanishing as soon as they impact; have them sink into the impact position
- Fix: MeshProjectiles are reset when collisions make them idle

16/1/14
- Fix: crash referencing apparently deleted wind turbine
    - in PhysicsManager::UpdateDevices(), When device hitpoints gets to zero or the device is not attached to a structure
        - device is marked for deletion instead of being deleted immediately
        - shouldn't fix the crash, but not sure what's causing it (no good clues)
- Fix: crash when AI tries to build a ground device (nil string output issue)

17/1/14
- Fix: Allow host to finish loading if a client drops out during loading
    - need to update network during loading, at least sporadically
    - add a callback to allow the network and UI to update during loading
- Added progress icon to loading screen
    - Writes a benchmark number of bytes to a Lua file in the map directory and to db folder
    - Uses value in db folder if map doesn't have one yet
    - Uses a default value if the Lua file isn't found
- Fix: Username sent with login message
- State change messages display text representation
- Console drops during multiplayer loading to show client loading status
- Fix: host starts game when any of the loading clients drops out
BACKED UP

18/1/14
- Fix: effect showing up at origin: construction of devices (had to set effect position & direction for Nick's effect to work)

19/1/14
- Fix: Weapons sometimes face wrong direction in multiplayer (initially only, AI built)?

20/1/14
- Calculate m_CladBothSides when structure changes (the inverse identifies the perimeter of the fort)
- Show background bracing to enemy when there is no cladding on one side
- Fix: Projectiles correctly sink into collision position before vanishing
- Add additional slow motion speeds, display shift next to fps when not normal

21/1/14
- Add faction support
    - identical weapon, different graphics. can be switched at gametime
    - need to be able to support additional factions as mods
    - add different Normal and Highlighted states to weapon sprites
    - iterate over the compositeSprite to set the weapon to a particular faction
        - If the faction's State does not exist the default state is used
    - Mods just need to adhere to a naming convention for states and insert their alternate states into the appropriate Sprite table
    - Effects are given the source teamId to query the faction name to e.g. set alternate sprite state
        - SparksEffect support factions
- Mods are given an opportunity for function calls by implementing the ApplyMod function
- factionName is detected and set in the Lua state when loading the mod to make duplicating a faction a one step process
- Fix: factions are loaded for replays
- Added Asia faction data

17/3/14
- Fixed and clamped slowDownFactor to fix problem when lightweight projectiles destroyed and passed through heavy materials (e.g. minigun vs armor)
- Fix: projectile trail precedes projectile and jumps ahead in steps (e.g. sniper)
- Fix: Don't reset m_ProjectileSprite when spawning a beam; fixes missing texture on beam laser

8/4/14
- disable context buttons based on affordability (dynamically)
    - material upgrade buttons
    - device upgrade buttons
- Fix: CommandInterpreter::ReceiveCreateLinkMessage wasn't taking into account the reclaim value of the existing link

9/4/14
- add repair mode with circular area of effect for structures
- reactor health bars, button jumps to reactor
- reactor button flashes when below critical threshold
- dead reactors are retained as disabled reactor bars

10/4/14
- Added EnableStructureAutoZoom flag in constants.lua to prevent annoying zooming in when right clicking a link
- Generalise control of device sprite state when neutral (e.g. to hide miner and stop the mine wheel)
    - Devices can be put into 'Idle' state when they are not owned by anyone
    - Added a list of four possible states to Device::SetSpriteState to take into account the combinations of faction and new idle state
- Fix: don't show miners when mine is under construction
- Fix: don't allow single nodes to be deleted instantly if they are foundations
- Fix: GetAttachedDevice ignored parallel links, allowing device attached nodes to be deleted in some cases
- When deleting nodes: slow scrap rate of struts to match the slowest to avoid falling structures and lost resources

11/4/14
- Fix: When new link and foundation can't be afforded at once, the link appears for a second and leaves an invisible node selected
    - No checking for affordability is done before sending to the server, so standin node is selected and it later fails
- Fix: struts won't recess under a device if they are under construction
- Fix: StructureEditor::UpdateContextMenu() crash: nodeA and nodeB were NULL, fixed condition for using mSelectedNodes
- Don't try to draw sprites that have an alpha of 0
- auto-detect open doors when hitting S

12/4/14
- Fixed building-01 tutorial
- Fixed naming of HUD items so that script functions would disable materials and devices properly

13/4/14
- Added script function to hide reactor bar panel
- Clamp reactor bar panel to the view when the HUD is hidden
- Add PopupBarHeight to constants to adjust sensitivity at bottom of screen to HUD popup
- Fix: Many DevIL errors going to Log.txt: DevIL Error 1290: could not open file (weapons/cannon/gunner.tga)
- Fixed various sprite and path errors in effects

14/4/14
- Moved core libraries to engine
- Added callbacks to allow Sprite and TextureManager to log errors via the console
- Simplified console trace history
- Disable C++ new/delete overridden operators in Release mode to improve performance
- Add -repeatload N command line option to profile loading
- Add -structure command line option to load state file with -map option
- Minor performance improvement of AnimatedTexture::GetSubFrame

16/4/14
- Fix: unterminated string when -structure not given with -map
- Refactor: remove parameters associated with the weapon type from the PNode class (e.g. m_Incendiary, sprite)
    - Move into reuseable ProjectileParams class
    - Put data into weapons/projectile_list.lua

17/4/14
- Fix: enabled flag not initialised for TextButton controls
- Fix: Weapons take a step back when upgraded
- Large construction sprite appears randomly
- Added -edit command line option (works with -map)
- Fix: cannon goes through two layers of armor & sniper projectile sometimes goes through devices (after refactor)
- Fix: still auto zooms when going from device selection to right clicking on a structure
- Fix: when sniper projectile is used on the mg the projectile sprite isn't drawn long and thin
- Apply projectile randomisation to beam

21/4/14
- Fix: screens are reset when terrain is cleared
- Fix: initialised all node, link, device variables, and Store error
- Removed perma-bracing material, updated render order of other materials
- Improved game state serialisation (with the view to seek in replays)
    - Keep live versions in memory
        - have same problem with copying pointers, vectors, etc. except global/constant ones
    - Serialise node and link objects entirely
        - Problems
            - how to avoid serialising/deserialising pointers, vectors, etc.
                - have marker variables to save/restore static data, don't put vectors inside, pointers ok
                - save/restore dynamic information (devices, links, nodes, effects, textures)
                - fix up anything else (time keepers)
            - node
                - Device (already done)
                - Sprite textures (already done)
                - Sprite clocks (already done)
                - Timer time keepers (already done)
                - node up reference node (already done)
                - vector of links (already done)
            - link
                - Triangle nodes (already done)
                - Sprite textures (already done)
                - link node pointer (already done)
                - link smoke effect (already done)
                - Fire segments vector
            - device (create new as before, then copy over simple data)
                - world
                - config
                - composite sprite time keepers
                - resource account
                - terrain
                - vector: node effects
                - animation script
            - (avoid saving state when projectiles are airborne or weapons firing (e.g. beams), fast forward from previous to seek)
- Write ReplayKeyframe messages on a regular basis when there are no projectiles
- Skip ReplayKeyframe messages during playback
- Write number of physics frames to the start of the replay file
- Add seek console/Replay command which finds and restores the next keyframe after the desired point
    - restore physics time state from ReplayKeyframe message
    - restore team resources from ReplayKeyframe message

22/4/14
- Fix: replay debug buffer start can't handle message sizes greater than 255 bytes
- restore node and device ids from keyframe, and next ids for nodes and devices
- Serialise state of random number generator
- Delay writing replay keyframes when delayed splash damage exists

24/4/14
- Replace random number generator with SimpleRandom to reduce memory/storage footprint of replay keyframes

27/4/14
- Fix: Node's Reference node and angle is recalculated on restore (no longer save ref node id)
- Fix: Recalculate m_DominantMaterial after links have been restored
- Removed dominant material from node simple data area
- Removed projectile related variables from node simple data area
- Stop writing a Loaded.lua when loading replays (goes into the user/replays folder)

29/4/14
- Don't write parallel link to structure file/replay
    - Need to preserve order of links so that m_LinkToNodeUpAngle is consistent (flag the first link and append to front)
    - Manually write NodeToLinkAngle, transfer triangle nodes and fire segments to written link

29/4/14
- Detect firesegment links in default state and avoid writing them all
- Fix: duplicate writing of links in some cases
- Turn off fog of war during replays

30/4/14
- Record a keyframe at the very beginning of a game and restore this instead of the actual spr file (no dependence on original spr file)
- Pause at the end of a replay instead of quiting
- Moved props from spr file to fwe file
- Add method to Button to turn it into a clickable timeline
    - send mouse position with click notification
    - sets progress direction
    - uses a child Button to show current position
        - (optional) if button pressed it can be dragged to seek
        - callback for release position
- Fix: nodes serialised under temporary bracing cause replay desync?
    - restoring temp bracing timer with wrong time keeper

1/5/14
- Reset reference node after all links have been sorted
- Don't recalculate the reference node angle on restore, as it ends up being different (must be calculated when the nodes are in different positions)
- Use the closest replay keyframe to restore from
- Fix: frame tracking when searching for a keyframe, causes erroneous selection towards the end of the replay

1/5/14
- ESC to deselect, F1 for pause menu, ESC resumes
- Disabled devices allow selection of structure with left mouse
- Fix: Devices sometimes not snapping nicely to structures & ground
    - Disabled node snap when device build is possible

2/5/14
- Fix: selected reactor then couldn't select any structure
    - If you can't build the device (e.g. reactor), reset the link selection angle and allow node selection
    - left click on structures for devices switches to structure editor, on space deselects

3/5/14
- Show device preview in replay

5/5/14
- Preview turbine blade animation in replay, independently for multiple clients
- Added DebugSwitches.h to speed loading and improve performance on slow test machine
- Don't show client preview device cost text for team-mates, don't show vis angles in replays
- Escape deselects device type

6/5/14
- double click while fully zoomed in restores the overview screen
- increase scroll rate for mouse and keyboard
- make error noise and flash suitable nodes when trying to build a chain
- add barebones mod to remove everything except a few buildable items (to speed loading time while testing)
- Add mini-gun to barebones mod and enable upgrades

7/5/14
- Compact render order to prevent unrendered materials and make it easier to mod materials
- Allow debug switch items to be controlled by mod
    - over-ride background before it's loaded
    - fix all nodes
    - disable effects
    - disable replay keyframes
    - change factions (team factions can be set in the constants script)
    - add to barebones
- Allow disabling of terrain texture loading

8/5/14
- Default terrain colour constant
    - barebones: New blocks are black but turn brown when map is reloaded
- Fix: Alternate Button constructor doesn't set mTimeline or mTimelinePointer
- Desync recovery
    - Ensure keyframe timer is based on the physics clock
    - Allow CMFile write mode to seek (automatically trims when a new write occurs)
        - added write_end member to track where writing has stopped
    - Load most recent keyframe before desync
- Fix: flush the command queue to prevent back up of new commands after recover
- Fix: selection is busted for a while, force edit mode on recover
    
9/5/14
- Fix: restore default material instead of no-material on recover
- Fix: first keyframe can be written on a different frame
    - Moved distribute tick commands back to original position to avoid an extra frame advance when waiting for tick end
- Server dictates the frequency of keyframe generation on map load (override constants value)
- Add desync auto-recover option to constants (host over-rides clients)

9/5/14
- Instant replay
    - Remember the time that the game was declared won
    - Add instant replay to the pause menu at the end of game
    - On press, end recording and switch to replay/observer mode
    - Seek to some time before the game was won
    - Show the replay HUD
    - Don't replicate pause to clients once game has been won

10/5/14
- Allow non-host players to linger in game once host has quit (to view replays)
    - disable client desync after victory to allow clients to go into replay mode
    - clients in instant replay ignore client desyncs, and ignore changes to client state
    - update chatroom status of replaying clients

15/5/14
- When entering instant replay, the ClientManager needs to have a replay client database installed which does not modify the actual one (held by the Multiplayer object)
    - notifications of changes to the actual database continue via the Console
    - The replay client database must be serialised and then modified by subsequent client select and client status messages
- Test: clients will not all quit with host (they have to leave the game of their own will after it's ended, so they can watch the replay)
- Fix: Crash when host quits to menu and client starts a replay
- Integrated replay HUD textures
- Added replay HUD button controls for skip back & forward, pause, play, speed up & down
- Added replay speed readout
- Fix: crash at CommandInterpreter:1411 while seeking within replay made from Sandbox
    - ExitDebugMode was clearing the promiscuous flag
- Show structure build icons during replays
- Write which mode (release or debug) a replay was recorded in, and if different during playback, disable verification of ticks

16/5/14
- Center replay HUD
- Fix: guntest replay goes out of sync constantly (Resources)
    - Check draw on neutral team resources
- Fix: Remote/replay client weapon previews can face the wrong way

18/5/14
- show/hide replay console like HUD
- Fix: If seeking to a future keyframes that doesn't exist, don't seek
- Add constant to control HUD slide speed
- Fix: Replay timeline pointer and bar can overshoot

19/5/14
- Fix: \me chat command not working
    - Added chat command type to console commands, which just directs the whole string the chat handler, if installed
- Add a temporary drop of the inactive console to display chat lines, important notifications, etc.
- Chat messages are recorded to and restored from replays
- Don't echo chat in console of source client
- Add constants for temp console drop
- Console parameters can be set in constants.lua during Root object construction
- Colours can be read directly from a Store object
- Remove obsolete Link::m_OwnerID 
- Fix: crash when editing (replay HUD height when it wasn't set up)
- Reduced ricochet durations and increased material variation for armor
- Fix: Debug mode mouse movements not showing up in desync DebugDump
    - Broken debug command replay parsing
- Fix: Debug mode mouse visualisation broken with multiple cursors
    - No longer goes into promiscuous mode for debugging
- Fix: Debug command list was broken once on desync
    - New and deleted messages
- Fix: right click on link just as it either finished deleting or noded vibrated on ground to destruction
    - UpdateContextMenu() crash L454, link is invalid
    - when link is destroyed clear associated snap state immediately (should be safe to inspect link if snapped to link)

20/5/14
- Fix: fullscreen console shows no history
- Added key to toggle fullscreen console (Ctrl+~)
- Fix: crash when clicking pause while replay timeline pointer is over the button
    - IsOverClickableControl doesn't set control pointer for some controls
- Different icon or colour for when destroying, repairing, etc.
- Colour resource text to show which is lacking
    - build devices
    - build structures
    - fire weapons
- Fix: crash when context menu updates on a destroyed link
- Prevent co-linear structures (select instead)

21/5/14
- Scale aiming circles with spotter bonus
- Fix: spotter visibility calculation is off (high visibility until left arc closed off, then low when right opened up)
    - Add spotter efficiency values for left and right to resource account
    - calculate visibility angles for spotters, efficiency calculated relative to full visibility
    - GetMin/MaxFireRadius inspects direction

23/5/14
- Added timescale texture to replay hud, lengthened timeline
- Cropped replay timeline peg to avoid obscuring buttons below it
- Prevent trajectory calculation in Weapon::SetTargetPoint when simply spawning a projectile
- Draw influencing spotters' visibility arcs when using assisted weapons
- Prevent co-linear structures when creating nodes
- Make sure reactor can't be repaired (added repairable flag to device)
- Fix: don't draw spotter vis arc for selected weapon

24/5/14
- Moved static weapon data to DeviceSlot

26/5/14
- Added simplified serialisation system for devices & weapons, to ease changes to class member layout
    - Writes 'detailed' flag ahead of device list
    - Only used to save map data, not replay keyframes, undo stack or clipboard
- Moved more static weapon data to DeviceSlot

- Removed obsolete operator members from Weapon
- Re-arranged Weapon members for compact data layout
- Fix: If a client quits prematurely it causes a replay desync
    - Front end handles client status message when in play, so change in client db is consistent with command frame
- Fix: If a client quits while it has a device selected other clients cannot select that device
- Fix: client left prematurely, instant replay is broken: instant desync, client name is garbage
    - client count written to replay didn't take client state into account
- Fix: replay timeline is not functioning in instant replay
    - Replay was deactivated
- Fix: replay HUD is hidden when reactor explodes in instant replay
    - ReactorsAreCritical tries to enter game over mode
- Fix: pause doesn't work during instant replay
- Fix: Instant replay doesn't resume when pause menu is closed
- Move ReloadTime to DeviceSlot
- Remove mPhysicsRandNextOffset

27/5/14
- Game balancing
    - Increase fire spread & damage by 100%
    - Reduce missile bounding circle by ~25%
    - Make swarm missile cheaper to shoot by 50%
    - Slow repair rate by 50%
- Removed filename stub from map sets
- AI battle top level menu
- Turn off promiscuous mode in AI battle
- Show victory/defeat in AI battle
- AI applies difficulty set in Battle screen
- Editor sends SetTeam to World to allow player to use team 2 in Battle

28/5/14
- Serialise lua mission and ai script state in replays
    - write out data
    - read in original script
    - read in altered data over the top
- All serialised scripts put dynamic data in the 'data' table
- Fix: replay desync by AI closing or opening doors after keyframe restore
    - Need to serialise doors associated with weapons

29/5/14
- TrackedProjectiles moved into data table to fix ocassional replay desync with AI
- No state change for stand-in links

30/5/14
- Fix: Random generator desync when playing against AI
    - AI script must be consuming random numbers
- Fix: Resource/Link state replay desync when playing against AI
    - Team resources are saved/restored correctly
    - Happens almost immediately after restoration
    - The AI team has fewer resources 4 frames after restoration of both energy and metal (greater difference in energy)
    - No commands in the queue
    - No sign of repairs in progress
    - AI sources: two wind turbines (blocked on the left), one mine, one reactor
    - AI drains: one mine (energy)
    - Most likely to be every source incorrectly applied
    - Solutions:
        - AI was trying to create nodes and links on non-existent nodes when large parts of the fort were destroyed
        - PlaceNode inserts the new node into the node array before calling ConnectNodes with it
- Add SimpleRandom seed to the Time checksum, to help instantly identify the source of deviation in random number generation
- Logging details of door_control message
- AI can't put a link in repair state if it's in construction or warmup states
- Scripts are passed the game time in frames, not seconds, for loss-less serialisation of ScheduleCall time
- Standin node is marked as Standin from the beginning
- PhysicsManager::Reset:
    - Projectiles are deleted as ordinary node objects
    - The MeshProjectile array reset at once
    - Standin node is deleted and re-added
    - ...Avoids calls to the scripts when seeking within a replay
- Check for inconsistent state on RestoreLinks
- Minor optimisation in PhysicsManager::ApplyPhysics
- In PhysicsManager::ApplyDamageToStructure check for inconsistent hitpoints
- In PhysicsManager::UpdateLinkState, set visited flag and only manipulate links once, instead of twice for the parallel link
    - Avoids a disparity caused when links are being repaired and resources are low
- PhysicsManager::LogLinkStates checks for consistency between link and parallel link states
- PhysicsManager::BreakStructure new link is forced Idle
- PhysicsManager::PlaceNode new node is inserted into m_Nodes before ConnectNodes is called
- PhysicsManager::ReLinkNodes checks for nodes already being linked, and linking to nodes with a zero id (not inserted)
- PhysicsManager::UnlinkNodes checks that a link is removed from both nodes
- Added PhysicsManager::WeakenAllLinks(), PhysicsManager::LogLinkStates(), and PhysicsManager::ParallelLinksConsistent()
- World::RestoreState always reloads the world state so that AI has an opportunity to analyse the existing structure
- Checksums are added to each keyframe and verified after loading to identify disparities caused by serialisation system
- Mission and AI script states are saved and restored from keyframes
- Door node pairs associated with Weapons are serialised to allow consistent use by AI scripts
- JointResourceAccounts can be set to trace mode to determine the sequence of transactions
- Reduced stiffness of cable material and global spring damping coefficient, increased drag: cables become stable
- AI does not try to create nodes or links when the source node (node A) doesn't exist
    - Prevents some inconsistent node/link state when damage to AI fort is great
- Set all temporary variables to local in ai.lua
- Added ai.lua InsertDestroyedLink function because ScheduleCall can't handle calls to functions kept within a table (e.g. table.insert), or with a parameter pointing to a table
- ScheduleCalls table put in data.ScheduledCalls
    - no longer stores actual function pointer and looks it up when time is due (required for reliable serialisation)
- Added blank Forts to Barebones, Broadsides, Under Siege to enable AI battles
- Added trace flag to SimpleRandom to allow access to the generator to be logged and compared between game & replay
- Store can be loaded from and saved directly to a CMFile, allowing script state to be serialised within a replay file
- CMFile implements LuaStateOutFile to allow LuaPlus to directly write to the memory buffer
- CMFile uses secure calls

2/6/14
- Reduced tolerance for zero v1 in SimpleRandom::Normal
- Fix: Cannon projectile caused replay desync under AI control
    - Inconsistent result of Weapon::SetTargetPointResolveTrajectory several decimal places down
    - Solution: reduce precision of angle to drop significant digits

- Fix: TryFireGun inspects device that no longer exists
    - Add DeviceExists script function to test this
- Reduce keyframe rate
- Move spring damping into material
- Make node air drag the maximum of attached material drags
- Write AI difficulty level to/read from replay file
- Fix: reset air drag to something lower when cable nodes detach
- Communicate physics frame rate to scripts

3/6/14
- Fix: activation of faction mods is too late to take effect
- Fix: beam weapons should make fire sound independently of impact and have an end sound effect
- Create an effect for each beam segment end, based on the collision material
    - carry these over to the next frame as far as possible
        - if the effect type changes for that segment then destroy it and create an appropriate new effect, and for any following
    - update effect position and normal with beam projection
- Sound effects can be disabled (cancelled)
- Beam impact sound effect loops
- Fix: SparkSet effect destructor only disables trail effect if it still exists

6/6/14
- Added 'effects' console var which can be toggled to disable effects
- Added log_effects console command to enumerate currently active effects, their positions, and active particles
- Fix: Particles width and height can't become less than zero
- Fix: White fullscreen graphic
    - Started happening rapidly and persistently after a cannon was destroyed and set off a chain reaction
    - Stopped after the top of the Broadsides fort was destroyed including some struts on fire
    - Sometimes black and not fading
    - some particles are valid but have apparently invalid width & height
    - May come from seeking to a point where smoke emitters are active or producted by reactor steam effects
        Restoring replay key frame at physics frame 12 time 0.000
        Restoring replay key frame at physics frame 2724 time 0.000
    - Solution: Device smoke emitter was not being copied from DeviceSlot structure to preview device

7/6/14
- Split checksums into team 1 and team 2 to aide indentification of the source of desyncs
- Client Sync state is now an unsigned short bit array; multiple flags can be set to indicate all of the items that have gone out of sync
- Slave weappons can be aimed and fired while the master is locked
- Fix: device repair message was charging the full repair cost and then charging pro-rata as the repair progressed (even when the device was already in repair mode)

8/6/14
- Fix: replay desync human vs AI
    - Trajectory calculation was inconsistent due to sprite not having its barrel angle set properly
    - Set the barrel angle on sprite in weapon deserialisation (before calculating AI trajectory)
- Fix: replay desync
    - Rounds remaining was not serialised so delayed weapons would sometimes fail to fire after deserialisation
- Fix: replay desync
    - Multiple spawn projectile messages could be sent before a weapon was locked; secondary ones would clear the locked flag and allow the weapon to track the cursor
    - Don't send spawn projectile messages once a weapon is locked
- Fix: replay desync
    - device impact by incendiary weapons caused inconsistent amounts of damage
    - Re-ordering of links caused different numbers of segments to detected as on fire under the device
    - Consistent calculation of fire segments regardless of link direction
- Fix: door control message handler did not check if the nodes were still valid

9/6/14
- Node and links have a simple and detailed serialisation to allow easy modification of data
- Fix: replay desync
    - Device damage from links on fire (link re-ordering)
    - Store primary and secondary link flag to ensure links are serialised in the same order they are created

10/6/14
- Save replay on entering instant replay
- Fix: weapon groups visible in instant replay & cause crash
    - Hide weapon groups on entering game over mode
- Added IsDeviceRepairable script function, AI does not try and cannot repair non-repairable devices
- Unified repair logic into PlayerController
- Area + device repair when zoomed out far enough
- Increased reactor power generation and decreased turbine generation to help underdog
- Make cable lighter
- Prevent weapons being fired during repair and scrap
- Prevent weapons being aimed during repair and scrap
- Increase max length of cable
- Fix: cable produces intermediate nodes when seeking (detailed serialisation issue)
- Fix: repair icon for devices is still construction type
- Fix: improve scrap icon

11/6/14
- Fix: Initial screens in Vs Computer wrong
- Order of screens goes home -> overview -> enemy
- Any change to the view resets the user screen index so the next cycle takes the view back home
- Fix: Don't flash nodes that can't be linked to due to alignment
- Increase size of block icon, fix render order vs. construction icons
- Draw extended link length from nodes with one link

11/6/14
- Fix: Team1/host cursor not moving during replay
- Observer home screen should be overview
- Fix: Reactor smoke appears at origin when seeking (mNodeEffects are updated as soon as device position set)
- Fix: can't replace materials by building over them
- Fix: break node temporary brace in only link is destroyed

12/6/14
- Open doors for a suitable spotter when launching a missile if there isn't one on the target already
- Draw dashed line when a spotter can't reach the target due to obstructing doors

15/6/14
- Fix: If you scrap a device while it's under construction, the device is instantly built instead of getting destroyed
    - CoH: construction doesn't go backwards if neglected, requires engineers to progress, instant reclaim
    - TA: construction goes backwards if neglected, requires construction bots to progress, reclaim by bots (causes damage)
    - Need a percent constructed value, which allows devices to be switched between construction and scrapping
        - Paid for when started
        - Refunded when scrapped
        - Non-functional when partially complete
        - When partially complete, can only be in contruct or scrap mode
        - Can take different amounts of time to construct/scrap
- Fix: teams don't change in Sandbox until node or device selected
- Add lock graphic to unavailable weapons

16/6/14
- Test: co-op multiplayer target painting still works
    - Fix: Cursor was being set to normal by subsequent weapons
- Fix: unable to select HUD icon after right clicking
- Fix: UI not clear/need tool tips
    - Tool tips above items panel with description, best use & requirements
- Prevent device & link repair when in construction, scrap, delete, warmup states
- Save lua scripts during desync
- Allow non-repairable weapons to repair their platform (e.g. reactor); show spanner icon

18/6/14
- Write a table of material names at the head of the link section, and refer to that table by index to save writing/reading a material name for every link
- Fix: Weapons sometimes face wrong way during preview
    - take initial pan angle from currently selected weapon
    - set preview position from mouse and apply direction constraint while ignoring visibility when changing weapon to build
- Fix: Revert after game caused non-sensical AI construction, instant replay causes replay desync
    - Seek to beginning of replay, like a desync recovery
- Revert is only offered in editor, and restart now does what revert did during play
- Fix: View returns to overview when seeking replay
- Integrate new icons, node highlight and scrap icon
- Fix: Prevent the picking of devices that don't satisfy prerequisites
- Fix: If you immediately select a locked device it is still highlighted in the HUD
- Fix: if any attached links are being deleted when a node is selected for deletion, those deletions are cancelled

21/6/14
- Added PageEffect, loads and shows a UI page
- Added transaction.lua effect which uses a PageEffect to show costs and benefits
- Building and scrapping devices and links shows transactions
- Firing weapons shows transaction
- Beam laser accumulates resources spent on firing and shows expense at the end
- Fix: don't show temp bracing ring for enemy
- Fix: Spotters work during repair
- Increased price of advanced buildings, fixed repair costs
- Add plus symbol to positive transactions
- Fix: devices item panel not centering icons properly
- Fix: mouse cursor drawn incorrectly when snapped to something in editor, or console active
- Fix: oscillating cursor when zoomed out, cursor is in aiming arc and close to another device
- Fix: background material not used when making new node through a device

23/6/14
- Add AI difficulty setting to chatroom

24/6/14
- Disabled some key events, some that may cause desync and other problems during online play
- Send client key events to other clients (via host), display these on the cursor path when debugging
- Fix: CommandInterpreter::ReceiveCreateDeviceMessage will foreground bg struts that were not temporarily backgrounded
- Fix: Disable fog of war while in debug mode

25/6/14
- Fix: Turn off texture edge repeat for background tiles that cause horizontal lines?
- Allow texture flags to be changed after loading
- Static keeps flags for tiling in independent directions
- UIEditor allows Tile S and Tile T to be set for different static controls, saves as flags
- Fix: weapons now difficult to select when zoomed out with another weapon selected
    - Separate check for snapped devices from inside aiming circle variable
- If snapped to grid, attempt to snap to nodes near that grid point, to avoid new nodes adjacent to existing nodes

26/6/14
- Fix: show dashed spotter laser even if door obscures the barrel

27/6/14
- Test: what happens when the laser hits an enemy door?
- Freeze device state if team becomes neutral

27/6/14
- Freeze link state if team becomes neutral
    - Change m_ConstructionTimer into m_ConstructionProgress/Rate floats
- ILinkVisitor can implement a LinkPassable callback which blocks the search if false is returned
    - Tested out blocking fort ownership when blocked by background bracing, doors and shields, but was frustrating/confusing/limiting

29/6/14
- Added powered flag to nodes and links
- Devices/weapons turn neutral when there's no solid link
- Links can't be repaired when unpowered
- Doors freeze when unpowered
- Repair on solid links stops when unpowered

30/6/14
- Fix: clients forts expand when host pauses after results
    - Don't pause simulation with pause menu after game over
    - When host quits or enters instant replay all clients are forced to pause simulation
    - pause is re-enabled (with replication off) when client or host enters instant replay
- Fix: clear selection when host pauses
- Fix: Client quiting while host is watching replay is not reflected in the chatroom status
    - host sets self to replay state when entering instant replay
    - client status messages received on the network are handled by Multiplayer when a replay is in progress
- Fix: Mines are not powered
- Fix: A series of mines can't be powered under a fort because the foundations aren't powered
    - ground devices can be powered if an adjacent node to a foundation is powered
- Fix: Can't paint laser targets on the ground
    - Always use the spotter if it's the last one available
    - Don't consider a collision an obstacle if it's beyond the target
- Fix: Weapon::IsEnemyInDirection: Don't consider the neutral team an enemy unless there's no actual enemy

2/7/14
- Optimise: Weapon::CalculateVisibility() shouldn't need to cast a ray to the terrain every frame
    - it doesn't change very much, only if the fort is moving dramatically
    - the precise value doesn't matter too much
    - Store it when the weapon is built and use it thereafter?
- Allow physics graph to be shown offline, rename and reorder graphs
- Place graphs relative to right hand of screen
- Optimise: send client mouse position separately to other selection state
- Fix: clear structure checksum before use to prevent resource desyncs indicating structure desyncs too
- Desync: Don't change the resource account of preview devices
- Fix: replay desync when connecting to a neutral structure with a mine
    - ReactorsClaimForts was added twice during Vs Computer games
- Fix: Visibility off the charts when no collision with view floor (clamped before calculating visibility)
- Map: added view/wind floor to Broadsides

4/7/14
- Fix: cannon bullet projectiles jumps during impact

6/7/14
- Allow link construction when in promiscuous mode
- Fix: can't paint dashed laser if the sniper is too close to the door

7/7/14
- Fix: Effects not populating the sorted list consistently (flashing transaction effect)
    - Expiry of an effect prevented the next one from updating
- Fix: door shut effect played twice due to parallel links being revisited
- Fire effect is cancelled on weapon destruction
- Free particles are assigned a unique id to allow them to be destroyed
- SpriteEffect::Cancel destroys the free particle when KillParticleOnEffectCancel is true
- Moved machinegun muzzle flash into machinegun.lua so it remains attached to the weapon when it's moving
- Fix: Machinegun can move before projectiles have finished emission
    - Weapon is unlocked from multiple projectile weapons only after the period of the last projectile has elapsed
- Fix: can't deselect a device type when grid is enabled

8/7/14
- Desync: Can't aim slaves that do not have an enemy in the master's direction, but still fires
    - Prevent panning in that direction and firing
- Fix: right facing weapons can take a fire angle that faces them backwards
    - One of the angle constraints was limited to Pi/2, should be Pi
- Updated mushroom cloud to approximate Nick's mockup
- Fix: stopped lasers following mouse cursor
- Fix: replay desync; door position/state out of sync on parallel links
- Show block when trying to replace materials via context menu and there is a device in the way
- Prevent and show block when trying to build a device on an unpowered link
- Add reserved flag for sound effects that absolutely must be played

9/7/14
- Add priority system for sounds, discard sound allowance system
- Investigate spark allowance system... discard
- Exposed parameters that affect wind flow efficiency calculation
- Added windy mod which makes canyon maps feasible
- Tweak mushroom cloud effect
- Fix: cable blocking wind
- Abyss map: Moved teams apart, put reactor out on a limb, good mining site up high
- Vanilla map: set lower most ground block to be owned by None instead of background, to prevent things showing on top of it
- Fix: grid colour not consistent/always visible
- Draw aiming gizmo as arc strip with outline, adjusted colours to suit
- Set lines to be smooth
- Set polygons to be smooth when rendering links

10/7/14
- Prevent construction from unpowered nodes
- Allow bg bracing to conduct power if there is a device overlapping them
- Materials have a flag ConductsPower to set conductivity

11/7/14
- Stop showing transaction and construction effects, and temp bracing clock (while paused) in editor
- Use armor_bullet_hit for minigun and snipers impact with armor and door
- Tone down bracing_hit_bullet volume and use it for mg, minigun, snipers
- Show current number of fx and sfx next to fps
- Put FMod max channels into constants.lua and increased from 32 to 64 to avoid loss of sound

12/7/14
- All material collision types have defaults
- Added penetrate class of material collisions; ap-sniper has effects for penetration of armor, bracing, etc.
- Fix: projectile animation smooth when penetrating links
- Weapons types can have limits to how many can be grouped; snipers can only have one per group
- Holding Ctrl while resizing a prop will lock it to the native aspect

13/7/14
- Add powered flags to structure checksum, removed team id
- Desync: link background preview applied to actual wind exposure calculation and spotter visibility
    - Fix add a flag to PhysicsManager::GetVisibleAngles that only applies the preview if set
- Fix: preview wind exposure animation forces doors open
- Fix: can't build a device on a link in editor just after building

14/7/14
- Weapon cool down icon
- Fix: force preview weapons to be ready to fire and instances to start unready
- Fix: large quick bounding boxes can block snipers from painting targets
- Fix: can't build with simulation running in editor
- Increased cost and build time of mine and mine2 so they are not so much of a no-brainer
- Rebuilt Abyss map with mirrored terrain and neat primary edge
- Increased reload time of AP sniper
- Added Long Shot map

15/7/14
- Add a single weapon arc radius multiplier to allow global adjustment to map scale, added multiplier to longrange mod, used in Long Shot map
- Fix: mirror structure functions causes some joints to break and do not mirror foundations and weapons
- Add yelps when weapons are damaged, alarm when reactor is damaged (with minimum delay until the next one)

16/7/14
- Number each connected graph, starting from reactors, then isolated nodes
    - Create a structure object for reactor-connected graph
    - Draw reactor-connected structures first, then disconnected structures and their devices
        - each structure is made up of different layers, so layers must be drawn separately for each 
        - separated by one-off elements (behind terrain devices, mid-ground effects, terrain)
        - draw reactor attached structures as before
        - draw any others just before the terrain foreground is rendered

17/7/14
- Fix: Brian unable to receive ping messages, Tim unable to directly connect to Brian's ip address
    - May be due to multiple addresses on one or both machines
    - Bind to all local ip addresses, not just the default
- Calculate and low pass filter stress score for reactor-connected structures, based on maximum and average strut rotation
- Fade in and out different levels of groaning sounds based on stress thresholds

18/7/14
- Detect rapidly developing instability, make effect
- Prevent collapse from persisting long after detachment, detect return to stability and stop any high level groaning
- TriggerSound script function returns the channel to allow the sound to be queried and stopped from script
- Added EndEffect script call to effect scripts
- Add Store file access to Debug used file list

20/7/14
- Add hash table of samples loaded from script, try to look them up instead of loading every time a script or sound effect loads a sound
- Fix: make sure script spawned effects are cancelled with all other effects on return to menu/seek/revert, etc.
- Fix: initialisation of stress delta was causing high initial groan level

21/7/14
- Physics frame advance (A key) only operates if the simulation is already paused
- Fix: mortar barrel can point down and get stuck there
- Fix: mortars and their previews start with their barrel at an impossible angle
- Replay timeline markers
    - Add a button at the nearest keyframe when B is pressed
    - Remove bookmark if there's one there already
    - Add the keyframe timeline position to the userdata of the button
    - Restore the timeline position when the button is pressed
- Fix: structures are not drawn immediately when seeking
- Fix: turned off device debugging info
- Fix: refreshed bracing plates for isolated nodes

22/7/14
- Desync: incendiary mortar keyframe state was repair, but it shouldn't have been
- Added Asia faction for incendiary mortar

23/7/14
- Fix: Standin node not being displayed
- Reduced bounding box height of wind turbines to make it easier to build upper levels
- Repair area applies at the cursor no matter what is selected or highlighted
- Links do not block enemy fire when being scrapped
- Can't repair a link being built or scrapped
- Scrap progress is anti-clockwise, re-construction picks up where scrap left off
- Reduced weight of bracing and armor based materials by ~17% to allow for higher/bigger forts
- Increase link loss threshold to avoid false positives during scrapping
- Paint the target where the laser falls, rather than where the cursor is
- Draw a red dot where the laser hits
- Flash links that are extremely stressed

24/7/14
- Fix: holes appeared in Nick's fort
    - old node selected when the create node message came in
    - only select the new node if the stand-in node is selected (assuming it's the standin for the one now built)
- Fix: clients can't change the time rate in instant replay
- Allow shift to group nodes as well
- Reduce volume in fade in point of structure groans
- Make laser easier to aim: increase aiming arc, draw direction line

25/7/14
- Don't show construction preview if there is a link aligned with it
- Intersect laser ray with background bracing first, and then continue on but without background bracing
- Fix: neutral structures are drawn on top of effects (e.g. mushroom cloud)
- Change ownership of the beam when it's deflected from an enemy shield so it does damage to friendly background struts
- Fix: beam effect continues on the ground for a while when the beam is moving around rapidly over ground (old effect not ended)
    - Reduce age of ground hit effect for laser to 1
- Mortars draw speed arc with percentage read out
- Fix: corrected beam damage when a damage function is applied

29/7/14
- Make laser apply damage to open doors in the same way as background bracing

1/8/14
- Add extra tiles to background

4/8/14
- Make appropriate noises when building different materials
- Add sound and dust effect for creating foundations
- Fix: one of a group of missiles will aim at the cursor, not the laser dot
- Fix: can't build in editor while paused

5/8/14
- Fix: spotter's door not automatically opened

6/8/14
- Only show angles that player can shoot from in aiming gizmo
    - The distance to test to is less than the maximum fire radius
- DeviceEditor remembers the doors of destroyed weapons and allows them to be closed

7/8/14
- Allow link to be created between standin node and reinforced node
    - local client caches link requests with standin node and creates local standin links
    - when the node is actually created the link request is sent (causes desync)
    - requests and links are cancelled if the node creation fails
    - re-create the standin link when the real node is made
    - complexity added in caching requests
- Fix: prevent snapping to bb when previewing device construction

9/8/14
- Show tip for building errors
- Effect script TriggerSound passes bool to indicate whether the sound should be played for enemies
- Added multiplayer.lua map subset
- Added empty forts so AI could run in multiplayer maps
- Added flags to rules.lua to turn off ReactorsAreCritical and ReactorsClaimForts to allow the tutorial to run
- Stopped disabling all materials at the end of the tutorial to prevent the controls being disabled

11/8/14
- Fix: Turbine angle per segment low
- Fix: MG min fire radius
- Hide context on repair
- Fix: Preview link not extended to extra length from isolated node
- Fix: Crash when replacing strut with cable then bracing
    - Nodes are detected as connected at the start of RelinkNodes using PNode::IsLinkedTo
    - Reclaim cables when replacing the link
    - Prevent struts being replaced with ropes

12/8/14
- Fix: Sniper projectile doesn't fade out after deflect up
- Cable drawn on top of other materials
- Drag to replace materials
- Added tool tips to making struts too long or too short
- Removed some unnecessary OpenGL state changes from background

16/8/14
- Updated fmod version to 3.75
- Fix: FMod fails to reset reserved channel state when channel ceases playback, leading to failure to allocate new channels
    - Clear reserved flag for every channel at the end of explosion lifetime
- Fix: Odd number of link states (don't include standin nodes/links in the state count)
- ListBox SetItemLimit can prevent unlimited accumulation of items (earliest added item is removed)
- Limit the number of items in console to prevent increase of memory allocation and console rendering

17/8/14
- Fix: if enemy is only in one direction then ignore visibility arcs; always face the enemy
- Device preview team is set in DE update to ensure correction faction is used
- Fix: weapon previews facing wrong way for replay observer

18/8/14
- Add error checking and recessing of material replacement mouse drag
- Fix: Could not shoot both grouped swarming missiles, resources sufficient (non-host client).
    - could pan angle of missile launchers be different?
    - force pan angle of ground devices?
    - ignore pan angle when firing slaves for ground devices
- Background materials above missile launcher
- Reduce angle/swerving of missiles during ReachingCruise phase to allow for tight missile chutes
- Fix: Crash when mesh projectile trail has expired ahead of collision

19/8/14
- Fix: Autosize system screens when watching replays, seeking changes screen, empty fort causes invalid screen
- rapidfire mod enabled by default in Edit mode
- Fix: cable highlight not showing
- Allow context menu to provide background bracing->armor
- Don't show armor, door or background bracing options in context menu if link is occupied by a device
- Hide tool tips before showing world

20/8/14
- Preload all wav and mp3 samples
- Check that mods can customise sounds and effects, add 'example' mod to demonstrate how various things can be done
- S shut doors highlighted by the mouse in structure editor
- Reduce/unify scrap periods for devices and weapons
- Select base level device/weapon type to build when picking an upgraded version

21/8/14
- Show ground tab in editor at startup
- Hide details panel in terrain and prop editor
- Fix: host replays desync (clients) when a non-host client views instant replay before the host
    - Fix a loop based on number of valid clients
    - Reset client slots that aren't filled from the replay to prevent them lingering
    - roll client_replay back into client_status message to simplify code
- Fix: delete original game data when entering instant replay and switching to a new client database (memory leak)
- Stop showing node context menu when left clicking existing selection as it can easily cause the player to delete it (the only option)

23/8/14
- Fix: AI mine was raised off the ground when rebuilt during a game in Vanilla
    - added separate function for getting the center of a device used for targeting
- Fix: Replay preview weapon sometimes facing the wrong way

24/8/14
- Remove damage highlighting mode (V key)

26/8/14
- Handle multiple overlapping doors in door shutter angle calculation
    - phase 1: use shutters to occlude full arc
    - phase 2: invert the visible angles to get the potential door shutter angles
    - phase 3: use solid struts to occlude door shutter angles
- Change cursor to open door icon if that angle will hit a door
    - cast ray from barrel, if it hits a door, turn the cursor into the door-open cursor

27/8/14
- Fix: Random number generator affected locally by test for door obstruction, causing desync
- Weapon blocked and low resources icons
- Weapon icons work with missile launcher
- Allow spotter vis arc rendering to be configured by script
- Add mouse pan cursor

28/8/14
- Missile mouse cursor is updated even if it doesn't have an assigned spotter
- Add mouse cursor state to client selection and switch remote cursors
    - Don't draw laser line for missile unless cursor is in target mode
- Multithreaded physics (optional)
    - Create 3 additional threads in the PhysicsManager
    - These threads are assigned a team (Team1, Team2 or None) and wait for a signal to run ApplyPhysics for their team
    - Main thread signals threads to start and waits for them all to finish
    - Physics.Threaded enables/disables it
- Optimise: CalculateEfficiency was being called for every turbine every physics frame
    - Now updates on a round-robin fashion to reduce peak load
- Optimise: ReactorsClaimForts device intersection with structures to find overlapping background bracing was expensive
    - Mark recessed structured overlapping device bounding circles only, (no inefficient while loop)
- Keys to toggle mouse cursors and fps readout (F7, F8)
- Name tags toggle changed to F6

29/8/14
- Optimise: Set a maximum refresh rate for the loading screen, to avoid waiting for vertical sync. Improves loading time from 14s to 1s.
- Added critical section around Debug Trace commands
- Optimise: simplified Matrix::GenerateRotationMatrix to only use z
- Optimise: PNode::GetStandInLinkTo and PNode::GetLinkTo
- Optimise: PhysicsManager::DrawLinks
- Optimise: favour speed

1/9/14
- Fix: commented SetPriorityClass as it caused a large decrease in performance on Windows XP (at least the slow Dell one)
- Desync: structures, devices (position/node desync)
    - One player broke, the other didn't
    - BreakStructure on a link with a standin link on the other end caused the standin link to be considered the reference link in UnlinkNodes
        -> m_LinkToNodeAngle was set to a different value to when there was no standin link present, causing the link to break instantly for the local client
- Added neutral team link colour to constants
- Fix: Don't adjust colour of standin links
- Fix: 2 missiles used by 2 team-mates cause:
    - Both snipers spot for client 0 if one door is shut (one dashed)
    - If client 0 then blocks both spotters the second spotter will make a dashed line for client 1 but won't aim the sniper at it

2/9/14
- add client username to command log for client_select messages

3/9/14
- Hold Alt key to fire grouped weapons in round robin
    - skip to next weapon if one is blocked
    - show cursor of least obstructed slave
- Fix: slave mortar power not copied from master

4/9/14
- Fix: SetTargetPointResolveTrajectory could not aim a laser pointing to the left
- Fix: Slave mini-gun doesn't aim if master is actively shooting
- Fix: AI not using heavy weapons (e.g. in UnderSiege)
- Fix: Won't open misile door with mouse click

9/9/14
- Fix: Editor undo changes camera
- Fix: replay seek can fail to move replay if there is a long sequence of projectiles

12/9/14
- Fix: door struts become inconsistent if they are a secondary link to a breaking node (causes replay seek desync)
- Fix: replay desync in Skylands toward the end, where a laser takes out a battery frame 42209
    - Swinging structure from up-side-down fixed node was creating large numbers of nodes via BreakStructure
    - This caused the fire segments of these links to be lost somehow when writing to the replay keyframe
    - Now broken nodes are prevented from snapping to the ground
        - and jump away from the ground surface if they were fixed to prevent their failure to create

17/9/14
- Added -/+ key bindings that call ExpandOrContractWorld (move everything towards or away from the mouse)
- Fix: weapons not aiming in replays
    - was using the current cursor position instead of selection position in client's game data

20/9/14
- Incendiary mortar sets background struts alight as they're passing through
- Fire travels faster on background bracing and cable
- Impact force not applied to background materials (background bracing and cable) to prevent lightweight cable flipping out when hit by laser
- Prevent damaged structure preview and conversion when recession target material has different hitpoints to the original

21/9/14
- ReactorsClaimForts uses ConductsPower flag to prevent changing ownership of structures
    - unselectable nodes conduct power so that non-conductive struts are selectable (e.g. cable)
- Show viable area for ground devices
    - Trim all viable surfaces based on slope then proximity to foundations
- Fix: client previews are drawn when device is selected (but not weapon)

24/9/14
- Another pass on the mushroom cloud to adhere to Nick's mockup
- Fix: drawing grid slows down frame rate dramatically (turned off smooth lines)
- Fix: deleting cable leaves invisible nodes
- Fix: crash when trying to clad a triangle bounded by a cable
- Fix: prevent cables from creating floating nodes
- Fix: refresh dominant material based on current links rather than from added material
    - check when creating/destroying/upgrading links
- Allow cables to align at nodes (added AlignedLinksAllowed)
- Fix: Clean up cables that have broken and dangle
- Fix: device angle should be set based on graphical node positions
- Fix: nodes jump as they are colliding with the ground

25/9/14
- Fix: nodes cloned during BreakStructure inherit velocity and force from parent
- Fix: nodes sometimes get negative mass after losing links, causing them to fly away
    - Node mass is updated every frame in UpdateNodeMass instead of relying on addition/subtraction
- Made cable slightly lighter
- Cleaned up main physics loop

26/9/14
- Fix: crash when BreakStructures places a node in the ground

30/9/14
- Update to latest version of RakNet (4.081)
- Message id is now an unsigned char to deal with numbers greater than 127
- UPNP is used to open router port for host 
- Use RakNet server for match making
    - Multiplayer object updates and searches MasterServer?2 and sends found servers to PublicServersScreen?
    - Remove server connection from PublicServersScreen
    - PublicServersScreen sends refresh command to Multiplayer
    - Multiplayer sends new server entries to PublicServersScreen when they arrive

3/10/14
- Add tool tip when exceeding weapon group maximum
- Add tool tip when grouping incompatible devices

6/10/14
- Fix: game messages are sent to chatting or loading clients?
- Join any time
    - client loads game data and sends loaded message to host
    - host sends current state snapshot to joining client
    - host starts sending commands to joining client immediately
    - when client has loaded state
        - waits until there are no projectiles or splash damage
        - sends current world state
        - installs world front end
        - applies all queued commands until up to date (no more end_tick messages in queue)

7/10/14
- Fix: don't draw buildable ground glow when team-mates are building a ground device
- Fix: can't alt-fire grouped missiles
- Fix: device preview doesn't use the platform's angle

8/10/14
- Fix: mods not loaded for replay (needed to decompress replay)
- Fix: all weapons in persistent reloading state when seeking back in replay
- Fix: RakNet bug, accessing buffer that had been deleted

10/10/14
- Fix: incorrect test for inconsistent links in BreakStructure (counting only Team2)
- Delete isolated links when building links over them

12/10/14
- Delete isolated links when building nodes over them
- Fix: sniper gets stuck facing the wrong way (doors as open)

13/10/14
- Screen cycle reset on view move only happens after a certain timeout (to prevent frustrated players being unable to cycle to overview & enemy fort)
    - Instead of setting current screen index directly:
        - Store a 'moved this frame' bool
        - In the update, detect when it has gone from true to false
            - then set the index to the home pre-index
        - When cycling the screen, prevent the next latch from setting the index so it doesn't reset the cycle
        - This will mean the screen will not reset to home while the player is moving the view
- Fix: wide black band drawn when swiping door over background bracing
- Fix: Standin links used to determine which cladding is used (background or foreground) to prevent poorly overlapped struts on background cladding
- Fix: Standin link when putting bracing over a device appears damaged

14/10/14
- update joining client's status on loading
- Delete UPnP port mapping when server closes
- Compress join state

15/10/14
- Update FTGL and FreeType
- Fix: text rendering has blurry edges
    - Font size specified in units (screen or world)
    - multiply size by screenScale
    - Shift the RenderText y reference point to the bottom of the text to allow reliable scaling (used in the transaction effect)

17/10/14
- Fix: break effect not triggered when link is lost to vibration
- Moving doors excluded for spotter exposure calculation to prevent slowly shrinking/expanding aiming arcs
- Show fire priority for grouped weapons' fire readiness
- Fix: don't show build shockwave effect for enemy
- Fix: kick out clients and delist from master server before closing UPnP
- Fix: non-public servers still list on the master server and open a port
- Clients can be set to observers in the chatroom
- Remote client build preview and cursors visible to observers

21/10/14
- Fix: device t was in the incorrect parameter position for CREATE_DEVICE Fort command
- Fix: AI told of destroyed nodes when deleting own cable
    - When non-selectable node or link is destroyed, rebuild the parent link
        - Need to associate non-selectable nodes with their original connecting nodes
    - Avoid rebuild when destroyed link destroys node (isolated nodes)
        - Need to forget all non-selectable and isolated nodes before delete
    - Added EnumerateChainNodes with callback to ForgetNode
- OnFoundationCreated turned into OnNodeCreated, called for the creation of every structural node, with parameters
- Fix: AI commands that rebuild the original fort continues if node doesn't exist (fixes isolated foundation node not being built)
- Fix: Prevent weapons being used while recording forts to prevent node ids being thrown out
- Added \set_fog_of_war 0/1 command to allow internal inspection of AI forts
- Fix: Eliminated unnecessary "Curr weapon exceeded count" error message in AI script

25/10/14
- Fix: disorganised AI rebuilding pattern
    - Make a list of nodes and links that need rebuilding, sort them by original node id
        - Schedule a regular rebuild call that works from the start of this list
        - Avoid building new Fort structure until this list is empty

31/10/14
- Keep list of current device ids with key to the Fort action
    - When device is destroyed set the appropriate flag in the Rebuild array
- When nodes or links are destroyed:
    - Search Fort table backwards from current position marking relevant nodes and link for rebuild
    - Track the deletion of nodes and links, don't rebuild preceding this
- Deletion of a node is split into deletion of links on reception
    - Better corresponds to AI Fort actions
- Prevent deletion of nodes and links during fort recording that risk unintentional loss of structure for AI
- Notify script when nodes are deleted normally by players
- AI script records expected deletion of nodes and links to avoid reconstruction on their deletion

1/11/14
- Fix: invalid group master remained when seeking in instant replay
- Compress replays when dumping crashes
- Fix: device links can be deleted by context menu
    - Show error message if this is attempted
    - Prevent new context menu from showing the option
- Fix: text huge when building over turbine air flow
- Fix: no transaction shown for foundation construction
- Fix: right clicking from a strut to strut doesn't change the context menu
- Fix: crash in UpdateDoors adding timespan to expired door effects
- Prevent firing of expensive weapons when rebuilding
- Fix: check if door link exists before trying to close it when handling wc_close_door in DeviceEditor

2/11/14
- Fix: AI gets stuck on a node when it's too far
    - nudge the position if it's not too far away
- If AI any nodes are unbraced then work on their links first

3/11/14
- AI: Wait until there's enough resource for both the link and a long bracing link before constructing a new node
- Fix: if weapons are destroyed close their doors immediately
- Fix: if weapons have no target close their doors
- AI: Only repair only most damaged and stressed elements while rebuilding
- AI: Set a probability for weapons to fire during rebuilding
- AI: Ground device discovery
- AI: Insufficient resources when building devices doesn't hold up structural rebuilding
- AI: randomise target preference
- AI: increase inaccuracy for mortars
- AI: AP-Sniper targets devices behind structure
    - Allow ray test to continue for a number of hitpoints before stopping

4/11/14
- AI: weapons sometimes keep doors open to shoot faster
- Fix: stuck on AI2: Rebuild action 81 failed - upgrading device when upgrade center not given

5/11/14
- Fix: sometimes missile fails to launch for want of a spotter even though there is one spotting
    - FIRE_NEEDSPOTTER returned, Weapon::HasSpotter was not working for AI
    - AI spotters with LOS were blocked and de-prioritised for selection after human spotter selection, now added to front of list
- Fix: Show HUD when restarting after game over
- Show pause menu automatically after user clicks on victory/defeat

7/11/14
- AI: tries to group weapons with affinity table
- AI: allow missiles to be grouped with other weapons

8/11/14
- AI: All mirror of fort if map is symmetrical
    - detect mid point by looking at first buildable terrain node
    - translate all x coordinates and invert device t
    - translate referenced nodes to other team

9/11/14
- AI battle and multiplayer: Allow team & AI fort selection with mirrored AI forts taken into consideration 
- Fix: if link is stretched and too long for a new link during BreakStructure call then ConnectNodes creates two segments, causing GetLinkTo to fail, causing a crash
    - Use the rest length of the link to recreate it, which should guarantee the connection

11/11/14
- Fix: AI spotter gets stuck (missile changes its mind and doesn't launch)
- Links can be destroyed instantly if one end is isolated
- Make wait/blocked/repairing cursors an additional graphic off the normal cursor
- Change cursor to reload graphic when weapon is reloading
- Fix: return obstructed when trying to create a device on a device non-supportive link
- Add close doors to weapon context menu
- Fix: Don't try to fire or group weapons which are scheduled for missile launch or are being used as spotters

15/11/14
- Moved repository from old Dell under custom Apache2 configuration with Trac to VisualSVN on new Dell laptop without Trac
- Added missing Devil includes
- Support multiple prop directories
    - Moved surfaces into environment directories
    - Re-arranged props
- Turn background bracing into bracing when a device is placed on it
- Don't highlight struts you can't build devices on

19/11/14
- Put props, background, surfaces and ground textures in separate theme folders
    - translate current background,    ground, surfaces and props to new theme folders
- Fix: textures that have already been loaded report zero bytes to load callback to make progress smoother

21/11/14
- Make only these textures available when editing a map with a specific theme

24/11/14
- Fix: edge set was being set to the first (empty) set when changing to edges tab
- Fix: Highlight correct HUD button when switching tabs and ground groups in editor
    - OnOpenTab called in relevant editor and then passed onto HUD to give a change for detecting highlight
- Fixed up incorrect texture ground and edge set references in all maps, made minor adjustments to some maps
- deleted entrenched, basemap and Long Shot - Trailer maps (obsolete)
- Fix: Instant delete of isolated foundations caused a crash
- Fix: prop scaling controls hard to use, should maintain aspect ratio by default
- Fix: prop scaling doesn't invert the object, maintains original orientation
- instantly save empty environment and structure files when creating a new map so that the theme can be determined when loading it later
- Fix: new foundation not selected after creation

25/11/14
- Fix: start screen set to origin
- Fix: crash in DrawDevicePreview when link of a remote client is destroyed

28/11/14
- Fix: Door highlight
- Fix: Material highlights apply to all links in DeviceEditor when nothing selected
- Fix: can't double click on a door to open/close when in device editor
- Fix: grey weapon button when able to afford it
- Fix: can't disable/enable shields by context menu

29/11/14
- Allow shields to be repaired while disabled
- Disable shields while being repaired
- Fix: maximum shield length too long
- Fix: variable size link power draw text
- Fix: cycling of shield's red damage sprite during construction preview
- Reduce shield build/scrap duration by 50%
- Reduce shield power draw by 20%
- Increase mortar reload period by 33%
- Replace node deletion with node repair button in context menu 2 to prevent accident deletion/fort collapse
- Increase air resistance to limit sway
- Reduce air resistance of projectiles (sniper at least)

30/11/14
- Allow background layers to appear on top of the ground/structure layers
- Fix: disable windows key while active
- Fix: disable sticky keys, toggle keys and filter keys when active

1/12/14
- Fix: turn on fog of war again when restarting in game against AI
- Fix: prevent links with foundations from being deleted instantly
- Fix: reload icon on clients is static (hide)
- Fix: reset view on restart (e.g. AI game)
- Disable materials on context menu & space bar in tutorial
- Made shield 25% cheaper to run

2/12/14
- Fix: isolated cable foundations extend ground-buildable area that can't actually be used, doesn't update until a real foundation is built
    - Standin node was being used to discover available ground edge
- Fix: improve AI's ability to shoot down missiles

4/12/14
- Fix: disable toggle simulator key in anything other than editor and sandbox
- Fix: energy resource never reach full capacity (off by one)
    - apply device generation in a second pass
- Fix: consume all device resources before generating them

5/12/14
- Fix: AI was rebuilding strut repeatedly
    - was rebuilding bg bracing instead of door even though the link already exists
- AI: Remove obsolete UPGRADE_DEVICE path and TryUpgradeDevice

8/12/14
- Desync: create link/node when resources are in competition between two building clients
    - standin link remaining at isolated node, changed scrap time on creating client
        - Use RealLinkCount to ignore standin link; not sure where standin link came from (should not be built as chain)

9/12/14
- Fix: Cleared standin node selection if construction failed, preventing linking from invalid node
- Draw a circle behind devices that are in use
- Add constants for name tag, device in use circle and name tag size
- Fix: clear device detail background when no type is selected

12/12/14
- Fix: drag applied to PageEffect is independent of time
- Allow isolated nodes to be deleted by context menu
- Fix: negative deltas in explosion update set to zero
- Fix: explosion time out moved to after effect update to guard against time skips prematurely destroying them/preventing effects triggering
- Fix: some effect texture names not resolved when no extension specified
- Fix: reduce missile_trail.lua sparks spawn rate (would sometimes run out of sparks)
- Don't show stress to enemy
- Fix: sniper trail extends beyond point of impact
- Fix: insufficient tiles on backgrounds for widest aspect ratios
- Fix: collisions missed when fast moving projectile passes multiple devices
- Move cursor to group save position when pressed a third time
- Fix: repository corruption when submitting & deleting large textures in data/effects/media
- Fix: Flickering block symbol on reticle in Patrick's fort
    - Fire test for cursor block was using moon-shot trajectory instead of direct-line
- Test: Brian was unable to Alt-tab or Ctrl-Alt-Del during multiplayer instant replay

14/12/14
- Fix: can't see client status in instant replay

16/12/14
- Fix: allow cable to align with links
- Fix: crash when replacing material of an isolated foundation node
- Fix: AP-sniper trail and bullet continues past impact
    - Record actual position of impact instead or relying on speed which can change between frames
- Fix: reactor smoke effects vanish when reactor explodes
    - Disable node effects and allow EffectsManager to take over the effects which expire naturally
- Reduce splash damage of mortars to prevent other mortars of full health nearby exploding too
- Reduce cannon hitpoints from 700 to 550 and increase max radius of splash damage

18/12/14
- Fix: laser reflection effects vanish when beam goes off
- Fix: laser hit effects persist when beam breaks through one material and hits another
    - don't create a new effect when the link has broken but try to carry effects over to the new collision
- Fix: beam effects disabled when weapon is destroyed
- Fix: Correct the damage applied by lasers to devices by doubling it in PhysicsManager::IntersectBeam
- Control ignition of fire (including background materials) for lasers using projectile properties (currently on for all beams)
- End sparks effects if they are disabled and have no active sparks
- Fix: EffectsManager can sometimes fail to create or show new effects
    - SparksEffect m_play_for_enemy wasn't cloned
- Fix: use real time for some effects (transactions, errors) so editor can run well while paused
- Fix: construction in Sandbox during pause breaks and crashes game (revert to editor path?)
- Allow individual particles to select between physics and real time deltas
- Fix: don't consider standin node or temp braced nodes in SpawnEffectOnNodesWithinLinkRangeOf

21/12/14
- Fix: users directory and user subdirectory is created and switched to before creating screenshots, crashdumps, etc. directories and log file
    - Removed obsolete g_StartupDirectory

22/12/14
- Allow cables to attach to any ground
- Cables make pegs when not acting as foundations
- Fix: entire cable is not highlighted when in device editor

23/12/14
- Fix: preview cable end node invalid when not snapped to ground
- Fix: Ignore ground nodes in IsPointOnGroundGroupSurface if they are detected to make up a fissure in IsPointOnGroundSurface
- Fix: Add a small bonus to ground nodes that support foundations in IsPointOnGroundGroupSurface so grid/ground intersections favour buildable ground groups

29/12/14
- Recess struts in front of weapons (cannon, sniper, etc.) but not mortars
    - Use selection box to block weapon/device placement on some ordinary non-recessible materials (e.g. armor)
    - IntersectsStructure has additional parameter to enable weapon recession boxes
    - Apply recession boxes in separate phases
    - Fix: remove to-background bracing from armor's context menu
    - Make bracing free to recess
    - Charge for changes in materials during recession and show total material transaction
    - Avoid weapon recession when Ctrl is held
    - Disable weapon recession when recording AI forts
    - Reflect affordability in weapon recession
    - Show cost of weapon recession in preview
- Fix: Door material sprite overwritten through reference, sometimes causes door chevrons to appear as armor
- Add a tool tip when building a device in empty space or ground
- Fix: in rare circumstances a sniper's bullet trail wouldn't appear
    - new Meshprojectile would be reset in DeleteNode when an old one was recycled; Node's m_MeshProjectile value wasn't cleared with MeshProjectile::Reset
- Fix: removed obsolete and commented EstimateYIntercept code (superceded by exact trajectory calculation)

1/1/15
- Fix: Applied pan angle to device preview to correctly recess materials in ReceiveCreateDeviceMessage
- Fix: doors are considered open and construction solid when viewing weapon visible angles while previewing construction

3/1/15
- Fix: miners still apparent when reactor is destroyed
- Fix: tiled props, undo, left click open space, crash
- Fix: tiled props don't work after the first
- Fix: plugged holes in PropEditor undo stack
- Added current layer to PropEditor
- New shield destroy sounds

5/1/15
- Fix: if another client is previewing construction at the same time
    - devices (esp. mines) are built facing the wrong direction
    - snapping to the ground doesn't work
- Fix: show pause menu when joining while host is paused
- Fix: exit joining clients immediately (after loading complete) if server quits before loading complete
- Fix: quit joining clients to main menu immediately (after loading complete) if server quits to main menu before loading complete
- Show a temporary message to indicate that the host has quit
- Fix: AI repairs weapons while in use by player
- Fix: can't extinguish fire when a strut is under construction
- Fix: extinguish fires on game over
- Change sniper bounding box so barrel can't protrude
- Fix: cannon recess too much behind/under the platform
    - raise bounding box off the platform
- Increase height of cannon bounding box to prevent overlap with structure above/make it occupy more space
- Fix: preview devices have their pan angles reset, and preview pan angle is saved like other preview values
- Fix: AI created devices and weapons set their pan angles (weapons use GetInitialPanAngle)
    - Fixed GetInitialPanAngle device pan angle
- Fix: weapon was not tracking remote client cursor
    - non-host client's weapons stop tracking if they are blocked

6/1/15
- Ignore projectile collision with source weapon until it has cleared
- Fix: take pan angle into account when calculating device center
- Replaced special mg flash blank frame with invisible copies of actual flash frames
- Add reload effect to play when reload timer expires
- Add cannon reload effect
- Adjusted sound volumes down of ground, armor deflection, structure groan and rumble
- Removed an annoying level 1 groan
- Add variety to ap sniper fire sfx
- Improve laser sound effect
- Allow reload effect to be offset
- Add an effect map for non-projectile nodes to DeviceManager::GetCollisionEffect
- Update/add variety to bullet/ground impact sfx
- Allow projectiles spawned from ground weapons to start in the ground without collision (missiles)

7/1/15
- Fix: Beam sets fire to local structure if it hits background bracing at enemy first
- Beam ignites background bracing as it passes
    - excepting source weapon's team until reflected by another team
- Fix: undo directory was appearing in data directory on editor revert
- Players on same team AI on one, destroy own fort, non-host player brings up pause menu before result shown, non-host player quits before host quits
    - Host puts message from client into the command queue but never executes it
    - If game is paused execute client status updates immediately?
- Fix: Joining clients cause a desync in the replay
    - Store client status update in the replay at the server
    - If the client is invalid when an update is received, add a new client instead
- Fix: Game crashes if host exits abruptly
    - Install loading screen and destroy World object before destroying the client database
    - Reduce timeout to 3 seconds
- Fix: destroy shell when WM_DESTROY received by Alt-F4
- Play construction sounds when AI or team mates are building

8/1/15
- Fix: problem with console listbox child clipping blocking out menu when fully up in debug mode
    - Had to reset the scissor box to the entire client area when disabling GL_SCISSOR_TEST
- Desync: AI tries to close a door that had previously been opened by a remote client
    - AI searches for open doors in front of the weapon (doesn't use door list at all)
- AI: Unable to delete ground devices
- Fix: laser doesn't show fire effect when repeatedly shot into the air (e.g. gunshot)
    - rapidfire mod had reload period too short
- Fix: laser blanks out when breaking through structures
- Fix: duplicate construction sound when replacing materials
- Fix: trying to build armor over devices shows a door (should fail)
- Fix: OnDeviceDestroyed unmarked devices and caused them to explode
- make laser buring background bracing as it passes optional
- Desync: Misc desyncs while shooting on the same team as AI
    - Reset/naive aim before calculating trajectory in case human has targeted locally

12/1/15
- Fix: preview device adds storage capacity during create device message handling
- Fix: laser igniting local team's structure
- Fix: If host quits before instant replay is available, non-host clients get booted to chatroom
    - Prevent host pausing between game won and game result
- Fix: select the first available map in chatroom
- Fix: spotter laser shows when deselecting a missile that's under construction
    - Don't allocate spotters for groups where all weapons are under construction

13/1/15
- Fix: unable to fire group if the master is under construction (missiles work)
    - Promote slaves to master if the master is not fully built
- Fix: repair area puts out fire on entire structure
- Fix: Don't show reload icon on remote clients' cursors
- Fix: Don't allow use of weapon recession when creating a link
    - fixes AI creating doors when trying to build armor over devices
- Fix: context menu shows on device group master, but it does nothing
    - Allow deletion, passes master to next fully built slave
- Fix: group member not selected from group button if group is already selected

14/1/15
- Added PhysicsManager::DumpWorld method to create text representation of the dynamic world content once a desync is detected, to help identify the source difference
- Desync: When AI closes doors reset the weapon direction so the result doesn't depend on where the weapon is pointing (can be modified by local client)

15/1/15
- Desync: if more than one player selects a weapon at about the same time they can all aim it, machinegun causes a desync when shot
    - When a client select message is received from another client, compare it with the current selection
        - if the same device is selected and the other client's ID is lower than ours
            - first try to promote a fully built unlocked slave to master of the group
            - otherwise deselect the device
- Fix: If two or more clients have the same slave selected, the selection will cycle through them
    - give the selection to the client with the lowest Id
- Fix: HUD item (turbine) not highlighting when resources available, clicking on another item allowed it to be highlighted
- Fix: machinegun can fire through recently closed door
    - move hardpoint backwards
- Fix: projectiles do not sink into devices like they do structures
- Abstract projectile sinking code (tailToCollDist, etc.)

16/1/15
- Desync: pan angle of preview device not set before checking collision with other devices
- Fix: fixed identification of console key profiles for reliable use of GetKeyBindingName across instances
- Fix: Reactor can be previewed on remote hosts after selecting an instance
- Fix: Draw additional name tag when device is selected, and otherwise nametag follows cursor
- Don't show cost preview of weapon recession of remote clients
- Fix: During play hiding the cursors will leave the local client's cursor visible
- Fix: moved name tags down a bit so it doesn't overlap cursor

17/1/15
- CO power brainstorming session
- Make door speed in terms of unit length per second
- Fix: don't restart door effect if it's already opening
- Fix: sniper sets missile paint target to rear of weapon if it's hard up against something solids

18/1/15
- Add a flag to prevent devices from flipping
    - Store device pan angle in non-detailed world state so non-flipping devices can be restored on load
- Adjust bounding box of cannon for one-sided operation, and lowered

19/1/15
- Fix: properly compress replay when entering instant replay
- Debug not when saving replay
- prefix date/time to world dumps during desync

21/1/15
- Add mouse sensitivity option
- Fix: sniper turns backwards if mouse is behind and missiles are deselected

22/1/15
- Fix: text resizes in UI editor with client area
- Reduce shield run cost by 33% and made repairing it cheaper than building it
- Commander passive modifications
    - duplicate device and projectile types for two teams
    - apply normal mods
    - apply mod to each set depending on selected commander mod
    - switch access depending on team
    - Add team parameters to type dependent script functions
- Fix: free projectile, device and weapon list sprite sets on closing device manager
- Fix: Reverted change to Text that caused transaction effect text to be too large

27/1/15
- Commander passive modifications
    - duplicate material types and apply mods
    - duplicate rules store and apply mods

29/1/15
- Fix: Joining team None to Team2 with higher hitpoint material makes it partly damaged
    - Creation team isn't necessarily the same as link source or destination
    - Consider the team to be of the node the primary link points to
    - Don't draw standin links twice when they connect forts of different teams

30/1/15
- Fix: Sniper doesn't aim when paint target is behind a door

31/1/15
- Replace debug temp bracing and selection graphic with textured version
- Allow modification of cladding by team
- Fix: Make default parameters to Static constructor and simplify appropriate instances
- Remove left and right brackets from DeviceEditor
- Fix: Context Material buttons not highlighting on rollover
- Commander passive modifications
    - When device changes side
        - reset reload & round timeouts
        - update node mass, link hitpoints
- Allow clients to modify their commander mod
    - Host can specify public, private or no commander
    - Populate commander list with local mod folder
    - Commander mods prefixed with commander-
    - All clients can change their commander
        - sent to host and distributed to all other clients
    - Pass the mods to the world for application

3/2/15
- Added a commander mode option: none, private and public
    - adjusted and disabled commander button visibility accordingly
    - observer can see private commanders
- Disable StructureEditor during replay to avoid crashes to do with local team Id being observer
- Save commander mods in the replay and re-apply them on playback

4/2/15
- Fix: need to activate StructureEditor to have strut highlights update, skip most of the function if observer
- Replay desync: When keyframe is written in the fire delay of mini-gun
    - Don't reset timers when SetTeamID doesn't change the team
- Fix: spotting laser is drawn when deselecting even though it can't be afforded
- Fix: spotter painting targets that are too close
- Fix: Deselect device type entirely and allow material highlight if prerequisits are not satisfied or disabled
- Save a preview of the system screens to the map directory and show them in the MapSelect screen

5/2/15
- Add primary flag and fire segment temperatures to checksum
- Fix: fire segments can swap during BreakStructure

6/2/15
- Fix: crash when a neutral weapon is selected at the end of a game
- Added new commanders
- Mods can use the Log function to help debug

8/2/15
- Fix: Fire hurt effects are being played for the enemy and not the local team
- Added final commanders with passive powers
- Fix: foundation is counted against affordability when linking to an already built foundation node

9/2/15
- Fix: playing as observer causes crash
- Fix: AI sometimes faces weapons in wrong direction in order to shoot down projectiles
    - Causes replay desync as restored weapons can't be made facing an inappropriate direction
- Associate factions with a commander using commander.lua files
- Increased builder discount to 20%
- Added effects for pause and resume

10/2/15
- Fix: commander-turtle building_materials.lua script function fails
- Increased repair cost of laser
- Reduced hitpoints of laser
- Reduced splash damage of cannon
- Add sound effect for start/restart, win, lose game
- Allow viewing stress in replays
- Fix: can't see players' actual status in multiplayer during replays
- Fix: commander changes that affect Team2 HUD don't appear
    - Pass in player's team with OpenMap command so the HUD uses the correct team
- Fix: replay desync due to uninitialised node surface up
    - initialise surface up at beginning of PhysicsManager::GetNodeCreationParameters
- Backup to DVD and Dropbox

11/2/15
- Fix: Observer crashed entering with two other players (don't prepare game HUD for observers)
- Reduced weapon upgrade build times

12/2/15
- Add laser sight to marksman's snipers/allow AP sniper to paint for missiles
- Retuned AP-sniper to have the same mass/drag characteristics of sniper so laser sight would be consistent
- Added constants for targeting laser colour and style
- Added incendiary radius, heating radius and offset to projectiles
- Builder has 2x faster material build times

13/2/15
- Only update httpConnection2 if we're posting to the master server or searching for servers
- TCP server is only active and updated if the host is public, or a client is searching for a host
- Detect failed attempts at connection to master server and prevent future attempts in this session
- Fix master server IP address string in http request call
- Fix: laser sound isn't cancelled when skipping replay while it's on 
- Fix: crash when missile is destroyed while it has a spotter
- Change points to wins
- Prop editor selects first texture when tab opened (needs work)

15/2/15
- Reverted change to AP-sniper mass and drag so it can pass through structure
    - means trajectory differs from sniper again so laser sight will have to be adjusted between weapons

16/2/15
- Fix: laser sight can't go down when facing left
- Fix: Team2 gets storage bonuses of initial devices of Team1 commander
- Fix: prop texture selected incorrect when opening prop tab
- Fix: prop button highlighted properly and deselecting current prop when switching tab
- Fix: desync doesn't produce screenshots
- Add a label to the dump_world command
- Add circular incendiary effect to device explosions

17/2/15
- Fix: crash when trying to draw StructureEditor during replay
- Fix: cancel all sounds when skipping replay
- Fix: replay desync after breakstructure with burning link
    - fire segments end up on non-primary link
    - Added extra annotation to DumpWorld
- Fix: SparksEffect::Update was creating a corrupt string with the factionName, so always using backup state
- Fix: animated sprite not given random start frame when instructued during transition from one state to another
- 'fire' sprite FireLoop state has a random start frame to prevent many fires started simultaneously being synchronised
- Added area fire to cannon destruction

18/2/15
- Add a hissing steam effect for putting out fires during repair
- Fix: standin link sometimes not drawn

19/2/15
- Fix: clients can attempt to build a new node while the previous one is pending, causing RelinkNodes to assert/crash
- Fix: allow incendiary area affect to apply between teams and neutral
- Fix: allow laser sight adjustment to be made per-weapon type, per client
    - ClientData structure has a map of weapon index/floats, set up during DeviceManager::LoadResources and altered per client later
    - laser sight adjustment passed in client_select message is only applied to the currently selected weapon type of the client
- Removed StopTCP call which caused crash
- Added password generator to RandomGenerator
- Create a password for updating and deleting entries on master server

20/2/15
- Add standin node/link info to DumpWorld and extra error message when sending a link request with invalid source
- Optimised: flame sprite and frame size are preloaded
- Fix: steam always appears at link midpoint on testground map/team1
- Fix: reflected projectile thickness is scaled consistently with normally drawn projectiles
- Fix: Projectiles are drawn past their collision position at fast playback speeds
- Fix: Crash when selecting a neutral device with upgrades (teamIndex negative)

22/2/15
- Fix: Replay timeline broken when joining late in the game
- Nick Added Russia faction

23/2/15
- Fix: reclaim value when upgrading links is properly handled in preview cost, request and handling
- If a door was not made under the recession box from armor and there is no door already there, turn a strut into a door
    - Add a preview material member to link for previewing auto door

24/2/15
- Use a customisable scoring system to change the way the auto door is selected based on orientation and barrel axis separation
- Align recession box with the barrel so that mortars can recess structures
- Added recession boxes to both mortars

25/2/15
- Fix: set mortar fire angle according to facing direction during preview so that it's consistent with in-play weapons
    - Adjust the recession box rendering, preview and actual recession functions
- Allow mortar base sprites to mirror and removed some obsolete textures
- Fix: Desync when creating mortars (update panning and barrel forward before adjusting box angle)
- Fix: Weapon recession attempting to recess non-recessible structure
- Fix: client watching replay after multiplayer game can't change time speed
- Backup to DVD and Dropbox

26/2/15
- Fix: If keyframe is made in same frame as device is deleted then there is a desync (avoid device destruction detection in RestoreLinks)

27/2/15
- Fix: Replay desync when sniper is created just before missile launch
    - Weapons were being created by AI without the FireAngle set, causing unreliable laser ray cast
- Fix: A global AI action variable is assigned (should be all local)
- Fix: AI sniper missile painting laser not drawn
- Fix: AI can paint targets through doors
- Fix: devices under repair can't be destroyed by a laser
- Fix: devices appear fully built immediately after seeking

28/2/15
- Fix: crash when a device is selected and a weapon is attempted to be grouped with it
- Allow \seek to take a frame number
- Fix: Structures2 desync near the end of a replay (multiplayer human vs AI or human vs human)
    - ReactorsAreCritical was not being added when restoring a replay, AI was never being told the game was over

1/3/15
- Fix: Skip to a point in the replay after the player's reactor has gone and the AI is not told the game is over
    - Avoid resetting mHasStartingReactor when seeking and notify script immediately to avoid unreliable timing
- Fix: can't turn off debug mode in multiplayer
- Fix: Faction not consistent during replay (e.g. player vs. AI, changes between construction and idle)

2/3/15
- Fix: Sniper recession preview & autodoor was wrong in replay (now uses default fire elevation)
- Fix: preview animation speed doesn't follow physics time keeper speed
- Fix: Prevent double click immediately after first, add constants for timing & distance
- Allow middle mouse slide to interrupt one in progress
- Reduce hitpoints of laser so two sniper hits will destroy it
- Fix: Cladding is sometimes not put in background with preview AutoDoor
- Increase extent of machinegun weapon recession box to improve autodoor predictability & ease of use
- Fix: machinegun rounds that look like they hit the missile do not
    - Fixed first pass test that would miss some collisions
    - Allowed more than one collision in a frame for projectiles that persist
    - Increased cannon collision radius to improve its ability to take down missiles
- Fix: crash in replay when trying to cycle materials (stopped devices and weapons too)
- Fix: Ghost client cursor was drawn in replay when wifi was interrupted and client rejoined
    - Host sends itself a disconnect client status message, forwards it to other clients and the front end for inclusion in the replay

3/3/15
- Fix: Colliding projectiles create effect in the wrong position and they sometimes miss each other (esp. when direct-on)
- Fix: Highlight flashes when weapon is under construction
- Fix: Last highlighted strut or node remains highlighted when cursor goes over a device in DeviceEditor
- Fix: prevent clients in chatroom from changing the commanders before joining a game
- Backup to DVD

4/3/15
- Active commander power infrastructure implementation
    - centralise team index calculation in World
    - Load two sets of resources per team when commanders are present
        - Detect this and adjust team index when team commander is active
    - Add key to toggle commander active state
    - Set active variable in Lua script for second set of resources
    - Add backup activation values for temporary forcing
    - Send message to activate or deactive commanders
    - Store team activation in detailed state
    - Load & call commander scripts
    - Projectiles refer to their parameters by pointer only to prevent changing data mid-flight
    - Allow commander mods to specify new effects and media using the modpath value
    - Allow mods to preload effects and samples
    - Add script function to toggle fog of war
    - Add ApplyMod call to devices/device.lua and weapons/weapon.lua after loading each item for convenient single-file modding
    - Check when reload time, repair rate is set (need to reset reload timeout and force it high when expired to prevent backtracking)

5/3/15
- Fix: memory leaks and unknown allocations
- Fix: properly serialised ClientData class (was previously writing std::map directly to file)

6/3/15
- Fix: random_seek gets into a deterministic loop. Now uses better quality random number generator, seeded with real time
- Fix: A few textures are being loaded in duplicate depending on their requested filename
- Add font configuration list to constants.lua and eliminated digistrip font and larger versions of Ariel (saves ~70MB of memory footprint)
- Added memwatch to ftgl_static project (clears up wild frees and exposes font memory behavior)
- Memwatch will break the debugger if there are any memory anomolies on exit
- Removed Debug in Dropbox configuration
- Move mortar air-burst effect in front of forts

8/3/15
- Fix: transaction PageEffect gets reloaded for ever instance and a new memfile gets allocated each time
    - Allow CMFile to be constructed statically and reference another (not owning the buffer)
    - PageEffect references the prototype memory file but still restores the page from it

9/3/15
- Fix: Write replay to disk in chunks to prevent failure of memory allocation
    - Allocate buffers at start: to receive replay data, to compress replay data (which is written to disk)
    - Write the preamble (game configuration), start frame, frame count, etc. to the file without compression
        - can be adjusted and read without decompression
    - Write size of each compressed block and size of uncompressed block before each chunk
    - On instant replay start, close replay and reload full uncompressed buffer, don't re-activate AI or mission scripts
    - Flush buffer, close and copy replay file to crashdumps/desyncs on crash or desync
- Fix: crash on replay save trying to access deleted physics manager

11/3/15
- Fix: state changed to replay after replay client database installed, further client status messages not handled properly
- Desync: joining a game with AI
    - Send the AI and mission script state with the join state
- Fix: memory leak - device manager not cleaning up device previews of activated commanders
- Reduce Replay compression buffer size to minimum needed
- Fix: AI fort selection doesn't appear to be very random, now uses better quality RandomGenerator and RealTimeKeeper for seed
- Fix: host was sending client status (loaded) back to loaded client, and client was repeatedly logging connection notification
- Add sentinel blocks between compression blocks in replay
    - Gracefully quit to main menu and show a message if the marker is not found
- Fix: Hide reactor health bars before display

12/3/15
- Add commander gauge HUD elements
- Add commander points to JointResourceAccount
- Update commander points and gauge when damage occurs and as points are draining
- Allow activation of commander by HUD button
- Allow commanders to customise the amount of damage and attack it takes to earn a full gauge, and how fast it depletes
- Turn commander toggle key into an instant full bar (will cause desync in multiplayer)
- Added commander ready star animation
- Controls can be marked to not block the mouse to for e.g. allow the commander star to extend into the game area without interfering with the selection
- Added effects for commander activated and deactivated

13/3/15
- Add commander ready effect
- Fix: Make mouse sensitivity option accessible by keyboard
    - First ListBox item can be tabbed to, then up/down will change the selection
- Fix: Back button in MapSelect doesn't have a tabstop
- Add mouse-over text popup to remind player what ther commander does for them (passive & active powers)
- Add commander help text to commander selection screen
- Fix: Better manage the flushing of the replay buffer so it never runs out of memory
    - Once a minimum of data has been written force another keyframe at the next opportunity
    - If the replay buffer runs out and is reallocated then increase the compression buffer too

14/3/15
- Desync: client manager was using real time to drain commander points
- Fix: Don't attempt to flush the replay buffer is empty
- Clear FileSelect screen tool tips
- Save replay last in debug dump so if it crashes the other information is still written (also put it in a try/catch block)
- Fix: Set initial mem file size of world dump to something large to avoid realloc fail
- Add commander points, commander mods and commander activation state to world dump
- Add commander points to Resources checksum
- Commander points cheat only works when there's one player
- Make world dump write directly to file to avoid having to allocate a buffer
- Serialise simple projectiles
    - Make another data area in Node for projectiles
    - Store index and activate status in ProjectileParams and write them with the projectile data

15/3/15
- Fix: don't refer to burnt out link again in PhysicsManager::UpdateFire (may be causing memory corruption)
- Fix: Adjust minimum and maximum levels of commander points bar
- Serialise mortars
    - Create a new mesh projectile initialised with the trail effect
- MeshProjectile should point to missile params found in node's mProjectile structure instead of copying it

16/3/15
- Serialise missiles
- Serialise delayed splash damage
- Fix: m_MeshProjectile can be NULL when serialising missile nodes
- Allocate large buffer for join state up front to save unnecessary reallocations (also fixes leak)
- Condense commander script setup in World into a function
- Disable commander activation button and effects on game over

17/3/15
- Fix: Resources desync when 2 players vs. an AI and damage armor with a sniper (commanders not loaded properly)
- Prevent game rolling on indefinitely, producing a long tail on replays
- Fix: Restart in Vs computer doesn't reset the map
    - Can't seek to beginning of replay because it's been flushed to disk
    - reload only the first chunk of the replay (fiddly, need to know how long the first chunk is)
    - Save replay on restart
- Fix: Remote clients show spotter laser when missile is reloading
- Fix: neutral devices don't have their colour set immediately when seeking
- Fix: make replay seek bar wider
- Fix: host quitting to chatroom forces clients back too
- Fix: preview devices are not transparent
- Fix: Free preview textures in map select screen

18/3/15
- Disable grid in replays
- Fix: Cable standin link isn't drawn
- Fix: faint chance that two clients will have a valid standin node with the same node id, causing the wrong standin node to unlink

19/3/15
- Fix: replay buffer memory leak when starting an instant replay
- Fix: mark commander data as loaded when starting a replay
- Fix: prevent grid being turned on during replays
- Fix: stop door effect when link destroyed
- Try to make flames direction follow their velocity (doesn't look good in many cases)
- Add a callback system to fileselect that allows a selected file to be analysed to fill in the tooltips, preview image, etc.
- Extract information from replays for the replay select screen: player names, AI state, commanders, run time
- Write information about all clients (not just playing) to the front of replays, to complete information when browsing replays
- Reverted keyboard tab controls

20/3/15
- Fix: if client joins and then the game ends, the client exits to chatroom with a notification
- Fix: only clients playing at the end of a game score a point for winning, rename chatroom column to wins
- Fix: Disable team buttons for invalid clients in chatroom
- Fix: link highlight shows in instant replay when seeking (link highlight value is saved in simple data)
- Fix: don't show player status changes from replay file when viewing replay (only actual ones)
- Add '(replay)' to chat messages coming out of a replay
- Return to replay selection screen (at the same position) after quiting a replay
- Fix: camera movements are not ignored during pause (e.g. hold and move middle mouse button)
- Fix: cancel any camera movements while paused (prevents unexpected shifts when unpausing)
- Fix: crash when mousing over invisible commander activate button in instant replay
- Fix: Don't try to save the replay during crashdump if we are not in play mode (prevents recursive crashes, losing original debug state)
- Reduce minimum replay flush threshold and replay buffer, increase period of keyframe writing

22/3/15
- Cancel commander activation on game over
- Prevent winning fort catching fire after victory
- Cancel deletions and repairs when structure goes neutral
- Fix: commander script teamId was always being set to Team1
- Commander can be selected in Vs Computer, and disabled entirely. AI commander is randomly selected.

23/3/15
- WorldScript tracks the current team, so it can prevent interference with the enemy team
- AI can activate commander
- AI targets enemy projectiles by calculating the time to impact and then projecting the target's position into the future
- AI Balancing: reduce mg, sniper, mortar, cannon and laser accuracies. Increase firing probability of AP sniper, mortar and laser during rebuild.
- Disable commander gauge alert while paused
- Pause all sound effects while paused
- Fix: Cursor's reload icon shown as full when swarm (first weapon) can be afforded, but upgrade (second weapon) can't and the swarm has just been fired
- Fix: show reload progress based on affordability first if all members are reloading and none can be afforded show reloading icon regardless
- Fix: If weapon is destroyed with door open (e.g. cannon) it remains open (ignore non-doors)
- Prevent scripts from interfering with the enemy or neutral forts

24/3/15
- Fix: Prevent damage applied after game over from adding to commander points to the gauge
- Fix: Bullet reflection followed by impact causes the projectile to appear to go past the impact
- Show repair and build icon if waiting to shoot weapons
- Desync: winning team remains set after replay gets to the end of the game. After seeking fires are constantly extinguished on the winnign fort.
- Fix: Disable construction and repair cursors on remote clients
- Make a simple world dump file without constantly changing values: positions, velocities, etc. to allow comparison of important changes between different frames

25/3/15
- Add build/repair mouse icon to devices

26/3/15
- Fix: If a replay keyframe is made while a metal store is being scrapped it desyncs when it is deleted
- Add scrap and reload mouse hover icons
- Move mouse cursor identifier out of mouse.h to worldtypes.h
- Make mouse sensitivity array configurable in constants
- Configure cursors and default substate offset configurable from constants.lua
- Fix: Weapon mouse control is not set after building

27/3/15
- Make LogApplicationCalls function redirection automatic
    - when a function is registered, if trace is disabled then the function is logged as-is
    - if enabled, a redirection function is made which logs the function name
    - variable is passed to disable, enable and trace first parameter
- Fix: reload and other icons shown on team-mate and remote client cursors in replay
- the trace state and ai script log level is set from the console

31/3/15
- Replay keyframes can be forced by events other than time
- Desync: replay desync when keyframe is made in the same frame as an AI device is created, initial and ongoing position is inconsistent sometimes
    - CommandInterpreter adds preview device to link to work out which link direction is used, to set initial pos accordingly (also better for recessing overlapping structure)

1/4/15
- Make a stress warning flashing overlay for over-stressed links
- Create node, link and device build effects run in editor
- Add customised device construction effects
- Add sound only option to effect spawn so editor doesn't clutter up screen with paused visual effects
- Undostack starts with a sizeable buffer to avoid reallocation when saving state
- Balance: reduced cost of turbine & super turbine, increased energy output of reactor and slightly decreased energy output of turbines (to make it easier to come back from losing all turbines)

2/4/15
- Adjust size of sandbags bounding box to match graphics
- Add sparks effect when burning structures break
- Fix: reload progress shows on multiple machinegun firing before burst is complete
- Fix: structure is not recessed in editor when placing devices if the simulation is never started
    - update team structure extents as soon as a new node, link or device is created or destroyed.
- Optimise: PhysicsManager::IntersectLineSegWithStructures only does one test of the incoming line seg with the structure extents, instead of one per link
- Fix: create device shockwave is sometimes jumbled (e.g. in editor)
- Standardise effects to prepend the path so it can be copied to a mod without adjustment
    - rename modpath to path
- Added missing glyphs to DNK font
- Added Console::TraceRaw function to avoid problems with tracing the percent character, and prevented Console accumulating logged text in unused string list

3/4/15
- Fix: weapon hurt effect not played immediately
    - PhysicsTimeKeeper set to zero then paused during loading the resumed on world installation
- Fix: AI commander is invalid in battle when commanders disabled
- Add different sound for constructing a door than shutting it

5/4/15
- Fix: PhysicsManager::GetLinkReclaimValue uses real link and logs an error if it's not found, returns zero value
- Log entire client database along with AI fort selection and commanders
- Log client database to world dump files
- Fix: Make any commander multipliers local to avoid modification
    - turn all divisions into multiplications
- Balance: increase turtle door speed to 2x and armor discount (to 20%)
- Balance: builder storage bonus set to 25%
- Balance: increased marksman's explosive round splash damage and radius
- Fix: Turtle gets half price repair on everything when active, and 20% off repair of armor/shields ordinarily
- Fix: reduce sandbags cost and mass to match reduction in size

6/4/15
- Fix: link destruct icon goes in opposite direction to device destruct icon
- Deactivate commanders on game over
- Fix: device remains selected when structure it's sitting on goes neutral
- Commander active sound loop plays in replay sometimes when a commander is not actually active
- Fix: commander points cheat doesn't activate the star effect
- area repair functions by mouse only: right first and then left mouse (hide context menu and avoid later processing of left mouse)
- Context menu triggered when right mouse goes up, to avoid having context menu on screen when using mouse-only area repair
- Allow weapon grouping by mouse only
    - left mouse release on a compatible weapon
    - if master weapon is not master in a group already then create a group in the first available slot
    - if it is master in a group add the target weapon into the group
    - if released on nothing then disolve the group
    - Draw a dashed line from master to slave
    - allow drag-grouping from structure editor
- Fix: weapon group array indices and mIndex value are now identical to the key needed to save/restore them
- Closing the doors of the current group master closes all slave doors too
- Fix: Clearing one group can remove a member of another group

7/4/15
- Use right mouse button to fire group in sequence
- Don't show device preview when context menu is up
- Fix: can't see mouse sub cursors of devices when in structure editor
- Fix: devices can be highlighted when structure editor context menu is up

8/4/15
- Fix: mouse-only repair area doesn't repair devices in the area

13/4/15
- Campaign mode
    - campaign script holds list of maps to load
    - on return from game check for local victory and move to next map on quit
    - Allow restart after instant replay (on lose)
    - Allow continue after instant replay (on win)
    - Allow continue after win (quit will save and return to main menu)
    - Specify spr file, mission script, AI fort and AI difficulty over-rides for easy, normal and hard
    - Allow editor to switch working SPR for multiple structure files in the one map
        - Show file selection dialog if there is more than one spr
        - Add switch command for copying/loading spr as a different filename
    - Don't save level previews if not using default structure file
    - Associate AI fort files with the current spr file (postfix filename)        
    - Store mission script in replay preambles
    - Save campaign progress in users/campaigns/
    - Fix: loading screen glitchy at beginning of campaign load
    - Fix: save file is not saved if the campaign is invalid

14/4/15
- Join state is saved and loaded in the World class
- Save campaign game state on quit if game not over, progress the campaign if the player won
- Right mouse button only fires if there are multiple weapons selected
- Fix: restart after rejoining a game takes you back to the save game, and doesn't reset the entire game
- Fix: restart after replay results in frozen time

15/4/15
- Fix: disable revert on pause menu when watching a normal replay
- Initial rough version of mission 1 for the single player campaign: mg/cannon vs incendiary mortars
- Fix: Allow devices and materials to be enabled per team from script

16/4/15
- Fix: restarting can cause an infinite loop if there are no devices or materials to select (CycleDeviceTool and CycleMaterialTool)
- Fix: disable auto-door if door material is disabled
- Removed armor and mines from mission 1, and moved machine guns away from the reactor to simplify the appearance
- Added 'target range' first mission with 4 cannons and 2 abandoned forts
- Campaign AI is disabled if the AI fort is empty
- Script victory condition reports winning team to allow campaign to advance
- Reduced weapon selection zoom bias (too sensitive at far view)

17/4/15
- Fix: restarting a mission with mods causes a duplicate mod error
- Fix: update team bounding boxes on structure paste, move, delete
- If a strut is on fire and is repaired selectively, do an area extinguish on that position (don't repair everything fully, just that link)
- Fix: Win the game, then run until the game automatically pauses. Restart and time is frozen.
- Fix: Run until the end of an instant replay and the pause menu pops up (it shouldn't). Restart causes a series of debug buffer errors.
- Mission1: Replaced cannons with machineguns and shrunk the map and enemy fort
- Fix: ShiftStructure doesn't update device actual positions, so bounding box is not always updated properly

20/4/15
- Added more sandbags to mission 2 to reduce chance of quick win
- Fix: Infinite loop when there's only devices without satisfied prerequisites and devices tab is switched to
- AI: miniguns will shoot at a target anyway if they have no line of sight to any other target
- Added wall map for introduction to construction

21/4/15
- Merge wall mission back into Vanilla
- Add armor mission, with workshop, mine and upgrade centres
- Fix: if mouse is released while over a UI control, the mouse grouping line remains visible
    - Make tool tips non-mouse blocking
    - Detect if left mouse is up and cancel the grouping
- If a grouping matches an existing group then restore the group (and don't dissolve the group)
    - If there's no match but the selection already leads a group then overwrite the old group
    - Switch the master if necessary
- Double left click on a weapon restores the first group lead by the selection, otherwise the first group with the selection as a slave

- Don't save a replay if it's less than a certain threshold long
- Remove NavEvent_ReloadMap handling - obsolete

22/4/15
- Added Vanilla Small map for early campaign missions (to make them easier)
- Remove obsolete upgrade enabled by team flag
- Set path variable of mission scripts
- Add EnableWeapon script function that acts on weapons, make EnableDevice work only on devices

23/4/15
- Reduced difficulty of armor mission by exposing the enemy machine gun
- Balance initial missions
- Add some screen space objectives to the missions
- Fix: clear objectives when mission cleaned up

23/4/15
- Allow laser sight to be adjusted using Hold right and middle scroll wheel
- Fix: Don't deselect when right mouse button used to repair or other special control

24/4/15
- Hold right and middle scroll wheel cycles the current material, device or weapon depending on current selection
- Added HUD details for workshop, upgrade centre and factory

25/4/15
- Create new front end for campaign management
- List the campaigns available and show their status (in progress), one save game allowed per campaign
- Allow a campaign to be started and its difficulty level be selected
- Allow a campaign to be abandoned
- Difficulty level is stored in campaign save file
- Fix: Text controls only consider immediate children as candidates for their icon constrol (fixes crash in UI editor)

26/4/15
- Gameplay session with Nick, Tim Dawson and Nart

27/4/15
- Hat switch is mapped to arrow keys to allow PS4 controller to pan view
- Fix: replay folder not created from scratch
- Put Next at the top of the pause menu
- Move mouse cursor to control center when tabbing through controls to allow PS4 controller to activate a control with cross button
- Clicking on the icon for the currently selected device deselects the current device

28/4/15
- Fix: Set a minimum time threshold at which a drag style struct build will kick in to reduce occurance of accidental mini-struts
- Desync: Observer desyncs the game when joining late
    - Host and joining client set the state to playing immediately, while the other clients put the client status message in the command queue to be processed later
    - Necessary so that host can send commands to the joining player immediately
    - Need other clients to bypass the command queue, but it still risks being out of sync with the host
        - Solution: include the frame number at which to apply the client status

29/4/15
- Fix: Commander gauge is visible to observers and HUD shows on desync
- Make Log Trace add a newline, update all uses
- Rename DebugMainLog to Log
- Rename all m_ prefixes to m
- Left click outside of context menu closes it.
- Fix: Don't try to create devices if context menu is visible.
- Fix: autodoor not working without armor, searched properly for door material to enable

30/4/15
- Balance: increase repair rate
- Show upgrade icon instead of build icon for upgrade devices
- Fix: Main menu 'Campaign' item starts white; TextButton items should apply their normal colour on initialisation

1/5/15
- Controls can be drawn before their parents
- Commander profile textures shown on HUD

2/5/15
- Merge MapSelect and FileSelect functionality into one flexible class
    - Search string is assumed to be a directory if it doesn't have a period in it
    - Populate list by search (file or directory) or script list with optional name mapping
    - The UI file acts as a 'skin' to change appearance
    - If the preview is present it can be set
        - Add preview file search string (uses file location path to build search string prefix)
    - Add selection callback and tool tips to map select
    - Add listPos to map select
    - If the select button is present then an item can be pressed before committing the selection
    - Externalise a filter callback and use it for the 'with AI fort flag'
    - Converted all FileSelect usage to MapSelect

3/5/15
- Remove old FileSelect files and references, delete FileSelect files
- Add commander preview to commander selection screens

5/5/15
- Support automatically detected corners and edges in Static control
    - When texture is set, look for corners
    - If no corners found the Static behaves as before (solid texture)
    - If corners found
        - Add child Static controls at each corner, flipping accordingly
        - Add child Static edge controls between the corners (basic texture if no edge found)
        - Add child Static central control (basic texture)
    - Fix: seams between child controls: use GL_CLAMP_TO_EDGE instead of GL_CLAMP
    - Don't save automatically generated controls in the page file
- Fix: glitch when going from main menu to the options screen for the first time
    - reset the current texture after using the font library so the actual texture is bound
- Cleanup auto-generated child controls when changing texture of a framed Static
- Fix: handle case where there are no items in a MapSelect list

6/5/15
- Map set uses directory name as display name by default to simplify the script
- Fix: ListBox reporting item selection when the item is not visible (invisible replay details showing up in tool tips)
- Fix: grouping a weapon with another weapon which is the only member of a group selects that group, doesn't add the first weapon
    - DeviceGroup::MembersMatch was producing incorrect results sometimes

7/5/15
- Prevent text from changing scale in the UIEditor
- Add buttons to re-order controls in UIEditor
- Fix: prevent entire collapse of tree view in UIEditor
    - Store a list of open and selected tree items as control pointers before modification
    - Make the modification then expand the list of previous expand items
    - Do the same for selection

8/5/15
- Add copy and paste in UIEditor
    - Serialise control to temporary file then restore it
- Add a button to the console to close it with the mouse

11/5/15
- Convert UI screens to Lua scripts
    - Base table is called Root
    - Configuration of control is written in the table
    - List of children is written in the Children table, in render order
- Add draw before parent checkbox to UIEditor and value in control serialisation
- Allow checkboxes to be clicked on directly
    - When setting the icon for a TextButton, make it a Button rather than a Static
    - Take the colours from the parent Static
    - When that Static receives a click call the handler of the parent
- Button controls make rollover, depression, and release sounds like TextButton controls

13/5/15
- Add style sheet system for colour schemes that can be referenced in the UIEditor
    - Single style sheet for all controls
    - Each control has a style that is found in the style sheet
    - Each style defines parameters for all types of controls
    - When a control is written it only writes a parameter if it differs from its style
    - When loaded it uses the style's parameters as defaults

16/5/15
- Add position variables to styles.lua and UIEditor
- Restoring controls from script with style refreshes values
- Empty size string for Static controls means native size times default scale or aspect ratio
- Allow style change to apply to multiple selection
- Make control width and height scriptable
- Constrain viewport to 16:9 in front end

17/5/15
- Safe zone adjustment in options screen (Display::SetViewportBorder)
- Allow Display to switch between fixing the horizontal or vertical dimension of the virtual screen (Display::SetVirtualScreenMode)
- Use full viewport but move the pages down to center vertically

18/5/15
- Static highlight option for TextButton
    - Cconfigurable in UIEditor (Slave checkbox for Button)
    - Create two-way highlighting system
        - TextButton (and Button?) control has an option to link to child buttons (mSlave variable in Button)
        - Child buttons highlight parent and vice-versa
        - If child button registers the click it is passed to parent which passes it to callback
    - Use this to replace specialised icon handling for checkboxes
- Hack FTGL to support vertical gradients when rendering Textured glyphs
- Fix: UIEditor loads the same fonts/sizes from constants.lua as the game
- Avoid UI screen script variable writing when they match the default (colours don't work well)
- Fix: UIEditor wasn't setting button rollover colour properly
- Fix: UIEditor wasn't clearing draw early checkbox
- Fix: UIEditor didn't allow the root control to be selected and edited

19/5/15
- Added some new front end texture assets
- First pass on title screen

20/5/15
- UIEditor: hide auto-generated controls
- UIEditor: optional faint outlines of all controls

23/5/15
- Automatically duplicate ListBox prototype child controls (e.g. Button highlight control)
- Select the next font size up instead of the closest to improve sharpness
- Added ListBox colour to style
- Fix: text bounds don't match rendering
- Fix: handle highlight colours and audio cues when TextButton is overlapping slave Button (hacked)
- Fix: control anchor not showing up in UIEditor

24/5/15
- Build new map selection screen for sandbox and skirmish

25/5/15
- Fix: incorrect mass highlight when tabbing out of listbox control
- Try using low-quality fonts for shadows: works and looks OK for large font sizes but alignment is off for small - could make it a TextParams option
- Fix: Add font size correction factor to constants.lua instead of depending on hard coded value
- Store UI control colours as ints for exact testing against style colours & shorter scripts
- Write control position and size as ints unless there is a fractional component

27/5/15
- Converted DebugUsedFileList to use std::string instead of strdup C strings
- Fix: used file list accumulates junk data (issue with text file character translation? weird. Now uses CMFile to write list as data)
- Removed obsolete equivalent file set system from DebugUsedFileList
- Fix: Ignore all folders outside of data and trim redundant directory prefix in used file list
- Fix: Replaced all forward slashes with backslashes for the used file list
- Fix: reloading used file list split paths with spaces into multiple items
- Used file list accumulates textures
- Automatically enumerate map previews to add them to the
- Added enumerate maps command to add all map files to the used file list

29/5/15
- Fix: UIEditor fails to show scripted sprites when loading a second screen
- Fix: Scripted control layout is in absolute coordinates
- Fix: UIEditor shadow settings are not restored when style is changed
- Fix: UIEditor parent should be selected instead of child if child is drawn first
- Fix: resizing a control with scripted layout doesn't clear the scripts
- Fix: complex Static controls with children obscured them due to uncontrolled render order (made auto-controls draw early)
- Add script variables for absolute parent x, y, w, and h to allow for relative placement of child controls
- Made a template screen to start new screens with
- Rebuild skirmish, campaign and options screens
- Fix: mousewheel over listbox leaves trail of highlighted items
- Add button to UIEditor to reset tab stop number
- Add new checkbox textures

3/6/15
- Add Static.Colour style and use it for consistent tinting of panels and listboxes (ListBox.Colour is obsolete)
- Allow tab panel to be created in UIEditor
    - Turn Tabbed panel into a control
        - Header and Panel children
    - Add save, restore and set style functions
    - Add create button toolbar
        - ask for text button or static button
        - creates header panel and two tabs with buttons/text buttons
- Fix: Centered buttons have incorrect mouse picking
- Empty x and y fields in UIEditor reset the position of the control relative to the parent
- Fix: ground texture coordinates aren't wrapping sometimes: HUD icon was changing texture to clamped

4/6/15
- Add feet panels to Static (allow the orientation to be flexible)
    - Graphic suffix _foot

5/6/15
- If a Text control is set as a slave it uses its parent as mIcon and sets that as a slave to itself
    - Allows Button->TextButton combination to behave as one button
- Setup automatic synchronisation of repository to C:\Users\Tim\Dropbox\Dev\Fort Wars\Current
- Fix: New Text, TextButtons appear with Ariel font - not Normal style. Applied Normal style to Static and Button too.
- Update scripted layout of child controls when resizing a control
- Rebuild Map Editor screen

6/6/15
- MapSelect can be used multiple times within an existing page (e.g. map editor screen)
    - Set the mPageRoot and mSelectButton values in ListMapsCommand

7/6/15
- Move layout parameters to separate file and remove Layout prefix
- Increase layout script box length
- Add line spacing style to ListBox

8/6/15
- Add second colour to apply to controls to apply vertical gradients
- Interpolate second Static colour for automatically generated child controls of Static

9/6/15
- Add corner scale factor to style sheets
- Panel buttons go into background state (specified in style only) when not selected
- Fix: TabbedPanel not initialising font & font size from assigned style (caused crash)
- Rebuilt replay and commander selection screens

10/6/15
- Rebuild server select screen
    - public servers display on public tab
- Rebuild new server screen
- Rebuild chatroom
- Fix: update commander label and preview when team is changed, turn off when observer

11/6/15
- Fix: Nudging/dragging controls losing scripted position of other dimension
- Selection in tree view prevents nudging (allow use of numpad keys)

12/6/15
- Fix: EditBox control shows & sets pressed and rollover colours in UIEditor
- Edit box should not be highlighted when it has focus
- Chatroom should empty chat string if player escapes
- If the nickname edit box is left empty then revert the text to the value before editing
- Fix: in chatroom pressing enter in EditBox when empty loses focus
- EditBox cursor uses same style as text
- Fix: resizing text doesn't resize icon (e.g. checkbox)

13/6/15
- Fix: Resizing a centered control sends X off wildly
- Fix: if a Static is resized with negative dimension it can't be dragged

14/6/15
- Fix: setting script h of a panel changes the colour (divide by zero in Static::InterpolateColour)
- Fix: EditorMenu is updated twice
- Fix: List items with button highlights produce rollover sound when clipped
- Fix: right mouse button causes repeated sound
- Fix: ListBox using TextHeight instead of line height for scrolling and visibility tests
- Fix: ListBox not displaying tooltips when mouse over highlight button

15/6/15
- Fix: scaling of cost previews

16/6/15
- Fix: position of device cost details
- Fix: Select device item, right click to deselect it, then mouse over the item again and it buzzes. Right click again and it stops.
- Fix: Hovering over checkbox doesn't highlight associated TextButton control
- Reduce spacing of console text
- Center loading screen, hide mouse during loading, center mouse at world start
- Set Commander-Name label in commander selection screen

17/6/15
- In MapSelect, if Select button is absent then preview and tooltips are set on highlight, otherwise on left mouse down
- Show map previews in replay selection screen
- Select the most recent replay by default
- Use script Name variable to populate commander selection list and commander name on battle screen and chatroom
- Center pause menu items vertically

18/6/15
- Fix: Sandbox restart causes crash in Replay::ReloadFirstChunk(), file not found
- Fire takes some time to put out and repair doesn't occur until it's put out
    - Repair state reduces temperature
    - Fire goes out below threshold
    - Strut repair doesn't start until fire is out
    - Struts cool down to zero if not on fire
- Fix: if host quits the clients' chatroom is not scaled correctly
- Fix: map preview not freed
- Fix: fires let out unexpected steam effect before being put out during repair

19/6/15
- Battle screen remembers settings if player decides to go back and change the map
- Fix: commander panel is obscured by second reactor bar
- Fix: skirmish commander settings inaccurate without going through commander selection
- Fix: under siege countdown continues after team 2 wins and is not centered
- Fix: Dynamic parent layout variables take into account anchor position and script evaluation moves Static's window
- Control::CenterHoriz should center relative to parent, or screen if none
- Fix: replay button controls are not cropped and centered

21/6/15
- Add build-snipe mission to Hillfort (campaign mission 2)
- Fix: infinite loop when incendiary mortars pass background bracing

22/6/15
- Add fire extinguisher icon when putting out fires
- Fix: set an energy price for putting out fire indepedent of material repair cost
- Fix: steam doesn't come from fire location when put out
- New mission: sniping in Vanilla Small

23/6/15
- Device construction fails if platform is on fire (AI retries later)
- Fix: remove sandbags from early cannon mission and make AI build up mortars
- Fix: make AI build up mini-guns in 'wall' mission

24/6/15
- Fix: battle team needs to switch if AI fort unavailable
- Fix: projectiles that are post collision can still take down enemy projectiles (e.g. mini-gun vs. mortar)
- Make first mission (Vista) quicker to complete and add some armor to show how it works
- Change executable names and window title to Forts
- Assigned io, os, debug and other functions nil value to avoid abuse by mod writers
- Override dofile function for future incorporation into pack file system
- Fix: preview mines show randomised frames when there are no structures in the map, and don't move otherwise (now follows physics time)
- Fix: HUD layout in building tutorial, show new highlight arrow, adjust next tutorial button position

25/6/15
- Fix: escape can be used while the script is controlling the mouse in the tutorial (disable reactor bar)
- Fix: hide mouse cursor at tutorial startup and allow player to experiment earlier
- Fix: Pausing during tutorial panning breaks the panning on resumption
- Fix: Next should return to the main menu
- Fix: update tutorial speech
- Add tutorial tips when the user makes common build errors (e.g. a chain or extends a node under construction)
- Fix: prevent adjusting weapon direction if there is no enemy
- Fix: move foundation cost preview to the left to avoid colliding with link cost
- Fix: foundation tip talks over other tips

26/6/15
- Autodoor and grid HUD buttons: allow sticky buttons to toggle
- Add save and restore named screen console functions
- Change wording around mobility, prevent talking over at height test
- Adjust building tutorial screen positions to make foundation context menu visible
- Turn off transaction effects to improve clarity during building tutorial
- Add EarthWork Games icon
- Explicitly list maps that are added to the installer
- Add credits page to main menu
- Fix: tutorial talking over self when destroying fort before finished talking

27/6/15
- Fix: AddTextControl usage in effect_util.lua causes crash

29/6/15
- Resources tutorial
    - Introduce two resources & explain resource panel
    - Explain reactor
    - Build a mine & metal store
    - Build a turbine & battery - construction in rooms
    - Add OnDeviceCreated script callback
- Add next button to resources tutorial
- Add a tip when the player tries to build a mine incorrectly
- Add tip about mass
- Add a tip when the player tries to build a device off the platform
- Don't make player rebuild if he achieves the 100% 
- Updated all editor tab buttons

30/6/15
- Add a tip about scraping to recover resources
- Fix: tip about mass is overwritten by other speach
- Simplify AI fort recording (now \record and \end), display which team the fort is being created for
- OpenMap can specify mission team, so tutorial script can control both teams
- Script callback OnDoorControl
- Weapons tutorial
    - Build a machine-gun
    - have an enemy machine-gun shoot the fort to show deflection of light rounds
    - Build a machine-gun and a door
    - Shoot back at enemy fort

1/7/15
- Detect first execution by a new user and launch the first tutorial immediately
- Turn off music at the beginning of each tutorial
- Updated loading screen
- Use localappdata directory if running installed game (hack: looks for .ico file)
- mplayer is placed in temp directory, user folder is deleted on uninstall
- Fix: missing letters, removed next tutorial link (seems to be causing it)
- Replace mplayer with mpc-hc to fix installer freeze and resolution changing while watching teaser video
    - Add registry value to prevent update popup dialog
- Add a script function to add Button controls to the HUD
- Fix: replace buggy TextButton with baked Button control to go to the next tutorial
- Remove the test campaign
- Added FortsTrailer.mov to media folder

2/7/15
- Added key bindings to options screen
- Use screen background for the loading screen
- Fix: stretch tool tip bar to fit screen
- Update weapon/device tips
- Fix: move tute1 marker so it passes accurately
- Fix: make material buttons pressable while sticky
- Fix tute3 door selection detection when mg is shot up more than once
- Mention how to shut doors in tute 3
- Fix: feedback given for zero efficiency turbines
- Remove 'efficiency' in front of percentage when previewing construction and prevent it moving with scale
- Add reminder with arrow about expanding foundations after timeout
- Fix: it's possible to trigger the repair with mouse left & right when controls are disabled

3/7/15
- Fix: save campaign progress on the completion of each mission
- Separate objectives from tips
- Add a tip to use the spacebar to cycle view and middle mouse to pan
- Remove third mortar & some extra bracing and delay extra bracing in 4th mission
- Allow all tutorial dialog to be skippable (space bar)
- Only show build limits when cursor is near or beyond
- Only draw part of the limit circle in the direction of the cursor

4/7/15
- Fix: Mouse cursor was sometimes forced to normal in weapons tutorial (mStateForced was uninitialised)
- Fix: fog of war disabled in weapons tutorial
- Point out that the reactor can be hidden in the enemy fort
- Increase initial tutorial resources to make it a nice number for the building tutorial

5/7/15
- Fix: need to remove lock and enable button when script enables an item on the tool bar
- LoadScript passes sTraceCallsToApp in call to actually enable call tracing
- Make tutorial replays functional
    - Some events such as selection of a device are not recorded as commands
    - Could record the execution of script event calls in commands and execute from replay
- Add a mod to set FramesPerTick to 1 to improve reliability of stream completion calls (investigate properly)
- Fix: infinite loop and another crash to do with OpenTab
- Decrease sniper skill in mission 3, remove 1 sniper
- Fix: reset mTransitionPaused and cancel movement when quitting in pause menu
- Reduce mortar power text size
- Add mip-maps to avoid moire on materials and cladding

7/7/15
- Reduce client name font size
- Don't draw limit arc when linking to a node past the normal max
- Pre-tension the ropes and reduce their mass
- Show an icon to indicate when a strut can support a device
- Fix: undo delete if any of the links at a node are being deleted
- Use pegs for all rope foundations until joined with an solid strut
- Removed all references to FortWars

9/7/15
- Fix: deleting a node with a link connected to a rope can cause the link to turn neutral before it's finished deleting
    - Rope node doesn't turn back into a peg

14/7/15
- Fix: unlinking a node by angle doesn't update the node graphic (e.g. when a strut falls off a rope foundation)
- Add a different sound for a door opening than it closing

15/7/15
- Fix: Can't allow rope attachment while excluding foundations
    - TerrainManager::CanPlayerBuildOn was only returning true if the block supported foundations
- Fix: Make production maps consistently able to attach ropes to non-rocky ground
- Fix: left click outside of the context menu hides it
- Fix: disable snap to node when link context menu is visible

16/7/15
- Save user settings in a Lua file, including safe zone
- Add a gameplay option to retain device type after deselection
    - Don't show preview if off and device is selected
- Add an option to allow left click to deselect weapons
- Fix: Select a built battery while in weapon mode and both battery and metal store are highlighted

17/7/15
- Add fire extinguisher sound when a fire is under the repair area
- Remove obsolete GlobalPageStack
- Add border value to settings lua
- Fix: mip-map generation/binding not working consistently
- Add lod bias to improve texture sharpness

18/7/15
- Fix: Cursor is still sometimes stuck on normal in weapons tutorial (remains in forced state when quitting game from pause menu)
- Fix: Don't show costs in details panel for some items (e.g. reactor) (added mShowDetail to DeviceSlot)
- Fix: HUD items slide rapidly when changing tabs, only when clicking on already built devices
- Fix: removed use of GL_POLYGON_SMOOTH which causes artifacts when drawing links

19/7/15
- Fix: fires jump around sometimes (e.g. testground map)
- Fix: if settings.lua doesn't exist use current screen resolution instead of hardcoded defaults
- Fix: Save LeftClickDeselectWeapon to settings.lua

20/7/15
- Sample filename shorthand now tries to load mp3 files too (before wav files)
- Add listener position and effect position for sound effects
    - add falloff and min/max distance factors to constants
- Add effect pos to operate, shut, open door effects
- Convert positional sounds to mono
- Add position to structure stress effects (geometric center of structure)
- Add a sound effect to projectiles (missile, mortar)

21/7/15
- Add support for sound effects fading in and out, and randomised trigger time
- Increased mortar trail volume and added short fade in period
- Add custom (linear) attenuation to SoundEffect class based on camera position (CameraFadeDist)
- Add support for randomised start position for fire sound effect
- Add device ambient sounds (reactor, mines)

22/7/15
- Fix: right click in aiming arc while grouped deselects group instead of alternating fire
    - Also can't deselect missile launches with right mouse for a time after they launch
    - only when 'left click deselects weapon' is enabled
- When multiple missiles selected and sniper does not have a painted target, right mouse click deselects the weapons
    - If all weapons are not available to fire then right click deselects
- Make fire sound broader
- Add a sound effect to projectiles (cannon, swarm)
- Add trail to cannon projectile

24/7/15
- Fix: Fire sound cranks up immediately after pause menu is closed
- Test: cannon projectile continues after mid-air collision

25/7/15
- Allow trail colour to be adjusted
- Add device ambient sounds (battery, turbines)
- Adjusted mortar power and fire radii to make short range mod adjustments obsolete
- Game session with Nick to make new screenshots

27/7/15
- Effects can be disabled and re-enabled
    - Only play device ambient sounds when in idle state
- Fix: don't update effect script if delta is zero (prevents repeated sound trigger)
- Double keyframe rate of the swarm trails to reduce corners
- Turn off debug text when taking an ordinary screenshot (delays screenshot by a couple of redraws)

28/7/15
- Fix: shields came back on after being turned off (RepairArea wasn't using DisabledRepair state)
- Fix: materials button gets stuck
    - Selecting the reactor in game doesn't switch to the devices tab - problems happen after that
- Fix: enemy mortars are hard to hear, increase volume
- Fix: disable keyboard hook when not in focus (improves typing response speed out of game)
- Alt-S will take screenshots in the front end with suffix -menu
- Add wide string support to Store (GetWString) for multiple language support

30/7/15
- Localisation support
    - Any script can contain strings (e.g. commanders), the variable name being the string id (mostly in strings.lua) with $ prefix
    - Each language is implemented as a mod prefixed with language-
    - The language mod's strings file can change the font
    - English is the basic language and can be used for the basis of other translations
    - Any strings not found are replaced with the id (not found)
    - Text controls hold both their string id and content
        - content is stored in wide characters and ASCII characters
        - modification outside string possible but not expected, wide character strings are considered localised or from user input
    - The language is a global setting, set the first time the game is run and can be changed in options
        - Try to select the language based on the current OS language on first entry
    - Separate mods should be able to contribute to a single translation
        - Allows translations to be added later for additional content
        - Single language folder; translations for separate mods have to create the folder if it doesn't exist

31/7/15
- Localisation support
    - Put main title size into a style (MainTitle) so language mods can adjust its size
    - Convert MapSelect/commander names to support wide characters
        - ListBox stores Text or TextButton controls; some handlers use the text
        - Need to be able to pass display wide character strings, but GetText only refers to char string
    - Editbox accepts only wide character input
        - Add WM_CHAR input to event queue for EditBox to consume

1/8/15
- Convert chat messages to wide strings
- Add constants to interface for convenient/efficient access
- Add a constant which can entirely disable commanders for early demonstration to journalists

3/8/15
- Desync hack: Avoid the random number desync by never calculating a random number if StdDev is zero
- Fix: nodes go through the ground if they reflect at a shallow angle just before a rise
    - Add a scaled normal vector to bounce the node off the ground, helps to spin structures instead of just sliding
    - Detect underground nodes and delete
- Fix: links deleted by vibration don't generate debris effect
    - Add variables to constants.lua to control vibration
- Reduce node/material collision effect volume
- Fix: upgrading the mine causes a crash (missing effect)
- Fix: HUD buttons still sticking
    - when materials are selected and D or W are pressed
    - right click on a strut, right click in space to close context menu, right click on a weapon
- Icons jumping when switching from materials to devices or weapons
- Fix: Weapon icons jump when using right mouse + scroll wheel

4/8/15
- Fix: can't deselect grouped missiles with right mouse when unable to shoot either for lack of resources
- Mortar air burst effect smoke particles follow the direction of travel or normal for swarm missiles hitting a surface
- Add a \reload_effects console function
- Device Node effects are continually tested for expiration to allow them to restart when effects are reloaded
- Add neutral team structure and device checksums to desync detection
- Fix: convert usernames to wide char, set host's username
- Fix: Maximum length of IP Address is based on a short address
- Fix: username and IP Address can be edited simultaneously on server select screen
- Limit IP address input to digits and periods
- Fix: not passing the address of local servers correctly - unable to connect
- Fix: left click on node, left click on weapon, right click to deselect: node snap still enabled during weapon placement
- Fix: Error parsing JSON when searching for public servers drops console
- Don't make auto-doors for mortars

5/8/15
- Fix: update tool tips for HUD items
- Fix: names not appearing fully in chat history

6/8/15
- Convert console to use widestrings
    - commands and variables will need conversion
    - having system wide character support will allow commands and variables to have localised names
- Fix: console not displaying full client names
- Fix: NAT punch through connection failure to server drops error message
- Console accepts wide char input for chat
- Fix: Tilde appearing in chatroom when toggling console
    - Mark as consumed and ignore input next frame when console uses it

8/8/15
- Fix: HUD tabs and items not hidden in tutorials
- Fix: HUD items not arranged nicely when enabled in tutorials
- Fix: Empty devices tab appears when selecting the mg in weapons tutorial
- Fix: New sync states were missing and caused a crash when slightly lagged
- Fix: missiles don't auto open doors
- Fix: An EditBox with original text can't be edited properly (set wide text from narrow text)
- Add Minigame-Height for recording maximum height of a fort

9/8/15
- Game On 2015 local games exibition at QUT
    - Very stable (no crashes or desyncs)
    - Height mini-game popular & fun (gathered some email addresses), although took too long (occupied PC while other people waiting)
    - Minor bugs (building missiles on soft ground, mortar muzzle pointing down, player state still 'playing' while in chatroom, flickering pause menu)
    - Accessibility issues (all caps DNK font hard to read, grid made it impossible to build full length struts, lack of player direction early on)
    - Presentation issues (no good pick-up & play map, no visual hints, repair system not obvious enough, grid too obvious when zoomed out)
    - Complexity issues (people building background bracing only, not understanding chain limitation)

10/8/15
- Fix: pause menu flickers in and out on client after game ends and before host has entered instant replay
    - Victory then client brings up pause menu. When reaches end frame pause menu flickers
- Fix: if client connects just after the server starts when commander is disabled the chatroom doesn't show it
- Fade out & disable grid with zoom level
- Fix: menus take a screenshot even when Alt key is not pressed with S
- Start with overview screen then zoom in to player's fort at beginning of match

11/8/15
- MapSelect supports simple information pages (use Page = true in map set)
- Tutorial list includes quick start guide simple page
- Fix: teaser is still playing during installation when user unchecks the option
- Revert default KeepDeviceSelection option to true
- Reduce size of height minigame to 6 grid squares wide

12/8/15
- Fix: alpine non-ore foundation surface not treated the same as that with ore
- Fix: change of mode in resources tutorial causes the devices to appear unavailable
    - Allow update prerequisites of inactive editors
- Allow scripts to disable deleting in structure editor
- Fix: remove instant replay from tutorials
- Fix: add next button to pause menu in tutorials
- Fix: can't control camera in instant replay
- Add visual indicator of area of repair
- Add help button to bring up quick start guide during game

13/8/15
- Replace padlock with tick icon for population limited items
- Move resource collectors to the beginning of the device list
- Create a new folder for each crash and desync to ease uploading (use date, time, and host computer name)
- Fix: set g_World to fix dumping of replays during a crashdump
- Save screenshot with crash and increase the compression level

14/8/15
- Fix: convert CommandInterpreter::LogCommand to use wide characters to handle GetClientName
- Reduce size of repair area effect to better match actual circle
- Repair devices under repair area as well as structure
- Debugging: Have server and clients exchange their world dump files for inclusion in bug reports
    - On desync, desynced client and host set up a request for files and send it to the other party
        - Each instance adds appropriate dump files to list and requests files from other
        - On request received sends file list back when files are ready
- Write random number seed to world dump

15/8/15
- Debugging: synchronise desync world dump
    - Need to keep a circular buffer of dumped world states and write the correct one on desync?
        - Allocate 8 memfiles to cover a second of gameplay
        - Write physics frame and world dump to first available or oldest slot
        - On desync search the list for the correct frame, or the first one after if not available
- optimise world dump
    - remove trailing zeros
    - don't write defaults
    - irrelevant fields (e.g. deviceT without a device)

17/8/15
- Tips: Add new script type that monitors the player and state of the fort, etc.
    - Add OnRepair callback to prevent repair popping up when player knows how to repair
- Add repair tip
- Stop showing a tip if it is dismissed more than 3 times and slow down reminders after dismissal
- Don't trigger repair tip if a device is being repaired
- Fix: Reset of mini-game scripts resets the score
- Fix: machinegun/weapons tab is selected on restart, even if weapons tab is disabled
- Hide tip if the condition is satisfied by other means (e.g. single link repair), but don't satisfy it
- Fix: cannon not producing a impact effect in campaign mission 4: projectiles can vibrate out of existance
- Optimise: only produce world dumps with every tick during online play
- Write testing guide for AIE students

18/8/15
- Fix: replays not passing filter as they are not directories
- Fix: MapSelect mCurrentType not initialised so pressing select in replays without first clicking on list causes no action

19/8/15
- Fix: replay list was almost empty after watching one completely and returning, then crashed
- Desync: clients on the same team as the host don't receive commander change updates?
- Fix: wide usernames not handled by client debug list
- Move client list down one line during debug mode and shift all down if any of the first few weapon group icons are visible
- Darken console background in order to remove the console text shadow (for performance)

20/8/15
- Fix: Host was truncating set commander message when relaying to other clients
- Fix: Projectile can penetrate a link (or at least hit a device behind it) if the line segment lands exactly on the link segment? Example in Vanilla_2015-08-19_160718
    - Movement of the structure over the frame to frame boundary can cause a projectile to pass through a structure
    - Look ahead a short distance to catch between frame movement
- Show where the missile launcher is blocked

23/8/15
- Allow armor to be turned into bracing by device placement (with scrap refund)
    - Set foreground material of core-armor to core-bracing
    - Don't show extra foreground button in context menu for armor
    - Refund team for resources freed from the armor
- Default to auto resolution (i.e. use the native system resolution), but allow it to be manually selected too
- Fix: energy costs missing from the device icons in resources tutorial and other random locations
- Fix: Weapons can be placed over open doors
- Fix: Fire on rope is offset too much

24/8/15
- Commander active sound isn't paused in replays and doesn't start when seeking into the middle of it. Seems to persist after use has ended
- Fix: can't create some neutral weapons in editor (e.g. missile launcher)
- Fix: If spotter doesn't have LOS the missile launches at the last contact point

27/8/15
- Fix: don't offset fires from cable joints (there are gaps between fires)

10/9/15
- word wrap for Text
    - If WordWrap is true then look for parent Static for bounds
    - Iteratively render parts of the text to fit the bounds
    - Adjust control size based on wrapping
    - Render as normal if out of bounds
- Tips:
    - Add tip template to HUD with wrapped text box 
    - Battery, MetalStore, Turbine, Mine

11/9/15
- Split FIRE_RESOURCES and MOUSE_RESOURCES into additional metal and energy versions
    - Call OnBuildError with metal and energy types to trigger resource low tips
    - Add second state icon to resources mouse
- Fix: Only execute audio effect when trying to fire reloading weapon
- If resource is short and resource is at capacity then storage tip is shown instead of production tip
- Tips:
    - Persistence: Save tips.lua script state to user directory at the end of each game
    - Restore the condition & satisfy functions on load
- Fix: tip font doesn't word wrap properly
    - Build line string progressively and do length test on entire line

14/9/15
- UIEditor:
    - Fix: tips Font not showing up when changing to Tips style
    - Fix: Redraw screen when word wrap is changed
    - Fix: Text control_width set to zero when first setting its stringId
- Add reset tips function to the options Input screen
- Support markup to highlight text rendered in word-wrap mode, insert icons, etc.
    - Need to search for tags and break up rendering according to markup
    - use simple markup [HL][/HL] to indicate highlights (nothing else supported as yet)
- When building a new shield change material to bracing afterwards (prevent new players building many shields)
- Fix: text Highlight state is not carried over between lines
- Fix: Shields draw power before they are complete
- \cvarlist shows one letter non-existent variables
- Fix: Mini-gun closes the door soon after opening it in Simple skirmish
    - Out of sync FIRE_ enumeration
- Fix: Pressing S with weapon or door selected will close a door under repair

15/9/15
- Fix: Process completed streams in the main thread (fixes failure to allocate textures and display some characters during tutorials)
- Fix: Remove obsolete fake Next button assets and script

16/9/15
- Optimise: Send single checksum of checksums for each tick, and resend cached checksums on desync to discover actual cause
    - Have a separate message structure which sends only one checksum, but write full message to replay
    - If that checksum matches then assume in-sync
    - On a desync of that checksum client sends full checksum message, which updates host and other clients
- Fix: \recover causes a crash on all clients
    - Replay buffer is being flushed (twice) then written out & copied to debug dump folder
    - Need to keep the replay buffer and file untouched
- Fix: crash when leaving a replay (trying to save invalid mTipsScript state)
- Fix: Editor::MapPassesFilter was not closing successfully opened files

18/9/15
- Add an empty chamber click effect for when trying to fire a reloading weapon
- Fix: sound effects are cut short when time is sped up
- Remove obsolete realtimebuild mode
- Ease in/out camera movements at startup
    - Current: works out zoom and pan rate and applies them independently based on frame delta, then bound to world extents
    - New: current time is used to interpolate screen position (not necessarily linear)
        - Ease in/out of camera transitions
- Smoothly zoom into cursor position
    - Bound destination screen to extents before interpolation
- Add classes to handle a variety of interpolation functions

19/9/15
- Add LinearEaseInOutInterpolator to use for long pans at a constant rate, but with eased start and end
- Add ease in and ease out functions for future use

20/9/15
- Use the zoom step to interpolate the current screen with the final screen centred on the mouse position
- Mouse zoom rate is proportional to the current zoom level (so it moves faster when zoomed out)
- Show aiming arcs in replays
- Fix: pause streams while app not in focus

22/9/15
- Prevent doors closing on a yet-to-fire weapon
    - Delayed fire weapons that is firing tells the doors it will pass through when they are able to close
- Double click to toggle shields
- Add disable shield effect
- AddStrings script function to allow scripts to add custom (potentially nested) strings to the lookup table
- EnableTip/OnEnableTip to Allow specific tips or all tips to be enabled and disabled

23/9/15
- Allow custom tips to delay the core tips

24/9/15
- Send Control key state to avoid showing preview auto-doors when it's not on
- Fix: Client select message sometimes sent twice when using the middle mouse button
- Record incoming and outgoing data rates
- HUD and graphs update is run on a real time delta
- Switch to bracing after door is created (like shield)
- Add Doors tip for when player tries to fire through a non-door twice within 2 seconds
- Tips can customise their minimum delay
- Tip: Trigger LevelPlatform tip when user builds several non-level platforms in a row
- Tip: Suggest making armor if bracing breaks and player hasn't built much armor
- Added spirit level graphic to show when a platform supports devices
- Fix: crash when unable to load log_files.txt

25/9/15
- Fix: rare replay desync when keyframe occurs during flight of guided missiles
    - Physics time was not identical to correct execution (earlier)
    - Two missiles were updated out of order and consumed random numbers incorrectly
    - Restore the order of mesh projectiles as well as their contents
- Optimise: don't write missile state for non-missile mesh projectiles
- Fix: crash in CollideProjectileWithGround, HandleCollision line 312: mNode->mMeshProjectile = NULL;
    - Only reset the mMeshProjectile pointer if mNode is not NULL
    - Catch any exceptions during the assignment and display a error on the console
- Fix: Store the physics time keeper time in replay key frames for precise restoration of state

28/9/15
- Fix: Missile state of mortars is being included in projectile checksum, causing replay desync

29/9/15
- Fix: desync when client joined while host was linking two nodes
    - Client misses out on a few ticks worth of commands due to the 3 tick look ahead
    - If any player commands are sent in that period the joining player doesn't execute them
        -> Delay sending world state by tick lookahead, sending commands in the meanwhile
        -> At joining client save the commands in a command buffer
        -> When the state has been received send these commands to the world
        -> Ignore early ticks
    - If paused, operate as normal but send a message to tell the joining client that the game is paused
- Fix: joining client causes Clients desync in replay
- Reduce ease of triggering level platform tip, increase minimum delay for all tips

30/9/15
- Tip: if there is no sniper LOS and the player tries to fire the missile, tell player to use a sniper
- Fix: Tips state is not saved at end if it didn't exist on game start
- Tips expire after being on screen for some time (customised per tip)
- Fix: Re-enabling a shield after the door effect has expired causes a crash
- Fix: crash in tips.lua OnLinkDestroy if player had not built anything yet
- Fix: Missile launchers use last target position when aimed at open door ends
    - Collision with opened door ends blocks the spotter but opens closed or closing doors
- Fix: Energy production figure shown for reactor incorrect
- Fix: If a missile is selected when the best spotter has open doors pressing S will not shut them
- When trying to group ungroupable weapons show "can't be grouped" rather than "too many weapons"
- Fix: Don't save the group if adding a member to the temporary group fails

1/10/15
- Move tips up if enemy resources panel is visible
- Add enable tips checkbox to options
- Move building tutorial demo screen position so the tip doesn't get in the way of construction
- Draw metal and energy icons on structure cost preview: PhysicsManager::DrawConstructionCostPreview
- Draw metal and energy icons on device cost preview: DeviceManager::DrawDeviceCostPreview
- Show a tool tip when build fails due to aligned struts

2/10/15
- Fix: Can't launch missiles in level editor
- Adjust missile hardpoint to show a clearance warning when building over missile launchers
- Tip: Suggest shutting doors if a weapon was destroyed after a door was left open (weapon not selected)

6/10/15
- Fix: Don't trace UPnP progress from thread
- Fix: Right clicking on a device in structure edit mode makes the context menu jump

15/10/15
- Fix: Right clicking on a device or weapon to switch mode
    - makes the items in the HUD jump
- Fix: Prevent laser from destroying sniper fire
- Balance: Make swarm missile incendiary
- Fix: increase node drag for linked nodes to shorten post-collapse wobble
- Remove restriction that at least one link must be completed before construction of a new node occurs to reduce frustration
- Balance: reduce metal cost of turbines to make it easier to bounce back from being wiped out
- Balance: reduce hitpoints of mines to make them more vulnerable to explosions of falling objects
- Hide background bracing from the HUD items

16/10/15
- Show tool-tips about materials when hovering over context menu
- Fix: add a penetration hitpoint value to projectiles so AP sniper bullet doesn't go through more than one layer of armor
- Use windows username in dump directories instead of machine name
- Trace log file directory, executable path, executable creation time (in Brisbane time zone) and windows username at start up
- Trace which client is local and host when logging client database on World install
- Use new drill instructor for tips
- Fix: If the fort is damaged by self-collapse don't show the 'build more armor' tip
    - Add an enumeration to OnLinkDestroyed call giving the break type (projectile, splash, fire, stress, etc.)
- Move minable ground arrow down in resources tutorial
- Fix: turbine efficiency reading not showing up

19/10/15
- Allow script to enable and configure an AI
- Add introductory skirmish to the tutorial list (with AI on team 2)
- Add a tip pointing out the help screen for early games
- Fix: weapon group panel doesn't follow console position
- Fix: Tip customised MinDelay not being applied

20/10/15
- Fix: Tips are shown after the game has been won
- Fix: Tips are shown for devices and materials that aren't enabled
- Fix: Increase the repair threshold if tip visible (avoid hiding it due to destruction of the most damaged strut)
- Move objectives text position down a little so they don't overlap with the debug text
- Remove zoom value from the debug text except during edit mode
- Fix: disable tips in height minigame
- Add timer to height minigame
- Hide transactions and other distractions in height minigame
- Show a blank resources panel in 01-building and height minigame
- Add delete back to the node's context menu
    - when it is selected renew the context menu with only the delete button to confirm

21/10/15
- Add question mark to context menu when confirming node delete
- Fix: context menu flickers when left clicking confirm button
- Don't show minimum build length when cursor is close to the node
- Don't show build preview when cursor is over the context menu
- Enable node snap when structure editor context menu is up
- Snap to extent when placing a new node further than the max length
- Fix: editor crashes
- Show incomplete struts as translucent
- Alpha of struts under construction added to constants
- Don't show cladding until all edges are complete
- Fix: memory leak in Triangulate::Process
- Fix: device graphics not clamped, causing line artifacts on some devices and weapons
- Fix: Ground nodes are not snapping properly to the grid when coming from structure editor
- Fix: when preview node snaps to extent the aiming arc preview continues to track the cursor position, not the snap
- Don't draw door rails in preview or construction

22/10/15
- Fix: shield graphic is still visible when disabled
- Fix: shield displays power consumption when disabled
- Only show link production when it is highlighted, and center the text
- Fix: crash a few seconds after a laser is fired and damaged was caused (Shield tip was referencing a non-existent function)
- Fix: don't allow repair once game is over

23/10/15
- Fix: don't add maps in a map set to map select screen that don't exist
- Fix: validate the default multiplayer map (it must exist)
- Fix: clear up console logging of debugging info during multiplayer
- Fix: can't select anything after skirmish restart until devices tab selected
- Fix: Repair tip causing a periodic stutter when enumerating links
    - The engine now tracks the min link health and the number of links on fire for query
- Fix: delete key will destroy a link but not undo one
- Fix: links being scrapped are translucent
- Cancel repair if a link or device is damaged again
- Add a repair rate modifier to materials to speed door repair by 50%
- Fix: add 'next' link from tutorial 3 to 4
- Add height-minigame to tutorials list
- Add demo mode toggle button to main menu
- Add start tip to height minigame
- Add rope tip to height minigame suggesting using ropes to attach to ground
- Add separate skirmish and multiplayer map sets for demos
- Reduce cursor speed by a custom amount when inside weapons' aiming arc (optional)
- Increase minimum aiming arc for machine gun, minigun and cannon with shortrange mod
- Fix: replacing a link material shows translucent link while standin
- Fix: changing mouse sensitivity from the default causes middle mouse pan to move out of sync
- Fix: can't extinguish fires

24/10/15
- Fix: node effect manipulation cause crashes when effects are disabled
- Fix: replay desync when restoring keyframe with laser cutting short soon after on bg-bracing which is breaking at each end
    - beam segments are not restored immediately upon keyframe restore: store them in the keyframe    
- Fix: increase replay keyframe period from 0.5s to 5s to improve performance & reduce replay size
- Add missileswarm-ready texture for launcher
- Desync: Creating a link to a recently disassociated node
    - Require that at least one node is owned by the requesting team
- If the node or device selected by a client becomes neutral then assume no selection

25/10/15
- Quick start guide not showing up in tutorials
- Make AI easier
    - Alternate between construction, idle and offense
    - Track new nodes that haven't been braced yet and remain in construction phase until braced
    - Reduce damage thresholds for easy setting
    - Increase weapon standard deviations for easy setting
- Fix: prevent BraceNewNode from using a future material replacement
- Optimise: AI repair only receives calls for links and devices that are less than the damage threshold
- Turn down volume of shield destruction effect
- Reduce Easy difficulty level in the game
- AI keeps track of offensive opportunities (weapons firing at targets)
    - reduces construction pause at higher difficulty levels if they are low
- Removed rope in skirmish tutorial to prevent AI reconstruction efforts getting stuck

26/10/15
- Added return code mappings for script functions, revised ai.lua's LogError usage to show hitches
- Fix: AI was not ignoring non-selectable nodes and creating incorrect mappings when ropes were being made
- Fix: first strut connecting AI fort to a neutral fort wasn't being recorded
- Fix: AI not opening/shooting missiles through doors
- Fix: if missile is fired while spotter door is opening, previous location is selected and missile is fired
- Fix: Spotter's door opens without a discrete click when the missile has its own door
- Fix: Right clicking grouped missiles deselects them or doesn't fire them
- Added damage states to cable

27/10/15
- Fix: it's possible to delete nodes during the early resources tutorial
- Add attract mode to replays: cycle the camera randomly
- Attract mode seeks to beginning when it reaches the end
- TextButton supports double click, MapSelect, EditorMenu and CampaignMenu supported
- SaveScreenPositionFromTeamExtents adds space on either side if there is an enemy in that direction

29/10/15
- Reduced Minigame-Height pad to 4 units wide
- Reduced time limit to 3 minutes
- Added a tip about using the grid

31/10/15
- Fix: RepairArea doesn't take into account Repairable flag
- Double repair radius to make it harder to miss things
- Repairing a node or link repairs the area around it

2/11/15
- Fix: AI can fire guns after disconnection
- Reset time speed on map restart (e.g. after instant replay)
- Clicking on difficulty radio button current selection turns it off
- Fix: node selection lost when connecting to neutral structure

3/11/15
- Replay desync: drag not updated when AI device placement pushes a strut into the foreground
    - Fix: CommandInterpreter::ReceiveCreateDeviceMessage tests that a device is not obstructed before changing the material to the foreground
    - Fix: CommandInterpreter::ReceiveCreateDeviceMessage tests that a link is not obstructed before changing the material to the foreground
    - Fix: CommandInterpreter::ReceiveCreateDeviceMessage updates node drag and plate index after changing to the foreground
- Fix: LinkCounter always passes health filter if there are any fires on the link
- Mini-guns facing wrong way in PAX-Cannons and devices flipping generally
    - Don't set the direction of neutral weapons
    - Force devices to the default direction
- Fix: New node not snapping to correct extent from isolated foundation
- Add faint circle for the maximum link length
- Fix: must be in structure editor for hover over door & S to close a door
- Add Factory tip to skirmish

4/11/15
- Fix: context menu was showing in some circumstances when trying to double click to operate a door
- Fix: increase double click threshold to 0.5s
- Double-click on doors open/shut when building

5/11/15
- Make master of a weapon group more obvious (adjust contrast between master and slave)
- Allow double-click control of doors when device or weapon selected
    - Turn on link snap when creating a node but filter out anything but doors
- Add optional auto close doors on weapon deselect or destruction
- Go to structure edit mode when left clicking on a door without a device blueprint selected
- Deselect node if right clicking on door during construction
- Switch to bracing after creating new armor
- Don't switch to post-create material when replacing
- Don't show building gizmo when in pause menu or far from node
- Increase arc span for minimum length indicator
- Always show minimum length circle, same colour as max length circle

9/11/2015
- Added Steam build system in autobuild/steam
- Integrated Steam API with matchmaking/server browser
- Modified steamworksexample for compilation in VS2005

10/11/2015
- Tested Steam integration with Nick
    - He was unable to start the game (thinking for a few seconds, then nothing)

11/11/2015
- Fix: crashes due to accessing NULL Steam interfaces and exiting when not logged in
- Fix: public servers tab crashes if not logged into Steam
- Set up automatic build DRM wrapping
- Added lobby browser and lobby screen

13/11/2015
- Integrate Steam lobby system & peer-to-peer communication
    - Add new tab to Server Select to list lobbies and create a new one
    - Add a new lobby screen to wait for others to join
    - Add peer-to-peer alternate communication system
        - If a user's SteamID is set then send messages & receive messages via Steam
        - Change except parameter of Multiplayer::SendToAll to a client Id
    - Move SendToAll and SendTo functions into ClientDatabase

16/11/2015
- Fix: unable to connect through lobby more than once in an execution
    - Reset Multiplayer::mConnectedToSteam in constructor to stop invalid game SteamID being sent to connecting clients

17/11/2015
- Desync: commander points/activation after Nick fired his laser at me, I was trying to fire grouped missiles with Ctrl held
    - My commander was active locally, but not on Nick's client. Commander points were too low for proper activation.
    - Doesn't occur in replay and no messages shown - indicates it was not triggered externally
    - Something going wrong with push/pop commander state (selected weapon must be neutral creating invalid array index)
    - Fix: deselect if trying to group nothing and the current weapon is not friendly

20/11/2015
- Fix: Join any time feature broken for Steam connections
    - Need alternative file transfer using the Steam peer to peer networking
    - Send directly through a messages
    - Send this pointer as request ID, with addition number, add index and count
- Fix: Initialised sString on first execution due to invalid initialisation on test PC Debug build
- Fix: moved interpolators out of global namespace due to weird vtable issues on test PC Debug build
- File distribution needs to handle different destination directory on receiver
    - Write relative path & filename into filepath field
    - Include a destination directory type (either data or user folder)
- Fix: SetupReceive not called for join files when not connected to Steam

21/11/2015
- Device node effects can be automatic (starts and runs always) or not
    - ConfigureDeviceNodeEffect can be used to turn it on or off
- AddDeviceNodeEffect adds a new node effect
    - Commander script Load function called after device templates have been created but before map is read

23/11/2015
- Fix: Buffer overflow when writing used files
    - Include null terminator for block allocation during text operations
- Fix: missing battery ambient sound
- Fix: double click on ListBox item highlight doesn't select the item
    - Support double click on Buttons
- Fix: effects spawned by destruction of links were not aligned with projectile
- Fix: particle effects were not oriented correctly for commander effects
    - Adjusted texture coordinates and rotated fire, impact and explosion effects to compensate for textures (e.g. Angle = -90)
- Added damage and width multipliers to laser
- Added weapon and device icons for all commanders

24/11/2015
- Added accessories to mouse cursor (separate from sub states)
- Hide mouse accessories during pause
- Delete mouse accessories on world exit
- Show script errors when applying mod scripts
- Show exceptions (call, file, and parameters) when calling script callback functions
- Add makeshift button highlights for commander effects
- Add sparkle effect to commander icons and buttons

25/11/2015
- Fix: unable to connect over LAN
    - Don't send SteamID if connecting directly
    - Give preference to RakNet connection when it's connected to the client
- Fix: set path of commander script before it's loaded for correct sprite definitions
- Fix: don't show an error for duplicate sprite definitions for commanders
    - can happen naturally when the same commander is selected
- Live game matchmaking
    - Keep lobby going after the game has started
    - If the game server has already started when a client joins a lobby, connect to it immediately
- Add pulsing button highlights for HUD tab buttons
- Fix: disconnect from lobby when exiting lobby screen
- Create a lobby automatically when creating a new public game
- Fix: disconnect status message was being sent after P2P connection was closed
- Only start auto lobby if the server settings specified public

26/11/15
- Disable the create lobby button (rely on automatic lobbies when making public servers)
- Disable the public servers tab (not functional)

27/11/15
- \save detailed to save map with complete state (damage, fires, etc.)
- Don't execute mission script in Sandbox so AI forts can be recorded without interference
- Show debugging information if schedule call uses an non-existent function
- Show filename and call name if Load, SystemUpdate or Update causes an exception
- Added ExecuteInScript to allow disabling of AI offense at any time
- Add RotateSpriteControl and GetCameraFocus script functions
- Send mouse key events to scripts for navigation tutorial
- Fix: reactor button jumps to empty space when zoomed out too far
- Fix: reactor button needs to be cropped to graphic
- Fix: Create steam effect when extinguishing fires on game result

28/11/15
- Add repair & navigation tutorial
- Fix: space bar works when camera controls are disabled
- Add repair tutorial tips for navigation
- Fix: can't repair the end of a rope attached to the ground
- AI selects randomly from a list of targets of the current priorityType to distrubute fire more evenly
- Fix: SimpleRandom::Range was not including upper
- In repair tutorial Add a threshold over which a pan is successful
- Make fires more audible at wider zooms
- Fix: orientation of nuke glow effects

30/11/15
- Add system for configuration and gating of AI offense and development by mission script
    - offense point system
        - firing weapons consume offense points (one per shot)
        - these can be drip fed to the AI by the mission script to adjust strength of attack
    - set maximum group size
- Rate of mortar bombardment in repair tutorial increases over time and reduced total duration
- Fix: crash in commander scripts when tracing script calls (not including effect_util.lua)
- Increase accuracy of mortars at hard difficulty
- Fix: Unable to restart missions scripts due to order of execution in World::RevertMap
- StopStream(-1) will stop all streams
- Fix: OnTipHidden and OnEnableTip save the current func name to fix call nesting issue
- In repair tutorial split up pan_view speech for skipping
- Added proper tips for navigation to repair tutorial

1/12/15
- Set zoom tip in repair/nav tutorial
- Set client icon in Steam
- Make private location for discussion and scheduling multiplayer games
- Fix: help screen dropped when starting tutorials with hidden HUD
- Fix: Slave weapons don't auto-close their doors
- Replace placeholder music

2/12/15
- Remove mention of building doors over existing struts from weapons tutorial to avoid confusion
- Request user select the weapon to aim if it's not already (weapons tutorial)
- Fix: machine gun tooltip not visible at beginning of weapons tutorial
    - change edit mode when OpenHUDTab script function called
- Add SetDevicePopulationCap and use to limit device construction in resources tutorial
- Deselect at beginning of weapons tutorial so machine gun detail doesn't show
- Flash cursor a different colour when drill instructor takes control in building tutorial
- Fix: menu music would stop prematurely
- Cycle battle music
- Start intense music loop in repair/nav test
- Clear objectives and timer on end and restart in repair/nav test
- Enable grid and add voice over explaining it in building tutorial

3/12/15
- Fix: don't send status on Multiplayer destruction unless connected to a game
- Change the server name to that of the player
- Desync: fires of winning team are not put out consistently, moved to PhysicsManager frame update
- Add workshop prerequisite to the upgrade center and factory tool tips
- Move 'drag' into the simplified world dump
- Fix: replay desync
    - drag not updated after reverting temp neighbour recession on device placement
- Save screenshots as JPG by default. Make TGA a user option.
- Optimise world dump text
- Removed war_plan_sparse battle music (not intense enough)

4/12/15
- Check for duplicate SteamIDs when logging into chatroom
- Send ping from client to server on a regular basis
    - If server doesn't receive one for a a few seconds then disconnect user

7/12/15
- Minimise when app loses focus
- Set application icons for Alt-tab and task manager
- Increase minimum AI door close delay to prevent catching the tail of the laser
- Allow user to skip the navigation tests involving the middle mouse button
- Fix: campaign appears in progress when it doesn't exist
    - Stores that don't open are not marked as successfully loaded
- Fix: don't echo the console toggle key in the console edit box (ignore two updates worth of input)

8/12/15
- Fix: Console \keylist command was not showing wide character key name and ids less than 0 properly
- Custom screen positions saved with Ctrl+Keypad 1-5 are added to the end of the system screens (home, overview, enemy)
    - Space bar cycles to custom screens after home, then goes to overview and enemy
- Added Alt+Keypad 1-5 to delete custom screens
- Custom screen functions make a click if the operation was successful (placeholder)
- AI delays rebuild of devices/weapons after they are destroyed (adjusted based on difficulty)

9/12/15
- create a reload animation state for weapons
- Fix: Reload timer extended additional round for all weapons, increasing reload time unnecessarily
- Optimise: ClientManager::AllocateSpotters() performing ray tests on current weapon for obsolete purpose
- AddDeviceNodeEffect and ConfigureDeviceNodeEffect can take "Root" as the nodeName
    - game will look up the root sprite's name and use that
    - allows device sprite roots to have unique names for cvarlist identification (position tuning)
    - Reverted all sprite root nodes from Base to unique names
- Device highlights are now dynamically rendered with a second additive layer
    - Deleted all highlight textures for devices and weapons
- Moved CompositeSpriteTuner from Device to DeviceManager so it would only register variables for inactive Team1
- Integrated cannon reload animation
- Deleted weapon highlight textures in commander mods

10/12/15
- Integrated machine gun, minigun, ap sniper, incendiary mortar, and heavy mortar reload animations
- Made a new effect for ap sniper shell ejection (timing is different to sniper)
- Deleted duplicate textures used for minigun and heavy mortar debris
- Keep all core textures resident (textures loaded from mods folder are reloaded)
    - Reduces secondary load times by ~75%

12/12/15
- Fix: crash during instant replays in multiplayer
    - CommandInterpreter::SendToCommandQueue returns immediately if not playing instead of sending or queuing message
- Fix: SteamID of directly connected clients being sent still
- Fix: don't time-out clients that are connected outside of Steam
- Don't post game to RakNet master server (obsolete)

13/12/15
- Fix: replay desync when commander active during keyframe (commanders forced off when winning team set)
- Fix: allow seek command in online instant replays
- Fix: prevent players joining after game has been won
- Fix: desync as soon as new player joins if existing player is building (resources, structure)
    - Joining frame sent early
- Fix: missile explosion orientation wrong
- Fade out music on game result and back in on instant replay
- Fix: disable 'public' checkbox if not logged into Steam

14/12/15
- Render material highlights with additive layer instead of HL texture
    - Deleted all material HL textures and references from scripts
- Device and material highlight rendering done with a loop instead of code duplication
- Removed obsolete house and tractor beam assets and scripts
- allow AI to use machine gun for occasional harassment
- Fix: AI machine guns leaving their doors open for extended periods of time
    - don't abort fire if waiting for door to open
- Fix: AI doors closing on firing weapons
    - DeviceManager::FireWeapon opens closing doors even if there isn't a ray intersection
- Reduce AI anti-air effectiveness
    - Added random variation to projectile fire reaction time, modified by difficulty
- Increased device rebuild delay
- Replace GetInstance with Get
- Make missile launch path look different to other weapons
    - Don't draw aiming gizmo outline
    - Draw pulsing arrow over flight path
    - Attach tip to mouse that snipers need to paint the target
- Increased width of sniper painting laser and sight laser
- Fix: orientation of missile ground hit sprite
- Converted pause menu bg to PNG and defeat texture to DDS to save space/load time

15/12/15
- Fix: node highlight state uninitialised (random highlighting initially in editor)
- Fix: flightpath node flickering during construction
    - Set progress thresholds for missile weapon nodes
- Fix: time freezes instantly in Editor
    - commands dropped in edit mode due to previous fix
- Nick: Laser and missile reload animations added
- Nick: Mortar animation updated
- Nick: Cursor edges outlined
- Show flightpath for slaves in a group
- Pulse highlight for selected devices
- Fix: music stops after a while in skirmish
- MusicManager skips tracks which fail to load and logs an error
- Fix: cursor movement remains slow in pause menu if it was in an aiming arc when paused
- Fix: take laser sight width parameters from constants
- Make laserdot texture larger and additive
- Fix: timeout double click timer to prevent twice the number of double click events on rapid clicking
- Fix: handle double clicks as normal clicks for team and AI difficulty in chatroom
- Fix: Windows mouse partially active in multi-monitor setups
    - Set Windows cursor position to zero if active
- Snap ground devices as close as possible to adjacent devices
- Fix: Show red preview if trying to build a ground device over a solid part of the structure
- Fix: Unable to build new mines away from foundations in editor

16/12/15
- Fix: Cast rays vertically to snap adjusted ground device to ground
- Moved ground device snap threshold and offset to constants

17/12/15
- Fix: Missile aiming cursor tip drops out when leaving spotters' aiming arc
- Add laser sight dots/starter lines to all spotters when attempting to paint for local client
    - Add all eligible spotters to a new list called available
    - draw a stubbed laser pointer for them at current angle
- Create a new position for laser sights to come from ("LaserSight")

18/12/15
- Fix: ClientManager::SnapToLink crashes when selected link of remote client not found
- Fix: Convert GetPersonaName from UTF-8 to wchar_t
- Detect trailing 's' of username to correctly format default game name (e.g. EarthWork Games' game)
- Fix: increase max username characters to match Steam (32)
- Fix: Replay desync: don't change direction of new weapon unless can face the new direction
- Fix: don't send JoinUnavailableMessage in PlayerController::GameWon unless online (caused crash in replay at game end)
- Fix: crash when closing doors and the currently selected weapon is under construction
- Fix: disconnect client status messages are now route & handled through CommandInterpreter
    - Prevents replay desync when clients suddenly disconnect
- Don't show MOUSE_NEED_SPOTTER for remote clients & replays
- Added log_input, scroll_threshold and scroll_factor for debugging & tuning mouse issues
- Fix: duplicate chat messages in replay for client's own messages
- Fix: all team members are allocated a point immediately after the winner is determined

20/12/15
- Added invite button to chatroom
- Added note about connecting to steam in new server screen
- Handle +connect_lobby command line option to respond to game invites
- Implemented GameLobbyJoinRequestedCallback_t in Multiplayer, Editor and MainMenu
    - sets g_LobbyID to the Steam lobby ID
    - quits to main menu (waiting to finish loading first)
    - MainMenu detects g_LobbyID is set and (re)launches Multiplayer object
- Fix: observers can't control their view
- Fix: observers crash if current tool is cycled with mouse
- Fix: prevent observers from repairing and grouping weapons
- Fix: host can toggle commanders when observer but can't see or change a commander selection
- Desync: late joining observers can't change the commander enabled check state
- Don't keep an extra copy of constants for Multiplayer
- Fix: Pause sound effect is paused too, resumes on unpause
    - Allow sounds to trigger at negative age, prevent early out when delta is zero (paused)
- Swarm missiles are incendiary again
- Re-balanced PAX-Missiles map
- Fix: ground weapons mirror for team 2

21/12/15
- Add additional configuration variables to AI script 
- Fix: place AI configuration variables in data table to prevent replay desync when changed dynamically
- Added a reaction range for replacing devices (ReplaceDeviceDelayMin to ReplaceDeviceDelayMax)
- Added data.SpecialTargets for AI targeting control with data.SpecialTargetProbabilityDefault and data.SpecialTargetProbability table for per-weapon preference
- Added data.SmallArmsPrioritiesOverride and data.HeavyArmsPrioritiesOverride for altering AI targeting preferences
- Added data.FireErrorStdDevOverride table for adusting per-weapon AI accuracy
- Fix: Mission scrips are assigned to the Any team, ExecuteInScript allows calls into any other team's script

27/12/15
- Add a ready flag to chatroom
- Add terrain-only ray cast function to scripting for special target line of sight determination (ignore structures)

30/12/15
- Place bg-bracing over devices if armor or door selected
    - Armor and door use RecessionTargetSaveName and WeaponRecession for weapon auto-door instead of device recession (making way for devices)
    - Use DoorTargetSaveName during weapon recession instead, then use RecessionTargetSaveName for intended purpose
- Fix: doors crossed with bracing make the door hidden behind cladding
- Main door sprite is drawn in the background and shutters in the foreground so weapon barrels are drawn in between

31/12/15
- Add option to disable AI extinguishing separately to repair
- Add option to disable AI rebuilding
- Add option to disable AI device repair
- Add separate damage thresholds for AI device repair
- Fix: AI repairs ground devices
- Fix: scheduled call name is correctly reported when an exception occurs in SystemUpdate
- Flash available spotters when missile is selected
- Fix: When quick start guide is shown on launch, menu music doesn't start
- Hold R key for periodic repair at cursor
- Dim and shrink fires after repair starts
- Steam build submitted

1/1/16
- Double left click outside of aiming arc to deselect
- Fix: reset undo stack on \switch

20/1/16
- Fix: Selected disabled material (rope) then couldn't select enabled material by left or right clicking
    - Prevent selection of disabled materials
- Fix: Battle music doesn't restart after skirmish result
- Adjust position of cursor when aiming arc changes size
- Fix: disable tool tips in Sandbox

21/1/16
- Fix: replay desync when laser breaks a strut in the frame before the keyframe
    - Do not use effect associated with beam segment (and its material index in userdata) to decide on beam owner if current link is not found
    - Instead report the hit material to the weapon immediately
- Fix: AI unable to rebuild starting foundations in mission 111
    - If a source node on the action table doesn't exist or isn't owned then skip it and try again later

22/1/16
- Add copy map function to editormenu screen
- Fix: AI can't rebuild down to neutral structure which has been severed
    - AI DiscoverLink creates nodes in both directions for existing links to cover all cases

23/1/16
- Fix: AI doesn't brace new nodes made during original fort rebuild
    - Original fort rebuild actions prioritised by links, nodes then devices (separately)
    - Discovery link enumeration is now started from any reactors on the team

25/1/16
- Make MarkStructure breadth first to make AI rebuild from around the reactor first
- Fix: BreakStructure can cause AI to lose track of a node which is still attached
    - The node with links which has rotated the least should retain the original ID
- Fix: in BreakStructure, links that are also rotated but follow a detached link are skipped
- Fix: double click on speed adjustment buttons ignores clicks

26/1/16
- Automatically darken ground blocks when pushed into the background & reverse
- Hide & don't update tooltips when pause menu is visible
- Add cost preview to right click menu, with durations (e.g. repair time, upgrade time, close door time)
    - material change (including reclaim)
    - repair cost/time
    - close/open door
    - device repair
    - device upgrade
    - device reclaim
- Fix: PhysicsManager::GetLinkRepairCost incorrectly calculating value
- Cannon and laser remember target
- Fix: upgrading a device doesn't show transaction
- Fix: rope reclaim doesn't show transaction

27/1/16
- Fix: remove cannon loaders during construction
- Fix: rope reclaim preview doesn't iterate entire length
- Fix: reclaiming orphan foundations doesn't return resources
- Fix: cable getting more metal back than it took to make
- Fix: hide all flight path sprites during replays
- Fix: missile launcher mirrors shortly after keyframe restore in replays
    - Don't change the pan angle of ground device previews (may have been lifted from another weapon)
- Fix: widen missile launcher and mine bounding boxes to prevent visual overlap
- Fix: ground devices can be built on non-supportive blocks when snapping to adjacent devices on a different block
- Fix: miner animation doesn't start if created during pause in editor
    - DeviceStateSetter::ProcessNode uses UnforceTime to clear the forcing done on the cloned preview device
- Steam build submitted
- Clear root folder of build to allow removal of obsolete files
- Copy exclusions.txt to base folder to avoid the use of problematic %cd% variable which may have whitespace
- Added batch files to exclusions.txt

28/1/16
- Fix: PhysicsManager::BreakStructure crashes on node ID resolution if either the current or new node has no links
- Fix: Context menu not hidden if selected node becomes an orphan and is deleted by PhysicsManager::HandleCollisions
- Fix: Context menu still visible when the selected node or link is no longer owned
- Fix: double click on context menu bin icon doesn't register click
- Fix: Node or link context menu repair area effect is centered on mouse, not node
- Fix: replay desync when connecting to neutral structures
    - PhysicsManager::MarkStructure was following standin links
- Fix: no replay preview when trying to create foundations
- Fix: neutral devices are deselected immediately in editor or sandbox
- Steam build submitted

31/1/16
- Fix: Nodes snapped to ground move downward when placed snapped at the edge of the extent
- Fix: error position is still snapped to ground if the link is too long
- Fix: no error if click inside ground within extent snap limit in StructureEditor
- Fix: PhysicsManager::BreakStructure gives the new node the original ID if rotation is anti-clockwise
- Fix: replace pan angle with Facing enumeration

1/2/16
- Fix: slaves don't change direction with master in under siege map
- Fix: outline and fill of aiming gizmo is out on under siege map at start
    - Convert legacy data on load
- Fix: panning of slaves is twitchy when panning master rapidly
    - Weapon::SetAim needed to reassign DesiredPanAngle to avoid change by SetFireAngle
- Fix: in editor while paused, create reactor then start simulation. 'contruction' icon remains on it.
- Fix: in editor while paused, create machinegun. 'head' of mg is not visible until unpaused.
- Fix: can't fire neutral weapons in editor
- Show device upgrade cost when it is unaffordable
- Fix: crash in DeviceManager::DrawDevicePreview from ClientManager::Draw when snap state nodes are NULL
- Fix: AI turbine facing wrong way
- Fix: AI not rebuilding devices after failing the first time
- Fix: Adjust positions of ground devices/weapons on Vanilla AI fort to compensate for increased width
- Steam build submitted

2/2/16
- Fix: deleting an isolated node doesn't show a transaction

3/2/16
- Fix: mg bullets can settle on wood after bouncing off armour. eventually fall through
- Add console option to dump world state every tick
- Fix: repair area can't be triggered faster than repeat period
- Balance: reduce wind turbine hitpoints
- Rename effects/effect_util.lua to forts.lua

4/2/16
- Optimise: calculate bounding circles for ground blocks and use them for early exits during line seg intersections
- Optimise: DrawFires early exit if link or parallel link has no fires
- Optimise: cache loop counts
- Optimise: GetMaterialType does not validate index. Added GetMaterialTypeSafe for when validation is needed.
- Optimise: when a link is replaced, mark the replaced link so it is not drawn and replacement standin links don't have to be searched for
- Optimise: cache random numbers used in edge set procedural generation
- Optimise: Add FastSin and FastCos, use them in GenerateRotationMatrix

5/2/16
- Test: ground bounding circles slightly too small
    - Collisions appear to be accurate
- Fix: neutral structures don't show foreground bracing to conceal internal devices
    - PhysicsManager::MarkStructure not visiting all links
- Fix: Nodes of secondary structures sometimes appear behind links
    - PhysicsManager::MarkStructure not visiting all nodes and marking/unmarking properly    
- Added longburst mod and TestgroundBurst map for optimising collisions
- Added optimised square root function: fast_sqrt
- Optimise: cache loop counts
- Optimise: GetParallelLink
- Optimise: Removed GetParallelLink call from PhysicsManager::IntersectLineSegWithStructures

6/2/16
- Fix: Restart minigame-height does not reset the time/score readout if the timer had run down previously
- Add WeaponsStartLoaded rule for weapons to start loaded at start or when constructed
- Fix: shield still looks enabled when disabled, add a new alpha level (LinkWarmUpAlpha)

7/2/16
- Fix: build bracing then immediately replace with armor; armor is solid during construction?
- \set_background command converts ground textures and props to new environment
    - Shows an error if there is no corresponding prop texture in the new environment and leaves as-is
    - Reloads terrain and prop items for the new environment

8/2/16
- Fix: Separate RoundsEachBurst from reload period so long long burst weapons don't take extra time to reload
- Fix: longburst mod doesn't modify reload periods (can be combined with rapidfire)
- Fix: Selected mortar tracks cursor's power setting while firing bursts
- Add keep-unclaimed, high-resources and start-loaded mods

9/2/16
- Optimise: Don't call UpdateCladBothSides when deleting nodes without links
- Optimise: Only call non-specific UpdateCladBothSides at most once per physics frame
- Fix: ignore grid and ground when snapped to build extent
- Fix: shortening of link from isolated node outside of extent
- Fix: allow snap to ground if it's within the build extent and the cursor is outside
- Steam build submitted

10/2/16
- Add secondary camera constraint system
- Fix: camera oscillation at world zoom limits

11/2/16
- Move navigation tutorial to beginning of tutorials
- Added flag prop to canyon environment
- Restore structures in building tutorial if the player destroys their fort
- Fix: skipping building tutorial intro misses 'move the cursor...' speech
- Fix: skipping 'grid button' speech activates 'cycle view' and so restores target screen
- Fix: \save_screen does not create an undo level

14/2/16
- Remove navigation from repair tutorial (keep reactor navigation)
- Fix: Facing written incorrectly in world dump
- Fix: connection details logging usernames incorrectly (not wide)
- Steam build submitted

15/2/16
- Enable camera controls in remaining tutorials
- Add editor key to damage lightly around cursor
- If map was saved in detailed mode then save it again (add clear command)

17/2/16
- Fix: Team2's aiming arc was out of place when bracing blocked the weapon on the left
- Fix: Client team doesn't get a win point if they quit immediately after game is won?
- Fix: Alt-firing a group does not update the previous shot marker of the leader until it is fired
- Fix: can't precisely target sniper in sniper alley mission near horizontal (issue with FastSin/FastCos)
    - Device::CalculateAxes() reverted to sin/cos

19/2/16
- Fix: Foundations have incorrect angle on sloping ground
- Fix: W in building tutorial shows weapons tab
- Fix: pressing space to skip initial building tutorial speech cycles the view
- Fix: changing time speed breaks the building demo
- Fix: can modify forts in early building tutorial (e.g. delete nodes)
- Fix: cursor remains yellow when paused or quit building tutorial during demo
- Fix: repair key enabled during building tutorial
- Optimise: loop counts in TerrainManager.cpp
- Steam build submitted

22/2/16
- Make building tutorial forts face inward to reflect how normal maps are arranged

23/2/16
- Fix: can't move structures around smoothly even when grid disabled
- Add support for animated props
    - add animated props folder with sprites.lua
    - load and add these to the props tab
    - reference these by prop name
- Add environment/common/props directory for props useful for all environments

24/2/16
- Flush replay buffer just prior to next keyframe if it is likely to blow the minimum flush threshold
- Double the flush threshold if it is less than double the last keyframe size
- Added first pass of 'Missile command' challenge map
- Optimise: use breadth first search in AnalyseStructure

25/2/16
- Fix: AI configuration not sent to joining client

27/2/16
- Add additional logging to determine multiplayer launch failure point after loading

29/2/16
- Fix: Clients sometimes freezing in loading screen (host finishes first)
    - Multiplayer::HandleLoadComplete was relaying client status messages when other clients had finished loading (using invalid SteamID?)

1/3/16
- Desync: when node bounce with a standin link only

2/3/16
- Fix: Break standin link if the distance grows larger than the max link length
- Steam build submitted
- Fix: animated props not loading properly
- Fix: . and , make the weapons tab visible when disabled

3/3/16
- Add music script to provide dynamic music
    - Plays Intro track
    - Accumulates points for events (firing weapons, destroying things) and decays the value over time
    - Switches music between Idle and Intense based on activity threshold
    - Plays Win or Lose on result
- Fix: music doesn't reset on Restart
- Steam build submitted
- Increased timeout as attempted (temporary) fix for Lobby connection problem
- Steam build submitted

4/3/16
- Fix: track series are forced to be looping by ignoring loop parameter
- Fix: stop music when instant replay is started
- Add reactor low mode to music script
- Add fade out of the previous track
- Fix: Clearing music script was causing stopping the ai script getting commands from the mission script in repair tutorial
- Fix: Add DisableMusic() script command rather than removing the script altogether

5/3/16
- Fix: RotateSpriteControl searches for control in the world page if not found in the HUD page
- Change direction of arrow and text in resources tutorial to encourage sideways expansion
- Add mine to building tutorial demo
- Don't add delete button to context menu if the 'delete device' key is disabled
- Allow script to disable snapping to devices in material editor
    - Disable device snapping in building tutorial
- Disable barrel and target by default
- Add arrow to resources tutorial to encourage vertical expansion
- Fix: skipping soon after building machinegun in weapons tutorial leaves the build arrow on the page
- Fix: if door material is selected before arrow highlights it, the arrow is not removed
- Fix: Don't fire the enemy mg until the door is complete in weapons tutorial
    - Cast ray from enemy weapon to the friendly weapon
    - If it touches an incomplete door then don't shoot
- Fix: music playing multiple streams at once after game over
- Fix: music looping first track, not entire play list
- Fix: music script starts too early when waiting for multiplayer clients to finish loading
- Steam build submitted
- Fix: enemy mg still shoots through constructing door
- Fix: if you rebuild the mg straight after it's destroyed the AI doesn't try to re-shoot it
- Fix: stop music at end of repair tutorial
    - ChannelHandle was changing when next track was played, so music script lost track
    - Allocate unique ids for each stream play (singular or series) for later manipulation

6/3/16
- Fix: restart skirmish from instant replay results in frozen time
- Fix: skirmish -> instant replay -> restart -> instant replay: assert missing REPLAY_MARKER_COMMANDS

7/3/16
- Fix: device.lua in mod causes crash if EnergyProductionRate or MetalProductionRate is not defined in device script (e.g. explosive barrel)
- Fix: Win/lose music is played over instant replay
    - Add OnInstantReplay call to scripts, stop current music there in music.lua and start the intense music playlist
- Fix: skirmish -> instant replay -> restart: intro music and intense music playing simultaneously
    - Need to end old music before the state is lost

8/3/16
- Added CallScriptNoParams in WorldScript to ease the addition of simple event calls
- Fix: music works in replay, reacts to action after seeking
- Tutorial scripts only accept OnStreamComplete events from replay when in replay to maintain synchronisation
- Fix: music doesn't fade when changing
- Fix: camera doesn't zoom in on skirmish restart from instant replay (Reset PlayerController)

9/3/16
- Fix: record script triggers to replay file to advance tutorial replays (e.g. all panning directions satisfied, mouse wheel scrolled, etc.)
    - Target these events to particular scripts, or they could have side effects
- Fix: restoring the structure state in the building tutorial replay causes a replay desync
    - Write the trigger into a script event
- Save and restore next series Id in replay

10/3/16
- Fix: Non-playing streams accumulating when seeking around building tutorial replay
- Fix: pause not pausing streams in building tutorial
- Added a tag to each series calculated from the script name and team to allow a script to easily stop all streams created from it
    - OnPreSeek call added to scripts for cleaning up before a seek
- All tutorials store their variables in the data table for proper serialisation
- Added optional screenName to IsPointVisible to allow repair tutorial to test fort existence consistently
- GetLocalSelectedDeviceId falls back to the first valid client if there is no local client set (as in a replay)
- Fix: Unpause all streams if simulation is running when the world is installed to play early streams in replay
- Fix: Only stop the menu music when opening a map, not all streams on world install
- Fix: replay desync in repair tutorial a few rounds into the bombardment
    - Replay feed points is 3 frames late and 1 point higher
    - Delay all OnStreamComplete events to the end of the tick for consistent delivery between play and replay
- Fix: Don't enable AI script twice at beginning of replay (repair tutorial)

11/3/16
- Optimise: reduce script update frequency to once per tick (4/30th of a second)
- Fix: don't show pan arrows in building tutorial replay
- Fix: don't show objectives in resources tutorial replay
- Fix: objectives position is reset when lines are cleared
- Fix: repair cost tip sometimes plays after the fort has been repaired in repair tutorial
- Fix: don't cycle view when skipping 03_fire_put_out
- Optimise: add bounding circles to structures
- Fix: Battle music played during resource tutorial replay
- Fix: Replay HUD controls disabled at beginning of resources tutorial
- Fix: Device population caps and enabling not serialised in resources tutorial, causing replay desyncs
- Fix: Weapon enabling not serialised in weapons tutorial, causing replay desyncs
- Steam build submitted 1019391

13/3/16
- JointResourceAccount has an unlimited mode
- Added UnlimitedResources rule to rules.lua
- 'Blank' right panel texture is automatically used when in unlimited mode

15/3/16
- Fix: If deletion of a node (or link?) results in an orphan foundation the resources for it are not recovered
    - CommandInterpreter::ReclaimLinkAndOrphans' call to ReclaimLink would update cladding, setting all visited flags and skipping any further work in PhysicsManager::UpdateLinkState
    - Delay cladding update by setting mUpdateCladBothSides
- Integrate new HUD modifications
- Add custom map prop directory
- Add foundation hint sign to resources tutorial, hide when foundations are built out sufficiently
- Add find flag tip to building tutorial
- Zoom in on reactor on introduction in resources tutorial
- Fix: no minimum delay when coming out of intro track or into low reactor state
- Music min period customised per state
- Added change in/out thresholds for intense music state
- Moved music parameters and debugging flags to top of music.lua

16/3/16
- Edges inherit colour of the ground blocks
- Use fixed width font (Tips) for resource read out
- Add a space either side of the resource readout text to work around font rendering layout problem

17/3/16
- Show music debugging as screen controls
- Show lowest reactor value for music debugging
- Low reactor music can be triggered by low enemy reactor as well as friendly (optional)
- Fix: turned off music debugging by default
- Fix: really large under cliff edge sprites in Abyss

18/3/16
- Add ZoomTo convenience script function to forts.lua to simplify screen transitions
- Force screen transitions in tutorials to prevent players accidentally looking away from something important
- Fix: Right pan arrow often not visible if player has already moved the screen
- Fix: Grid snap invisibly overrides link extent snap and blocks building
    - Move circle snap into CursorManager for consistent evaluation between preview and command processing
    - Ignore grid snap if the snap lands outside the circle
- Fix: Ground nodes are hard to place at the extent of the circle
    - Trim ground edges to the circle
- Fix: Ground node creation at the edge of the circle can fail silently if the structure is moving away from it
    - Relax max length constraint for ground nodes (still limited to max link length)

19/3/16
- Add a strut counter to the early building tutorial
- Fix: Delete node, link breaks off it, all links in scrap state revert to idle
- Replace cursor with mouse graphic with animated buttons in building demo
- Fix: crash when selecting a node with no material selected (circle snap setup)
- Add restart to all tutorials
- Add door sign to weapons tutorial

20/3/16
- Shield, armor and doors appear as bracing when viewed with fog of war to increase ability to hide structure
    - Draw shield in background when fog of war applies
- Fix: Font does not reflect style in UIEditor
    - Font combo was sorted alphabetically
- Only show 'next' button when the tutorial has finished

21/3/16
- All contiguous structures have a structure state in the mPrimaryStructureState list
    - Neutral structures (the old secondary structures) are drawn after all primary structures (Team1 and Team2)
- Use structure bounding circles and boxes to limit collision tests to links within the intersecting structure
- Fix: crash when mesh projectiles run out (don't spawn a new projectile node)
- Fix: TerrainManager::IsLineSegOutsideExtents was apparently producing false negatives

22/3/16
- Add a repeat loop parameter to stop at frame command

24/3/16
- Move music debugging to the right hand side
- Fix: OnInstantReplay caused an exception in music.lua for team1
    - MinPeriod needs a default when playlist has no setting
- Fix: link snap not working properly in multiplayer
    - SnapState::InsideCircle was not set CircleSnap was on
- Don't restore view/cursor position when double clicking on a group already selected
- Remove autoZoom from DeviceEditor::SelectDevice
- Fix: playlists not looping

25/3/16
- Snap power to 100% when cursor is near the outside of the aiming arc, draw an arc to indicate this
- Increase size of cannon aiming arc
- Increase size of mini-gun aiming arc, reach maximum size further from the ground, increase minimum slightly
- Fix: Door/reloading icon gets in the way of aiming for Team2
    - Switch icon to the other side when weapon is on the right (some icons still need adjustment)

27/3/16
- Add variable length silence between tracks in a playlist
- Add music.lua option to prevent return to idle until current intense track and silence are complete
- Add random number functions that use the local random number generator to prevent music script desyncing physics, AI, mission, etc.
- Playlists can be randomised
    - Re-randomise each time the list loops
    - Avoid repeating the last track played when ordering the list
- If cursor is inside an aiming arc when view is cycled, reposition it so it is in the same relative position

28/3/16
- Remove enemy base from view cycle during play mode
- Cycle view jumps to overview first if zoom is below a threshold
- Optimise: don't draw structures and terrain blocks if they are off screen (add a buffer)
    - Add Visible flag to StructureState
    - Clear these then set them if their structure intersects with the screen bounds
    - Add mVisible flag to PNode structure, use this in PhysicsManager::SnapLink to avoid testing against off-screen structures
- Fix: neutral structure disappears if you connect to it by rope
    - Structure is neutral but part of a primary structure
    - Mark structures as primary during painting instead of relying on team

29/3/16
- Optimise: Use Device::GetPlatform instead of FindDevicePlatform in ReactorsClaimForts::Apply()
- Optimise: disable LogLinkStates in PhysicsManager::UpdateLinkState
- Optimise: use device bounding boxes and screen extents for clipping
- Optimise: use terrain block bounding boxes and screen extents for clipping
- Optimise: mortar_air_burst effect uses a sprite for smoke instead of spark set
- Optimise: calculate speed in SparkSet::Update rather than SparkSet::DrawLate
- Optimise: add initial hitpoints to Link to quickly calculate relative health
- Optimise: use iterators for frequently used node functions PNode::GetLinkTo and PNode::GetParallelLink
- Optimise: adjust temperature of neighbour segments when on fire, instead of checking the neighbours of every end segment
- Optimise: removed unnecessary keyframes in swarm_trail effect

30/3/16
- Fix: non-neutral secondary structures don't get rendered (using obsolete neutral team method to enumerate them)
- Fix: remaining enemy fort vanishes out after reactor goes, need to keep structure Primary flag updated
- Fix: Fire extinguish effect repeats frequently on AI fort
- Fix: Crash when reactor nodes are deleted before ReactorsClaimForts::Apply()
- Fix: ground edge trimming by circle incorrect, causing snapping to nothing in empty space
- Test: Nick's Russia campaign

31/3/16
- Fix: ground edge random offsets incorrect during replays causing huge edge sprites to fill the screen
    - Recalculate ground group random series offsets after seeking
- Fix: physics thread event objects closed
- Optimise: Use thread to compress and write replay file to disk to avoid dropped frames due to CPU usage spikes
    - Profile replay compression and write to disk
        - Compression taking ~30ms, write taking ~0.1ms with 128KB min write size
        - Compression taking ~64ms, write taking ~0.18ms with 256KB min write size
        - Compression taking ~20ms, write taking ~0.094ms with 64KB min write size
    - Make a copy of the buffer to compress and use a thread to compress and write it
    - Set thread priority to idle to avoid interrupting other threads, check it's completing
- Fix: clipped ground snap not working properly
- Fix: beam isn't drawn if weapon is off screen
- Fix: AI doesn't shoot remote weapons in SP203
- Fix: alpine rock texture is wrapping at top edge
    - Fix: Set clamp to edge on edge set icon texture and actual sprite
    - Texture flags are updated if they are already loaded
    - Flags are set before mip-map generation
    - Moved alpine rock texture up one pixel to avoid texture wrap (reason unknown, GL_CLAMP_TO_EDGE is set before mip map generation)

2/4/16
- Convert to team function for Alt + 0-2
- Fix: Part of laser structure in PAX-Lasers doesn't delete
- Ctrl + X cut structure function in editor
- Fix: AI unable to connect to neutral structure in PAX-Lasers

3/4/16
- Optimise: cull structures, devices and terrain out of cone using bounding circles in PhysicsManager::GetVisibleAngles
    - Add a function to mark nodes as visible to a code: source, angles and max dist and ignore unmarked
- Fix: grid snap not working in terrain editor
- Fix: Some textures not loading properly

4/4/16
- Fix: projectiles drawn before neutral structures
    - Separate projectile rendering from PhysicsManager::DrawNodes, now in PhysicsManager::DrawProjectiles
- Fix: mortar trails drawn behind neutral structures
- Optimise: exit PhysicsManager::GetVisibleAngles as soon as there are no visible angles
- Optimise: move RicochetFade values to PhysicsManager member variables
- Optimise: PhysicsManager::IntersectLineSegWithStructures: progressively cull structures as the line segment is clipped
- Fix: AI halts rebuild if a CreateNode call fails due to lack of ownership (happens when attempting rebuild of existing neutral structures)
- Fix: AI doesn't use earlier links to brace new nodes, which can adversely affect nodes created while rebuilding existing neutral structure
    - ai.lua BraceNewNode starts at the beginning of the Fort table to select links
- Fix: DeviceEditor::HandleControlEvent crashes when mSelectedDevice is NULL and is passed to SendDestroyDeviceMessage

5/4/16
- Fix: \save command only uses first letter and doesn't copy default mission script

6/4/16
- Fix: replay data corrupted when restarting
    - Final flush before loading first chunk is done in the main thread synchronously
    - mEndOfFirstCompressedChunk was being set in main thread even though the work hadn't been done yet (moved to worker thread)
- Optimise: AI ignores neutral structures if they are never connected to
    - iterate the Fort structure before discovery
    - get the structure id of each neutral node referenced and add it to a table
    - during discovery only add Fort instructions if neutral nodes are in these structures

7/4/16
- Fix: if existing neutral structure is entirely gone:
    - the AI connecting link always fails because the destination node doesn't exist yet and can't be rebuilt from the neutral side
    - Convert create link command into a create node command if the destination node was originally neutral
- Fix: crash when destroyed device tries to ignite platform which no longer exists
    - Device::GetPlatform sets return nodes to NULL before return false
- Add frustration level to AI actions, decay these slowly to allow later re-attempt
- Fix: PAX-Lasers link connecting with neutral structure was incorrect orientation, preventing create node being inserted
- Fix: AI can join two new nodes with a link creating an unstable structure
    - CommandInterpreter::ReceiveCreateLinkMessage fails with CS_UNSTABLE if both nodes are not reinforced
- Fix: skip AI link action instead of retrying if one of the nodes doesn't exist yet
- Fix: ropes creating links in the AI Fort table
- Fix: PhysicsManager::MarkStructureBreadthFirst is duplicating link visits, resulting in a larger than necessary AI Fort table
- Fix: skip AI create node action if the source node is unstable

8/4/16
- Fix: AI gets stuck painting the target with sniper
- Fix: AI delay-closes doors on weapons that are needed for spotting, launching or are in use
- Fix: AI fails to re-open a door when closing without a collision (enable DoorsClosingAsClosed filter)
- Fix: CommandInterpreter::SendSpawnProjectileMessage was using Device::GetBarrelBase to determine if the weapon was clear to shoot
    - This caused the sniper to test from its root
    - Changed to use hardpoint for consistency
- Optimise: exclude non-doors when AI tries to open all doors for a weapon
- Fix: Fires sometimes return for AI and player after being put out
    - Also spread across rope rapidly after it was extinguished
- Fix: if a missile launcher warming up to fire becomes neutral it launches instantly and the launch effect happens as normal
- Fix: reject or skip new AI links that are unstable (co-linear) unless one of them is vertical
- Fix: if CreateLink is attempted from CREATE_NODE action and fails, skip to the next one (caused AI to stall)

9/4/16
- Fix: new structures are invisible in editor unless simulation is running (paint structures on node creation)
- Fix: crash when restoring an undo level with a NULL device selection
- Update structure extents when deleting nodes and links

10/4/16
- Fix: Structure extents don't update when deleting link
- Fix: cycle view sometimes gets stuck zoomed into the fort in PAX-Lasers
- Use last zoomed-in position for home position during gameplay
- Move music.lua into new scripts folder to allow Jeff to turn off music track synchronisation

12/4/16
- Fix: AI can't rebuild ropes if they are destroyed
    - unselectable nodes are currently ignored by DiscoverLinks, so all rope links are not rebuilt
    - need to treat ropes as a unit during discovery, destruction, and cleanup
        - EnumerateLinks: when an unselectable link is found, follow it to the end and use that node to report the link
        - Destruction: when a link with an unselectable node is destroyed search to both ends and report that only if they are both selectable
        - Cleanup: AI script schedules a call to DestroyLink with the first actual link of each end of the rope
- Fix: AI creates links to free nodes
- Fix: AI uses ropes or shields to brace new nodes
- Fix: AI can rebuild nodes and links instantly, which can cause them to be destroyed again instantly by a beam (and being unfair to the human player)

13/4/16
- Add DoCutscene function to forts.lua to easily script camera movements, objectives and highlights

14/4/16
- Allow cutscenes to be skipped when not in transition
    - Cutscene position is maintained and only an AdvanceCutscene call is scheduled to keep time
    - If the scene is skipped the AdvanceCutscene call is flushed to make it happen immediately
    - Clean of the current scene and camera move is handled immediately, and scene setup scheduled for after the transition
- Fix: cutscenes are broken on restart
    - Defer cutscene calls until first replay keyframe has been made
- Fix: unable to disable camera controls with EnableCameraControls from mission script
    - DisableStartupZoom overrides camera controls when EnableCameraControls is passed false
- Fix: crash when OnLinkDestroyed called without any scripts being set up

15/4/16
- Modify music volume per track
- Fix: Skirmish restart causes an exception in music.lua StartIntro
- Fix: Changed bombdrop bombs to explosive barrels instead of reactors to prevent team2 not losing
- Fix: group slaves don't have their doors auto-closed when another group is selected
- Fix: if snapped to grid just outside of circle the construction preview can snap to ground

16/4/16
- Enter sets the home screen
- Add command to enumerate currently loaded scripts and their associated team
- Add command to execute Lua instructions in a particular script (by index)
- Letterbox bars and popup commander for single player cut scenes
- Cutscenes automatically show letterbox and hide HUD

18/4/16
- Fix: exception in AdvanceCutscene
- Send "escape" OnKey event to scripts in order to skip cutscenes
- Add commander texture and speech bubble to character on right of letterbox
- Cutscene text looks up strings for translation
- Fix: weapon group slaves don't shut their doors if another weapon is selected

19/4/16
- Fix: direction of arrows in forts.lua ShowArrow
- Add show device support to cutscene system
    - add list of device type, position, direction objects to DeviceManager
    - clear all at once
- Add ghosted devices to Mission 103 cutscene

20/4/16
- Mission script can customise letterbox characters using SetControlSprite
- Added TextLeft and TextRight to scene tables to activate the two characters
- Fix: letterbox hidden in cutscene after restart
- Fix: stop mirrored sprites from getting clipped when an edge hits the screen extent
- Adjust position of the left commander to the screen edge
- Fix: cleanup arrows and ghost devices and cancel camera movement on restart
    - Add OnPreRestart to clean up previous scene

21/4/16
- Show/hide ghosted structures from script in cutscenes
    - Call LoadStructureFile, enabling callback to receive details about new structures in script
    - DeleteStructure added to clean up at the end
- Fix: crash when deleting an orphan node in the editor

26/4/16
- Fix: crash in terrain editor when using Backspace without a group selected

27/4/16
- Disable AI offence during cutscenes
- Add 'Props' support to cutscene structure
- Draw prop names when in prop edit mode
- draw ghosted structures as translucent, ignore collisions, physics, snapping and visibility
- Turn 'reactor low' state into a sting, pausing current state while playing
- Fix: restart skirmish at some stage during end-game sequence -> HUD did not reappear

28/4/16
- Fade out reactor-low if lowest reactor is lost
- Play victory/defeat music as soon as game is won, without delay (add option)
- Loop victory/defeat music
    - Make victory/defeat an exception to pause menu pausing all sounds and music
- Add a music state for the cutscene
    - mission script music script to pause when the cutscene starts and and resume when it finishes
- Fix: each change to the lowest reactor health creates a new sting

29/4/16
- Compiler can define DEMO to force demo only mode
- Build project from the command line
- Added BuildSteamDemo.bat to make demo configuration
- Moved tutorials to the start of the campaign

30/4/16
- Fix: second tutorial doesn't load properly, updated Exit to use "next"
- WorldOpenMap mission team defaults to Any to allow mission script to affect both AIs
- Fix: menu tab order
- Fix: idle music not playing
- Fix: restart after loss caused the intro music to play over the cutscene music
- Reduce demo lists to best maps
- Fix: Ai: node not considered unstable if it's a foundation
- Fix: AI: links are not colinear if they form a triangle
- Fix: test if new AI node is on ground before abandoning attempt from unstable node

3/5/16
- Added media, volume and delay parameters to DeviceExplodeSFX() for customisation

4/5/16
- Added SFXVariants to device_destroy_util.lua to simplify creation of sound effects with variants
- Fix: AI can get into an infinite loop trying to find a weapon to shoot if firstIndex is less than weaponCount
    - Added attemptCount to limit loops

5/5/16
- F2 to instantly toggle the in-game and replay HUD
    - toggle graphs changed to Ctrl+F2

8/5/16
- Fix: crash when changing map environment
    - prefix parameter with environment/

9/5/16
- Add a console command to trigger an effect at the cursor every time the mouse is clicked
- Fix: Removed beam laser FireEndEffect placeholder

10/5/16
- Fix: Initialised FTLibrary manually to fix mysterious crash in Debug configuration
    - Also fixes mysterious memory leak
- Fix: joining client gets stuck at the end of loading
- Add an 'force start' mode for the host to start a game without the participation of unready clients
    - Add force start checkbox to the chatroom, reset after each game, hide from non-host clients
    - Send start message only to ready clients
    - Send status of loading clients to non-participating clients
    - Don't wait for clients who are chatting when in the loading screen
- Fix: memory leaks in netutility.cpp (leak free after multiplayer battle)
- Make zoom out with middle mouse reverse the zoom in path for touch screen pinching
- Change remote cursor colours based on team
- Updated credits (Jeff handling sound)
- Fix: UIEditor init and cleanup FTLibrary

11/5/16
- Fix: music intensity set to half way on instant replay start
- Simplify campaign script format
- Hide demo toggle button if demo mode forced at compile time
- Add lua script to remove unreferenced maps before making the build

12/5/16
- Expose UI event sound effect paths to constants.lua

13/5/16
- Preliminary touchscreen support
    - Add touchscreen calibration page
    - Add 'touch here' controls at the top left, top right and center of the screen
    - Show them in sequence
    - Calculate the mouse sensitivity and initial position from these    
    - Lock sensitivity once touchscreen has been calibrated
    - Prevent game from setting the cursor position which would change the offset
- Fix: set position of effect when gun fails to fire (reloading)
- Reverted input initialisation order, added initialisation tracing

14/5/16
- Fix: crash when joysticks attached
- Fix: Renamed IFilter to avoid clash with platform SDK symbol

17/5/16
- Copied solution to FortWars2015.sln and updated it to Visual Studio 2015
    - New project files added
    - Removed DirectX include paths from new projects
    - Unable to get max macro working, replaced with __max
    - Empty macro definitions caused compile errors
    - Some type casts needed to suppress warnings
    - LuaPlus:: namespace scope needed in LuaState_UserStateOpen, LuaState_UserStateThread and LuaState_UserStateFree
    - abs changed to fabs in CCRakNetSlidingWindow::OnAck
    - Removed DataFile project
- WM_TOUCH support
    - single finger pan moves cursor
    - single finger double tap creatses mouse left click
    - double finger pan moves camera
    - Filter distance parameter to reduce shake while panning/zooming
- Fix: Single swipe needs to start a click, but need to avoid it if soon after a second finger lands
    - Need a separate start flag/pos for 1 and 2 fingers
    - 1 finger only triggers click when sufficiently far from starting position
    - 2 finger pan still correctly records starting position which isn't consumed by 1 finger path
- Fix: move cursor when in pause menu and UI
- Fix: buffer overrun when logging opengl extensions

18/5/16
- Add global voice volume constant

19/5/16
- Enable swipe click only when in structure editor
- Touch & Hold generates a right mouse click
- Disable hold right click after finger displacement
- Allow doors to be opened with one click of the touch screen
- Deselect node when panning

22/5/16
- Add campaign transition voice to the end of the repair tutorial
- Delay tutorial voice when crashes are expected: End of building, End of weapons
- Added data.Disable flag to stop AI activity entirely without affecting other Disable flags

23/5/16
- Disable cursor and device preview while panning
- Repair when 3 or more fingers
- When touch-zooming below the minimum zoom or above maximum zoom reset the start distance
- Default scene duration is infinite
- Unable to click/double click in UI with touchscreen (increase click delay threshold)

24/5/16
- MapSelect shows preview with rollover and selects with single click
- Allow player to click on screen to skip cutscene (for touchscreen support)
- Two items selected in UI list boxes when using touchscreen
    - Happens when moving cursor from TextButton with Button slave to Button slave
    - Need to call MoveToTabStop when the slave causes a rollover of the TextButton
- Test: Desync in 114 replay (Change in script which disabled AI during cutscene)
- Fix: CommandInterpreter::LogCommand crashes if nodes or devices referenced by a command aren't found during replay with active desync
- Fix: Structure can go neutral without losing its reactor
    - Appears to happen when part of the structure breaks off, turns neutral and is destroyed (not immediately)
    - Structure which breaks off doesn't turn neutral immediately (SID 9 created frame 13966)
    - MarkStructure is somehow jumping from SID1 to SID9
    - BreakStructure can change the ID of a node
        - if a link of that node has an attached reactor the platform node IDs can bridge two structures
        - Update any attached device platforms if the node ID is changed
- Trigger customised effect when each commander is shown
- Delay start game horn
    - HUD waits for first update without letterbox to trigger
- Remove calibrate touchscreen screen link
- Fix: battle lose song when succeeding at the repair tutorial
- Prevent tips from showing if cutscene active
- Fix: Tips not showing at all (promiscuous not set in ClientManager in time)
- Added Minigame-Height to demo
- Fix: height not available in Skirmish (add AI Fort to make visible)
- Fix: timer count-down slow in height minigame (script update now less frequent)
- Fix: cleanup current scene when ending prematurely and restore final screen instantly
- Fix: CancelScheduledCallsOfFunc not removing items from calls table
- Allow touch screen to skip in building tutorial by clicking on-screen text button
- building tute: Keep skip button on screen after cycle view voice has finished
- building tute: Move skip button away from the bottom of the screen to avoid accidental movement by touch
- Disable camo and fuse materials, show background bracing on the HUD again
- New AI forts for Abyss and Twin Silos

27/5/16
- Disable mid-game state save during cutscene
- Fix: letterbox visible and unable to control mouse on campaign mission restart
    - Cutscene started on Load even when restoring game state
    - Add gameStart flag to Load function and only do cutscene if true

28/5/16
- Add new objectives panel
    - Add ContentsBottom, ContentsRight, PrevSiblingBottom, PrevSiblingRight script layout variables
    - Re-evaluate layout after all controls have been restored
    - Mission scripts Use position of first objective to place others
    - Enable word wrap for each line and use layout variables to offset lines
    - Cutscene system automatically shows mission name and objectives found in string table
- Added new Objective font style for objectives text
- Updated Mission 101-114 with new objective strings
- Weapon group count can be limited (to make space for the objectives panel)

29/5/16
- Fix: observer crashes (need to disable tips script)

30/5/16
- Fix: instant clients replay desync with 2 vs 1 for client 2
    - Add log clients command
    - Store client index as well as Id in replay to guarantee identical ordering
    - Also make sure mJoinStateFrame == 0 condition is treated consistently
- Fix: observer cursor is visible in all replays
    - Prevent observers from sending client select messages (unnecessary use of bandwidth)
- Fix: screen shakes when restarting repair tutorial
    - OnRestart was not being called for campaign missions, which cancels the startup zoom
- Fix: Double middle mouse button would take a frame to jump to view constraints
    - Bound camera to world immediately after instant ZoomTo operation
- Fix: skipping after putting out fires halts the repair tutorial
- Fix: crash when skipping 'reactor too complicated to repair' speech
- Move repair tutorial objectives into new system
- Fix: disable resource tips when resources unlimited
- Fix: AI replay desync when playing back resumed campaign mission
    - Save game state was loaded first and so lost when ai.lua was loaded

31/5/16
- Fix: Mission 102 replay desync
    - Team1 & Team2 UpdateAI scheduled calls are done out of order
    - AI scripts must be added in a different order
        - Team1 AI script is enabled after loading so script order is different to replay keyframe
        - Add ForceAITeam1 so that all AI scripts are known and sorted properly at load time
- Fix: Ghost structure causes a desync in Mission 102 replay
    - Exclude ghost structures from checksum
- Fix: Adjust Mission 102 AI to prevent player winning without intervention
- Fix: First cutscene commander not shown in Mission 102 replay
- Fix: hide objectives in replays
- Disable debug readout by default for release builds
- Fix: remove cannon from short-range mod (not necessary in Abyss)
- Fix: Team2 home position in 102
- Reduce end-game pause menu delay slightly
- Add pause menu button for observers (to benefit non-keyboard users)
- Fix: crash when quiting instant replay and host had quit
- Fix: 1 vs 1, end game, replay client, then replay host. Host crashes.
    - host running Steam, client not
    - host is trying to send time sync messages using the replay client database
- Change all cutscenes to "'Space' or click to continue"
- Increase zoom and scroll speeds slightly
- Fix: display change failed on 2-in-1 laptop
    - Call SetProcessDPIAware so that GetSystemMetrics returns correct existing resolution
- Move weapons tutorial objectives to new system
- Fix: Tutorial crash when skipping post-fire test speech in repair tute, clicking on skip button
    - Button is referenced after mid-click deletion
- Fix: 'List item' shows as first replay in empty list (rename to 'no replays available')
- Fix: Replay screen select crashes if list empty
- Fix: waitingForViewCycleCount not reset after use, allowing skip to backtrack the building tutorial

1/6/16
- Hide objectives when activating instant replay and restarting
- Fix: Objectives not visible when restoring a mid-game save
- Fix: Don't call CleanupScene if scene index hasn't been set yet
- Fix: Crash when calling legacy AddToContextMenu with NULL control
- Fix: 3rd client doesn't receive disconnect message of 2nd client, gets duplicate entry on quick reconnect
    - Client is logged out on host (other clients notified) before client database is updated
    - Use SetPortHostOrder and GetPort to communicate Steam message user Id
    - zero the rest of the address so it can't be mistaken for an actual address
- Fix: client is connected by Steam client connected by IP. Exit at the same time -> Steam client isn't removed from host
    - Increase sleep before closing connections to 200ms
    - If host receives a ID_DISCONNECTION_NOTIFICATION then force removal of client from database

2/6/16
- Fix: AI fails to rebuild existing devices
    - DiscoverDevice was returning nil, ending the enumeration
    - LinkCounter could potentially skip a device on a parallel link
- Fix: chatroom crash when COs disabled
- Steam default (demo) build submitted
- Steam beta build submitted

3/6/16
- Fix: catch exceptions when reading replays to prevent corrupt files crashing the game
- Fix: Possible to attempt load of incompatible replays
    - Don't show preview when replay is incompatible

6/6/16
- Fix: Master mortar tilted left, slave mortar tilted right, fire at an angle such that slave desired facing is left
    - Unreliable replay desync: ApplyFireAngleConstraints uses garbage mBarrelAngle
    - Slave should not fire if its firing direction is different to the master (outside of aiming arc)
- Fix: building new door nodes door over device is blocked even though background bracing preview is shown
    - buildingMaterial->mWeaponRecession unnecessarily blocked it

7/6/16
- IsOverClickableControl tests children first to allow nested buttons
- Add buttons to delete individual replays
- Fix: Non-host can change AI difficulty
- Fix: Map and ChangeCommander TextButtons in chatroom don't have callback/notifyId set

8/6/16
- Fix: when Steam connection lost nothing happens and clients can't reconnect
    - Client disconnects with suitable notification
    - Host is notified the connection is lost and clears the lobby
    - Host recreates the lobby on reconnection
- Fix: refresh text button doesn't work
    - Automatically set the child slaves of TextButtons to have the same notify id

9/6/16
- Removed obsolete context button
- Fix: Support Alt-Tab (and other Windows message processing) during loading
- Fix: Tab TextButton won't de-highlight when releasing button, Button doesn't show highlight when pressed
    - Button parent thinks it's still pressed and calls PressWithoutTrigger
    - TextButton presses and releases it's mIcon button
    - Removed action from TabbedPanel::HighlightTab to allow tab to revert
- Add \inspect_page console command to help diagnose disappearing chatroom control bug

13/6/16
- Fix: cursor inertia is kept when Steam overlay is shown
    - Hide cursor and force to the centre of the screen
- Pause game when Steam overlay is shown, but make pause menu invisible

17/6/16
- Fix: control panels visible in the UIEditor when built using VS2015
- Fix: load global constants register in UIEditor
- Fix: set paths when loading sprites in UIEditor
- Campaign support
    - Expose page, control, effect and battle start functions to new script type
    - Serialisation happens as before in the data table
    - Single campaign screen allows page root to be changed
    - Result and conditions are reported to script
    - If Campaign table present then functionality is as before
    - Added new USA campaign with tutorials available in first map presented

19/6/16
- Campaign script contains page, theatre, map
    - script must enumerate the controls and identify theatres
    - create page->theatre->map->complete structure
    - mission completion updates completed conditions and unlocks regions
        - next region to unlock set by sibling order
        - if all regions are complete then next page is loaded
    - Theatres using the Series: prefix have their missions available sequentially

20/6/16
- Automatic fallback to png extension for textures

22/6/16
- Add preview and fight button to campaign maps
- Commander in campaign screen prevents the fight button registering a click
    - Control mouse blocking can be toggled in the editor

23/6/16
- AI fort rescripting
    - Write the file line number into the original Fort commands before modification
    - add \build_fort <suffix> command to enable AI playback in Sandbox without firing
    - add support to \record command to rewrite remainder of the AI fort script from current position
    - ai.lua fortIndex advances when bracing a new node with the next action
        - Makes rescripting during construction more reliable
- Fix: AI fort can't build ropes to ground that doesn't support foundations
- Campaign support
    - Mission preview/fight button
    - Make preview button clickable to cycle image
    - Double click on map location starts game
- Fix: reactor exploded when Jeff built a metal store right next to a reactor 
    - ReceiveCreateDeviceMessage was passing node position by reference to LineSegIntersectsWithDevices
    - moved the node when an intersection occured

24/6/16
- Campaign support
    - Added page navigation and quit buttons
    - Added campaign description strings to all tutorials and missions
- Convert EffectsManager to a Singleton for use in front end
    - Initialise, update and cleanup in FortWarsShell
    - Convert all references to use singleton
    - Make separate folder for front end effects: ui/effects - always keep them loaded
    - load/unload effects folder for each map. Tag them as temporary and clean up
    - default behavior when mWorld is NULL (listener pos, faction names, commander mod loading, time speed, etc.)
    - Render after UI is drawn
- Added test dust_cloud effect on the map when a game is won

25/6/16
- Fix: ui effects paused after game (PhysicsTimeKeeper is paused on quit)
    - SparkSet timekeeper set to RealTimeKeeper if effect is configured for that

26/6/16
- Medals for theatre completion
- Detect campaign completion
- Highlight theatre when a map is selected

27/6/16
- Automatically load strings.lua found in the same directory as the loaded page (for campaign pages)

28/6/16
- Center dust_cloud effect on the complete medal
- Fix: initialise right, up, and forward vectors in Display to enable particles to render in UI
- Add shrinking/glowing medal sprite effects to dust_cloud
- Add a campaign track playlist
- Completion achievement for theatres
- Fix: details tabbed panel not responding to tab clicks
- Fix: projectiles drawn after terrain edging

29/6/16
- Modular condition scripts are loaded as per mission configuration
    - Campaign script adds a list of condition scripts sourced from CustomData
    - Editor tells World to load these
    - Script OnGameResult calls calculate their result, sent to Editor and save in campaign script
    - Campaign script shows/hides and changes state of medals depending on condition completion
- Fix: Crash or failed sound effect after campaign game
    - prevent all effect samples from being freed after a game (also reduces secondary load times)

30/6/16
- Support multiline CustomData
- Fix: OnGameResult doesn't get called if instant replay is run
- Fix: If player quits (rather than hitting next) pause menu after a win it is not recorded in campaign
- Support parameters to conditions
- Add MaxAcceptibleLosses parameter to condition-no device lost.lua
- Add 'condition-no device damage.lua' with id, type, and track created parameters
- Mission 101 in the campaign uses condition-no device damage.lua for no damage to derricks achievement
- Renamed mission forts to be consistent, campaign script assumes this name
- Fix: disable enemy AI for tutorial missions and allow different fort files to be specified

1/7/16
- Fix: tutorials are marked complete even if they weren't finished
- Show theatre name
- Add up theatre achievements and show that number of theatre medals
- Fix: immediately update theatre medals after a game
- Fix: re-center campaign backgrounds
- Clear effects when changing campaign pages
- Fade out music when transitioning between menu campaign music

3/7/16
- Add campaign selection cursor
- Make selection cursor interpolate its position

4/7/16
- Fix: accidental double click new page UI buttons when quick (e.g. campaign->select campaign)
- Fix: Earlier theatre mission achievements aren't recorded
- Add campaign victory screen
- Music playlist can be customised per page by setting the custom data of root
- Fix: cursor pos, source and target don't have metatables on campaign restore, causing exceptions in update
- Restore cursor position on campaign restores
- Fix: music can fade out during loading
- Fix: victory music plays inappropriately during first two tutorial missions
- Play a different effect if nothing is repaired under the cursor

5/7/16
- Add constant to enable double click auto-win
- Fix: overview in 01-building not wide enough
- Mission 109: Made enemy mg less effective, fort defensive early on, faster and with less protective structure
- Mission 110: Added doors and armor to enemy fort to prevent victory by mg, enable sniper when it is reached to allow replacement

6/7/16
- Sound effect for when carrier moves with fade in/out
- Fix: carrier sound doesn't fade out on victory page
- Fix: exception when moving carrier then moving to victory page
- Move basic functionality (Vec3 definitions, ScheduleCall/SystemUpdate) into scripts/core.lua
- USA.lua includes core.lua and can use ScheduleCall
- Make campaign medal appear after effect
- Fix: crash when launching a missile (anim script needed to update interpolate.lua location)
- Add work in progress message pop-up to the start of the USA campaign
- Fix: disable derrick device
- Fix: heli sfx plays sporadically during tutorial play
- Fix: message shown every time going from page 2 to page 1
- Fix: Heli sound played during battle and cutscene music continues into battle Mission 101
    - Stop all streams when entering a battle, just before resetting all Ids
- Fix: Campaign Start/Fight button doesn't register unless on the text
- Fix: Winning and then losing on restart fails to register medals

8/7/16
- Fix: Replay is still selected after deletion (clear preview and info)
- Fix: compound panels don't obey non-default anchors
    - Move sub control coordinates depending on parent anchor
- Fix: Word wrap doesn't obey parent non-default anchors
- Fix: VS2015 project out-of-date warnings
    - Remove missing files from projects
    - Add postbuild.bat to sync network copies without build error
- Convert custom data double quotes to single quotes on serialisation
- Clear custom data text control if no control selected
- Unify use of IControlVisitor to accept a regex
- Fix: ground/grid intersection doesn't work when moving ground nodes
- Snap to world extent has the lower priority than snap to grid

10/7/16
- Show campaign map theatre unlocked button

12/7/16
- Add total medal count and theatre unlock thresholds
- Fix: clicking on backdrop of theatre unlocked button clears the popup
- Add condition-limit enemy shots.lua campaign achievement script
    - Used in Mission 108

13/7/16
- Make campaign auto-win complete all achievements
- Add DeviceType parameter to limit energy shots condition
    - Use in Mission 112 for winning before cannon fires
- Fix: Victory screen isn't unlocked when completing final mission
- Make new map for showing at events (Cannon Fodder)
    - Well equipped player fort
    - Large but defensive AI fort
    - Add to demo skirmish map list

17/7/16
- Add unlock-all-weapons mod for intro maps
- Disable fog-of-war and unlock all weapons in Cannon Fodder map

22/7/16
- Add demo flag to constants
- Fix: crash in PhysicsManager::ApplyDamageToStructure if passed nodes are not linked

23/7/16
- Replay desync: Vanilla Azza vs Beeman on Tim, at 29504 (restore from 29268). No desync if restored from 26684.
    - One link is repaired when it shouldn't have been
    - The link was turned from armor to bracing when a mortar was build on the adjacent platform
    - Recession of armor to bg bracing is not reversible
    - Add a member to Link to save the material used instead of relying on the recession system
- Add a 'shared' user for sharing replays via Dropbox
- Fix: Broadsides resource capacity doesn't take into account batteries
    - Related fix: Resources2 replay seek (11716) desync in Broadsides multiplayer (2 vs AI) after AI had been destroyed
- Steam default (demo) build submitted
- Steam beta build submitted

24/7/16
- Write replay name into log when opening
- Write MapSelect search parameters to log when there are no results
- Pressing play at end of replay restarts
- Pin HUD when restarting from attract
- Turn off attract when restarting
- Cannon Fodder map
    - Remove grass below bridge to missiles
    - Remove doors on missiles
    - Make sniper easier to get LOS
- Seeking after a desync exits debug mode
- Fix: music.lua uses invalid team parameter when calling GetRule on game result causing crash for observers

26/7/16
- Draw aiming line on all weapons, but not on slaves
- Add a flag to disable campaigns from being listed
    - Disable old linear campaign in Steam build

27/7/16
- Fix: Grouped weapons sometimes don't fire
    - Master and slave fire angles sometimes differ slightly; added tolerance
- Fix: weapon muzzle flashes delay until on-screen
    - Update CompositeSprite node animations when off screen
- Fix: aiming missile spotter at nothing aims missiles at origin or last known target

28/7/16
- Show crosses on overlapping devices and structure when previewing
- Allow device snapping to platforms with an existing device, but show in red with cross on existing device
- Show cross or red line on ground that can't be attached to

30/7/16
- Fix: replay desync when cannon restored with team eliminated on facing side but not other (switches direction on keyframe restore)
- Fix: AI can build recess in default direction while weapon points in the other
- Prevent Derrick device from going dark when neutral
- Show device sprite depending on owner (flags)
- Fix: mine animation plays rapidly in replay preview
- Make 'keep device selection' off by default
- Show blocking icon on intersecting structure when placing ground devices

31/7/16
- Fix: AI can't rebuild silo housing in Twin Silos
- Custom fire animations: Make fuse fire animation fizz to start with
- Some materials can't be repaired (fuse)
- Fix: resolve duplicate V keybinding for flip vertical/toggle view floor
    - M, D and V enabled in editor for cycling items

4/8/16
- FMod Studio & director support
    - buzzing at start of Skirmish and at other times to a lesser extent, fire effect doesn't end after extinguished
        - excessive channels created by update mistake
    - some effects are 2D (armor richochet)
        - set 3D attributes
    - tutorial speech talks over each other
        - only call OnStreamComplete when playback close to end of sound
    - crackling/popping when panning around ambient sounds
        - remove setVolume call on ambient effects
        - keep sounds going all the time to stop popping
        - Set custom rolloff curve to make the sounds local
    - Fix: sound lost after alt-tabbing post-game
        - master channel group not being resumed
    - Fix: invert all priorities
    - Fix: odd noise when projectiles impact shield
        - issue with shock_impact.wav?
    - Fix: popping sounds when first starting
        - Set 3D position of sounds before unpausing
    - Fix: clicking/snipping when repairing fire during 04-repair
        - Script function TriggerSound must unpause sound after setting 3D position
    - Fix: some sounds not paused during pause menu
        - Pause individiaul channels, not master channel
- Fix: stop AI firing when using build_fort command
- Re-saved 04-repair as detailed save materials were corrupted

5/8/16
- Integrate FMod Studio support
    - Load single sound bank specified in constants
    - Use effect path/filenames to automatically load event descriptions and create event instances
    - Update studio listener and event instance 3D attributes
    - Added new Studio project Forts.fspro and directories to fortwars/audio
- Fix: crash in wndproc.cpp access of MusicManager::Get().PauseAllChannels when not initialised
- Fix: set window focus after initialisation

6/8/16
- Support FMod Studio live update
- Fix: didn't get 'no unit losses' medal in 101
- Remove .lua suffix from FMod Studio event names
- Fix: effects on mortars suddenly stop and some effects appear at odd locations & repair effect sometimes appears over enemy fort in 04-repair
    - Weapon is holding onto its mFireEffect after it has expired, then another Explosion is created with that pointer
    - Pointers don't uniquely identify an Explosion over time
        - Use an id to track and update Explosions instead of pointers
- Add \save_page serialisation command for debugging chatroom issue
- Fix: \record does not always disable AI successfully (assumes script index)
- Only stop Studio event instances that are not one-off to prevent premature ending
- Fix: audio cuts out entirely after several Studio events are triggered
    - updated to latest version
- Fix: missile event continues after impact
    - Stop looping events on Explosion::Enable(false)

10/8/16
Fix: Frame advance not working in instant replay during multiplayer
Add details to repair_area and repair_device command tracing
Node IDs are excessively high on MP 4v4 1
    Copy structure increasing IDs unnecessarily; compact new structure nodes
    Add command to reset IDs
    Destroy all projectiles and reset next node id before building new nodes
    Add warning when node Ids are greater than 100,000
Fix: replay desync: armor was turned into bracing to place a device, link initial hit points not have been updated
Fix: replay deysnc: nodes with temp bracing attached to a foundation break instantly when restored from a keyframe
    Don't set mAngleToReferenceNode for such nodes and don't move them in UpdateTemporaryBraces 
Fix: InitialHitpoints of parallel link is always zero when restored from keyframe
Fix: Links were being put into repair state when they were potentially at full health
Fix: unable to fire missile launchers in editor
    Client selection not sent
Fix: laser cuts out instantly if fired in editor
    Resource account not set

11/8/16
Fix: crash if non-participating client is in map select when others return to the chatroom
    mQuitOnLoaded and mMainMenuOnLoaded not initialised, incorrectly exiting Multiplayer when client receives end_game message
Fix: replay desync reset MeshProjectile mMissileParams when resetting or attaching it to a new node
Replay desync Vanilla Large 170246 pf12304: incendiary mortar was serialised with guided missile properties set
    Ensure mMissileParams are NULL when projectile is a mortar

13/8/16
Fix: If a client exits early their points are shown as -1
Support for execution on Windows XP
    Platform toolset set to Visual Studio 2015 - Windows XP (v140_xp)
    Deploy msvcr100.dll
    SDK include and lib paths (some dodgy hard coded paths)
    Switch off use of SetProcessDPIAware and Touch specific functions
    Switch off use of if_indextoname by #undef IF_NAMESIZE in miniupnpc.c

14/8/16
Fix: In chatroom the two righthand columns disappear when another client joins while game is minimised
    GetScreenScale was returning 0, causing a divide by zero

15/8/16
Platform toolset set to Visual Studio 2015 - Windows XP (v140_xp)
Move exit/back buttons to the bottom left, select/start/create buttons to the right
Move MusicManager to engine in new audio project
Add Effect property of Control for buttons to call Studio Events (later create Explosion objects)
    Default set in constants.lua

16/8/16
Fix: crash in UIEditor (NULL reference), moved Log initialisation earlier
Changed button event suffix to _rollover and _press
If _rollover button Studio event doesn't exist then fall back to default to save having many identical events
If effect .lua file doesn't exist, spawn Studio effect anyway
Make _press suffix implicit for brevity and to easily allow normal effects to be used for UI events
Add SelectEffect to materials and devices
    Don't play when switching pages by the HUD buttons

17/8/16
Move SelectEffect to device_list.lua and weapon_list.lua
Use SetSpriteState to show medals earned in campaign instead of ShowControl
Remove campaign data.Complete table and refer to theatre.Maps[].Complete instead
Adjust all theatre medal totals to allow unlocking of all theatres and campaign completion
Make achievement medals appear on campaign map in sequence, only if the were not previously earned

18/8/16
Fix: AI not upgrading missile launcher
Fix: start-loaded mod not working for detailed saves
Fix: DoubleHull map doesn't detect game won
Fix: device/weapon reverse cycling with mouse wheel
Removed resource collectors/storage in DoubleHull
Fix: a few small memory leaks in Main and FortWarsShell::Run, passing new objects to CreateBackEnd
Optimise: Eliminate small frame-tofallocations
    convert CompositeSprite::GetAnchor name parameter to char*
    CompositeSprite::GetNode to use char*
Fix: ambient sounds not playing
    Set eventInstance volume instead of stopping in Explosion::Disable
Fix: set mEffect of a TextButton's checkbox to be the same
Map achievement medals are shown when restoring a page
Automatically calculate MedalCount to be equal to the number of medals possible to attain

19/8/16
Remove cursor limiting behavior to work around Steam's hidden cursor tracking
Condition script: shots hit devices
    Track projectile count and ids
    If projectile expires add miss count
    Count up to limit parameter (can be unlimited)
    Work out accuracy and compare with required accuracy parameter
Condition script: no device built
    Track the number of devices built, compare with acceptible number
Condition script: group created
    Add OnGroupAddition script call, from DeviceEditor
Condition script: no device disconnected
    Add OnDeviceTeamUpdated script call, called from ReactorsClaimForts
Fix: Music series advances when the current track ends

20/8/16
Fix: condition results not re-evaluated after restart
    Scripts are cleared on restart and never reloaded
Optimise: don't reload a condition script if it's already been satisfied
Fix: conditions do not accumulate over restarts
Condition script: limit fort hits
Condition script: hidden device shot
Implemented all achievements for second theatre in part 1 of campaign

21/8/16
Show error message when condition script fails to load
Condition script: connect to ground
Fix: condition script 'limit fort hits' OnDeviceHit filters projectile type
Implemented all achievements for third theatre in part 1 of campaign
Mission 107 achievement 2 changed to 'don't light a fire'
Theatre unlocked animation
    Set up animation table to interpolate banner alpha, and control positions
    Add OnKey support to allow dismissal
    Spawn effects at start and dismissal
CampaignScreen sends mouse input to campaign scripts
Removed full screen button and instead handled left mouse down
Stop clearing effects just before campaign unlocked animation shows

22/8/16
Fix: upgrading uses a hard coded effect
Add a 'device complete' effect
Allow customisation of mSmokeEffect per material
Fuse material burns at the same speed in both directions
Add support for ease in and ease out to interpolate.lua script
Apply ease in and ease out the theatre unlock banner animation
Pause or fade out campaign music when a theatre is unlocked, fade back in after dismissal

23/8/16
Fix: Achievements get false positives when the same condition script is used
    Use index to uniquely identify scripts instead of script filename
Add a button to syntax check Lua script in Custom Data edit box in UIEditor, and make box wider
Fix: AI failing to activate in campaign missions in some circumstances
    Stop disabling AI after cut scene could have been skipped
Fix: fuse sometimes fails to progress due to use of default heating value instead of material value
Fix: fuse is sometimes impossible to light when going from bracing as it cools faster than it heats
Make theatre tally count only current page

24/8/16
Add medal drop effects for info panel and theatre tally
Wait until all medals have dropped before moving to the next page
Partial integration of LuaPlusRemoteDebugger for campaign script debugging
Fix: Set theatre unlocked banner name string id properly
Block input while waiting for medals & banner to finish
    Wrap Input functions in MouseCursor, and return zero when it's disabled
    Disable mouse button processing while banner is up, and disable button rollover

25/8/16
LuaPlusRemoteDebugger: Skip over seems to 'skip out' sometimes
    Fix: nestedCalls not reset
    Fix: use of tail calls breaks nested call counting
LuaPlusRemoteDebugger: Find doesn't work
LuaPlusRemoteDebugger: Local variables and watch values don't evaluate
    Fix: Wide string formatting wasn't handling narrow strings
    Fix: LS_DebugAddWatch was using the wrong indices to get the position and identity of variables
LuaPlusRemoteDebugger: Local variable table expansion expands every table
    Fix: Filter top level variables using the expansion list (still expands all temporary values)
LuaPlusRemoteDebugger: Unable to expand numerical keys
    Identification is made using dot notation and only looks up strings
    Fix: look for numerical keys and convert to integer index in GetValueObjectFromIdent
LuaPlusRemoteDebugger: SimpleString was allocating and leaking small quantities of memory

26/8/16
LuaPlusRemoteDebugger: Project paths inconsistent, causing problematic rebuild behavior
LuaPlusRemoteDebugger: Enter 'go' state at connection, rather than 'break'
LuaPlusRemoteDebugger: Support debugging of all states at once
    Pass command line option to enable Lua debugging
    Call process packets on a regular basis
    Enter 'GO' state immediately when registering a state late
    Use full path names instead of filename only
    Register Lua states and files as SetupScript is called in WorldScript

29/8/16
Cycle unlock banner horizontally
Fix: Text controls save customised style flags when differing from the default control style
Generalised theatre unlocked control animation system for use with smog animation
    Create a table which specifies association between control property and the animation table, plus function to call while updating & waiting
Implemented motherload smog animation
Reduce the delay between medal drops by 20%
Hide 'hit any key to continue' on campaign screen animations at the start

30/8/16
Control can force mouse click processing to support form along side the pause menu
EditBox cursor is appended to text to work with word-wrap (still issues with text rendering)
Add optional email entry form to Victory/Defeat

31/8/16
Show achievement panel at the end of the battle
Support attachment of effects to specific controls
    Pass the control to SpawnEffect
    Add a render callback to EffectsManager but record association in Explosion
        Remove IExplosionManager interface
    After the control is drawn, draw all associated effects from sorted list
    Avoid drawing explosions associated with controls during normal effect processing
    Allow effects to be delayed
Add completion as a special achievement to set the result state in-game
Fixed derrick arrow on mission 101

1/9/16
Add achievements to the objectives panel with icon
Make \reload_effects reload UI effects too
Fix: OnAchievement overwrites sCurrentFunc for OnGameResult
Fix: False positive on don't attach to floating island achievement (not counting attachments in table correctly)
Trigger objectives instantly if possible (e.g. creating a group) and update the objectives panel
Fix: Mission 118 AI remained disabled after skipping cutscene early
Fix: on restart extra medal(s) appear in the objective panel
    Objectives added again for each restart (check number of children on panel)
Fix: Theatre Unlocked banner squashed
Fix: On the fly achievements are kept even if the mission isn't completed
    Mark these as provisional and only commit them at OnGameResult
Fix: Mission complete is dropped again after winning and restart
Fix: Helicarrier not positioned at first map on a page

2/9/16
Fix: exception when going to campaign victory screen (cursor doesn't exist)
Fix: draw pause menu on top of cutscene controls
Append email to end of file instead of reading in entirety & writing it back
Mod to shorten build times on Cannon Fodder
Achievements for Skirmish
    Add achievements from mission script before ShowObjectives
    Force reset on revert map
    Suppress achievements panel on victory
Achievements for Cannon Fodder
    Make a group
    Connect silos
    Snipe a target
    Build a weapon
    Land a warhead
    Snipe through a door
    Kill one reactor
    Shoot down a mortar
    Fire all weapons
Fix: achievement panel visible in repair tute
Fix: result music not playing at end of repair tute
Reduce objectives panel spacing & font size for achievements
Reduce objectives panel width for Cannon Fodder
Fix: AI not offensive on Mission 104
Disable fog of war in early campaign missions
Fix: pause menu sound event not playing

3/9/16
Add permanently scrolling control support to campaign script
Fix: particles with non-square aspect ratio don't scale uniformly
First pass of campaign victory screen animation
Fix: all medals on the campaign map drop at once
      Hack data.gameFrame to 0 for page 3
Fix: hide achievements panel for weapons tute

6/9/16
Recurse complex campaign scripts to remove unused maps from build, add TrimMaps.bat

7/9/16
Allow campaign pages to be disabled
    Set Enabled = false in custom data Root control
    Add a increment parameter (+1 or -1) to SetPage which will change the current page if the set one is disabled
Steam build submitted

Fix: victory page not animating
    Reset campaign script frame and time on, restart the animation on Load
    Add LuaState wrapper constructor to Store
Control custom data is loaded into a table instead of global namespace, returned from ExecuteCustomData
Add transition Animation to campaign page root custom data instead of hard coded index
Add Animation effect to Map buttons to trigger smog animation

8/9/16
Fix: vertical preview link blinks out if structure is moving laterally
    Processed mouse position, snapped to circle, is based on physical position while length is calculated to graphical position of node
    Re-calculate processed mouse position based on graphical position
Preview doesn't go red when on a link with an existing device
Grid on by default
Don't associate a screen position when using mouse drag to group weapons
Fix: cursor is restored in two taps of the group number key if screen is already restored
    Track the restoration stage in mGroupRestoreStage and reset on new group
Fix: Player can accidentally restore screen when tapping group key compulsively
    Don't restore view/cursor if group already restored on first hit
Keep temp bracing after joining two braced nodes
    Release nodes from temp brace when there is at least one link to a non braced node
    Break links attached to braced nodes as normal

11/9/16
Add arrows to point in direction of available nodes when trying to build a chain
Move transaction effect to screen-space, drawn after the HUD
Increase zoom and pan speed

12/9/16
Add offset and reference control constants to transaction effect
If reference control not set, draw transaction at the previous world-space location
Add constant to set scrap time of materials rather than reusing build time; reduce time to scrap materials to 3 or 4 seconds
Reduce time to scrap devices and weapons by ~20%
Reduce size on struct construction icons (View.ProgressIcon.MaterialScale)
Increase size of temp bracing icon
Cannon Fodder adjustments for EGX
    Disable transactions
    Swapped sniper and ap-sniper to better facilitate late missile launching
    Added some additional bracing to reduce impact of heavy mortar
Fix: map name empty in Map Editor
Camera shake effect
    Constantly generate shake offset using 1D Perlin noise function
    Add new effect type which defines an envelope, setting the scale of the shake actually used
    Add quadratic envelope parameters
    Add PlayForEnemy for coarse filtering
Reverse team associated with effect: projectile impacts belong to the hit structure
Anti-air projectile collision and ground impact effects are associated with team None
Add camera shake to mushroom cloud, cannon fire, heavy impact, medium impact and missile structure hit effects
Fix: Chatroom AI checkboxes and force start layout incorrect

20/9/16
node_pointer effect animated the arrow towards the node
Ground devices will snap to the edge of an overlapping device anywhere within its width
Increase snap threshold for devices
    Move TerrainManager::mEdgeSnapDistance parameter used by IsPointOnGroundSurface into SnapConfig
    Add new constant for DeviceManager to override this when placing ground devices
Added shorter/lesser shake to cannon and missile impacts, including ground
Appended username to end of mailinglist.csv to avoid Dropbox conflicts
Added environmental variants of Cannon Fodder for EGX
Disabled rain in Fields environment for EGX

22/9/16
Fix: crash when laser destroys a projectile
Increased opacity of aiming gizmo, outline to white
Removed objectives from Cannon Fodder

24/9/16
Increased size of email form and used Arial font
Email form automatically has focus

29/9/16
Fix: Crash near end of PlayerController::StartInstantReplay(), Replay::Seek at mReplayFile->GetPos, dereference NULL pointer, starting instant replay
    Replay file corrupt. Show error message instead of crashing.
    Workaround: show console message that replay is corrupt, quit to main menu
Fix: Crash in PhysicsManager::UpdateStructureState at float filteredStress = state.StressDeltaFilter.GetCurrentOutput();
    Something to do with the inline virtual function?
    Unlikely that state is a corrupted reference since it is referred to earlier without a crash
    Work around: remove inlining of GetCurrentOutput, add exception handler, log state to console

30/9/16
Fix: Crash in ClientDatabase::SendToAll called from PlayerController::GameWon in instant replay after client had quit
    Don't send JoinUnavailableMessage during replay
Desync: sniper changes direction to left while neutral on one but not the other
    Dated client selection used to turn neutral weapon
Desync: Creation of link allowed for one client but not the other after selected node turns neutral
    Cannon projectile isolates selected node, turning it neutral
    Link created frames later for one client but not the other
    Should have been rejected by distance on both clients
    Desync must have happened on the node position first
        Force applied to selected isolated node ignored when standin link connected?
        Temp bracing must still be operating on isolated node due to standin

1/10/16
Replay desync: laser hits mortar, platform has slightly more HP in bad state
    N187-N232 goes from 4 to 6 fire segments a frame late in the bad state frame 4033
    Mortar goes in frame 4033 Preceding frame
    Appears that:
        node/link parameters to PNode::IgniteAt are reversed
        Mortar's device platform nodes are reversed in the keyframe, no way to find out why
        Order is 187, 232 in the AI script discovery
        Reversed for orientation, so device is attached to secondary link
        Platform must not be set correctly when AI builds device
        Fix: reverse platform node IDs when adding device to secondary link

2/10/16
Replay desync: door closing too early
    CF Alpine @7900
    Order of two scheduled calls reversed
    TrackedProjectile member AntiAirWeapons using unordered set has unreliable deserialisation order, consume random numbers in different order
    Fix: use ordered list with InsertUnique
Fix: interrupt ai recording on 204 team 2 - nothing is actually built
    Map was changed, next node Id must be taken from the map not the AI Fort script
Fix: AI Fort on 204 unable to build past line 27
    Disabled first part of UnstableColinear as it was blocking the link creation and didn't make much sense
Fix: If structure is edited after an AI Fort is recorded, amended structure commands don't work
    For recording to work the original and actual nodes of the structure must be equal
    Fix: Have CommandInterpreter query the AI script for the translation (if available)
Fix: Campaign victory music not playing
Fix: AI misbehaving in weapons and repair tute
Fix: updated fmod and msvc DLLs in installer

3/10/16
Replay desync: mortar reload timer out of sync
    Add weapon reload timers, timeout and rounds remaining to checksum
    Fix: Force reload timer to zero during construction and reset reload timer when weapon is complete
Fix: Amended fort recording still failing in 204
    Link and device creation translate node Ids
In Debug configuration enable optimisation for utility projects and physics inner loop, line segment intersection and structure painting
Fix: support > 1000 replays in MapSelect
Remove device splash damage on mortar destruction, slightly bump up structure splash damage of incendiary mortar
Auto refresh local and lobby tabs
Start and stop an environmental studio effect
World environment effect runs indefinitely

4/10/16
Fix: Truncate Text contents when setting new values, double capacity
Fix: pause_at_frame fails if frame rate is very low
Log replay desyncs to a file in user dir with date & time, replay file, previous seek frame, desync frame, type
Log physics frame during a crash

5/10/16
Fix: Filter unbuildable devices from AI Fort table (e.g. Reactor, Derrick)
Remove obsolete kc_toggle_node_snap in PlayerController

6/10/16
Fix: corrupt detailed saves of 305 and 308
Add a new effect with shake for explosive barrels and batteries
Add camera shake distance based falloff

7/10/16
Fix: multiplayer instant replay says "replay is corrupt", but is fine afterwards
Fix: server select auto-refresh crashes when hosting game
Fix: validate set_background parameter instead of crashing, and enumerate valid parameters
Fix: 1v1 multiplayer -> host goes instant replay, then client -> host quits, then client -> host appears as in replay to client
    Client does not receive the chatting state of the host while they are watching replay
    Client has not had it's db state set to replay, so doesn't direct client status messages to db
    Host ready not set on client return
        Host ignores client's 'replay' state
Fix: Effects end prematurely in slow motion
Add a coloured ready button on the bottom right of lobby
    Start button turned into a ready/not ready button for clients
    Host always ready while in chatroom
    Add 'Stop' and 'Go' styles
Fix: Effect aging doesn't pause, effects vanish while replay is in pause

8/10/16
Fix: Reactor steam effect frequently misplaced or missing
    Move structure stress and crash effects to Id based tracking to prevent unintended usurp
    Only destroy SparksEffect in its Update when disabled and no sparks if sparks have already been made
    Set EffectsManager::Update delta to zero if World exists and PhysicsTimeKeeper is paused
Steam build submitted

9/10/16
Add data.TargetingIgnoreNeutral to exclude neutral structures from ray cast LOS testing
AI: Mission 308
    AI fires laser or cannon into neutral structure: add option to make neutral structures impenetrable
    Tries to rebuild fuses if barriers destroyed (filter from Fort table)
Replay desync: upgrading devices when start-loaded mod is active
Remove VS2015 DLL from Steam build (now installed by Steam)
Remove FortsConfig (obsolete)
Show selected node and device numbers in editor debug readout
AI: Mission 305 requires AI to use specific weapons at specific targets
    Associate weapon id with one or more target from which it selects (overrides special targets and general targeting)
        Added data.WeaponTargets table
Fix: prevent DeviceComplete from spawning effects, notifying scripts, etc. when deserialising game state
Fix: client still in replay after leaving earlier than host
    When in replay all client status changes should go directly to the client database
    In SendClientReplayMessage set host bool, points to -1, and username
    In PlayerController::StartInstantReplay, use actual client database to realise the change in state to replaying
Fix: can't pause multiplayer instant replay just after win/loss (host only)
Allow pause menu when console is down

10/10/16
Fix: username controlling device is shown if cursors are hidden
Drop console progressively to show more lines for notification, chat, etc.
    Limit console drop and duration
Fix: only consider game joinable if the host is still playing
Fix: unable to activate Join button (only toggles ready status)
Joining client sends chat message to notify other players including team
Clean up console tracing to make important events more obvious
Drop console for change of status
Allow clients to change their own ready status
Fix: client status changes notify immediately after load - not necessary
Fix: various snap modes don't work for remote client cursors when drawing construction preview
    Set up a snapConfig based on current snap type to do all snapping
Fix: client status changes notify for own changes

11/10/16
Fix: remote device preview shown when client doesn't have it selected
Fix: crash when starting instant replay when offline

12/10/16
View jumps to overview on replay seek
    Local team hack in EnterDebugMode causes change of screen elsewhere, remove and keep team as Observer
    Need to pass Any team to SnapLink and SnapDevices to broaden search (not just local team)
    Show ground devices in foreground when team set to Observer even if fog of war is on

13/10/16
Fix: Scripted campaigns revert to normal difficulty on continue
Add custom loss condition to 305: any derrick lost
Fix: preview weapons show arc as not ready to fire
Don't show forward facing angles on weapon preview to reduce clutter
Don't show backwards facing angles on weapon preview if no enemy in that direction to reduce clutter
Only show visible angles for missiles when it changes or placing
Don't show change in backward facing visible angles if no enemy in that direction
When previewing constrution affecting turbines, don't show non-affected side
Add last shot marker to machine gun and minigun
Previous shot angle/power not correctly translated to slaves

14/10/16
Set visible angle max dist to barrel + clearance distance instead of outer draw radius to reduce the amount of false negatives
Set position of ambient effect to listener position
Add sound for receiving chat messages
Add sounds for receiving change of status
Increase LinkExtentSnap from 30 to 50

16/10/16
Fix: replay desync in split against AI at 16660
    AllocateSpotters is done during the draw update, not the physics frame step, leading to unreliable results when playback speed is high
Added Split and Spire 1v1 maps with AI forts

17/10/16
Turn off grid during replay
Fix: ambient effect is lost after first seek in replay
Add campaign map theatre medal bias
    MedalBias in Theatre custom data
Show locked tutorial missions faded out
Make campaign mission drops larger
Fix: Disable smooth lines in UIEditor

18/10/16
Fix: ConvertGroundDirectory directory parameter gets corrupted from shared buffer use
ConvertGroundDirectory produced a time stamped csv report on map enumeration or conversion
    Shows old and new file versions, detailed status, fort counts, failure status
Add fort count to beginning of spr files
Include link & device health in non-detailed save to better allow data changes in all maps
Add 2nd "reset" parameter to ConvertGroundDirectory to resave structure files as non-detailed
Convert all maps to include fort counts and health in non-detailed saves (spr version 18)

19/10/16
Fix: prevent condition-device changes owner.lua from counting devices more than once

20/10/16
Part 2 achievements
Detect construction of ground devices on one or more ground blocks, separately or simultaneously (204-1, 205-2)
Fix: OnDeviceTeamUpdated not called for on-structure devices going from neutral to a team
Condition: Device built before other team
Condition: Fire a group of a particular configuration (203-2, 207-1)
    Add 'group fired' script callback
    Allow script to query group contents
    Prevent spawning of projectile/group fired call if team unable to afford it

21/10/16
Refresh mission achievement scripts and parameters on campaign load to save restarting campaign for each achievement change
Add \attach_debugger console command to wait for LuaDebugger connection
Allow execution of strings in campaign scripts
Fix: After smog animation to new page, clicks are possible and can stop the cursor interacting with the page or select maps
Faster theatre unlock dismissal
Instant medal drop for autowin
Add mission name to campaign map preview
Fix: Alt-F4 closes the window but doesn't kill the process
Allow construction of team None structures on Team1 or Team2 ground
Add condition-efficiency reached.lua script for last part 2 achievements
    Construct devices of minimum efficiency
    Build weapon type above device of minimum efficiency
Fix: Page advances if last theatre medal count is exceeded in earlier missions
Fix: Medals sprites sometimes appear before they drop
    reset time speed before re-entering campaign map
Fix: disable smooth lines for bounding boxes in editor

22/10/16
Reorder tutorials to: nav, weapons, repair, resources
Building tute: Cut back building tute so it's only navigation to begin with
Resources tute: Add existing mine, player only has to build 2 more
Resources tute: Add mg and armor to make it look like a real fort
Repair tute: Remove 2nd fort and reduce test period in repair
Weapons tute: Make it possible to topple the enemy fort
Weapon tute: speed mg construction
Building tute: add a delay before leaving the mission
Weapon tute: Go straight to "build a machine gun on the front of the fort"
Weapon tute: Remove speech about armor deflecting fire and closing doors
Weapon tute: Go straight to shooting reactor speech after destroying mg
Repair tute: Remove "remain vigilant", go straight to "press the R key"
Repair tute: Remove "notice fires take time to put out"
Repair tute: Remove "we need your help on the front"
Resources tute: Remove "reactor produces metal & energy"
Resources tute: Remove "It takes some metal..." go straight to "To increase out metal storage capacity.."
Resources tute: Disabled tip_mass
Building tute: Add "You found it" after finding the flag, then quit

23/10/16
Converted ghost.spr files from spr version 17 to 18
Weapons tute: Add targets for first machinegun, delay attack until all targets are destroyed

24/10/16
Weapons tute: Enable machinegun from the start
Fix: in weapon tute enemy doesn't fire if you are too quick to build the mg
Increase size of drops in part 2 and 3
Automatically move the chopper to the next mission once complete
Fix: completing campaign with autowin left the mouse invisible
Fix: hide item highlight if the tab changes (weapons tute)
Weapons tute: reduced objectives panel so it doesn't obscure the reactor & arrow
Repair tute: Protected enemy fort from machine gun
Fix: Adjust the mg so the aiming arc doesn't move so much
Fix: reactor highlight shown if enemy fort topples and machinegun is destroyed before reactor
Weapons tute: set resources unlimited
Fix: "we've been attacked" when player deletes an mg
Fix: instant replay shown in pause menu after first win/restart
Fix: if first mg is selected when it's finished "aim in the arc" is not played
Remove 'resume' from tutorial win menus
Add victory banner to 1st and 4th tutorials
Add animated arrow if player gets stuck when building the door
Don't draw grid when weapon is selected
Fix: crash in multiplayer when loading screen command is sent to newly installed World
Weapons tute: updated mg location arrow and deleted it when a device is created

25/10/16
Fix: remove from HUD resource devices in 109
Add medal bias to part 2
Fix: avoid damage to armour achievement fails if device is hit
Fix: TrackingType with empty table should return false. Check for consequences
    Empty table and string case is fine
Fix: re-add "resume" to replay menu during instant replay
Hide grid during cutscenes
Fix: mission 203 objectives panel too large & cluttered
Fix: funky foundations and links in 207
Unify mission names shown in-game (part 1)
Update campaign preview image
Fix: show resource icons if firing is unaffordable and door is in the way (no action currently)
Make weapons click if short of resources, same as reloading, but not if door in the way
Add credits to demo menu, add 'EarthWork Games' to credits screen

26/10/16
Unify condition script parameter formatting

27/10/16
Fix: minimise black screen flash on start up
    Don't change screen resolution unless necessary
    Keep the window hidden as long as possible
Use WS_POPUPWINDOW instead of WS_OVERLAPPED to allow correct use of AdjustWindowRectEx
Allow resolution to be set by command line (e.g. -width 800 -height 600)
Fix: ultra wide screen aspect support
    Window mode doesn't immediately reflect window dimensions: Call MoveWindow
    UI cut off at top and bottom
        switch between width and height relative transformation based on aspect ratio
    Background blank at edges: scale to width
Allow window position to be set by command line and options screen (e.g. -x 100 -x 50)
Add windowed mode in options screen
    Window position can be changed at run time, saved and reset
Button double click disabled by default to prevent lost single clicks, enabled for ListBox prototype highlight

28/10/16
Autofire: Double click when not part of a group, or group is already restored
    Attempts to open doors at intervals, then fires when clears, then closes doors when no shots remaining
    ClientManager treats autofire weapons like AI to paint the target
    Initialise mTarget and mTargetT if the weapon has not already been fired

30/10/16
Fix: Only cache/send client select message at the end of each tick
Desync: On remote client, build wood in front, then add armor, then build mg behind armor immediately -> resources desync
    Fix: PNode::Link Marked2 is not initialised to false
Fix: Autodoor can be created if a suitable door already exists but is open at the time
Fix: loading first tutorial causes crash
Fix: unable to double click on drops in map
    mEnableDoubleClick is on by default, and a second click is registered before the double click
Fix: HUD arrows misplaced in resources tutorial
Fix: Floating transaction shown at end of PhysicsManager::RecessOverlappingStructure
Remap to WASD keys, tab to select next loaded weapon
F, V to rotate aim up and down, E to start autofire
Q to shut door

31/10/16
Fix: can't fire missiles as a group
Fix: testground and Mission 118 saved in detailed mode
Prevent maps being saved in detailed mode
Fix: hard to select ground devices in editor if one is already selected
    Promote device snap above ground snaps
Fix: autofire can shoot through closing doors, allowing weapons to shoot the door or themselves
Fix: Double-click not registered on weapon if coming from structure edit mode
Fix: move auto update period to constants and shorten
Fix: autofire gives up immediately when it hits solid structure
Fix: Group members that can't fire immediately due to lack of resources can fire much later
Fix: Replay hud not correctly positioned on some screen resolutions
Fix: crash when starting level editor trying to move children when replay HUD is NULL
Steam build submitted

1/11/16
Fix: \save undetailed creates a 'u' map
Fix: if shooting through closing doors, allow the shot to proceed but open the door
    FireSelectedWeapons checks doors in first pass with openDoorsOnly, then fires together if all clear
    If there is no collision on the first ray, check rays with doorsClosingAsClosed set, open these any doors found
Open all doors when attempting to fire
Automatically open doors for snipers painting targets

3/11/16
Fix: debug text appears after restart
Fix: autofire changes laser direction during fire, can cause replay desync
Fix: mReplayRoot can be uninitialised, causing crash on loading level editor
Make attract mode zoom out when a big weapon is fired or a reactor goes
Fix: Door under repair can auto-open when launching a missile
Reduce text size of mortar power
Fix: hard to select ground devices in editor if one is already selected
    Only enable ground snap modes if no device selected or keep selection is enabled
Keep mouse position when zooming out (not just in aiming arc)
Hide slave aiming arcs
Fix: selecting another weapon soon after one autofires the first

4/11/16
desync: weapon "Head" angle not set before extracting hardpoint position/direction in Weapon::Update
Fix: crash when user double clicks on a device
Fix: autofire only changes weapon angle when active or not selected

8/11/16
Back up PAX Aus build
Fix: crash when pressing autofire key while a device is selected
Increase aiming arc size of laser and cannon, increase MaxVisibilityHeight, reduce sensitivity factor and min aiming angle of cannon
Aiming variation for autofire
    Makes a few attempts in case the variation causes it to collide with solid structures
Fix: flood of door control messages when spotter laser touches a door
    Avoid sending if door has already been associated with the weapon
    Clear doors after closing
Only change materials after construction if a minimum length strut could not be completed with the remaining resources
Slight refactoring of double click handling

9/11/16
Recess solid materials when placing/replacing in front of weapons
Fix: team 2 weapons default to aiming up
Fix: show shot marker from start of weapon life time
Fix: device preview can show during autofire of selected weapon

11/11/16
Integrate stats and achievements
    For each mission: Attempted, GamesStarted, GamesWon, GamesLost, AverageWinTime, AverageLossTime, Ach1 & 2
    Create a struct for mission stats
    Program wide stats: Started, Starts, Ends, Time, First Menu, etc.
    Version reset
    Log misc stats
Enable Sandbox
Private beta communication links
    Steam group
    Open user folder
    Email Devs
Re-map pause to Esc
Disable deselect-pause during cutscenes
Balance: Weakened mg and sniper
Balance: Mg more prone to ricochet

12/11/16
Achievements
    Complete campaign
    Complete all missions
    Complete all achievements
    Enter 10 multiplayer games
submitted steam build 2016-11-12a
Fix: Console error for missing tutorial achievement stats
Convert stat output to minutes and hours
Fix: early exit by host not counted as a multiplayer game
Fix: coarse multi histogram not counting first bucket
Put stat mission names into a list
Fix: menu first counting when there are existing menu starts
Fix: moved quickstart.lua OK button to match new graphic
Fix: crash if chat message is received and mChatroom is NULL
Added warning about video sharing

13/11/16
Make Ctrl +/- zoom in/out fully
Remap Zoom marquee tool to B
Fix: Pressing escape immediately after restarting (or starting) a mission will cause an Lua exception in StartCutscene
    Flag cancel if early
Fix: if mission completed is 1 then set attempted to 1 also
Campaign map keys: Esc to quit, Enter to start selected mission
Fix: tab order in main menu and splash screen
Fix: long chat strings cause crash
Fix: limit players using server config
Add friends and private options to new server screen
Add note about Esc to skip cutscenes
Fix: pan keys sticking
    poll input rather than relying on events
Fix: add Dropbox file request link to main menu
Increase separation of pause menu items
Make Lobby default tab
Removed obsolete public servers tab
submitted steam build 2016-11-13a

14/11/16
Disable menu music in lobby
Clarified beta links in main menu
AI on missions in part 2 is disabled when cutscene is skipped early
Open crash and desync folders after they're written
Copy link to open DB file request in crash and desync folders
Unify prefix of crash and desync output files for better ordering in file request folder
Change 107 achievement 2 from 'don't light a fire' to 'hit mortars'
Add a tip to shoot the barrels in weapons tute
Put a population cap on machine guns in weapons tute to prevent repeat speech
Update objectives in repair tute to include shooting down mortars, add tip for RMB + LMB shortcut
Enable AntiAir tip in repair tutorial, show when mg is disabled but team has one
Fix: No resume in the pause menu in repair tute
Fix: show pause menu with score in Height Challenge
Stop pan keys working while console is down
Add turbine efficiency to device readout

15/11/16
Fix: Lobby visibility radio buttons can be turned off
Show number of players and capacity in the lobby list
submitted steam build 2016-11-15a

16/11/16
Fix: text buttons with icons creep to the right every time they're saved
Log autofire_start and autofire_end command details
Fix: transmit autofire state to other clients to prevent use by other players and AI, causing desync
    Also for teamed AI/human replay - prevent AI trying to fire weapons in autofire mode
    Option 1: send a start and stop message, spawn/door control messages are sent from the initiating client as current
        Marks a weapon as 'autofire remote', i.e. another client is operating autofire and it can't be used currently
        Local client must wait for confirmation before doing anything - there may be races
Desync: when joint breaks with a standin link and the node swaps ID with the clone due to standin link
    Then clients make different actual links but not the other due to the difference 
Keep doors open after autofire if local client has the weapon selected still
Increase autofire door close delay for machine guns
Reinstate version string to prevent connection of incompatible clients
Fix: host can remove self from database if a client disconnects, causing crash in Chatroom::GameJoinable
    Due to a corrupt client disconnect message making the host set its address to that of the client
Fix: clients in instant replay booted when host quits
After multiplayer games return to server select instead of main menu (black screen flash known issue)

17/11/16
Updated FMod build from 1.08.09 to 1.08.14
Fix: command queue and count is not cleared before joining (left over messages causing desync on join?)
Allow F6-F8 to work while console down
Fix: stop pan keys working while modifier is pressed
Don't substitute background or door material when overlapping weapon clearance if Ctrl is held
Fix: 'Map' text button in chatroom saved almost off screen
Fix: underscore saved to end of username if cursor is on
Fix: Don't activate a button on Enter if there is something in the chat box in the chatroom
Don't put tab characters into EditBox
Fix: ignore tab stops if they are disabled
Add ping to client table in chatroom and in-game (via F8)

18/11/16
Support changing of faction by mission script
Remap split group in editor
Fix: cycle item shortcuts don't press tab buttons
Automatically filter out part 3 missions from build
Fix: can't place adjacent turbine on bg bracing (strut intersects with neighbour)
    Lift and narrow bounding box to reduce instances of strut intersection
    Relax condition when intersecting device is on a strut aligned with the one in question
Fix: Team 2 weapons wig out during upgrading if they are blocked on either side
Carry over target angle and power when upgrading, clipped to new aiming arc
Fix: hide shot marker during construction
Excessive lag in game boots client to lobby
Added master volume control
Fix: keep track of where the icon came from to avoid adjusting saved Text control position for those externally made
Remove data segs from crash dump to reduce size (no apparent benefit)
Transmission of desync files over Steam
    Send files when the file request arrives
    debug dump destination must exclude userdir for relocation of files to work
    desync folder won't have the same name on the other system, and may be created after the files are received
        unify desync folder across all clients, but differentiate filenames
Fix: prevent host ever logging out self
submitted steam build 2016-11-18a

20/11/16
Fix: Desync when joining - 3rd party does not mark joining party as Playing at correct physics frame
Fix: While paused after desync another player joined, chatted, then disconnected
    Ever repeating client status/desync messages followed
    Disconnection loop created in Multiplayer::LogoutClient by sending self the disconnect message for logging to replay
Fix: Client with paused menu up applied client status instantly instead of via command queue
    Use GetSimulationRunning() for reliable testing of paused status
Fix: Client doesn't immediately apply status changes that happen during pause, causing desync on resume
Fix: reset mWorldPauseSent when client is set to joining
Fix: ClientDatabase::HandleClientStatusMessage adding blank clients instead of clearing slots when receiving invalid client messages
Fix: Host actually drop out clients when in Playing state and doesn't spam console
Drop lag sync state when client returns to chatroom
Set host ping to 0 for clients

21/11/16
Fix: Ready button not appearing in lobby after host returns from a completed game
Fix: don't allow Esc to drop the pause menu if it's a remote pause
Fix: Resume activating twice in multiplayer, unreliable when Esc pressed rapidly
Fix: crash when % is used in chat strings
Host sends world dump and logs of clients to other clients so there is a full set at each folder
Fix: host unable to bring up pause menu after desync
Close console when returning to chatroom
Fix: remove duplicate date from desync log copies
Incorporate a date & time to the desync folders, set by the host to be uniform
Show debug readout on desync screenshots
Prefix chat with \team to send it to team only, \all to everyone
    Defaults to all in chatroom and team in game

22/11/16
Reduced end game grace period by 25%
Client stuck in pause menu after host quit first after game
Require connection to Steam to start the game
Tab to switch who the chat message gets sent to. edit the prompt to indicate who it gets sent to
Don't show (all) in front of messages to everyone
AI: detects when construction is resource starved and reduces fire rate
Fix: grouped weapons have reduced fire rate for rebuilding and resource starvation applied
Fix: AI can not progress if weapon use prevents sufficient accumulation
    If create device results in insufficient resources, reduce probability of firing some weapons

23/11/16
AI: reduce construction phase if there's nothing to build
AI: Add chance to ignore penetration limits for some targets and weapons (e.g. cannon vs. reactor)
AI: detect if mortars are unable to hit target due to terrain overhangs
    Use mirror of fire angle for rough test
AI: if no device target found then some randomly selected nodes
Fix: AI should close doors if unable to afford the shot or reloading
Fix: AI weapon groups won't fire simultaneously if doors are in the way
Fix: Allow AI fort to proceed if unable to build a device
Fix: don't try to fire weapon if it's part of a weapons group attempting to fire already
Fix: add margin of error to AI adjustment of node position
Inspect state of stats (match starts with random number written to settings)
Add time bomb
Fix: crash when double clicking to go to the next tutorial
submitted steam build 2016-11-23a

25/11/16
Initialise buffer to prevent crash popup
Fix: multiplayer client status change events triggered properly
Add version number to main menu
Revert doors stay open when weapon retains selection for auto fire, just keep machine gun and sniper doors open longer
    If player takes manual control of the weapon by shooting it, don't auto close the doors
Add tips to weapons tute about construction and double click/E to fire at last angle
Make AI shoot at door as soon as it's constructed
Show animated create door arrow earlier
Convert door material to wood after constructing a new node (but not a strut)
Jeff updated client connected event
Added reactor protection against AP-snipers
submitted steam build 2016-11-25a

26/11/16
Fix: crash when trying to display team chat in replay
Write Steam app build Id to log

27/11/16
Fix: piracy crashes still generate crash dumps
Fix: Update stats after started flag set to avoid piracy false positive
Fix: pause menu appears at end of multiplayer replay with quit only option
Allow \record command to specify the team to record
A replay can be used to record an AI fort in case \record command is forgotten in Sandbox
Add missing AI forts to Hillfort - Long
Fix: AI doesn't create node if there's an unexpected one already there, links to it if necessary
Fix: WorldScript SnapToNode returning node index instead of id
Fix: AI doesn't map nodes that should not have been created at startup
Fix: AI script exception when AI Fort is empty of CREATE_NODE commands
Balance: reduce swarm fire cost by 50% and build time by 20 seconds
submitted steam build 2016-11-27a

28/11/16
Add an editor key (Ctrl + M) to create a mirror of a ground device for the other team
Fix: AI fort selection not very random for 2 available forts
Validate symmetrical ground devices
Validate symmetrical maps vertically
Add \check_symmetric console command for editor
\enumerate and \convert_ground commands default to maps directory
Add symmetric map validation to \enumerate_maps command and report (flag and result)
Hide construction lines and grid when taking screenshots for map previews
Observer space bar should zoom into both sides
Preview images are not accumulated as resident textures
Fix: Map preview images are updated after new version have been taken without restart
Validate ground and structure nodes, links and devices for symmetric maps
    Highlight differences with node_flash.lua effect
Hide debug text, reactor bars and cursor when taking screenshots for map previews

4/12/16
Team Deathmatch Refactor
    Detect and save the number of forts in each map
    Convert maps to new format (change format number)
    Change observer team ID to -3
    Add game mode option to lobby
    Add enum to WorldOpenMap indicating game mode (deathmatch or coop)
    On game start during TDM
        Iterate each team and covert a randomly selected structure on that side to that team
        Any remaining forts are deleted
        Happens before first keyframe is recorded, so should be replay-safe
        Team-mate door shutter not drawn
        Team-mate mines dark
        Unable to place new mines
        Side resources not showing correctly on HUD
        Able to build solid struts over devices
        Test that players are divided between forts
        Test that if there are not enough forts, players start sharing
        Delete unallocated forts
            If one side has an AI enabled without any humans then delete surplus forts up to the number of humans
        Crash in ClientManager::AllocateSpotters
        Show team cursors
        Spotters not painting targets
        Delete ground devices that were assigned a team but are not close to a foundation
        When player joins, accept allocation from host
            Otherwise allocate the joining client to the least populated team        
        AI doesn't fire in team deathmatch (must drop higher team allocation)
    Fix: Replay desync: client desync when joining (host applies playing state too soon?)
        Client status message in replay is applied immediately where it should be held until the appropriate frame
    Splitting resource pools
        When a new team is create add a new resource account to a map
    Add higher team accounts to replay keyframe
    Add higher team accounts to checksum
    Add higher team accounts to world dump
    Randomise player allocation
Ignore terrain and friendly structures when calculating turbine efficiency
Piracy checks
    global_stats:
        check that global starts is above a minimum
        check that global starts is greater than it was at last execution
        check that an invalid global stat is missing
    main directory file count, DLL count, EXE count, users directory
    user directory
    Steam App BuildId minimum
Fix: team chat works when players are separated in team death match
Fix: crash when loading unlimited resources mods when starting map editor
Fix: set order of forts in MP 4v4 1
Fix: unlimited resource mods not applied to team death match
submitted steam build 2016-12-04a

6/12/16
Fix: TDM desyncs if the host loads before a client (high team given)
Fix: crash Skylands ruin was set as Team1, confusing TDM fort allocation
Show OBS instead of T-3 in client list when set as observer (and support localisation of these)
Updated Split map, made symmetrical and recorded new AI fort
Fix: unable to launch missiles in skirmish against AI when on Team2
Fix: crash when a team exits TDM and tries to re-enter
Fix: crash when observer tries to join TDM
Fix: neutral structures are deleted in TDM
Allow game to be distributed without commander data
Automatically remove commander data if disabled
submitted steam build 2016-12-06a

7/12/16
Test: chinese font

8/12/16
Desync: TDM in Vanilla Large: unready client joins host on team 2, random number desync at about frame 600-700
    Joining client isn't aware that whole forts are missing when AI enumerates structures
    Prevent fort deletion for sides which have AI enabled (AI can get stuck if it doesn't have everything)
Made Vanilla Large symmetrical
Fix: Multiple music tracks playing at once. Duplicates music requests are ignored
Fix: Menu music plays after returning from multiplayer and replay
Fix: initial focus issue
    Show window and set focus immediately after window creation
    Use SetForegroundWindow on WM_ACTIVATE

9/12/16
Allow E to work by hovering over a weapon
    In building mode works without switching modes
Make it easier to switch to building mode with a weapon selected when left click to deselect is not enabled
    Double click on structure to enter building mode
Fix: Sound effects sometimes carry on after quitting instant replay
    Effects with oneshot events must carry on until the event has dies, so that they can be stopped on clean up
    Use the maximum of the explosion life span and the event length
Fix: some looping sounds (e.g. reactor, laser) carry on after pause with short delay
    Pause & unpause all explosion events

11/12/16
Create new depot 410903 for holding game content, original depot 410901 has single empty.txt file to clear out content
Extend time bomb to the 1st of December
Don't consider total number of files & directories in the root folder as an anti-piracy trigger (too greater chance for false positives)
\log_stats global can take a number of days to log the history of each stat
submitted steam build 2016-12-11a

12/12/16
Strut extrusion
    Left mouse down on a link and drag previews a strut extrusion with offset from click point
    Snap both ends independently to existing nodes and ground
        If one end point snaps to an existing node, snap the whole link
    Attempt to join these with the original link nodes plus cross braces
    Skip existing links
    Apply length constraints
    Drop extrusion if either node disappears
Fix: initialise StandinNodeID of CreateNodeMessage before passing to PlaceNode
Add capacity for 2 StandIn nodes
PNode stores mStandInNodeID, waiting link requests are sent as standIn nodes are replaced

13/12/16
Strut extrusion
    Generate a complex construction preview
    Draw waiting link requests to hide latency during extrusion
    Don't draw/create link if both points are on the ground
    Use background material when extruding door
    Fix: double click on door in structure editor fails to operate it
    Intersect solid struts with weapon clearance

14/12/16
Strut extrusion
    Allow create link messages to refer to nodes that are not yet made, to allow extrusion to be made in one step
    Add special case for drawing the link between the two standin nodes

15/12/16
Strut extrusion
    Prevent extrusion at low angles
    Prevent extrusion when aligned with other struts
    Calculate cost and reject if unaffordable
    Draw invalid extrusion preview in red
    Show cost preview
    Include foundations in cost calculation
    Recess struts using PhysicsManager::StrutShouldBeRecessed
    If material is unaffordable use recession material
    Align platform if close enough to horizontal or vertical
    If extruded node hasn't snapped but is close to vertical or horizontal, make it snap
    Disable node snapping during extrusion
    Holding control turns off material picking, alignment and clearance recession
Reduce initial size of WorldDump::mTickStates

16/12/16
Strut extrusion
    Make only one cross brace
    Add up transactions periodically to avoid them overlapping
    Put extrude alignment angle into constants
    Fix: Armor extrudes as background bracing if it's unaffordable, instead of bracing
    Fix: alignment with unselectable nodes don't block extrusion
    Block extrude if a point enters the ground

17/12/16
Place cursor at the last shot position when tabbing through weapons
Compensate for structure shift when autofiring a weapon
    On fire, add the device angle to the target fire angle
    On re-fire subtract the current device angle
Fix: AI doesn't respect locked weapon during team deathmatch
Fix: AI takes a long time to do anything
Auto defending machine guns
    Run AI script on player side
    Disable everything except anti-air

18/12/16
Reduce effectiveness of AI machine guns
    Specialise and increase anti-air std dev
    And random range to lead factor
    Only allow one anti-air weapon to fire per TryShootDownProjectiles call, round robin
        Add a chance to continue firing anti-air weapons
Close doors of anti-air weapons if time is short and projectile is heading toward weapon
Clear anti-air lockdown if threat destroyed
Fix: AI doesn't close doors when autofire interferes with aim
    Store doors opened by AI separately, close these in addition to found doors
    ReserveWeaponAim for AI for a period to prevent autofire returning to last shot
Fix: clicking near a diagonal strut can create an instant extrusion
Fix: manually open a door prevents the AI from ever closing it
Fix: cancel extrusion on pause
Fix: save script context when calling OnWeaponFired
Make AI open all doors instantly
In human assist mode, AI doesn't open doors to shoot down mortars (data.AntiAirOpenDoor)
    Unless the door is above the center of the weapon

21/12/16
Cancel Team17, Adult Swim & 505 games keys
Allow AI assistance to be disabled per mission or entirely
    Disable for campaign missions
Fix: AI assist not enabling
Make an Extrusion structure and pass to ExtrudeLink
Show extrusion preview for remote clients and replays

22/12/16
Fix: defences can open doors just before swarm impact
    Make each available defender inspect all projectiles
    retract or stay hidden if in danger from any
    select the best target (closest and/or most threatening)
    target the center of projectiles nearby
Fix: unnecessary opening of doors for last of swarm
    Don't lift lockdown if projectile is destroyed
    Extend lockdown period to 2.5 seconds 
Multiplayer: if there is a human on the AI's side turn it into an assitant
Fix: crash when weapon tries to operate invalid AI door
Balance: halved mini-gun reload time
Balance: Increased mini-gun burst length to 13 from 11 (+18%)
Balance: Doubled mini-gun standard deviation
Balance: Reduced mini-gun projectile damage by 7%
Fix: Only tries to open high door if blockage was caused by a door
Fix: obscured mortars take anti-air priority over missiles
    Test for line of sight to each target before considering it
Fix: don't load AI fort if acting as an assistant
Optimise: don't test anti-air targets for line of sight if too far away
Skirmish: add auto defences checkbox
Fix: crash when quiting multiplayer without Steam running

23/12/16
Add push/pop current script functions to WorldScript and roll them through all script events (e.g. OnWeaponFired)
Fix: letter box not stretched & right charcter misplaced for ultra wide screen
Add functions to enable AI debug levels at run-time
Fix: AI mortars disabled in mission 2

24/12/16
Fix: Explosion sprites fight for depth
    Stagger Z depth so lower particles shown in front
Fix: Missiles circle after passing the target
Fix: Ground devices closer to neutral pegs are claimed by team None
Fix: extrusion won't snap to neutral structures
Fix: eliminate wait from mortars in 102
Fix: dragging out a new node shows correct preview material, changes when built
Fix: helicarrier doesn't start in a sensible place on campaign map
Fix: typing in console during loading causes long repeat of characters
Fix: victory screen clipped off the bottom
    Make animation coordinates relative to page root, not absolute
Optimise: Only send client extrusion state during extrusion

25/12/16
Add circle and line effect types
Add script functions to spawn circle and line effects for debugging
Optimise: stagger AI updates to avoid CPU spikes
Optimise: don't cast more rays as soon as weapon is detected as in danger
AI: Calculate quadratic intercepts of mortars to improve accuracy of lockdown
AI: Visualisation of mortar trajectory and intercepts
AI: Only enter lockdown if there are doors associated with the weapon
Fix: smoke particles depth fighting

26/12/16
Fix: AI can operate doors undergoing repairs
    Add flag to link state to trigger close once repair is done
    Clear flag if door is opened
    Close if repair is cancelled due to lack of resources or damage
Fix: AI goes into lockdown if its doors can't close due to repair
Fix: AI builds existing Fort pattern while in human assist mode
Use ffmpeg to capture video in separate process
Added video capture frame rate to options screen

27/12/16
Fix: general AI behavior not limited in human assist mode
Fix: AI enabled on player team in campaign missions
Fix: capture handles paths containing spaces
Fix: ffmpeg console window can show if slow to start
    Attempt to regain focus after starting several times with delay

28/12/16
Fix: ffmpeg console window showing inconsistently in different situations
    Use CreatePipe and CreateProcess to hide the ffmpeg child process
Fix: Extrusion messages sent unnecessarily, causing queue congestion
    Incorrect comparison of last and current (size and pack)
Fix: Switch capture to real time keeper when paused to continue recording
Add timestamp to command trace
Fix: Client calls AbortLoad on timeout from host
Fix: Only flag mReceivedJoinFiles when joining
Allow capture during replay
Fix: Script has control of any high teams (in Team Deathmatch)
Fix: AI inspects the side to work out if an enemy weapon has fired

29/12/16
Integrated glew to access pixel buffer object functionality
Fix: Devices replay desync sometimes at 480: tiny difference in mReloadTimer
    Reload and Round timer values were saved in two different places
Fix: record weapon doors in SerialiseSimpleData

30/12/16
Move to rational step period (1/25)
    Scripts get frame rate from constants
    Increase sub-steps to 13 to compensate
Fix: Some effect scripts loading forts.lua
Fix: auto-defences not working in team deathmatch
Fix: use mDropout instead of AbortLoad if host drops out during play

31/12/16
Fix: remap step sim and damage area to avoid conflict with pan left
Fix: don't close anti-air weapon doors if unavailable
Fix: Game action freezes when playing Nick as host, Tim times out
    Intercept WM_SYSKEYUP-VK_MENU (consuming 6 seconds)
Reduce depth bits from 24 to 0 to save video memory

1/1/17
Fix: set missile launcher width the same as mine for interchangeability
Fix: prevent extrusion of non-selectable links
Added -vsync cfr option to ffmpeg to improve playback speed when unable to keep up
Capture video frame just before SwapBuffers to take advantage of the vsync wait period
Don't pick material when starting extrusion to allow specific extrusion types
Fix: close thread, ffmpeg process and all handles on EndCapture
Log capture stats neatly
Fix: abort capture if ffmpeg or thread stops responding
Add 25 fps capture option
Fix: don't attempt extrusion unless started
Don't drop material selection during extrusion while holding Ctrl
Fix: FrameRate value not set for campaign and condition scripts
Fix: OnCampaignPageLoaded/SetStat crashes if not connected to Steam
Increased subsamples to 14 to avoid observed instability in ropes
Balance: doubled mg reload and increased round period (slightly) to make auto-defences less reliable
Submitted steam build 2017-01-01a

3/1/17
Fix: Unknown crash in WeaponController::ProcessNode
    DeviceController::ProcessNode and WeaponController::ProcessNode moved to cpp file

5/1/17
WIP Record audio to mp3
    Create Fmod sound to receive recording
    Load and use Lame to encode to mp3

9/1/17
WIP Record audio to mp3
    Use single chunk buffer to write overflow
Update FModStudio to version 1.08.15
Use a circular buffer to record audio
Fix: read cursor getting ahead of write cursor
Start/stop audio recording at same time as video
Added lame_enc.dll to bin

10/1/17
Fix: video recording is shorter than it should be
    Keep remainder of capture timer
    Use -vsync passthrough instead of -vsync cfr
Use temp filenames during capture
Merge video and audio file into single video file using ffmpeg
Add video and audio bitrate options to constants, supporting VBR

11/1/17
Added missing RecordAudio files and BladeMP3EncDLL.h
Refactored RecordAudio storage for easier reuse of recorder and encoder (e.g. for capturing microphone)
Attempt to use waveform-Audio API to record microphone
    Apparently limited to recording from one device at a time

12/1/17
Fix: set timestamp in replays and restarts
Default to recording in real time
Add option to capture full game or toggle with key
Bind record start/stop key during a game/replay
Add button to export short clip to gif
Fix: Only hide overlays when capturing in replay
Esc can be used in replays to stop short captures
Fix: Rebound record video capture to Alt-R to avoid conflict
Show flashing recording indicator in top right corner
Show captured filename after clip has ended
GIF capture ends when pause menu is activated
Fix: removed g_CaptureRate 0 meaning off

13/1/17
Generate a palette before creating GIF
Fix: Crash when saving in level editor
Fix: crash when recording GIF in windowed mode
Add time limit to GIF recording
Display::RunProcess stops waiting after 6s

14/1/17
Add watermark to GIFs

15/1/17
Make watermark optional when recording video (but not GIF)
Add layout variables (ScreenWidth, ScreenHeight) to align controls to the right/middle of the screen
Add top right, bottom right and center anchors
Fix: unable to advance cutscenes
Fix: repair tutorial finishes before bombardment
Clouds missing from Canyon background

16/1/17
Allow extrusion while a node is selected
Fix: can't extrude a link with a temporary brace
    Allow unstable extrusions if one of the nodes has snapped to a non-braced node
    Show invalid (red) extrusion otherwise
Fix: mg muzzle flash out of sync with projectiles
Fix: fullscreen red when firing mg in debug
Add placeholder buttons to record video and GIF on replay HUD
Fix: Create new node, immediately link to another node -> link disappears
    Stand-in node is destroyed when real node is created, along with link
    Add to mLinkRequestQueue until node is real
Fix: mini-gun flash out of sync with projectiles
    Show muzzle flash when first delayed projectile is spawned
    Hide when last projectile is spawned

17/1/17
Movie playback
    Integrated Theoraplayer SDK 
    Resize static texture if necessary to occupy entirety
    Use static linking
    Campaign script can run a movie instead of animation
    Set all projects to character set Multibyte

18/1/17
Rearrange campaign screens using ScreenW & ScreenH layout variables
Added test file for campaign cutscene 2
Movie playback
    Playback audio stream
    Replaced .mp4 sample with .ogv

19/1/17
Subtitles drawn on top of movie
Movie subtitles have language mod applied for translation
Spacebar to pause/resume movie cutscenes
    Delay all subtitles while paused
Clean exit when using Alt-F4
    Handle WM_CLOSE to schedule quit in the main loop
    Call Shutdown in FortWarsShell destructor before anything else
Update Editor guide
Fix: polluted skycolour shows gaps on ultra wide
Force saved screens and previews into a specific aspect ratio (width fixed)
Allow Disable AI fort by script

20/1/17
Fix: Allow machine guns to open doors to shoot mortars in Mission 110
Submitted Steam build 2017-01-20a

22/1/17
Fix: extrusion not working in editor
Fix: can't join newly created node in editor
Fix: paste structure creates corrupt structure
Fix: RestoreNodes adds highestExistingNodeId to allocated id, making extra high ids
Fix: Extrusion creates multiple undo levels
Delete all structure doesn't create an undo level
Fix: reverted previous change to RestoreNodes node id allocation
Fix: Cutscenes play when restarted in Skirmish
Fix: disable human assist in tutorials
Fix: can't open link context menu from device mode
Fix: console error shown in 01-building: Vec3 not declared

23/1/17
Fix: AI not firing at specified location only on 103
Balance: Shorten door close delay on 103
Fix: AI stopped partway through 204
    Got stuck trying to build a foundation that was too close
    Advance beyond frustrated actions at the leading edge of the Fort, try to rebuild
Fix: disabled fuse in 204
Fix: Don't turn on grid when exiting cutscene in replay
Fix: Don't disable input when entering cutscenes in replay
Fix: ruins don't block AI cannons in 207
Fix: Page02 Theatre Unlocked static not centered
Balance: added extra armour to enemy fort in 104 to prolong player enjoyment
Balance: reduced enemy repair threshold to shorten victory
Boss mission support: Don't allow spotters or ground weapons on disabled structures to operate

24/1/17
Removed obsolete ITerrain interface
Ground collision effects can be specialised based on surface (null surface produces no effect)
Boss mission support
    Ground devices take structure id from nearest structure
    Pick structure id from world at run time
    Create an invisible block that destroys projectiles and block beams without effect
        Terrain blocks can be disabled
        Disable block when stage 2 is entered
    projectiles are destroyed when out of view bounds
    Add block name to terrain file format, set using \name_block command
    Disable 401 barrier by name
    Serialise terrain block enabled state and placeholder offset & offset prev
    Convert existing terrain files to version 20
Optimise: don't free animation and ground textures for faster secondary loading times
\convert_ground updates system to show progress
\convert_ground can take a map index to resume from

27/1/17
Optimise: ai.lua only calls NodeTeam once to reject unbuildable actions, move other calls down
Fix: BoundCameraToWorld after PlayerController::UpdatePanning to prevent overstep
Fix: ViewManager::BoundToWorld handles larger working space in terrain edit mode, preventing oscillation
Boss mission support: cut scenes play mid-way and end of battle
Enabled Page04 to test boss mission in place

28/1/17
Fix: stat errors in part 3
Add a hidden flag to stop setting campaign stats
Fix: 309 second fort fires through barrier
Fix: Letterbox appears for Sandbox replays with cutscenes
    don't run mission scripts when promiscuous is true
Fix: OnPreSeekSystem caused an exception seeking in replay
Fix: 401 stage 2 fort not rebuilding
    Second fort built after first fort AI scripted; second fort ignored during discovery
    Purpose is to prevent post-AI additions from being confused with Fort script at runtime?
    Instead, when scripting AI, start node id from a high value (10,000)
Added EnableRecIndicator option to settings.lua
Fix: weapons facing wrong way before update
Fix: memory leaks

29/1/17
End-of-theatre/mission dialog
    DismissResult built into forts.lua takes 4 names of cutscenes:
        0 (loss), 1, 2, and 3 objectives
    Campaign script passes strings in a WorldAddOutro structure
        Separate objectives/cutscene pairs
        Add to a table in the mission script
        Specify and load a script containing the outro cutscenes
Fix: Crash in ReactorsClaimForts::Apply when ground device has no closest node
Added 8x and 16x time speeds

30/1/17
Fix: floating neutral node bug in Mission 118_2017-01-29_112327.fwr
Localisation support for front-end screens and build errors
Localisation support for various messages
Adjusted position of first campaign page forward button for consistency

1/2/17
Add flag to hide controls in UIEditor
TimeShift uses float to set time factor
Added 1.5x time factor
Hidden controls can be toggled in UIEditor->View->Show All

2/2/17
Tutorial 03-weapons rework
    convert speech to cutscene and tips
    add starting fort with reactor
    merge navigation tutorial to start of 03-weapons
    move enemy further away to give more space

3/2/17
Tutorial 02-resources rework
    convert speech to cutscene and tips
    Don't send "mouse left" to script OnKey when over the hud to prevent skipping tip

5/2/17
Tutorial 02-resources rework
    Move repair bombardment to the end
    Trajectory preview of mortar
    Eliminated drag on mortars for precise trajectory preview
Fix: particle angle can't be updated externally
Fix: Tooltip for mortar
Balance: reduce scrap speed of turbines
Added batteries to back of enemy fort in 02-resources to collapse the base
Removed 04-repair tutorial from USA campaign map

6/2/17
Apply low pass filter to mortar fire angle and speed
Allow some tips to persist after clicking in world
Fix: objectives shown again after mid-game cutscene
Fix: clicking rapidly at can leave arrows in 02-resources
Fix: wobble at start of 02-resources
Fix: eliminate time at start of 02-resources without letterbox
Fix: prevent HUD page changing when trying to highlight an item
Make a sound when tip is shown and hidden (tip_show.lua and tip_hide.lua)
Fix: advance script when device is picked from the scene
Expand tip box for tutorial
Fix: prevent persistent Tips from being hidden when clicked on

7/2/17
Add cutscene to middle of 03-weapons
Add roughcut intro video to beginning of campaign
Fix: campaign map music played over movies
03-weapons: expose enemy barrel to fire, but douse the flames to weaken the fort
Balance: increased mg projectile mass and reduced drag to reduce ricochet
    To reduce chance of killing snipers deep inside forts by bounce
Fix: Control::IsPointClipped assumes control has top left anchor
Fix: Re-bound gc_contract_world and gc_expand_world to require Alt to avoid collision with zoom in/out
Fix: 16:9 aspect monitors cut off left fort during 02-resources bombardment
    Recalculate zoom when restoring screen position
Added RepairCancelsOnDamage, disabled in 03-weapons to prevent player shots blocking fire extinguish
Balance: adjusted enemy barrel position in 03-weapons to weapon the fort just enough to be easily defeated

8/2/17
Turn off start_game effect for tutorials
RestoreScreen can take "team1", "team2" or "overview" to refer to system screens
Fix: clamp values in ViewManager::CalculateZoom to avoid sliding at end of camera transition
Fix: unable to toggle Skrirmish commander enabled check by clicking on the text
Fix: toggling Skirmish commander enabled toggles preview panel
Added 1/32x and 1/64x time speeds to replace buggy super slow speeds
kc_toggle_show_cursors hides weapon reload icons
Fast build in tutorials
02-resource: continue as soon as all damaged struts are repairing
Add drag arrow from starting fort in 03-weapons
Add events for starting and snapping extrusion
    Keep pointers to extrusion snap points
    When one or both go from NULL to something, trigger event
Snap extrusion to 95% of the max length
Game version incremented to 0.21, replay version incremented to 17

9/2/17
Revise dialog for campaign part 2 & 3
Reduce Physics.TickLookahead from 3 to 1 to reduce response time to sub 160ms

10/2/17
Replace all instances of Ore with Metal, capitalise highlighted names of objects
Place outro line into outrosTheatre.lua cutscenes
Add CharacterLeft and CharacterRight to change graphics mid-cutscene
Fix: Text highlight loses space after highlight block
Remove all caps highlighting
Show mission name instead of folder name in campaign map preview
Use Mission 401 instead of 114 for part 1 & 2 final mission
Reveal motherload region after second theatre in each part
Helicarrier moves and motherload revealed after theatre unlocked anim plays
Go straight to tutorial mission after intro video
Fix: campaign map visible before intro video starts
Random tips in first loading screen drawn from db/strings.lua LoadingTips
    Graphic textures mirrored in ui/textures/loading
    Randomise seed of EffectsManager Rand for loading screen tip selection

11/2/17
Fix: account for achievements already gained from a mission to test if outro should be played
Allow mines and silos to extend available ground

12/2/17
Allow nodes & links to be selected while a device is selected for instant extrusion, etc.
    Only snap to doors when cursor is in the aiming arc
Trigger snap_node, snap_ground, extrusion_start events from single joint construction
Fix: snap_node is playing when extrusion collapses
Add a note to the tip box saying click or Enter to skip
    Convert skipping to Enter
Fix: picking device from world and placing selects structure
Fix: after a device has been built to the population cap, weird error message appears when clicking on links
    Drop device selection
Only show grid when placing a node, extruding, or placing a ground device
Use transaction preview with resource icons for foundations
Left drag in space to pan view
Prevent left click skipping pan test in 03-weapons
Add arrow pointing to connection in 03-weapons

13/2/17
Fix: don't deselect weapon when left mouse panning
Fix: mg bullets raining down
Fix: extrude armor infront of weapon turns into BB
Fix: don't start panning when just created a new node
Comment on missing or out-dated tutorial and loading tip graphics (recoil)
Allow tool tip to hide graphic when empty, add expanded text box to use

14/2/17
Fix: loading subtitles is attempted for all PlayMovie calls
Tutorial bonus objectives
    Connect fort
    destroy barrels
    Build 100% turbine
    Defend fort from mortars
Fix: popup message shows when returning to tutorial page

15/2/17
Add note to first theatre to unlock about how to unlock
Fix: Right click disabled in 03-weapons
Fix: Enter doesn't allow to skip hand pan task
Fix: Enemy AI can open player doors
Fix: mission 306 - building up to make a foundation with grid on, the preview vanishes
Fix: Unable to toggle from overview in Vanilla - recalculate screen zoom on load
Fix: update screen positions for sensible space-bar behavior after connecting fort in 03-weapons

16/2/17
Fix: hide previous shot marker and grouping lines when controls are locked
Fix: show 'select weapon' message in 03-weapons if door is opened directly
Fix: can't operate campaign map buttons after game has been sitting in background for a long time
    RealTimeKeeper paused regardless of pause status of PhysicsTimeKeeper
Fix: sniper projectile cut short
    Reduce ProjectileTerminalVelocityForceThreshold
Fix: Mouse lag - Mouse movement seems laggy
    Eliminated mouse delta filtering
Changed to separate Start/Ready buttons in lobby, Ready button has a checkbox to indicate state rather than text
Fix: Chatroom uses some literal strings
Fix: Slave button overwrites mIcon of parent even if already set
Fix: TextButton gets stuck repeating rollover sound
Fix: client team reverting to zero after force/join in 1v1 TDM
Fix: loading tip doesn't show if you leave lobby before a game
Fix: shoot all targets objective not working in 03-weapons
Fix: crash in replay- Weapon saving AI doors under repair without correct count
Desync: Instantly in 1v1 TDM
    Client apparently allocates forts before host has finished loading
    Send client status messages before StartGameMessage
Fix: Set clients unready only after start game message sent
Fix: don't turn off client ready state when inviting friends to avoid host losing ready status

17/2/17
Fix: PhysicsManager::IntersectLineSegWithStructures is comparing links out of order during replay
    mPrimaryStructureState's structure id order is different
    Apply std::sort at end of PaintStructures
Move create group achievement to 101
Update the achievement for Missions 118: now snipe both mortars
Fix: Europe outro dialog incorrect
The achievements for 104 need updating, now the first mortar has been removed
    Cycle minigun group fire
Fix: theatre outros can play more than once
Tokenised splash screen strings, updated strings and preview

18/2/17
Fix: client stuck in pause menu at end of battle
    mEndOfGameTimeoutEnabled wasn't being cleared so client was constantly rebuilding pause menu
Fix: replay desync when extruding during keyframe recording
    Extrusion commands can span frames and be separated by a keyframe
    Need to put PNode's mStandNodeID into simple data for serialisation
Fix: replay keyframes were within 8 frames of each other
    Remove confusing/unnecessary mMinimumFlushSize and instead just record keyframes at regular intervals
Fix: weapons can face wrong way when seeking TDM replays
LogCommand shows extrusion and keyframe commands
Fix: Recursive use of Format in CompositeSprite::IterateNodes
Fix: Memory corruption in TDM when laser hits enemy
    Weapon::ProjectBeam and PhysicsManager::CollideWithLinkPossible converts team to side
Fix: could not place device with another selected, 'keep selection' enabled
Fix: TDM team 2 had trouble firing missiles - left click pan interfering

20/2/17
Balance: Increase laser reload period, build time
Balance: Reduce warhead and heavy mortar build time
Balance: Reduce minigun damage, increase build time, fire cost and reload period
Renamed \dump to \crash_dump to avoid accidental use
Renamed \dump_world to \dump for ease of use
Add dump at frame command (allow multiple), and clear dump at frame
Fix: replay desync at high speed due to link->mWeaponLockTime taking time from PhysicsTimeKeeper, not physics clock
Fix: commander not charging in TDM
Prototype reactor effect for commander activation
Remove leaderboards from mission brief panel
Add upgraded mine graphics, compressed mine textures into dds
Added MirrorLeaf flag to CompositeSprite Node, to flip the second miner in the upgraded mine
Add Link mWeaponLockTime to checksum
Fix: underscore can be added creating a new map or copying existing map
Fix: in PhysicsManager::BreakStructure, delete newNode in early exit if necessary
Fix: PhysicsManager::IntersectLineSegWithStructures remove obsolete nodeId parameter
Fix: host and client both watching instant replay, host drops out, client soon gets "excessive ping, dropping out"
Fix: client can time out when game doesn't have focus
Fix: Chatroom refreshing even while not visible
Fix: Client simulation not halted when game times out
submitted Steam build 2017-02-20a

21/2/17
Trigger node effect with _end appended when turned off in Device::ConfigureNodeEffect
Fix: disabled shield blocks available firing angles, and stops slaves from shooting
Fix: struts under construction don't block aiming arc
Disable left mouse pan in terrain & prop editor
Fix: console stuck down when P2P connection failed during multiplayer load

22/2/17
Rename material, devices, and projectiles to remove core- prefix, hyphens & standardise naming
    Projectile saveNames mirror the weapon they are associated with
Device and material display name and tool tips move to devices/strings.lua
Subtitle strings are drawn from campaign strings.lua, so can be translated in the same way

23/2/17
Export strings into a TSV file, import into Google Docs
    Add UniToAscii project to convert into format Lua interpreter can work with
    Export strings.lua files and process into tab separated values file to import into Google Sheets

24/2/17
Renamed materials, devices and projectiles delimited by single quotes
Added GenLangs project for producing language mods from a spreadsheet
Cutscene at the end of the first tutorial, and when you connect to the fort
Hook up cutscenes 2 & 3
Remove final cutscene from 401
Hide HUD after rebuild in 03-weapons
Fix: Allow rebuild of sniper in 102
Fix: need spotter cursor showing up in 102 after machineguns destroyed
Fix: mouse pan cursor sticks when entering cutscenes

25/2/17
Allow base strings.lua to be absent so all strings are always taken from a language mod
Make material.mDisplayName a wstring for variable length
Make theatre medals appear only when all medals are earned
Fix: skirmish commander enabled when global setting is disabled
Support playing movies in-game
Show victory/loss movies in mission 401
Fix: extrusion can sometimes get stuck
    Drag a nearby joint onto a link enters extrusion on the up
Fix: Unable to extrude with weapon selected
Fix: Unable to select nodes or all links and extrude when disabled device selected
Fade out music, disable camera control and hide cursor when playing victory/loss movie

26/2/17
Add debug Text class mode that displays dummy strings for anything not set via token
Fix: SimpleDialog deals with stringId rather than raw text for localisation
Tokenise mouse speeds
Tokenise campaign in progress
Fix: UIEditor evaluates layout of all controls when position or size changes of any control
Fix: Correctly calculate PrevSibling layout variables, and added left and top
Tokenise fixed key bindings
Re-use faction sign off strings
HUD tab buttons are blank and have localised labels
Added ParentPressed layout variable to drop HUD tab labels
Tokenise resource readout strings

27/2/17
Move old victory page to Page03 only for preview
Remove restricted commanders
Rename campaign to Black Gold
Add arrow to machinegun in 02-resources
Increase variability of mortar trajectories in 02-resources
Tab buttons not switching in tutorials
Fix: objectives too spaced out
Fix: sliding out of theatre unlocked banner
Fix: campaign in progress not selected
Too hard to achieve objectives in Burning Down The House
Remove 'no video sharing' graphics
Change mission brief tab to objectives
Make 03-weapons wider
Fix: overview in abyss doesn't cover upper mining areas
MapSelect can be configured with Buttons discovered in Grid
Added Index, W and H layout variables for arranging buttons in a grid
Added Grid layout for commander selection
Show disabled commander silhouettes
Disable padlock to hide level editor
If loading lua file fails, attempt luac
Compile tutorial script to hide trajectory code

28/2/17
Fix: sprite manager time updated in front end
Add pulsating selection overlay to grid buttons
Grid prototype serialised to create new grid items
Set grid item Name label from script
Commander selection is preserved between visits to selection page
Turn panel in battle screen into a button to change commander
Moved commander icon effects up a little to not obscure weapons
Fix: Devices made during commander activation don't get node effects
    Needed to use inactive device prototype in ReceiveCreateDeviceMessage
Balance: decreased marksman active period to 10s and increased charge rate by ~30%
Fix: Effect when small rounds hit foundation surface absent or incorrect (armor hit)
Remember commander screen selection in Multiplayer
Fix: Campaign fight button not working
Save campaign progress before and after each mission
Fix: Disabled human assist AI in part 3 & boss mission
Fix: factions for part 3
Fix: Unnecessary calls to Team1 AI and toggling of Team2 AI
Fix: Trap repairs itself in mission 306 -> make neutral

1/3/17
Added rollover highlight to MapSelect's Gridbox
Balance: increased Architect's storage bonus from 25% to 50%
Stop left click anywhere advancing tutorial tips
Fix: idle music not stopped on victory in 02-resources
Fix: mg getting hit in 02-resources
Extend trajectory in 02-resources
Fix: streams that are resumed instantly can fail to restore their volume
Fix: prevent music.lua making changes if it has been paused
Fix: 03-weapons progress if player connects to fort before peforming navigation tests
Fix: crash in MapSelect when updating grid after destruction
Fix: 03-weapons outro exit shows the HUD
Fix: remove click when left click panning while device selected
Fix: hide HUD item highlight in tutorials if tab changed
Device not building when picking from existing (turbine in 02-resources)
Fix: When device is selected and keep device selection is off, vertical struts are not snapped to
original system screen positions are saved as original_* for later restoration
Fix: 03-weapons system screens not restored on restart
Fast-build mod sets build and scrap duration of all devices and weapons to 2 seconds to speed mg build in 03-weapons
Fix: Block left size of 03-weapons after connection to preview skewed zooming
Fix: remove pan arrows if navigation area skipped
Tips are permanently dismissed after one click instead of three
Tips take much longer to appear and stop appearing after being satisfied 3 times
Added states to music.lua which can be mapped to different series, for overriding
Tutorial music scripted into 03-weapons and 02-resources

2/3/17
Fix: remove instant replay from tutorial menus
Fix: if player restarts first mission before winning, the outro isn't shown
Fix: shot marker is unreliable for simple restores, update after platform angle is set
Fix: Practically zero link health is seen as fully healthy link
    Added a small amount of extra animation time to cover the edge case
Fix: machinegun flash doesn't appear on enemy the first time
Increased projectile tail factor by 50% for dramatic effect
Fix: first mission -> restart -> win -> insant replay -> restart
    Error: debug buffer start is not pointing to a valid command
        Seems to happen with longer replays
    HUD pops up unnecessarily
Fix: objectives not hidden when entering instant replay
Fix: replay select screen doesn't keep the preview, changes with rollover
Fix: can start a left click pan over replay HUD

3/3/17
Add overheat mechanic to machinegun
    steam effect and sound
    linear meter
Balance: machinegun overheats after 3 rapid bursts
Commander selection portraits
Sort commanders by faction
Add a string to exclude certain commander folders
Fix: random commander selection ignores disabled ones

4/3/17
Preview for 401 not included in preview build
Create special preview strings file for mission 401
Allow special mission preview index 0 in campaign
include LuaC in the bin folder and compile campaign progress to deter cheating
Fix: fmod 3D attributes not set when there is no effect script associated with an event
Fix: Unable to append fort scripts
    Reintroduced script to remember which file line each action came from
Optimise: Disable smooth record in tutorials
Fix: 401 not being included in build
    campaign pages have different case as folder
Fix: win by chain reaction broken in WMD
    Update number of barrels and specify DeviceType as barrel
    Ignore events after game is over
Add tips about tab and refire to WMD
Add debug key to lose map medals (k)
A bridge too far: Snipe all machine guns broken
Replace string instances of cable with rope
Fix: Alternative Facts objective still mentions second mortar
Fix: no resume in instant replay menu
Fix: replay hud visible after skirmish instant replay & restart
Fix: detachment in 03-weapons breaks tutorial
    Most likely to happen immediately after connection -> wait a period until running cutscene
    After cutscene if disconnection happens, save current tip and pop up tip ask for reconnection
Fix: HUD popping up after outro cutscene
Miniguns pointing downward after upgrade
Fix: commander preview doesn't show if you return to map select with commanders enabled
Fix: script crash when reconnecting fort poorly
    Handle case where there is no persistent tip
Remove tip about level platforms, too many false positives
Fix: textures not clamping on props
Balance Make AI miss the first shot in 101
Balance Make AI miss the first half minute, then be far less accurate in 107
Fix: don't set up original_* screen positions unless in play mode
107: mortar position not focussed on/pointed to, lower overview position slightly
Balance: increase AI chance of firing cannon or laser during rebuild to make it less gun shy
Balance: slightly reduce AI idle time during Normal
95% health counts as repaired in 02-resources for accessibility
Balance: Make it slightly easier for mg projectiles to hit missiles (shootdown radius 12->14)
Automatically stop recording video or GIF if replay hits the end

5/3/17
Fix: movie and campaign map layout in resolutions with aspect ratio of 1.6:1
Fix: movie image garbled for split second on start
    Show/update movie Static but set alpha to zero for half a second
Pause after connection cutscene to allow player to see medal drop, slow transition
Fix: Skirmish AI not rebuilding weapons claimed in neutral forts
    Disconnected forts that start as owned by the AI are not referenced
    Now mark all structures as referenced regardless of starting team and add extra pass for these forts
Fix: AI can build devices on neutral structures
Fix: sniper sight missing in multiplayer game
    ClientManager::IsDeviceLocked was comparing client side with weapon team
Listed keys for adjusting sniper laser sight, time speed and toggling HUD and status readout
Fix: CommandInterpreter::HandleNetworkPacket logging all traffic
Fix: ground texture and props not showing up in editor
Fix: turtle doesn't insta-repair in TDM
Fix: ClientManager::AllocateSpotters crash when using missile refire in TDM, line 681
Fix: Using % in the chat causes a crash
Fix: Oscillation of camera when zooming out rapidly
Fix: Don't try to zoom out when at maximum zoom
Add key to activate commander (Ctrl + C)
Fix: Clouds background has a gap at the top in 16:10
Fix: don't apply window position in fullscreen, or the controls to change it
Block console drop and effect caused by live and replay chat during capture
Fix: camera stuck zoomed in during second tute
Fix: special handling of motherload not being applied due to differing case
Shortened and removed some objectives in pt1

6/3/17
Campaign, Sandbox and Skirmish menus return to previous position/settings
Listbox navigation keys work when mouse is outside
Setup tab stops in campaign menu
Fix: Time up/down are registering double clicks
Add key to upgrade devices including hover + press
Fix/update key bindings
Move version string into constants for easier updating
Allow objectives to be collapsed
Fix: skipping navigation tips doesn't advance the script
In 02-resources, advance after a period once both objectives satisfied and after fires are doused
Fix: objectives visible outside campaign and during cutscenes
Update commander grid layout for smaller portraits
Fix: unable to exit editor
Fix: deleted original_* screens added
Use drill instructor for starting outros
Fix: AI doesn't discover links when there are no actions in Fort
Fix: AI scripts not restarted in Skirmish

7/3/17
Disable key navigation in console
Fix: key activation of commander causes desync & spammed end events
Fix: crash when activating commander
    MapSelect creating duplicare sprites
Fix: don't activate commander by key after game is over
Fix: text button colours in pause menu hard coded
Use static vcruntime to avoid dependency on Steam installer which sometimes fails
Replay music intensity not reset on seek
Right align version text
Change all _stricmp to secure versions
delete Spanish mod from build

8/3/17
Update workshop base to show animation
Fix: music stops sometimes during multi-reactor games
    Reactor low sting not playing, so no completion notification
Fix: Reactor low string can be cut off by its destruction
Fix: Hide all flightpaths on restore state
Turn off node & link selection at a zoom threshold
Boost WeaponSelectionZoomBias slightly
Enable FMOD_INIT_VOL0_BECOMES_VIRTUAL and set vol0virtualvol to reduce number of real channels used
Fix: sfx channel count climbs with every battle
    Unpause before release

9/3/17
Fix: Set path for commander scripts in all locations to prevent sprite load failure

10/3/17
Show real/virtual channel breakdown in debug readout
Added video attract mode
CutsceneActive may not be cleared before other input events are handled while paused
    WorldScript OnKey can return true to indicate the event has been consumed
Fix: consume all input events on campaign and battle exit
Fix: Cancel all effects on campaign exit
Fix: Apparent freeze when Escaping campaign during medal drop
    Re-enable mouse input on campaign exit
Fix: wait short time after returning from mission before handling escape events
Fix: moved in-game help screen up to avoid the HUD
Fix: Sitting on a bomb mission objective snipe mortars can be won by destroying reactor

11/3/17
Replaced length in many strncmp calls with fixed upper limit
Fix: spurious crash on entry to multiplayer commander select and in lobby
    4v4 1 multiplayer observer TDM with commanders
    StructureEditor::StructureEditor was using negative teamId/teamIndex from observer -> memory corruption
    This was happening elsewhere with random memory corruption
    Clamp negative teams to 0
Fix: Team2 fort sometimes full of holes in skirmish or multiplayer
Fix: Ambient and looping node effects audible when game doesn't have focus
Fix: Video attract mode went on during multiplayer AI battle, observer only
Attract mode in skirmish returns to map select when interrupted
Attract mode works in multiplayer pause, returns to lobby on interruption

12/3/17
Changed obsolete \restore_default_preferences to global \reset_options
Fix: crash in HardwareTimeKeeper::Update(). QueryPerformanceCounter failing?
    Check return value
    Align clock_time to 8-byte boundary
    Validate time shift and time scale
Add power consumption tip to shield mouse over
Fix: busted foundation in Abyss
Fix: filter enemy commander selection
Add a tip about extrusion if player doesn't use it for a while
Move Sandbox further down the main menu list
Reinforce extrusion in first tute
Add a tip to Sandbox describing what it's for
Fix: don't show build error when left clicking far from an isolated node
Fix: Limit preview from isolated node to maxlength, not maxlinklength
Add extrusion handle when mousing over a strut
Change cursor to pan hand during extrusion
steam build preview 2017-03-12a submitted

13/3/17
Fix: video attract mode always enabled, causing crash in preview
Fix: excess logging
Tokenise commander names and description

14/3/17
Fix: don't show extrusion handle on non-selectable links
Fix: Skirmish enemy commander selection not very random
Fix: Blank SpriteProto created with sprite key 0 due to composite Static having no sprite
    No action in update, etc. if Sprite key is invalid

15/3/17
Fix: crash on game over/reactor destroyed (probs music related)
    music.lua calling PauseStream with currentChannel nil
    Call OnPreSeek before and OnSeek after instant replay is set up
    Remove OnInstantReplay from music.lua and properly reset music state in OnSeek
Fix: ReactorLow sting doesn't fade out on defeat
Set optimisation the maximise speed (including movie player libs)
Fix: Commander name in chatroom wrong

16/3/17
Tokenise cursor readout generation (e.g. fire, generate, cap, efficiency)
Tutorial
    Integrate new extrusion animation
    Put extrusion tip first
    prevent selection of joints until extrusion done
    On success, mention normal construction
    Fix: Connection tip shown every time an extrusion takes place (with sound)
    Detect when player misplaces a weapon and advise correction

17/3/17
Tutorial
    Protect enemy fort before reveal
Fix: when restarting 401 following movie mouse not responding to input 
Add rapid fire on stage 2 of 401
Tutorial
    Detect misplacement of second mg in first tute
    Allow continuation when misplacing mg and then opening up a hole
    Detect misplacement of mortar in second tute
    Allow rebuild of machine gun of in second tute
    Make mortars easy to shoot down in second tute (added easy_aa mod)
    Fix: tute breaks if player deletes mg during barrel shooting
    Clarified some instructions
Darkened background of theatre unlocked animation
Final mission
    Overcharge reactor
    Extend mortar range
    Drain reactor health until mission won
    Show overcharge effect
Fix: crash in PhysicsManager::Dump world when NULL platform nodes are dereferenced
Fix: crash in Multiplayer constructor
    passed HideLoadingTipCommand to loading screen via front end factory

19/3/17
Make a note about turbine efficiency preview in tute 2
New shield impact effect
Fix: -map command line not working
Update laser sight graphic
Removed obsolete Construction_worker graphics and nodes
Fix: Sandbox tip showing up in editor
Fix: low energy tip showing up when full
    AI was triggering OnBuildError for player
Add main menu tip recommending starting the campaign to learn how to play
Change 104 objective to build and upgrade a new minigun
Enable Auto-defending machine guns through campaign for Easy and Normal difficulty
Fix: Pause resource collection & consumption during cutscenes
    mProductionEnabled added to replay key frame, replay and network versions incremented
Balance: AI doors stay open a few seconds longer in Europe bridge mission
Optimise: Msg::ScriptEvent zeros string memory for better replay compression

21/3/17
Pause/resume resource production via message sent by Mission script to avoid replay desync
Fix: selection/building issues when ground device selected, confusing error shown
Fix: Extrusion snapping to non-owned ground
207: the AI is still firing his cannons and destroying the ruins first
Steam stats for 3XX & 401
Fix: pause menu not appearing after 203
Add time limit objectives for part 3

22/3/17
Fix: Map AI nodes to originals when creating and deleting nodes and links
Fix: Clamp next node ID to 10000 when appending an AI fort
Fix: When appending after an extrusion, extrusion fails
    Swap order of actions so that BraceNewNode advances fort index, for identifcation of script line
barebones mod now doesn't disable items, stil disables physics
Base string files don't have to exist for the mods to load
All string files are loaded through ModManager
Fix: mod filename can be forced so different string files can be loaded into the state of a another
Moved strings.lua files into language-English mod via Google Sheet

23/3/17
Added DummyModManager to UIEditor to always load strings from English
Added Game options tab, moved some options & reduced size of checkboxes
Allow optional unlimited resources in Sandbox
Prevent device selection when cursor is within build circle, but allow when zoomed out some way
Disable device selection when extrusion in progress
Decrease StructureSelectionZoom slightly to reduce accidental selection
Fix: Extruding wide struts can build without a cross brace
Enabled optimisation for Debug build (except files as necessary)
Added cycle preview button to map and replay select screens

24/3/17
Objectives for part 3
Add insta build cheat for testing
Add fill resources cheat for testing
Add insta reload cheat for testing
Fix: objectives for mission 305 misnamed
Fix: MessageNames out of sync with Msg::IdType, causing crash on debug mode
Fix: pause menu popping up on escaping 310 cutscene
Fix: AI rope position in 305
Fix: AI gets stuck building a rope in 305
    Failed actions (e.g. create node) during normal buildout blocks indefinitely
    Add to frustration like when rebuilding, eventually skip
Fix: instant build cheat not triggering OnDeviceComplete
Play cutscene 4 when entering motherload

25/3/17
Fix: Subtitles of final cutscenes not showing/causing errors

26/3/17
Fix: WorldScript AddTextControl passing NULL parent to SetControlText
Fix: 306 keeps firing at destroyed barrel, and not firing missiles
Fix: reactor still overdriven on restart of 401
Fix: replay keyframe desync when mortars and missiles are airborne simultaneously
    Mortars were not reserved a slot, later missiles could overwrite them, sharing the MeshProjectile pointer
    Added node mp slot to projectiles checksum & increased replay and multiplayer version numbers
Fix: skipping navigation tutorial prevents you building single joints
Add icon to indicate preview can be cycled to campaign map preview
Fix: crash in HUD::Update when neutral in Sandbox, hovers over commander activate
Fix: Can't launch missile if it is cut off during fire and reconnected
Fix: Steam can't delete old maps due to unrecognised Loading.lua file
    Moved loading byte count into single Loading.lua file in user dir
    Delete all obsolete Loading.lua files on start, and any empty folders left afterwards
Store keeps filename if file not found and createOnFail is true
Store::Save uses member filename if NULL is passed
Fix: Crash in StructureEditor::Update when no materials are enabled and a node is selected

27/3/17
Fix: Unable to repair pegged ropes near their end
Fix: 401 second stage overview screen not updated
Add tip to deter blocking the machine gun in 2nd tute
Fix: some sounds still play when sfx disabled
Fix: music overlapping in mid cutscene of 401 if reactor low plays
Fix: cutscene music overlaps if you restart during mid cutscene in 401, and doesn't end
Fix: transactions showing up for observers
Fix: hide commander selection from console
Fix: clean up multiplayer console logging for clarity
Fix: don't show TDM high teams in chatroom
Tokenised multiplayer status strings
Make console linger longer on chat messages, drop deeper
Don't drop console during multiplayer loading
Change multiplayer loading screen text to 'waiting' once loaded early
Optimise: Stop sending key events over the network
Disabled obsolete mod windy

28/3/17
Missiles missing target sometimes
    Recalculate target continuously until within certain range of target
    Lock target once within range to prevent circling
Prevent execution of script commands from console during multiplayer
Master volume not set on launch
Fix: crash on save & quit of editor trying to trace NULL replay
Fix: Host unable to bring up pause menu during initial replay
Multiplayer state sync and crash issues
    1v1, client loses, host starts instant replay quickly, client quits
        Client crashes in lobby, no crashdump
    Quick 1v1, host quits instantly, then client quits soon after -> client thinks that host is still playing
        Host thinks client is ready
    Crash in CompressAndWriteChunk when slow client machine quits game
        Wait for end event to be set - appears to prevent other state bugs

29/3/17
Fix: Pause game and sounds during final movie
Fix: Pause music during final movie and resume afterwards
Fix: reduce mortar boost in 401
Added \sweep_blocks command to remove single node blocks
Mute all sounds continuously during final movie playback
Fix: Subtitles not showing up in final movie
    Pausing simulation stopped updates to script
    Keep physics time going but turn off physics & other updates (will desync replay)
Fix: condition-time limit.lua awarding objective for defeat within time limit
Fix: crash on exiting replay trying to log invalid replay filename
HUD disabled on revert automatically when cutscene started immediately
Fix: Invalid sprites cause crash
    Commanders effects are loaded permanently, but become invalid the next game
Fix: Commander icon effects not appearing
Fix: condition-time limit.lua counts displayed time too fast, uses actual time for result

30/3/17
Fix: team distribution doesn't handle TDM teams, causes memory corruption
Fix: replay keyframe desync when taken shortly after mesh projectile impact
    no MP needed to be created
Fix: AI sometimes fails to put out fire
    Make extinguishing fire free to prevent AI running out mid-repair
    Prevent fire igniting on or spreading to links under construction
Fix: Preview snapping to sloping struts while selected weapon is building and keep device selection is on
Fix: Hitting enter in edit box screen appends underscore
Fix: Empty server name starts lobby with empty name
Fix: Spaces in lobby are allowable chat
Fix: commander can be triggered by the keyboard without being charged
Fix: ui/strings.lua loaded for every Listbox and grid item

31/3/17
Add tabs to map select screen
Fix: crash when selecting maps in new tabs
Help button in editor goes to Steam guide
Use display name of map instead of folder name in multiplayer
Fix: use time remaining to calculate objective consistently
Added separate checkboxes for auto defences in multiplayer
Added EarthWork Games logo movie at start
Show 'restart required' when changing video options
TextButton uses DisabledColour from style when mEnabled is false

1/4/17
Revert chatroom to two checkboxes for AI, but log changes to the chatlog to indicate meaning
Fix: delay starting the fire on easy and normal in 306
Auto refresh tab when you switch in lobby select
Fix: crash in client on connect
Fix: clients able to change commander enabled
Re-arranged chatroom layout

2/4/17
Fix: mouse over back bracing in context menu, overlay is misplaced up
Fix: Repair key sticks if held when cutscene starts, or console is dropped
Set version string of lobby, filter lobbies
Exclude included maps from editor, except template
Fix: logo movie centred for ultra widescreens
Fix: Startloaded mod not working
Center mouse on start
Fix: AI builds expensive devices out of order
    Don't apply frustration for starved resources
Optimise: Turtle doesn't enumerate fully healthy links/devies on activation
Drop shield selection after construction
Fix: time limit clock doesn't reset if you restart after winning
Fix: mortar reload sfx position
Show error effect when trying to replace solid material over a device

3/4/17
Fix: Lua exception when trying to transfer resources from nil team
Fix: start-loaded not working in TDM
Memory corruption in Multiplayer
    Host thinks joined files received
    Use of a negative index when updating client database
    Lagged client messages handled by host after reconnection, ignore
Fix: Missing stats logged when joining multiplayer by invite
Fix: 'Player wants to play Map' not translated to display name
Make map inclusion case insensitive
Automatically delete maps for preview build
Added German, French, Spanish and Russian languages, Slovak partial
Fix: not awarded objective if one of the items is upgraded
Fix: GenLangs doesn't produce files with Unicode encoding

4/4/17
Fix: Russian strings not loading completely
    Lua has trouble with some characters, open file in binary mode
Word wrap objectives on mission briefing panel
Automatically select language on first execution
Show language selection screen if language not supported
Show keyboard selection screen on first execution

5/4/17
Fix: crash MusicManager::OrderPlaylist at playOrder[pos] = unorderedIndices.back()
    Handle missing data with error message
Fix: movie playback initialised more than once on resource reloading
Fix: alignment of skip text on HUD speech bubbles
Added LanguageScreen to select language and keyboard layout
Added start of MatchMaker object for background match making
Fix: crash when loading long device name in Russian language
Fix: crash while lobby alert control is not present
Add data support configuring transition to user screens

6/4/17
Text::RenderWordWrap using incorrect text scaling when outside of parent bounding box
Nest objective text in new Sprite control to facilitate word wrap
Fix: Objective text overlapping when wrapped
    decrease line spacing for Objectives style
Fix: PhysicsManager::GetNodeCreationParameters not using position snapped to ground for intersection test
Add move node (N key) to editor for making minor adjustments to node positions

7/4/17
Fix: desync when Nick joined AI vs AI on Team1 game with 3 other observers
    For Nick AI was in human assist mode
    Solution: drop the others to human assist
Fix: Replays with AI when pivot is non-zero desync
    Calculate the pivot on restoring terrain
Provide preset keyboard layout bindings
    copy preset into users folder as keys.lua
    load in console, and search for each name as loaded, with modifiers
    Key names reverted to narrow char to allow Lua lookup
    Renamed so they can be Lua variable names for localisation of descriptions
Fix: Prevent capture when at end of replay
Fix: T key not working in TDM
Fix: Don't start video recording if at the end of a replay
Fix: delay change to music to prevent exception on first replay seek

8/4/17
Fix: white rectangle appearing on objectives in first tute after cutscene
Fix: can't delete devices by context menu
Fix: ignore calls to SkipScene during cutscene transition
Fix: can still gain objective 2 in 104 by cycling fire
Fix: commander tool tips don't show in TDM
Fix: Wrapped editor tabs don't respond to clicks
Fix: Toggle fixed node function, made it editor only
Fix: floating foundations in map
Fix: Spotter unable to open door when it is repairing at first attempt
Fix: music overlapping when restarting a replay with a starting cutscene
Fix: crash when trying to hide overlays during video recording in replay
Fix: Unable to open missile doors when attempting to paint target
Fix: Remove padlock in review build using REQUIRE_STEAM

9/4/17
Translate languages to native name in options screen
Add function to look up the key for a key binding name
    E.g. {Save} becomes Ctrl + S
Add alternate keyboard layout binding mods
Extract language and keyboard names from mods folder instead of constants
All key profiles now global so bindings can be inspected at any time
GenLangs: Fall back to English if string missing on export
    Write missing strings to missing.csv
Integrate Key display string lookup table into strings state for localisation
    Load after other strings to reference the modified ones
Convert mouse speed to a slider to save space in input tab
Show keyboard selection in input screen
Roll key binding tokens through localisation table
LoadingScreen tips use SetString instead of SetText to substitute key binding

10/4/17
Added Fine style and used it to shrink key bindings to fit Russian strings
Fix: UIEditor crashing trying substitute key bindings, disable
Update Video options layout
Add button to open user files to video options tab
Fix: terrain key profile not being enabled
Fix: Made video options tips font consistent
Fix: Store from LuaState not loaded successfully if NULL
Fix: Crash in various places, cleanup correct key profile
Enabled rope in 203
Fix: StructureEditor key profile not using global
Fix: rare crash when mortars hit devices
    Node is sunk for a couple of frames while MeshProjectile is NULL
    Don't sink projectiles that are maked explode on touch
Fix: upgrade shockwave not additive

11/4/17
Fix: strings not loading on second mission after changing language
Fix: Change to OS language if it hasn't been set manually
Autowin command in unlimited_test branch for testing all dialogue
Prevent any condition script triggering if the player loses
Capitalise all native language names

12/4/17
Compile list of key names, add to string table with English descriptions
Tokenise video options tips
Tokenise key descriptions
Tokenise Any, Background, Wind Floor, etc. in editor
Tokenise Editor debug readout
Alert/join when a lobby appears with your search settings
    Create MatchMaker global when outside of Multiplayer
    Keep a list of lobbies that are current
    Present each one in turn, don't show twice
    Hide tip if it becomes invalid or times out
    Disable during tutorials, cutscenes, pause and overlay
    Connect to lobby on Yes, and allow disabling
    Lobbies seen in the server select screen are not presented

13/4/17
Fix: added ListHeading style to space out language & keyboard lists
Fix: corrected shadowing on start up language & keyboard list
Removed up/down arrows on start up language & keyboard list
Move music files into Fmod project
    Attempt to open PlayTrack calls as studio events
    Treat as a single channel, create operators (e.g. Pause) to hide difference
    Poll for ending and use new SetStreamComplete to notify scripts
Fix: far lobbies showing up in close lobby alert
    Apply distance filter continuously
Fix: disable lobby alert search while in multiplayer
Fix: set volume when track is an event
Fix: Lobby alerts crash when not logged into Steam
Fix: win points not awarded in TDM
Fix: tutorial music plays under victory in tute 1
    AdjustVolume was using invalid channelHandle to ramp volume via MusicManager::Pause

14/4/17
Fix: victory music stops when pause menu appears
    Mark events as continue on pause
    Don't pause events/streams that are just going to be resumed
Fix: Sounds and music continue when not in focus
    Update FMod studio
Fix: music doesn't resume after silence break
Fix: sound and music resume when returning to focus while paused
Fix: Menu music doesn't resume after returning from sandbox
Set default keyboard based on supported languages
Make pin buttons sticky
Fix: Sticky buttons not responding to different anchor
HUD pause button ("Menu") is responsive while paused
Fix: Campaign Previous button disabled on first page
Fix: helicarrier sound plays during loading when fight is clicked during play
Fix: hide mission briefing until next map is selected

15/4/17
Compressed chatroom client table
Moved Force start check and added late join check under client table
Fix: memory leaks in Static and StructureEditor
Allow host to prevent late entry into teams
    Add flag that host distributes: LateTeamJoin with checkbox for host
    Players part of a team at start are marked with their team
    When a player is in the chatroom and the flag is set, adjust their team options according to these
Fix: client commander check cleared when observer
Cleaned up console when client joins
Fix: compress threads not closing after battle
Fix: crash when host quits and client is connected by LAN
Fix: Setting ready status just before start causes crash of both host and client
    Host sends list of ready clients. Anyone too late misses out.
Fix: joining client hangs in loading screen if host quits at the same time
Fix: client joining during loading can still be put on Team 2
Fix: update reactor panel position before display
Fix: hide observer hud on instant replay
Fix: Restart menu option appears when host leaves during instant replay
Fix: Not updating Steam callbacks during loading

16/4/17
Fix: Briefing missing when quitting or losing a mission
Reduce in-game username size and move to right of cursor
Fix: device highlight colour incorrect in TDM
Stop showing username on device selection
Show team-mate selected device highlight on slaves and ally teams in TDM
Make selected device highlight additive
Fix: kick desynced client, others continue as normal, with global notification
Add campaign achievements for Normal and Hard
	Each campaign part
	Winning all drops in each theatre for a part
	Winning final battle
	Difficulty set at start of each submenu, defaults to normal
Fix: missiles miss in close maps

17/4/17
Fix: Commander was showing Tab highlights when active in DB
Fix: player names not appearing in replay preview for TDM games
Add word wrap to file select tips
Make AI/auto defences on by default in multiplayer
Add v-sync option
Console uses new font
Fix: commander display name not used when previewing replays
Fix: search for actual tags to avoid highlighting names in replay preview
Fix: don't show temperature gauge on all team cursors
Fix: achievements not triggering correctly
Calculate rigorous (all missions complete) inside script
Fix: space bar not working in 401 and 103
Fix: restart 401 after defeat: rapid fire still on
Fix: mouse not visible after campaign complete
Fix: remove final credits from build
Update strings
Fix: Pillars and Catacomb visible in editor
Fix: 401 stat errors on start
Reverted debug readout to fixed width font
Fix: Script Update exception when returning to motherlode