Fix the hero flickering overlay after healing. Fixes #2666. Patch by Adrian

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15510 3db68df2-c116-0410-a063-a993310a9797
Fix OOS problems caused by an unwanted modification of the simulation state by the GUI.

Refs #1257

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15511 3db68df2-c116-0410-a063-a993310a9797
Fix previous commit, refs #1257

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15512 3db68df2-c116-0410-a063-a993310a9797
Add a new tool to make some quick template analysis to try and detect imbalances or see if our balancing works. WIP.

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15513 3db68df2-c116-0410-a063-a993310a9797
Small cleanup, including a correction in the templates documentation, and the removal of residues from the culling changes.

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15514 3db68df2-c116-0410-a063-a993310a9797
Update my "Template Analyzer" script to have output about civ too. Try to guess if they are balanced against each other.

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15515 3db68df2-c116-0410-a063-a993310a9797
Changes our JSNative functions to use JS::CallReceiver/JS::CallArgs.

This is the new way for working with arguments in JSNative functions. JS_THIS_VALUE, JS_ARGV, JS_SET_RVAL and direct access to vp or argc are deprecated and will probably be removed in future versions of SpiderMonkey.
CallArgs also takes care of proper rooting and you can get the values as Handles or MutableHandles. The interface changes a little bit for ESR 31, but commiting this now still makes it easier and the changes shout be straigtforward (search and replace more or less). 

Refs #2462
Refs #2415


git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15516 3db68df2-c116-0410-a063-a993310a9797
Changes FromJSVal to take a JS::HandleValue instead of JS::Value.

JS::HandleValue is basically a wrapper around a JS::Value that is safe for exact stack rooting and moving GC.
I've tried to keep this changeset rather small and isolated and therefore create additional JS::Rooted<T> values at some places where the function should eventually directly take a JS::Handle<T>.
The functions "CallFunction" and "CallFunctionVoid" put their arguments inside a JS::AutoValueVector because this will be passed directly to "CallFunction_" with ESR31.

Refs #2462
Refs #2415


git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15517 3db68df2-c116-0410-a063-a993310a9797
Forgot to use excnObj in r15517. Also roots an additional jsval.


git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15518 3db68df2-c116-0410-a063-a993310a9797
Move some trees to accessible locations. Issue found by willsmith182.

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15519 3db68df2-c116-0410-a063-a993310a9797
Fix re-garrisoning on visible garrison points after killing the units on that spot. Issue found by Stan.

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15520 3db68df2-c116-0410-a063-a993310a9797
Re-allow placing skirmish entities in Atlas. Refs #1696

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15521 3db68df2-c116-0410-a063-a993310a9797
Update of the template analyzer tool with more parameters and probably a more accurate representation of civs (with the right settings).

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15522 3db68df2-c116-0410-a063-a993310a9797
Fix how the template analyzer scripts takes walkspeed into account to some extent for ranged units, add a new script to create a RM to check balance using triggers, and add a readme file to try and explain the outputs and parameters better.

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15523 3db68df2-c116-0410-a063-a993310a9797
Makes custom JS objects compatible with SpiderMonkey ESR31.

In v24 you called JS_InitClass and passed in a definition of JSNative functions. Later you could call JS_NewObject with this class and the object would get a prototype with the specified JSNative functions.
In ESR31 you now have to explicitly store the prototype object returned by JS_InitClass and pass it as prototype argument to JS_NewObject to achieve the same.
This change modifies our existing ScriptInterface implementation for custom object types a bit and uses it at places where the JSAPI was used directly before.

Refs #2462


git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15524 3db68df2-c116-0410-a063-a993310a9797
Fixes tests.
Changes direct access of EndGameManager.gameType to getter function, by convention

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15525 3db68df2-c116-0410-a063-a993310a9797
Fixes MSVC warning C4189: 'componentManager' : local variable is initialized but not referenced (Script_RegisterComponentType_Common is a static member function, so an instance of CComponentManager isn't needed)

git-svn-id: http://svn.wildfiregames.com/public/ps/trunk@15526 3db68df2-c116-0410-a063-a993310a9797
Merge 'remotes/trunk'