202 Commits

Author SHA1 Message Date
Eric Walch
d54f6ac448 Changed trumble mission to only offer at the main station as always was intended but was already wrong implemented in the legacy version.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4346 127b21dd-08f5-0310-b4b7-95ae10353056
2011-02-13 13:10:49 +00:00
Jens Ayton
9546b7b11b Removed obsolete ES5 compatibility functions.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4339 127b21dd-08f5-0310-b4b7-95ae10353056
2011-02-12 19:31:27 +00:00
Jens Ayton
27bac3ca61 JS audit: OOJSShip. Moved addPassenger() and awardContract() to PlayerShip where they belong. Also made them not print warnings when conditions aren't fulfilled, because returning an error flag _and_ logging a warning is an unhelpful combination.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4292 127b21dd-08f5-0310-b4b7-95ae10353056
2011-02-11 01:13:21 +00:00
Jens Ayton
d1db0f0f64 JS formatInteger() now punts on *very* large values correctly.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4273 127b21dd-08f5-0310-b4b7-95ae10353056
2011-02-08 22:45:30 +00:00
Jens Ayton
267ffc8697 JS formatInteger() now punts to default JS behaviour instead of returning an error string for large values.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4272 127b21dd-08f5-0310-b4b7-95ae10353056
2011-02-08 22:41:28 +00:00
Jens Ayton
b346c2d28a [Mac] Dock tile plug-in now follows screen shots directory around.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4255 127b21dd-08f5-0310-b4b7-95ae10353056
2011-02-07 15:25:51 +00:00
Jens Ayton
150dd2b9a5 JavaScript console and global object are now rebuilt when resetting the game, to make it impossible to smuggle information across sections. There seem to be minor JS-related leaks as a result. Be on the lookout for exciting new crashers! As an arguably unfortunate side-effect, the console currently doesn't work when resetting into strict mode.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4210 127b21dd-08f5-0310-b4b7-95ae10353056
2011-02-01 21:12:38 +00:00
Jens Ayton
11df41547a [Mac] Hopefully fixed horrible-loud-noise bug (bug #17214), and definitely fixed quieter popping noises at the end of sounds.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4187 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-29 21:40:03 +00:00
Jens Ayton
bce687613f Disabled TAF in deployment builds (and also shader debug hotkey, and extra info on FPSometer).
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4184 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-29 20:45:17 +00:00
Jens Ayton
b050faa3b2 Experimental support for letting station scripts determine whether a ship is physically able to dock. Disabled because of collision detection problems with inactive docking ports.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4165 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-27 19:50:13 +00:00
Jens Ayton
399e369606 Fixed default escort function (first four ships no longer try to fly inside mother).
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4119 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-22 20:38:44 +00:00
Jens Ayton
f99dd38018 Escort positions are now cached. Fixed copying of scripts under OS X.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4116 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-22 13:52:38 +00:00
Jens Ayton
c2059960be coordinatesForEscortPosition can now actually be overridden. Default implementation avoids bit-twiddling hacks.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4114 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-21 20:45:35 +00:00
Jens Ayton
5cef2b972d Why can't you just read my mind, svn? (Missing file)
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4113 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-21 09:04:17 +00:00
Jens Ayton
c8d6b1cf44 Simplified default coordinatesForEscortPosition().
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4106 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-20 20:23:56 +00:00
Jens Ayton
214d87e63c Escort formations can now be defined in JavaScript by implementing coordinatesForEscortPosition().
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4105 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-20 19:52:01 +00:00
Jens Ayton
bd9000ee12 Console input is now reported as <console input> instead of oolite-debug-console.js:779 in stack dumps, profiles and traces.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4093 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-18 16:30:54 +00:00
Jens Ayton
3e8696a606 Redefined global.worldScriptNames in JavaScript.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4092 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-18 15:30:39 +00:00
Jens Ayton
9a35273d39 [Mac] Build fix for JS profiling.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4085 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-17 07:47:37 +00:00
Jens Ayton
f48c751092 Fixed timer sorting.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4084 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-16 22:47:26 +00:00
Jens Ayton
08519fb6be JS special.jsWarning() now skips one stack frame as intended.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4077 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-16 14:04:17 +00:00
Jens Ayton
ded012d0e5 Put all of prefix script in a nice, sanitary closure.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4053 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-12 21:36:10 +00:00
Jens Ayton
ccd30cb8a9 Added compatibility accessors and warnings for misuse of JS System and Player.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4052 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-12 20:52:05 +00:00
Jens Ayton
48abeeedef Renamed Ship.prototype.roleProbabilities to Ship.prototype.roleWeights (with compatibility accessor).
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4050 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-12 14:29:55 +00:00
Jens Ayton
96a358bae1 Removed unused compatibility-accessor helpers in prefix script that would no longer work anyway. Ignore undefineds in debug console pretty-printing. Treat PlayerShip.prototype as stale entity ref in PlayerShipGetProperty().
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4044 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-11 22:14:03 +00:00
Jens Ayton
16a0e45f45 Handle method setup properly in prefix script, now that this works thanks to constructor cleanup. Made SoundSource.prototype.playSound() a JS wrapper.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4023 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-06 19:09:01 +00:00
Jens Ayton
3b16dd9438 Rearranged prefix script to work in oldjs builds.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4017 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-06 16:28:13 +00:00
Jens Ayton
926b2f81ea Made use of ECMAScript 5 meta-stuff; methods defined in prefix header are now non-enumerable and non-writeable just like native ones.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4016 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-06 12:05:16 +00:00
Jens Ayton
6a6ab8af5a Backported Array.isArray() for oldjs builds.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3986 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-04 12:51:33 +00:00
Jens Ayton
4fac70192f Cleaned up oolite-default-ship-script.js for strict mode.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3963 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-03 00:27:00 +00:00
Jens Ayton
dc07d56bf6 Disabled strict mode for oolite-default-ship-script.js for now.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3962 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-03 00:16:23 +00:00
Jens Ayton
d1ae8972e5 Updating of strictly pointless copyright year thingies, yay!
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3960 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-02 20:27:12 +00:00
Jens Ayton
c34f7e03f1 Enabled ECMAScript 5 strict mode in all built-in scripts.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3958 127b21dd-08f5-0310-b4b7-95ae10353056
2011-01-02 17:54:54 +00:00
Eric Walch
b8359a110b - Added a JS script to pilots. On unloading at a station, the event "unloadCharacter()" is send to the pilot-script.
- Characters in character.plist now always do a basic setup. That way there is always a valid pilot when not using all character keys. This allows for partial randomisation of pilots for the unused keys.
- Added a JS script for the constrictor-pilot.
- Added default pilots to be used by oxps.

git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3841 127b21dd-08f5-0310-b4b7-95ae10353056
2010-11-30 20:11:45 +00:00
Eric Walch
7b0c256e99 - launchPolice and launchDefenseShip now add the ships in front of the launchQueue.
- escorts can no longer, wrongly, escorting ships that already entered witchspace.

git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3760 127b21dd-08f5-0310-b4b7-95ae10353056
2010-09-24 11:12:36 +00:00
Eric Walch
3c099b9a59 - Added AI command: thargonCheckMother for a more efficient thargon handling.
- Improved the thargletAI slightly.
- Changed policeInterceptAI so that launching ships without target immediately clear the launch area.
- Moved the constrictor script from shipData to the worldScript. (to prevent problems with bad oxp copies of the constrictor)

git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3752 127b21dd-08f5-0310-b4b7-95ae10353056
2010-09-16 20:13:01 +00:00
Jens Ayton
d16dc20f0b All scripts now use underscore prefix for custom properties. Also general cleanup and linting.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3732 127b21dd-08f5-0310-b4b7-95ae10353056
2010-07-30 21:54:50 +00:00
Jens Ayton
723846018e Exposed global object as property of itself, instead of fiddling around with silly functions where it's needed.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3730 127b21dd-08f5-0310-b4b7-95ae10353056
2010-07-30 20:00:46 +00:00
Marc
cabe9792c7 Undocking in interstellar space is now possible:
- to enable the new functionality, added the interstellar_undocking key to station/carriers. If "interstellar_undocking" = YES; , the station will remain where it is instead of moving to the nearest system, as it's always been the case up to now.
- quick fix to the nova mission to take this new possibility into account.

git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3725 127b21dd-08f5-0310-b4b7-95ae10353056
2010-07-28 12:01:39 +00:00
Jens Ayton
fc0d9a962d removeCargo now recalculates available cargo space. Specifying an empty string for a ship's script now acts as though no script was specified.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3723 127b21dd-08f5-0310-b4b7-95ae10353056
2010-07-27 20:06:55 +00:00
Jens Ayton
07b8dfa646 Trumble random reset fix as per http://aegidian.org/bb/viewtopic.php?p=115179#115179
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3722 127b21dd-08f5-0310-b4b7-95ae10353056
2010-07-27 18:34:08 +00:00
Jens Ayton
e94eddecea Accumulated minor cleanup.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3720 127b21dd-08f5-0310-b4b7-95ae10353056
2010-07-26 19:37:31 +00:00
Marc
a94d4b5bac - station_roll can now be used inside individual stations' shipdata.plist. If not found, use the systemwide override inside planetinfo.plist if defined, or standard station roll, as before. (trunk)
- more copyright fun: replaced instances of em dash with '-' to help syncronise updates better, added copyright info to the profiling stopwatch.

git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3656 127b21dd-08f5-0310-b4b7-95ae10353056
2010-07-04 22:32:30 +00:00
Marc
65dff53391 - added one missing copyright info, and updated copyright notices in maintenance.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3655 127b21dd-08f5-0310-b4b7-95ae10353056
2010-07-04 18:39:27 +00:00
Marc
2448a4f38f - OK, now all copyright notices inside the code should be up to date!
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3654 127b21dd-08f5-0310-b4b7-95ae10353056
2010-07-03 18:45:37 +00:00
Jens Ayton
8e9e906b76 Backported generalization of SystemInfo.systemsInRange() (oops - intended to do that for 1.74.1). Don't use multi-texture materials on hardware which doesn't support it.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3639 127b21dd-08f5-0310-b4b7-95ae10353056
2010-06-28 18:15:31 +00:00
Jens Ayton
637b7042ef Updated trunk changelog.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3630 127b21dd-08f5-0310-b4b7-95ae10353056
2010-06-27 17:38:31 +00:00
Jens Ayton
cf36d4f7fa Added JS system.scrambledPseudoRandomNumber().
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3614 127b21dd-08f5-0310-b4b7-95ae10353056
2010-06-26 15:46:26 +00:00
Eric Walch
749ea7de08 Make sure the mission version of the constrictor always has a bounty, even when a constrictor version from a third party is chosen.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3571 127b21dd-08f5-0310-b4b7-95ae10353056
2010-06-19 13:37:34 +00:00
Jens Ayton
b5c5b5547d Tidied up prefix script a bit. Use longer timeout when loading scripts (accidentally omitted from r3550. Sorted JS Ship methods.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3566 127b21dd-08f5-0310-b4b7-95ae10353056
2010-06-19 09:42:04 +00:00