Page 1 of 1

Commodity-legality in OXPs

Posted: Sat Jan 22, 2011 9:55 am
by Squeek
Would it be possible to make something that normally isn't controlled controlled in a specific sector?

Say, A planet where you can't bring in liquor/wines?

Or, one where you can't bring in furs, or whatever?

Re: Commodity-legality in OXPs

Posted: Sat Jan 22, 2011 10:51 am
by JensAyton
No, the list of illegal goods is universal. (It really ought to be set in commodities.plist, but it ain’t.)

Re: Commodity-legality in OXPs

Posted: Sat Jan 22, 2011 11:19 am
by DaddyHoggy
I guess it could be scripted though. I thought about a "permits" OXP as a mission based oxp a long time ago - Communist states issuing expensive permits to bring in luxury goods or face heavy fines, a hippy "anarchy" state where drugs were encouraged but you'd need a permit of carriage (so you'd have to script the equipment that reset your legal status to clean provided you had the permit and were only carrying narcotics and you went to this particular system).

Re: Commodity-legality in OXPs

Posted: Sat Jan 22, 2011 11:35 am
by Eric Walch
DaddyHoggy wrote:
I guess it could be scripted though.
I assume so. Since 1.74 JS can access the contents of the players cargo. A script can check the cargo on docking in specific systems and act on it.

Re: Commodity-legality in OXPs

Posted: Sat Jan 22, 2011 3:01 pm
by Commander McLane
Squeek wrote:
Would it be possible to make something that normally isn't controlled controlled in a specific sector?

Say, A planet where you can't bring in liquor/wines?

Or, one where you can't bring in furs, or whatever?
Yes, fines for carrying specific goods depending on a list of planets can be scripted quite easily.

Note, however, that the game engine does not fine you for bringing illegal commodities into a system, but only for taking them out of a main station.

Re: Commodity-legality in OXPs

Posted: Sat Jan 22, 2011 3:34 pm
by Eric Walch
Commander McLane wrote:
Note, however, that the game engine does not fine you for bringing illegal commodities into a system, but only for taking them out of a main station.
But we don't always need to copy the game engine. e.g. when the admiral of a military station does not want any booze be brought at his station to keep his crew alert, you could add next lines to a ship-script for that specific military station.

Code: Select all

this.otherShipDocked = function (ship)
{
	if (ship.isPlayer) 
    {
         var fine =  manifest["liquor/wines"] * 50;
         if (fine > player.credits) fine = player.credits;
         if (fine > 0)
         {
             player.addMessageToArrivalReport("You have been fined "+ fine + " credits for bringing in booze to this station";
             player.credits -= fine;
         }
    }
}

Re: Commodity-legality in OXPs

Posted: Sat Jan 22, 2011 4:08 pm
by Mauiby de Fug
In ArcElite, Furs were also banned commodities. It took me quite a while to realise that the were legal in Oolite! I toyed with the idea of making an oxp that made it illegal to sell furs at, say feline worlds, but decided that I couldn't be bothered at the time.