Jens Ayton
5bad08f43d
Fixed Ship.hasEquipment() compatibility method in cases where equipment is undefined.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3453 127b21dd-08f5-0310-b4b7-95ae10353056
2010-06-03 20:58:17 +00:00
Jens Ayton
badbc4b8c5
Restored old Ship.hasEquipment() behaviour, added deprecation warning.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3408 127b21dd-08f5-0310-b4b7-95ae10353056
2010-05-25 19:35:53 +00:00
Jens Ayton
766259e7bf
Planet textures can again be changed via JavaScript.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3319 127b21dd-08f5-0310-b4b7-95ae10353056
2010-05-11 20:41:14 +00:00
Eric Walch
f4e872077a
- Increased the strength of the Constrictor a bit when fighting against more experienced players.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3210 127b21dd-08f5-0310-b4b7-95ae10353056
2010-04-24 08:32:23 +00:00
Jens Ayton
a79eae0acc
Better error logging when loading a saved game fails. Fixed up some script comments.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3080 127b21dd-08f5-0310-b4b7-95ae10353056
2010-03-26 23:07:23 +00:00
Eric Walch
955390d1c4
- Moved both fine messages to the arrival report screen.
...
- Removed a backdoor to do contract runs in a strict game.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3039 127b21dd-08f5-0310-b4b7-95ae10353056
2010-02-24 20:28:47 +00:00
Eric Walch
41d0d79ad7
- SystemInfo.systemsInRange now does not find the current system.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@3000 127b21dd-08f5-0310-b4b7-95ae10353056
2010-01-30 17:26:51 +00:00
Marc
bb5e6e963d
- fix: oolite.setScreenBackground() & oolite.setScreenOverlay() from rev2921 ( the latter was called .setScreenForeground() before ) now change background & overlay for as long as the current GUI screen is still active, as originally intended.
...
- change: mission.runScreen now accepts the 'overlay' parameter (was 'foreground', which isn't recognised anymore).
- fix: report_screens now call the guiScreenChanged() event too.
- new: added the following keys to screenbackgrounds.plist: 'mission_overlay', 'overlay', 'docked_overlay', 'paused_overlay', 'paused_docked_overlay'. If viewing a gui screen when pause was started, and paused_overlay/paused_docked_overlay produce a texture, the overlay texture is displayed instead of the 'Paused - press P' message.
- fix: save game screen now behaves more like other screens - it responds to the various F keys (while still allowing numbers to be typed in), and the [back] & [more] onscreen buttons work when clicked.
- bouns fixes: random bugfix to a deprecated function redirect, and the 'overwrite game?' mini screen now responds to the translated y/n keys instead of hardcoded ascii values.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2928 127b21dd-08f5-0310-b4b7-95ae10353056
2010-01-04 06:22:35 +00:00
Marc
472b08f9af
- fix: no more mission.runScreen flight related crashes.
...
- more js missions cleanup.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2783 127b21dd-08f5-0310-b4b7-95ae10353056
2009-11-26 02:32:12 +00:00
Marc
bf23119d18
- mission.setInstructionsKey fix (the global prefix implementation would not be able to tell which oxp it was called from)
...
- yet another windows DEP fix. There's something inside OOJSScript that windows doesn't like.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2770 127b21dd-08f5-0310-b4b7-95ae10353056
2009-11-20 15:27:11 +00:00
Marc
3a92c0f7d1
- minor tweaks to missions, reworded one nova screen.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2762 127b21dd-08f5-0310-b4b7-95ae10353056
2009-11-19 02:31:04 +00:00
Marc
116d83f955
missionScreen RFC part III
...
* yet more RFC bugfixes, there were quite a few not-quite-right bits, I _think_ I got all of them now...
* added titleKey as a mission.runScreen parameter, for use with missiontext.plist
* updated all internal missions to use the new mission API, some mission keys normalisation.
* fully tested & fixed both nova & trumbles missions.
* proper fix: no save when the sun is going nova!
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2759 127b21dd-08f5-0310-b4b7-95ae10353056
2009-11-18 21:58:32 +00:00
Marc
f7affbc01a
MissionScreen RFC part II:
...
* missionScreenOpportunity now fires up after loading a savegame & at startup, as well as after docking.
* fixed a mission callback related crash.
* fixed clash with fines and mission screens.
* name change for new mission.runScreen parameter shipModel: is now showModel.
* the foreground & background images now display correctly in relation to the spinning demo ship.
- code cleanup
- added missing keys to the shipdata entry schema
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2758 127b21dd-08f5-0310-b4b7-95ae10353056
2009-11-17 18:27:11 +00:00
Marc
7bb627586f
* New mission.setInstructions to go with mission.setInstructionsKey, analogous to the mission.addText / mission.addTextKey pair.
...
* mission RFC part I. Initial implementation of the changes proposed in the forum. Will need tweaking.
* added new parameters to mission: title & foregroundImage (identical to backgroundImage atm)
* assorted code tidying up.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2750 127b21dd-08f5-0310-b4b7-95ae10353056
2009-11-15 00:24:23 +00:00
Marc
03a1728895
- Applied pv4's patch to trunk, with modifications.
...
* ship.target = null now works as expected.
* adding trumbles to a ship has now got variable chance of working, depending on how many trumbles are already on board. Always works with 0 or very few trumbles.
- more cleanup: removed a windows compile warning, added a possible freeBSD bugfix, updated a js comment & autoindented Universe.m
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2720 127b21dd-08f5-0310-b4b7-95ae10353056
2009-11-04 20:57:11 +00:00
Marc
228ae5a9f5
- change: hyperspace tunnel colour now scriptable from inside planetinfo.plist
...
- comment cleanup inside constrictor hunt.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2681 127b21dd-08f5-0310-b4b7-95ae10353056
2009-10-18 19:30:31 +00:00
Jens Ayton
bc3a113b0f
Incomplete support for general polygons in missile icons. (In case of splodey, setting the OLD_ICONS macro in HeadUpDisplay.m to 1 will revert to the old drawing code.)
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2661 127b21dd-08f5-0310-b4b7-95ae10353056
2009-10-10 12:23:24 +00:00
Marc
47f9f2c920
* corrected manifest miscount when ship in flight.
...
* last change to player.ship.manifest: manifest.food & similar are now read/write manifest quantities. Internally all commodities are now going to be referenced by the canonical identifiers, commodities.plist still overrides the displayName - the .manifest.list array is unchanged, and still read-only.
* renamed 2 ship properties for consistency: ship.availableCargoSpace & ship.cargoCapacity now become ship.cargoSpaceAvailable & ship.cargoSpaceCapacity.
- more code tidying.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2637 127b21dd-08f5-0310-b4b7-95ae10353056
2009-10-06 09:09:08 +00:00
Marc
3cb2045315
- many nova bugfixes, should now be more difficult to break the nova mission. Sun flares up at random intervals inside the nova system.
...
More testing required.
- systemInfo float values are now properly treated as numbers.
- minor code cleanup.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2491 127b21dd-08f5-0310-b4b7-95ae10353056
2009-09-13 01:25:18 +00:00
Eric Walch
fee7ea9350
Corrected last nova script change. Stopped NPC ships from consuming fuel on deceleration. Increased NPC deceleration in speed range above max_speed.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2478 127b21dd-08f5-0310-b4b7-95ae10353056
2009-09-11 19:21:46 +00:00
Nikos Barkas
72db4ee904
Fixed nova mission.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2461 127b21dd-08f5-0310-b4b7-95ae10353056
2009-09-10 15:49:51 +00:00
Jens Ayton
0586f0a832
JS SystemInfo changes: added read-only properties coordinates, galaxyID and system, method distanceToSystem(), and static method filteredSystems(). Undefined SystemInfo properties are now undefined rather than null. Also added prefix helper function to get SystemInfo for all systems in a given range (default: 7 ly).
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2403 127b21dd-08f5-0310-b4b7-95ae10353056
2009-09-05 18:19:23 +00:00
Marc
da8da6183d
bugfix for bug #15454 - legacy scripts inside CARGO_SCRIPTED_ITEMs now work again. Tested with ore processor 1.52.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2375 127b21dd-08f5-0310-b4b7-95ae10353056
2009-09-03 23:27:18 +00:00
Jens Ayton
3c10a9b2be
Bumped version number. Changed Mac system requirement to 10.4, and cleaned up target configuration in preparation for 64-bit support.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2335 127b21dd-08f5-0310-b4b7-95ae10353056
2009-08-30 14:49:03 +00:00
Eric Walch
b585e1d0ed
Added a JS method for player: addMessageToArrivalReport(message). Added a eventhandler that fires after the last arrivalReportScreen is shown. Changed the internal missions so they no longer overwrite this report.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2276 127b21dd-08f5-0310-b4b7-95ae10353056
2009-08-06 20:24:25 +00:00
Eric Walch
47cbf22071
patrol-ships no longer patrol the mainStation area but the area around the launching station. Re-added Xeer as hard coded text at two places were it refers to Xeer from G2.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2270 127b21dd-08f5-0310-b4b7-95ae10353056
2009-07-31 09:34:51 +00:00
Nikos Barkas
9309befa43
Commiting Frame's implementation of player.ship.galaxyCoordinates and player.ship.cursorCoordinates.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2223 127b21dd-08f5-0310-b4b7-95ae10353056
2009-07-03 17:50:53 +00:00
Jens Ayton
1feeb63fd8
Ran all game scripts through JSLint ( http://www.jslint.com/ ), but not console script because it's full of JavaScript 2-isms. The JavaScript 2 that isn't going to happen. Yay.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2182 127b21dd-08f5-0310-b4b7-95ae10353056
2009-05-22 22:45:02 +00:00
Nikos Barkas
a8c42528b2
Fixed a capitalization error in previous commit.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2137 127b21dd-08f5-0310-b4b7-95ae10353056
2009-04-21 06:59:56 +00:00
Nikos Barkas
e1cf86812a
Commited Eric's updated nova mission script and added the nova_coward mission text.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2136 127b21dd-08f5-0310-b4b7-95ae10353056
2009-04-21 06:51:50 +00:00
Nikos Barkas
fc462e2e9f
Commited a preliminary version of Eric's update to the Nova mission. The witchspace buoy now sends distress call messages when in the vicinity of the player, if current system is going nova.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2134 127b21dd-08f5-0310-b4b7-95ae10353056
2009-04-20 22:35:54 +00:00
Nikos Barkas
0a161f1c4d
Fixed a 'control reaching end of non-void function' warning. Updated the nova mission script to use the new sun.hasGoneNova method.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2057 127b21dd-08f5-0310-b4b7-95ae10353056
2009-02-12 17:39:42 +00:00
Jens Ayton
8f841d5e62
Deprecated system.goingNova and system.goneNova in favour of existing Sun equivalents.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2055 127b21dd-08f5-0310-b4b7-95ae10353056
2009-02-11 19:36:20 +00:00
Jens Ayton
ca68c038a4
JavaScript tweaks: deprecated entity IDs; made Entity.position and Entity.orienation read/write since their read-onliness wasn't really accomplishing anything; added toSource() method to Vector and Quaternion; Vector() and Quaternion() constructors can now be called without the new keyword, allowing the use of call() and apply().
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2038 127b21dd-08f5-0310-b4b7-95ae10353056
2009-02-07 12:53:09 +00:00
Jens Ayton
dbde672d01
"Small" change to group and escort handling, now with explicit group objects. I really must stop making "small" changes. (N.b.: JavaScript ShipGroup currently fails to work in interesting ways.)
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@2028 127b21dd-08f5-0310-b4b7-95ae10353056
2009-02-06 16:13:36 +00:00
Nikos Barkas
c910d93bc9
Fixed a syntax error in the Cloaking Device mission script.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1952 127b21dd-08f5-0310-b4b7-95ae10353056
2009-01-01 17:20:54 +00:00
Jens Ayton
c3627ea200
Changed cloaking device pod script to use recommended way of testing for player.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1933 127b21dd-08f5-0310-b4b7-95ae10353056
2008-12-29 16:09:10 +00:00
Nikos Barkas
8882503eab
Fixed the Cloaking Device mission.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1930 127b21dd-08f5-0310-b4b7-95ae10353056
2008-12-29 07:02:16 +00:00
Jens Ayton
dd1ac56784
Simpler, more efficient equipment shopping code using OOEquipmentItem, with side effect that available_for_all now parses its value correctly.. Corrected use of fuzzyBooleanForKey: in r1855.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1856 127b21dd-08f5-0310-b4b7-95ae10353056
2008-11-15 01:10:01 +00:00
Jens Ayton
19cbb04377
* Fixes to ship registry:
...
- is_template is no longer inherited, causing all derived ships to be
silently deleted.
- Ships whose model canât be found are now reported and deleted from the
registry.
- Ships used as subentities no longer require roles.
- Ships with invalid subentity definitions (not exactly eight tokens) are
now reported and deleted from the registry.
- New is_external_dependency key suppresses errors for missing like_ship and
subentity references. (A ship with is_external_dependency will still be
deleted from the registry if it canât be properly resolved, there just
won't be a message about it.)
* Added missing compatibility method player.spawnOne().
* Default galactic_hyperspace_behaviour respelled to BEHAVIOUR_STANDARD.
* Corrected warning text in setGalacticHyperspaceBehaviourTo:.
* Added nil check in collision detection.
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1853 127b21dd-08f5-0310-b4b7-95ae10353056
2008-11-13 09:47:15 +00:00
Nikos Barkas
bfde71ea55
Fixed thargoid curses comms messages appearing out of nowhere (thanks Eric).
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1848 127b21dd-08f5-0310-b4b7-95ae10353056
2008-11-09 10:05:53 +00:00
Jens Ayton
bbd9c0ef23
Ye bigge version number bumpe. Also removed deprecated JS stuff that's been around for two versions, and added :logOn and :logOff console macros.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1828 127b21dd-08f5-0310-b4b7-95ae10353056
2008-11-03 17:55:32 +00:00
Jens Ayton
0df8ba731c
Copy & paste error.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1801 127b21dd-08f5-0310-b4b7-95ae10353056
2008-10-17 23:10:30 +00:00
Jens Ayton
53e8c39d94
Eating own dogfood.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1800 127b21dd-08f5-0310-b4b7-95ae10353056
2008-10-17 23:09:12 +00:00
Jens Ayton
3f07f2230c
Fiddling with script converter, and bunch of scripting changes as a result: added player.rank, player.legalStatus, system.countShipsWithPrimaryRole(), system.pseudoRandomNumber, system.pseudoRandom100, system.pseudoRandom256; renamed Ship.shipDescription to Ship.name and Ship.shipDisplayName to Ship.displayName. Also, JS console script now strips out trailing line breaks.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1755 127b21dd-08f5-0310-b4b7-95ae10353056
2008-09-01 18:21:21 +00:00
Jens Ayton
14b36f0f64
Deprecated messy ability to use a list of number arguments as a vector/quaternion literal, in favour of array literals.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1728 127b21dd-08f5-0310-b4b7-95ae10353056
2008-08-07 16:12:51 +00:00
Jens Ayton
e10591c31a
Renamed JS Vector to Vector3D to avoid namespace issues in JavaScript 2.0. Added bounty property back to JS player. Oversight of player vs. player.ship in built-in scripts.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1727 127b21dd-08f5-0310-b4b7-95ae10353056
2008-08-07 08:06:08 +00:00
cmdrjames
89d837daaf
reduce deprecation warnings by changing player.docked to player.ship.docked
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1717 127b21dd-08f5-0310-b4b7-95ae10353056
2008-08-02 20:16:22 +00:00
Jens Ayton
87d724fc8a
Fix for bug in prefix script adding player compatibility aliases to all objects.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1716 127b21dd-08f5-0310-b4b7-95ae10353056
2008-08-02 19:19:01 +00:00
Jens Ayton
3315272c00
Split JS Player object into Player and PlayerShip. Made curved sides of arc-detail smooth.
...
git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@1710 127b21dd-08f5-0310-b4b7-95ae10353056
2008-07-28 17:34:37 +00:00