Yes, you can use local vars, functions, etc. All JavaScript language features are available.
Local vars won't hold their value between two different invocations of the script.
Join us at the Oolite Anniversary Party -- London, 7th July 2024, 1pm
More details in this thread.
More details in this thread.
Search found 364 matches
- Sat Feb 03, 2007 1:43 am
- Forum: Suggestion Box
- Topic: Anyone want to write scripts using JavaScript?
- Replies: 37
- Views: 24188
- Fri Feb 02, 2007 9:33 am
- Forum: Oolite-PC
- Topic: Textured planets experiment - discussion here
- Replies: 85
- Views: 63231
We can unload the textures and I did have code to try and do that for the planet textures, but my lack of Obj-C knowledge bit me and I couldn't make a simple LRU cache work! Pretty embarrasing. If we pre-generate all textures for all planets we'll end up with 2048 images on disk which will take a lo...
- Fri Feb 02, 2007 5:23 am
- Forum: Suggestion Box
- Topic: Anyone want to write scripts using JavaScript?
- Replies: 37
- Views: 24188
- Fri Feb 02, 2007 3:32 am
- Forum: Discussion
- Topic: What is happening on the PC?
- Replies: 15
- Views: 8630
I've transferred the equipment work to the javascript branch, because it could turn into a huge job and I don't want to wreck the trunk. I have managed to colour-code each item on the status screen now with orange if it is up to 75% damaged, and red if it is worse than that. Same goes for the equip ...
- Thu Feb 01, 2007 11:37 pm
- Forum: Oolite-PC
- Topic: Textured planets experiment - discussion here
- Replies: 85
- Views: 63231
- Thu Feb 01, 2007 11:33 pm
- Forum: Discussion
- Topic: Detailed Textures*
- Replies: 183
- Views: 77193
- Thu Feb 01, 2007 11:28 am
- Forum: Discussion
- Topic: What is happening on the PC?
- Replies: 15
- Views: 8630
- Thu Feb 01, 2007 3:05 am
- Forum: Discussion
- Topic: What is happening on the PC?
- Replies: 15
- Views: 8630
*And to be able to have the player's ship stored while he flies a borrowed ship for racing or military missions. *And to check and set variables for the state of repair for the hull and installed equipment. While looking at the first of these (for the capture ships feature I was doing) I decided to...
- Tue Jan 30, 2007 11:07 am
- Forum: Suggestion Box
- Topic: Wishes, pleas, suggestions and demands!
- Replies: 50
- Views: 28412
Giles posted the wings files for the basic set of ships at http://capnhack.com/hosting/oolite/Oolite/OoSat.html.
- Mon Jan 29, 2007 3:51 am
- Forum: Oolite-PC
- Topic: Textured planets experiment - discussion here
- Replies: 85
- Views: 63231
Various people have requested texures for the suns. I am playing around with this, on and off. Here is a sample rendering of a sun texture . There is no atmosphere and no sunspots yet. As LB hinted near the beginning of the thread they could be done similarly to how the clouds are done. Nor is the s...
- Sun Jan 28, 2007 9:58 pm
- Forum: Discussion
- Topic: Lights and reflections?
- Replies: 7
- Views: 2599
- Sun Jan 28, 2007 10:24 am
- Forum: Expansion Pack
- Topic: Tescoo Bulk Carrier
- Replies: 37
- Views: 22861
Try the switchLightsOn AI command. See http://wiki.alioth.net/index.php/OXP_howto_AI. If you've defined the lights the same way as on the vipers it will probably work.
- Sat Jan 27, 2007 10:19 pm
- Forum: Discussion
- Topic: Lights and reflections?
- Replies: 7
- Views: 2599
Giles and Ahruman had a few conversations in the theads about this that went over everyone else's heads. I think the shader work was meant to do some of this stuff. But shaders can only be guaranteed on the Mac - for instance I have no hardware capable of running Giles shader code. There might be ot...
- Sat Jan 27, 2007 10:45 am
- Forum: Suggestion Box
- Topic: Salvaging ships
- Replies: 19
- Views: 15006
- Sat Jan 27, 2007 1:35 am
- Forum: Expansion Pack
- Topic: Enterprise-D ship- Coming to life in Oolite!
- Replies: 38
- Views: 28381