What is your maximum speed
Moderators: winston, another_commander
- Okti
- ---- E L I T E ----
- Posts: 700
- Joined: Sun Sep 26, 2010 1:51 pm
- Location: A GH shop, near witchpoint to Oresrati in Galaxy 8
What is your maximum speed
I would like to find out maximum speed player ships speed, used by the players.
I may need to edit the post later, because I used the entries used in shipdata.plist.
I may need to edit the post later, because I used the entries used in shipdata.plist.
-
- Quite Grand Sub-Admiral
- Posts: 6682
- Joined: Wed Feb 28, 2007 7:54 am
Re: What is your maximum speed
The Speed of Mind.
Do I win?
Do I win?
- Okti
- ---- E L I T E ----
- Posts: 700
- Joined: Sun Sep 26, 2010 1:51 pm
- Location: A GH shop, near witchpoint to Oresrati in Galaxy 8
Re: What is your maximum speed
Good oneanother_commander wrote:The Speed of Mind.
Do I win?
- Okti
- ---- E L I T E ----
- Posts: 700
- Joined: Sun Sep 26, 2010 1:51 pm
- Location: A GH shop, near witchpoint to Oresrati in Galaxy 8
Re: What is your maximum speed
I hope Google [Bot], will not vote
Re: What is your maximum speed
The speed of Dark.
No matter how fast light is, it always gets there first...
No matter how fast light is, it always gets there first...
My OXPs via Boxspace or from my Wiki pages .
Thargoid TV
Dropbox Referral Link
Thargoid TV
Dropbox Referral Link
- Okti
- ---- E L I T E ----
- Posts: 700
- Joined: Sun Sep 26, 2010 1:51 pm
- Location: A GH shop, near witchpoint to Oresrati in Galaxy 8
Re: What is your maximum speed
That's another good oneThargoid wrote:The speed of Dark.
No matter how fast light is, it always gets there first...
By the way I know max speed for a NPC is set in shipdata.plist, but is there a way to set it by JS
- Smivs
- Retired Assassin
- Posts: 8408
- Joined: Tue Feb 09, 2010 11:31 am
- Location: Lost in space
- Contact:
Re: What is your maximum speed
The speed of silence...you can't even hear it coming.
Commander Smivs, the friendliest Gourd this side of Riedquat.
- Commander McLane
- ---- E L I T E ----
- Posts: 9520
- Joined: Thu Dec 14, 2006 9:08 am
- Location: a Hacker Outpost in a moderately remote area
- Contact:
Re: What is your maximum speed
Nope. Most of the hard ship specs are read-only in JS. The documentation tells you so, also for maxSpeed. It tells you also if something is read-write.Okti wrote:By the way I know max speed for a NPC is set in shipdata.plist, but is there a way to set it by JS
- Okti
- ---- E L I T E ----
- Posts: 700
- Joined: Sun Sep 26, 2010 1:51 pm
- Location: A GH shop, near witchpoint to Oresrati in Galaxy 8
Re: What is your maximum speed
I knew the reply, but it may be a good thing to set up an npc's speed according to player ships speed.Commander McLane wrote:Nope. Most of the hard ship specs are read-only in JS. The documentation tells you so, also for maxSpeed. It tells you also if something is read-write.Okti wrote:By the way I know max speed for a NPC is set in shipdata.plist, but is there a way to set it by JS
I know that is possible to set in AI, but is there a way to set percentage of the speed, according to criteria in JS?
Re: What is your maximum speed
Script-wise you can use desiredSpeed, which works the same way as the AI equivalent.
But of course just because you set it in script doesn't mean that the ship's AI won't then change it again, depending on the AI code. And also the desiredSpeed is of course capped at the maxSpeed.
But of course just because you set it in script doesn't mean that the ship's AI won't then change it again, depending on the AI code. And also the desiredSpeed is of course capped at the maxSpeed.
My OXPs via Boxspace or from my Wiki pages .
Thargoid TV
Dropbox Referral Link
Thargoid TV
Dropbox Referral Link
- Okti
- ---- E L I T E ----
- Posts: 700
- Joined: Sun Sep 26, 2010 1:51 pm
- Location: A GH shop, near witchpoint to Oresrati in Galaxy 8
Re: What is your maximum speed
Thanks Thargoid,
I will try that.
I will try that.
- Commander McLane
- ---- E L I T E ----
- Posts: 9520
- Joined: Thu Dec 14, 2006 9:08 am
- Location: a Hacker Outpost in a moderately remote area
- Contact:
Re: What is your maximum speed
Thargoid already answered that one. Speed is something else than maximum speed. Just because a car can make 180 km/h doesn't mean that it's going at this maximum speed all the time. Sometimes it goes slower, sometimes it even stops.Okti wrote:I knew the reply, but it may be a good thing to set up an npc's speed according to player ships speed.Commander McLane wrote:Nope. Most of the hard ship specs are read-only in JS. The documentation tells you so, also for maxSpeed. It tells you also if something is read-write.Okti wrote:By the way I know max speed for a NPC is set in shipdata.plist, but is there a way to set it by JS
I know that is possible to set in AI, but is there a way to set percentage of the speed, according to criteria in JS?
The same is true for Oolite. ship.speed is something else than ship.maxSpeed. There is also ship.cruiseSpeed, which is always 80% of ship.maxSpeed. All of these are read-only in JS. If you want to set a ship's speed you have to use ship.desiredSpeed, with the caveat mentioned by Thargoid. NPCs are meant to be flown by AIs, not by scripts. In Oolite 2 these two will perhaps be more integrated than they are now. And even now you could try to give a ship nullAI and fly it only by script commands. I am not sure, however, which advantages that would have. The state machine system has proven itself kind of useful for NPC-flying.
You could also try to experiment with ship.velocity.
Re: What is your maximum speed
If NPC ships have injectors, they can move up to 7x normal max speed until they run out of fuel.
...But you may need to tell them to do so.
...But you may need to tell them to do so.
- JensAyton
- Grand Admiral Emeritus
- Posts: 6657
- Joined: Sat Apr 02, 2005 2:43 pm
- Location: Sweden
- Contact:
Re: What is your maximum speed
No, it isn’t (which is why it’s exposed).Commander McLane wrote:There is also ship.cruiseSpeed, which is always 80% of ship.maxSpeed.
cruiseSpeed
can be lowered to 99 % of the maximum speed of a ship’s slowest escort in order to keep formations together.E-mail: [email protected]
- Commander McLane
- ---- E L I T E ----
- Posts: 9520
- Joined: Thu Dec 14, 2006 9:08 am
- Location: a Hacker Outpost in a moderately remote area
- Contact:
Re: What is your maximum speed
Ah yes, I forgot that.Ahruman wrote:No, it isn’t (which is why it’s exposed).Commander McLane wrote:There is also ship.cruiseSpeed, which is always 80% of ship.maxSpeed.cruiseSpeed
can be lowered to 99 % of the maximum speed of a ship’s slowest escort in order to keep formations together.
So it would be more correct to say that
cruiseSpeed
is usually 80% of maxSpeed
, especially if the ship in question doesn't have escorts.