Okay, I'm totally confused, and I can't make heads or tails of the wiki on this matter. How exactly does one build a mission OXP? I want to write one for the Wyvern OXP I'm working on, but I don't know how to get started.
I kinda need a quick step-by-step (tho a link would help, too). Just note, the wiki guide on how to write OXPs is not helping me.
How to build a mission?
Moderators: winston, another_commander
-
- ---- E L I T E ----
- Posts: 503
- Joined: Sat Jun 11, 2011 7:46 pm
Re: How to build a mission?
How are your Javascript skills? Missions are mainly handled by scripts.
The best way to understand them is to look over the existing ones and see if you can follow how they work. For a first look I'd recommend reviewing the scripts for the built-in trunk missions. They are relatively simple and should give you an idea of how things go together.
The best way to understand them is to look over the existing ones and see if you can follow how they work. For a first look I'd recommend reviewing the scripts for the built-in trunk missions. They are relatively simple and should give you an idea of how things go together.
My OXPs via Boxspace or from my Wiki pages .
Thargoid TV
Dropbox Referral Link
Thargoid TV
Dropbox Referral Link
-
- ---- E L I T E ----
- Posts: 503
- Joined: Sat Jun 11, 2011 7:46 pm
Re: How to build a mission?
My javascript skills are non-existent, but I've been known to learn programming and scripting languages within a one to two week period. If I learn that, then I should be able to make sense of the existing mission OXPs.
Out of curiosity, are there any alternate scripting languages that could be used in place of a .js? I DO know VBScript and Python. Just thought I'd ask.
Out of curiosity, are there any alternate scripting languages that could be used in place of a .js? I DO know VBScript and Python. Just thought I'd ask.
Re: How to build a mission?
No, the OXP scripts are in Javascript (Spider Monkey JS from the recent version of Mozilla Firefox iirc).
There is the older XML-type scripts as well (I forget the proper name of it), but they are much less capable as to what you can do.
JS isn't that complex (especially with the wiki as a reference guide), and several of us can help you along if you get stuck. Plus you have many examples to go along with as templates.
There is the older XML-type scripts as well (I forget the proper name of it), but they are much less capable as to what you can do.
JS isn't that complex (especially with the wiki as a reference guide), and several of us can help you along if you get stuck. Plus you have many examples to go along with as templates.
My OXPs via Boxspace or from my Wiki pages .
Thargoid TV
Dropbox Referral Link
Thargoid TV
Dropbox Referral Link
-
- ---- E L I T E ----
- Posts: 503
- Joined: Sat Jun 11, 2011 7:46 pm
Re: How to build a mission?
You have just given me great courage. I'll start on that tonight, hopefully (after I get some of my REAL programming work done).
- Capt. Murphy
- Commodore
- Posts: 1127
- Joined: Fri Feb 25, 2011 8:46 am
- Location: UK South Coast.
Re: How to build a mission?
Dragonfire, as a non programmer (but also someone who picks things up reasonably quickly),
I found the site below a useful resource for basic JS syntax, use of inbuilt objects (Math.random() and the like) etc. The examples are geared towards web scripting, but make the syntax easy to understand.
http://www.w3schools.com/js/js_intro.asp
Coupled with poring over other people's work and the wiki documentation that got me going.
As far as the Wiki documentation goes making sure you understand the use of the event handlers as it's these that kick off the relevant parts of your script at the right time.
http://wiki.alioth.net/index.php/Oolite ... _reference
http://wiki.alioth.net/index.php/Oolite ... t_handlers
And for what aspects of the game engine you can interact with and change via script.
http://wiki.alioth.net/index.php/Oolite ... ject_model
These pages are constantly open whilst I'm writing script.....i.e. you'll use them a lot.
I would suggest starting of with a simple idea, get it working and then go on to something more complex.
I found the site below a useful resource for basic JS syntax, use of inbuilt objects (Math.random() and the like) etc. The examples are geared towards web scripting, but make the syntax easy to understand.
http://www.w3schools.com/js/js_intro.asp
Coupled with poring over other people's work and the wiki documentation that got me going.
As far as the Wiki documentation goes making sure you understand the use of the event handlers as it's these that kick off the relevant parts of your script at the right time.
http://wiki.alioth.net/index.php/Oolite ... _reference
http://wiki.alioth.net/index.php/Oolite ... t_handlers
And for what aspects of the game engine you can interact with and change via script.
http://wiki.alioth.net/index.php/Oolite ... ject_model
These pages are constantly open whilst I'm writing script.....i.e. you'll use them a lot.
I would suggest starting of with a simple idea, get it working and then go on to something more complex.
Capt. Murphy's OXPs
External JavaScript resources - W3Schools & Mozilla Developer Network
Win 7 64bit, Intel Core i5 with HD3000 (driver rev. 8.15.10.2696 - March 2012), Oolite 1.76.1
External JavaScript resources - W3Schools & Mozilla Developer Network
Win 7 64bit, Intel Core i5 with HD3000 (driver rev. 8.15.10.2696 - March 2012), Oolite 1.76.1