Possibility to cancel a Player's launch from station?
Moderators: winston, another_commander
Possibility to cancel a Player's launch from station?
Hi,
I found the world script event shipWillLaunchFromStation but it is not possible to cancel that launch, is it?
If it is really not possible:
Would it be possible to include this for future use?
Thanks,
QCS
I found the world script event shipWillLaunchFromStation but it is not possible to cancel that launch, is it?
If it is really not possible:
Would it be possible to include this for future use?
Thanks,
QCS
- Wildeblood
- ---- E L I T E ----
- Posts: 2453
- Joined: Sat Jun 11, 2011 6:07 am
- Location: Western Australia
- Contact:
Re: Possibility to cancel a Player's launch from station?
There's a station method .dockPlayer() you can use to re-dock a player that launches before you wish, but... WHY!?
Re: Possibility to cancel a Player's launch from station?
Player ship launch is not preventable once started (and even some things you might expect to prevent it - no docks being large enough, or no docks with
What sort of situation are you thinking of for this?
allowLaunching
set, for example - don't affect the player ship)What sort of situation are you thinking of for this?
- phkb
- Impressively Grand Sub-Admiral
- Posts: 4830
- Joined: Tue Jan 21, 2014 10:37 pm
- Location: Writing more OXPs, because the world needs more OXPs.
Re: Possibility to cancel a Player's launch from station?
I can think of a number of mission scenarios where you might want to prevent the player from launching. For instance, in the WIP "Life in the Frontier" (which is accessed via the interfaces menu), a sub mission might quarantine or impound the players ship. The solution in those scenarios could be to use "allowInterrupt = false" on the runMission screen, and then stop the player from exiting the interface screen. The problem then arises that you can't save the game when "allowInterrupt" is false. You can't switch to F2 to save the game or even exit.
If the "allowInterrupt = false" option could still allow the F2 options screen, and when reloading put the player back into the correct interface screen, then that solve the problem. However, I suspect that's a rather major change.
If the "allowInterrupt = false" option could still allow the F2 options screen, and when reloading put the player back into the correct interface screen, then that solve the problem. However, I suspect that's a rather major change.
Re: Possibility to cancel a Player's launch from station?
Thanks for the dock() suggestion, it might not work as I planned though. I would have to check it first. I guess that's too late.
Idea was to have a minor "mechanics" OXP to prevent people from launching with controlled goods in store (or HyperCargo, for that matter).
Like you give your computer the "launch" command and it says "Are you sure? The cargo manifest says you probably shouldn't".
It could come with a slight penalty in time, I guess. Main reason is just to avoid becoming offender accidentally. Of course only if the player wants to (install this OXP). I guess it would be very handy for new players (and for me )
Regards,
QCS
Edit: Ok, I had a quick test, and it didn't work, but in a different way as expected.
Console output :
[general.error.inconsistentState]: ***** ERROR: status is STATUS_DOCKING, but dockedStation is nil; treating as not docked. This is an internal error, please report it.
What I did: a world script with:
this.shipWillLaunchFromStation = function(station)
{
//from the JS reference, dockedStation is set at this point
player.ship.dockedStation.dockPlayer();
}
Idea was to have a minor "mechanics" OXP to prevent people from launching with controlled goods in store (or HyperCargo, for that matter).
Like you give your computer the "launch" command and it says "Are you sure? The cargo manifest says you probably shouldn't".
It could come with a slight penalty in time, I guess. Main reason is just to avoid becoming offender accidentally. Of course only if the player wants to (install this OXP). I guess it would be very handy for new players (and for me )
Regards,
QCS
Edit: Ok, I had a quick test, and it didn't work, but in a different way as expected.
Console output :
[general.error.inconsistentState]: ***** ERROR: status is STATUS_DOCKING, but dockedStation is nil; treating as not docked. This is an internal error, please report it.
What I did: a world script with:
this.shipWillLaunchFromStation = function(station)
{
//from the JS reference, dockedStation is set at this point
player.ship.dockedStation.dockPlayer();
}
- Wildeblood
- ---- E L I T E ----
- Posts: 2453
- Joined: Sat Jun 11, 2011 6:07 am
- Location: Western Australia
- Contact:
Re: Possibility to cancel a Player's launch from station?
That never had a chance of working, but this should:-QCS wrote:What I did: a world script with:Code: Select all
this.shipWillLaunchFromStation = function(station) { //from the JS reference, dockedStation is set at this point player.ship.dockedStation.dockPlayer(); }
Code: Select all
this.shipWillLaunchFromStation = function (station) {
this.$bounty = player.bounty;
}
this.shipLaunchedFromStation = function (station) {
player.bounty = this.$bounty;
station.dockPlayer();
}
You might try this just to see what happens :-
Code: Select all
this.shipWillLaunchFromStation = function (station) {
station.dockPlayer();
}
Re: Possibility to cancel a Player's launch from station?
Indeed, it did. But it feels so wrong... the ship launches, then I could come up with the warning, player decides he didn't want to, and returns to the station...Wildeblood wrote:this should:-Code: Select all
this.shipWillLaunchFromStation = function (station) { this.$bounty = player.bounty; } this.shipLaunchedFromStation = function (station) { player.bounty = this.$bounty; station.dockPlayer(); }
Well, I guess in this case, it is not the own computer which asks you if you are sure, but the GalCop scans your manifest and gives you the chance to re-dock immediately to avoid the fine. But it feels so strange that you are "towed" back into the Launch tunnel backwards instead of flying there yourself in a forward manner.
I will have to think about the "scenario" a bit. I feel this should cost a few credits but I wanted to avoid that.
True, but I often have controlled goods confiscated from former piratesWildeblood wrote:Much easier to just warn them at the moment of purchase, though, rather than waiting until launch.
Same error as above.Wildeblood wrote:You might try this just to see what happens:-Code: Select all
this.shipWillLaunchFromStation = function (station) { station.dockPlayer(); }
- Venator Dha
- ---- E L I T E ----
- Posts: 329
- Joined: Sun Feb 23, 2014 11:26 am
- Location: Sweden
Re: Possibility to cancel a Player's launch from station?
To expand the idea a bit (Expect it would need some Dev work to create )
Create a launch protocol/check list to cover, for example:
Fuel level : Full, low, insufficient for next destination.
Free pylons available.
Illegal cargo
Un-repaired systems
Pressing 1 get this launch protocol then pressing 1 again will launch.
Would also prevent accidental launch when pressing 1 instead of 2 after docking
Create a launch protocol/check list to cover, for example:
Fuel level : Full, low, insufficient for next destination.
Free pylons available.
Illegal cargo
Un-repaired systems
Pressing 1 get this launch protocol then pressing 1 again will launch.
Would also prevent accidental launch when pressing 1 instead of 2 after docking
Taurus Driving through the galaxy since... .
Re: Possibility to cancel a Player's launch from station?
Very good idea. And if one could cancel a launch, one could also do all this with an OXP (even the F1F1 sequence).Venator Dha wrote:To expand the idea a bit (Expect it would need some Dev work to create )
Create a launch protocol/check list to cover, for example:
Fuel level : Full, low, insufficient for next destination.
Free pylons available.
Illegal cargo
Un-repaired systems
Pressing 1 get this launch protocol then pressing 1 again will launch.
Would also prevent accidental launch when pressing 1 instead of 2 after docking
- Wildeblood
- ---- E L I T E ----
- Posts: 2453
- Joined: Sat Jun 11, 2011 6:07 am
- Location: Western Australia
- Contact:
Re: Possibility to cancel a Player's launch from station?
Try my Docked HUDs OXP. It was created for a player who habitually launched forgetting to re-fuel. It doesn't check for controlled cargo or un-repaired equipment but that could possibly be added.Venator Dha wrote:To expand the idea a bit (Expect it would need some Dev work to create )
Create a launch protocol/check list to cover, for example:
Fuel level : Full, low, insufficient for next destination.
Free pylons available.
Illegal cargo
Un-repaired systems...
- Smivs
- Retired Assassin
- Posts: 8408
- Joined: Tue Feb 09, 2010 11:31 am
- Location: Lost in space
- Contact:
Re: Possibility to cancel a Player's launch from station?
Surely these are basic checks the pilot should be making anyway!Venator Dha wrote:Create a launch protocol/check list....
Seriously, the pre-flight checks are an important part of the immersion in the game (for me at least) and I wouldn't want to see the game 'idiot-proofed' like this. Not in core anyway, what people use as OXP is up to them.
Commander Smivs, the friendliest Gourd this side of Riedquat.
- Venator Dha
- ---- E L I T E ----
- Posts: 329
- Joined: Sun Feb 23, 2014 11:26 am
- Location: Sweden
Re: Possibility to cancel a Player's launch from station?
I think we agree but are looking at it from the opposite directions.Smivs wrote:Surely these are basic checks the pilot should be making anyway!Venator Dha wrote:Create a launch protocol/check list....
Seriously, the pre-flight checks are an important part of the immersion in the game (for me at least) and I wouldn't want to see the game 'idiot-proofed' like this. Not in core anyway, what people use as OXP is up to them.
I would see this as introducing the basic checks in a visual, in-game, way. I don't see this as an idiot proofing - they would just press F1F1 without thinking I definitely see this as an OXP - As I understand it, it would just needs some Dev help around the pressing of F1.
Taurus Driving through the galaxy since... .
Re: Possibility to cancel a Player's launch from station?
"Are you sure you want to launch? Yes/No"
Re: Possibility to cancel a Player's launch from station?
This is just a thought regarding the launching - docking tunnel. Someone with proper skills might be able to replace the tunnel effect with something more appropriate that might suit the situation.
Re: Possibility to cancel a Player's launch from station?
I guess I can do the following:
- Let the player launch.
- Bring up the warning, ask the player if he wants to return to dock immediately or continue launching and accept the consequences.
- If player chooses to continue launching, nothing more happens (normal bounty behavior).
- If player chooses to return to dock, normal AutoDocking sequence starts, bringing the player back into dock. Player is warned to under all circumstances the AutoDocking must not be interrupted. When the ship docks, fees are not applied. If player cancels the AutoDocking, fees apply (and may even be doubled).
Question:
- How do I initiate normal docking sequence? Is this the same station.dock() only that the ship has to be some meters away from the dock? Otherwise I have not seen a possibility to call the docking.
- What should the OXP do when the auto docking is cancelled from outside (station cancels because of being attacked, for example)? Wait and idle until the station allows docking again? Maybe the player needs to defend? Really not an easy question...
- What if player was already offender before docking, then committing another crime by leaving the station with controlled goods. The solution above would still leave him offender, making him very likely to be target of GalCop attacks. Should the OXP somehow put the player "under quarantine" not to be attacked by GalCop in that time?
Edit: Thinking more about this... this is not really a good idea since this would only work with a docking computer... well, I guess, cancelling a Launch would be the best option really.
And I tried the station.dock() - this works immediately, even from 10km away but it does not really run the docking. It is more like the fastDock function. Still, this is only possible (in game idea) with a docking computer.
- Let the player launch.
- Bring up the warning, ask the player if he wants to return to dock immediately or continue launching and accept the consequences.
- If player chooses to continue launching, nothing more happens (normal bounty behavior).
- If player chooses to return to dock, normal AutoDocking sequence starts, bringing the player back into dock. Player is warned to under all circumstances the AutoDocking must not be interrupted. When the ship docks, fees are not applied. If player cancels the AutoDocking, fees apply (and may even be doubled).
Question:
- How do I initiate normal docking sequence? Is this the same station.dock() only that the ship has to be some meters away from the dock? Otherwise I have not seen a possibility to call the docking.
- What should the OXP do when the auto docking is cancelled from outside (station cancels because of being attacked, for example)? Wait and idle until the station allows docking again? Maybe the player needs to defend? Really not an easy question...
- What if player was already offender before docking, then committing another crime by leaving the station with controlled goods. The solution above would still leave him offender, making him very likely to be target of GalCop attacks. Should the OXP somehow put the player "under quarantine" not to be attacked by GalCop in that time?
Edit: Thinking more about this... this is not really a good idea since this would only work with a docking computer... well, I guess, cancelling a Launch would be the best option really.
And I tried the station.dock() - this works immediately, even from 10km away but it does not really run the docking. It is more like the fastDock function. Still, this is only possible (in game idea) with a docking computer.