Free Trade Zone OXP
Moderators: winston, another_commander
- Mauiby de Fug
- ---- E L I T E ----
- Posts: 847
- Joined: Tue Sep 07, 2010 2:23 pm
It would appear that if one is a Fugitive, docking at a FTZ actually reduces your legal status to Offender!
One consequence of this is that after one survives a sortie with the Thargoids as a reserve for the Galactic Navy (in the oxp of the same name), and then detonates an Energy Bomb to clear up all the little Thargoid Robot Fighters, and, somewhat less sportingly, a whole bunch of your former Navy comrades as well (thereby becoming a Fugitive), one can make a short trip to your nearest Multi-Government system, stop by the FTZ to become an Offender, and then blast a few pirates on the way to the planet to become clean again. (Whew, that was a monster of a sentence!)
A quick, easy and morally dubious way to gain 100+ kills while remaining Clean!
One consequence of this is that after one survives a sortie with the Thargoids as a reserve for the Galactic Navy (in the oxp of the same name), and then detonates an Energy Bomb to clear up all the little Thargoid Robot Fighters, and, somewhat less sportingly, a whole bunch of your former Navy comrades as well (thereby becoming a Fugitive), one can make a short trip to your nearest Multi-Government system, stop by the FTZ to become an Offender, and then blast a few pirates on the way to the planet to become clean again. (Whew, that was a monster of a sentence!)
A quick, easy and morally dubious way to gain 100+ kills while remaining Clean!
- Disembodied
- Jedi Spam Assassin
- Posts: 6885
- Joined: Thu Jul 12, 2007 10:54 pm
- Location: Carter's Snort
Confirmed, but I'm not sure why. The FTZ script.plist is as follows:Mauiby de Fug wrote:It would appear that if one is a Fugitive, docking at a FTZ actually reduces your legal status to Offender!
Code: Select all
{
free-trade-zone = (
{
conditions = (
"status_string equal STATUS_EXITING_WITCHSPACE",
"planet_number greaterthan -1",
"systemGovernment_number equal 2"
);
do = ( "addShipsAt: free_trade_zone 1 wpu 0 0 -0.3",
"addShipsAtPrecisely: ftzpirate 2 wpu 0 0 -0.25",
"reset: local_freetradezone_marked");
},
{
conditions = (
"status_string equal STATUS_EXITING_WITCHSPACE",
"planet_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 75"
);
do = ( "addShipsAtPrecisely: pirate 2 wpu 0 0 -0.25");
},
{
conditions = (
"status_string equal STATUS_EXITING_WITCHSPACE",
"planet_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 30"
);
do = ( "addShipsAtPrecisely: ftzpirate 2 wpu 0 0 -0.2");
},
{
conditions = (
"status_string equal STATUS_EXITING_WITCHSPACE",
"planet_number greaterthan -1",
"systemEconomy_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 70"
);
do = ( "addShipsAtPrecisely: ftzpirate 4 wpu 0 0 -0.15");
},
{
conditions = (
"status_string equal STATUS_EXITING_WITCHSPACE",
"planet_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 50"
);
do = ( "addShipsWithinRadius: ftzhauler 1 wpu 0 0 -0.2 5000");
},
{
conditions = (
"status_string equal STATUS_EXITING_WITCHSPACE",
"planet_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 75"
);
do = ( "addShipsWithinRadius: ftzhauler 1 wpu 0 0 -0.25 5000");
},
{
conditions = (
"status_string equal STATUS_LAUNCHING",
"planet_number greaterthan -1",
"systemGovernment_number equal 2"
);
do = ( "checkForShips: free_trade_zone",
{ conditions = ("shipsFound_number equal 0" );
do = ( "addShipsAt: free_trade_zone 1 wpu 0 0 -0.3"); } );
},
{
conditions = (
"status_string equal STATUS_LAUNCHING",
"planet_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 50"
);
do = ( "addShipsWithinRadius: pirate 2 wpu 0 0 -0.3 10000");
},
{
conditions = (
"status_string equal STATUS_LAUNCHING",
"planet_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 75"
);
do = ( "addShipsWithinRadius: ftzpirate 2 wpu 0 0 -0.3 10000");
},
{
conditions = (
"status_string equal STATUS_LAUNCHING",
"planet_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 50"
);
do = ( "addShipsWithinRadius: ftzhauler 1 wpu 0 0 -0.2 5000");
},
{
conditions = (
"status_string equal STATUS_LAUNCHING",
"planet_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 75"
);
do = ( "addShipsWithinRadius: ftzhauler 1 wpu 0 0 -0.25 5000");
},
{
conditions = (
"status_string equal STATUS_LAUNCHING",
"planet_number greaterthan -1",
"systemGovernment_number equal 2",
"d100_number greaterthan 90"
);
do = ( "addShipsWithinRadius: police 6 wpu 0 0 -0.3 5000");
},
{
conditions = (
"status_string equal STATUS_DOCKED",
"dockedStationName_string equal Free Trade Zone",
"local_freetradezone_marked undefined"
);
do = (
"set: mission_freetradezone_fine [legalStatus_number]",
"add: mission_freetradezone_fine 5",
"setLegalStatus: [mission_freetradezone_fine]",
"set: local_freetradezone_marked YES",
"reset: mission_freetradezone_fine"
);
},
);
}
Code: Select all
{
conditions = (
"status_string equal STATUS_DOCKED",
"dockedStationName_string equal Free Trade Zone",
"local_freetradezone_marked undefined"
);
do = (
"set: mission_freetradezone_fine [legalStatus_number]",
"add: mission_freetradezone_fine 5",
"setLegalStatus: [mission_freetradezone_fine]",
"set: local_freetradezone_marked YES",
"reset: mission_freetradezone_fine"
);
},
- 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:
The code looks correct to me (and I guess it must have worked at some time).
My guess is that for some reason the "set: mission_freetradezone_fine [legalStatus_number]" doesn't work, but will result in mission_freetradezone_fine being set to 0. If the rest of the code is working, 5 would be added to that, so finally legalStatus_number would be set to 5, which would lead to an offender status.
Could you do another test and see whether player.bounty is indeed 5 after this part of the code is run. And also that it stays at 5 with subsequent dockings at the FTZ?
My guess is that for some reason the "set: mission_freetradezone_fine [legalStatus_number]" doesn't work, but will result in mission_freetradezone_fine being set to 0. If the rest of the code is working, 5 would be added to that, so finally legalStatus_number would be set to 5, which would lead to an offender status.
Could you do another test and see whether player.bounty is indeed 5 after this part of the code is run. And also that it stays at 5 with subsequent dockings at the FTZ?
- Disembodied
- Jedi Spam Assassin
- Posts: 6885
- Joined: Thu Jul 12, 2007 10:54 pm
- Location: Carter's Snort
A Clean player's bounty is set to 5 after docking. Multiple dockings in the same FTZ (without jumping out) don't add to this (which is the intended result). Go in as a Fugutive, though, and you come out as an Offender with a bounty of 5. It looks indeed as if
is actually setting mission_freetradezone_fine to 0.
Code: Select all
"set: mission_freetradezone_fine [legalStatus_number]"
- Eric Walch
- Slightly Grand Rear Admiral
- Posts: 5536
- Joined: Sat Jun 16, 2007 3:48 pm
- Location: Netherlands
Im sure it worked in the past. I used the same construction in the legacy script of thargoidWars because the original code by Murgh did not work. That was explicit tested to work correct. But that was back with Oolite 1.69 or 1.70 at the most as it is now using a JS script.Disembodied wrote:is actually setting mission_freetradezone_fine to 0.
I just looked in the code and noticed that there are 3 names that are renamed to get more consistent names. In the whilteList.plist there is a list with tho old names for translation to the new ones:
Code: Select all
query_method_aliases =
{
"fuel_leak_rate_number" = "fuelLeakRate_number";
"fuel_level_number" = "fuelLevel_number";
"legalStatus_number" = "commanderLegalStatus_number";
};
UPS-Courier & DeepSpacePirates & others at the box and some older versions
- Disembodied
- Jedi Spam Assassin
- Posts: 6885
- Joined: Thu Jul 12, 2007 10:54 pm
- Location: Carter's Snort
That's done the trick. Go in as a Fugitive, come out as a Fugitive with an extra +5! I'll update and upload the OXP.Eric Walch wrote:Probably the automatic replacement is not working correct. Try if changing the name to "commanderLegalStatus_number" does work. If that new name does work, the Oolite bug is here and the two other names above are likely to not work either in current Oolite. (name change was in r 2098, march 2009)
Edit: does this mean the new version won't work properly with versions of the game older than March 2009?
- Disembodied
- Jedi Spam Assassin
- Posts: 6885
- Joined: Thu Jul 12, 2007 10:54 pm
- Location: Carter's Snort
New version of the Free Trade Zone OXP now available for download, once again with working legal garnish courtesy of Eric!
Yep! However, the aim is still get the next stable ( which is still coming, btw ) totally backward compatible with 1.65 save games & OXPs, so the bug discovered by Eric is going to be fixed in the near future!Disembodied wrote:Edit: does this mean the new version won't work properly with versions of the game older than March 2009?
Hey, free OXPs: farsun v1.05 & tty v0.5! :0)
- Eric Walch
- Slightly Grand Rear Admiral
- Posts: 5536
- Joined: Sat Jun 16, 2007 3:48 pm
- Location: Netherlands
But not by me. The problem is however that the condition part is handled different than the "DO" part. I just wrote a small script:Kaks wrote:Yep! However, the aim is still get the next stable ( which is still coming, btw ) totally backward compatible with 1.65 save games & OXPs, so the bug discovered by Eric is going to be fixed in the near future!
Code: Select all
{
conditions = (
"status_string equal STATUS_LAUNCHING",
"legalStatus_number greaterthan 5",
);
do = (
"set: mission_test [legalStatus_number]",
);
},
Code: Select all
(
YES,
(
(
0,
"status_string equal STATUS_LAUNCHING",
"status_string",
0,
(
(
NO,
"STATUS_LAUNCHING",
),
),
),
(
1,
"legalStatus_number greaterthan 5",
"commanderLegalStatus_number",
3,
(
(
NO,
5,
),
),
),
),
(
(
NO,
"set:",
"mission_test [legalStatus_number]",
),
),
(),
),
UPS-Courier & DeepSpacePirates & others at the box and some older versions
- Disembodied
- Jedi Spam Assassin
- Posts: 6885
- Joined: Thu Jul 12, 2007 10:54 pm
- Location: Carter's Snort
Re: Free Trade Zone OXP
Newly updated [wiki]Free Trade Zone[/wiki] page on the wiki, courtesy of Fatleaf: many thanks to him and to all the wiki wizards for their excellent wikiwirk!
- 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: Free Trade Zone OXP
Disembodied has very kindly given me permission to update and maintain this OXP going forward. He's also shared some ideas with me on how the OXP may develop in the future.
In version 0.21 (now available via the download manager):
In version 0.21 (now available via the download manager):
- Converted model to be a variation of the new Rock Hermit.
- Added a customised docking tunnel texture for use by BGS.
- Turned on docking requests.
- Limited FTZ's to only appear in TL7 systems or higher.
- Converted plist-style script to Javascript.
- Updated the populator routine to use the new Oolite populator methods.
- Added routines to check if the FTZ was destroyed in a system, and only recreate the station after 30 days have passed.
- Updated the market script to use the new style.
- Added an option for commanders who dock at the station to either take the bounty increase, or pay a fine.
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: Free Trade Zone OXP
Not tried this OXP before - has it always used Z on the ASC? Zieman Habitats also use Z, you see.
Not that it's a problem - just curious.
Not that it's a problem - just curious.
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
- 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: Free Trade Zone OXP
As far as I'm aware it's always had Z. I can easily change it to something else, although I'm not sure what to.Cody wrote:has it always used Z on the ASC?
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: Free Trade Zone OXP
No need - plenty of multiple usages on the ASC already, and it's easy to tell FTZs from ZHs anyway.phkb wrote:I can easily change it to something else, although I'm not sure what to.
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!