Only Java-Script?

General discussion for players of Oolite.

Moderators: another_commander, winston

Post Reply
User avatar
Svengali
---- E L I T E ----
---- E L I T E ----
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Only Java-Script?

Post by Svengali »

Should Oolite only support Java-Script in future releases? Some thoughts about that.

With JS we'll get a lot of new stuff to play with and if it's the only language any new scripter can learn it within 3-4 month. The development for Oolite will be a lot easier to handle and even the translation of 'old' scripts shouldn't be to difficult. Currently I'm learning JS (there are a lot of tutorials online).

What do you think?

User avatar
LittleBear
---- E L I T E ----
---- E L I T E ----
Posts: 2759
Joined: Tue Apr 04, 2006 7:02 pm
Location: Teaned, Galaxy 3. Ship: Boa Class Frigate: Transfigured Night. Rated: Dangerous.

Post by LittleBear »

No. A lot of contributors are no longer active, so woudn't be able to translate their script. And it would be a major undertaking to translate a big script like Assassins (5,000 lines) or Random Hits (15,000 lines) and then playtest it. Please don't make me do it! :shock:
My OXPS : The Assassins Guild, Asteroid Storm, The Bank of the Black Monks, Random Hits and Renegade Pirates can be downloaded from the Elite Wiki here.

User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Post by Eric Walch »

Svengali wrote:Should Oolite only support Java-Script in future releases? Some thoughts about that.
Not do-able as you will loose a lot of existing OXP's. And there are a lot of OXP's that just have a few lines to add special ships. Those will not take much execution time and are for starters much easier to write than JS. And translating existing large scripts is also to much work as LB says. (UPS currently has about 2800 lines)

I think it is more important to write a good document about the differences between the two script systems. When the difference is clear, a programmer that wants to write a larger script will more likely choose for JS. But I agree that new functions should not be implemented with the old scripting system to motivate programmer to use the new scripting system for new oxp's.

But with the old scripting system you can also improve the execution-time of a lot of oxp's by not putting the majority of conditions in the main level. One long oxp alone will not take much time, but with installing of more and more OXP's time becomes an issue.

User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Post by JensAyton »

The plan, such as it is, is to maintain support for the old scripting system but not add new features, and discourage its use once the mythical next stable release comes out. In an ideal universe, old-style scripts would be translated to JavaScript at load time, but the efficiency problem caused by the “tickle event” approach would still be there for most cases.

User avatar
Svengali
---- E L I T E ----
---- E L I T E ----
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Post by Svengali »

Ahruman wrote:
The plan, such as it is, is to maintain support for the old scripting system but not add new features, and discourage its use once the mythical next stable release comes out.
Thanks Ahruman, that was the question behind this thread.

Eric wrote:
But I agree that new functions should not be implemented with the old scripting system to motivate programmer to use the new scripting system for new oxp's.
Yupp. Second that.

Post Reply