Implements global tech modification function. Fixes #1358, refs #1520.

Applies tech modifications to template data returned by GuiInterface.
Extends engine to load arbitrary global scripts, separates this from RNG
replacement. Refs #1193.
Loads global scripts for most script contexts for consistency.
Adds simulation tests for global scripts.

This was SVN commit r12056.
This commit is contained in:
historic_bruno
2012-07-03 02:16:45 +00:00
parent db943341a8
commit 99d04e93bb
14 changed files with 195 additions and 111 deletions
@@ -116,7 +116,7 @@ public:
TS_ASSERT_DIFFERS(d1, d2);
boost::rand48 rng;
script.ReplaceNondeterministicFunctions(rng);
script.ReplaceNondeterministicRNG(rng);
rng.seed((u64)0);
TS_ASSERT(script.Eval("Math.random()", d1));
TS_ASSERT(script.Eval("Math.random()", d2));