Arrivals and departures
Moderators: winston, another_commander
- Wildeblood
- ---- E L I T E ----
- Posts: 2484
- Joined: Sat Jun 11, 2011 6:07 am
- Location: Western Australia
- Contact:
Re: Arrivals and departures
Be afraid.phkb wrote:
Look, here's another one in the same script:-
Code: Select all
this.shipDockedWithStation = function(station) {
// set up the interface screen, if required
this._playerDockTime = global.clock.adjustedSeconds;
var p = player.ship;
if(p && p.isValid) {
if (station.hasNPCTraffic && this.$checkStationRoleForView(station)) {
this._selectedStation = station;
this.$initInterface(station);
}
}
}
player.ship.*
in this function!
Code: Select all
this.shipDockedWithStation = function(station) {
// set up the interface screen, if required
this._playerDockTime = global.clock.adjustedSeconds;
if (station.hasNPCTraffic && this.$checkStationRoleForView(station)) {
this._selectedStation = station;
this.$initInterface(station);
}
}
- phkb
- Impressively Grand Sub-Admiral
- Posts: 4841
- Joined: Tue Jan 21, 2014 10:37 pm
- Location: Writing more OXPs, because the world needs more OXPs.
Re: Arrivals and departures
Not yet. Thanks for the tip.Wildeblood wrote:BTW, have you checked it works after a player escape pod sequence?
- phkb
- Impressively Grand Sub-Admiral
- Posts: 4841
- Joined: Tue Jan 21, 2014 10:37 pm
- Location: Writing more OXPs, because the world needs more OXPs.
Re: Arrivals and departures
A technical question: I'm trying to display one of the models from Commies as the background on a mission screen. I have "model" set to "[workcom]". However, nothing shows up. I noticed that Commies uses an XML based plist file - could that be the reason? The same is happening for ship models from Anarchies.Layne wrote:Still not sure why the commies ships aren't showing up.
- Norby
- ---- E L I T E ----
- Posts: 2577
- Joined: Mon May 20, 2013 9:53 pm
- Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
- Contact:
Re: Arrivals and departures
No, the reason is that you are not in a communist system and the shipdata contain a conditions part which disable this ship on mission screens also.phkb wrote:I'm trying to display one of the models from Commies as the background on a mission screen. I have "model" set to "[workcom]". However, nothing shows up. I noticed that Commies uses an XML based plist file - could that be the reason?
A workaround if you make your own shipdata entry using the same model and no conditions or a like_ship with conditions which allow all governments just to overwrite the original conditions.
Re: Arrivals and departures
Hmm. I'm not sure that's intended behaviour, there. Most demo ship creation doesn't check conditions - it's just the mission screen one which does.Norby wrote:No, the reason is that you are not in a communist system and the shipdata contain a conditions part which disable this ship on mission screens also.
Something to look after 1.82
- Redspear
- ---- E L I T E ----
- Posts: 2708
- Joined: Thu Jun 20, 2013 10:22 pm
- Location: On the moon Thought, orbiting the planet Ignorance, looking through a telescope with the lens cap on
Re: Arrivals and departures
Harsh IMO, very harsh.Wildeblood wrote:So outraged.
Why?
phkb couldn't have given much more of a warning as to the current state of the oxp (not oxz).phkb wrote:So, while I'm really happy to be sharing this, I'm also fairly nervous - I'm playing with things way above my pay grade here! I hope you understand that what I'm saying is that I need help to make sure I haven't broken something horribly, but that the core game of Oolite still continues to play in a satisfactory way. With this much code the potential for unforeseen conflicts and breakages is huge, so I need some feedback from some willing testers on a few issues. Testers will need to pay close attention to their actions as they will have a big impact on the dock list.
...
For the moment, I'm just releasing this as an OXP, rather than OXZ, the reason being it's a lot easier to see and change things in an OXP, and I'd like to encourage people to look inside as much as possible. An OXZ will follow once the code is stable.
To your credit Wildeblood, you do help phkb to tidy up the code but it's not really so difficult to draw parallels between code and manners is it?
Getting them right makes things run smoother, run better. Each misstep a PPoF, as you put it, a point of frustration or distress for the user/recipient.
My coding could use a hell of a lot of improvement and I'm sure that my manners aren't perfect.
You seem to favour straight-talking and not be shy about criticism so there it is.
- Wildeblood
- ---- E L I T E ----
- Posts: 2484
- Joined: Sat Jun 11, 2011 6:07 am
- Location: Western Australia
- Contact:
Re: Arrivals and departures
Yeah, you're right, Redspear.
Last edited by Wildeblood on Sun May 24, 2015 3:54 pm, edited 1 time in total.
- phkb
- Impressively Grand Sub-Admiral
- Posts: 4841
- Joined: Tue Jan 21, 2014 10:37 pm
- Location: Writing more OXPs, because the world needs more OXPs.
Re: Arrivals and departures
As an OXP in now in play, I've created a new thread in "Expansion Packs" called "Station Dock Control OXP". Version 0.3.0 has just been released which addresses a few of the bugs Layne reported, but a few others, and fixes the code issues identified by Wildeblood.
Link to new thread: https://bb.oolite.space/viewtopic.php?f= ... 74#p237074
Link to new thread: https://bb.oolite.space/viewtopic.php?f= ... 74#p237074
- Redspear
- ---- E L I T E ----
- Posts: 2708
- Joined: Thu Jun 20, 2013 10:22 pm
- Location: On the moon Thought, orbiting the planet Ignorance, looking through a telescope with the lens cap on
Re: Arrivals and departures
Takes courage to say and is to be applauded.Wildeblood wrote:Yeah, you're right, Redspear.
You're an asset to these boards with your coding skills and innovative oxps (of which I'm a fan).
Anyway, not for the first time, I've probably said enough... Thanks for the edit.
- Wildeblood
- ---- E L I T E ----
- Posts: 2484
- Joined: Sat Jun 11, 2011 6:07 am
- Location: Western Australia
- Contact:
Re: Arrivals and departures
Why did this one never make it into the Sensible Tweaks topic?Wildeblood wrote: ↑Fri May 15, 2015 4:14 pmCode: Select all
this.shipLaunchedFromStation = function (station) { if (player.ship.fuel < 7) { station.dockPlayer(); player.consoleMessage("Forgot something?", 5); } }