Selling the Enemy Proprietary Military Technology

How to best implement double-agent-tude?

I have an idea that I want to put in a Nova plugin. Well, technically, I don't want to do anything other than tell other plugin developers about my idea so that they can put it into their own plugins if they want, or just know that it's possible.

The only problem is, while I believe it's possible, I haven't tested it and don't know for sure, so I can't state definitively how to do it. So what I am now going to do is explain precisely what effect I want the player to experience, describe how I think it might be implementable, then ask for suggestions and opinions.

Without further ado, the scenario I envision is this:

The player (who I will hereafter refer to as, "the player",) joins a military organization wherein he or she becomes a front-line fighter tasked with performing tactical and strategic attacks on an enemy, and defending key positions therefrom. To aid him or her in this, the governing body of the military has issued the player a standard combat ship fitted with launchers adapted for high-tech ordnance, and access to as many missiles as he or she deems necessary for his or her present objective.

In short, you've got a ship with missile launchers, and missiles are free from your supply depot.

These missiles contain proprietary technology that forces not associated with the government that developed them would give premium amounts of money for. The player can follow his or her orders, performing tasks and not going AWOL, steadily moving up in the ranks, or he or she can defect. The chance to defect is not given by a mission being offered, but by selling weapons to groups not affiliated with the military of which the player is a part.

That is, you can sell your missiles to other governments for loads of cash, and have the chance to work as a double-agent.

Now, that's all well and good, but I don't know how to make it work. To keep things simple in this example, let's say there's a single type of missile that a single government's military produces and offers to its soldiers for free, and which people on a single spöb will pay a king's ransom for.

So the question is, how many outfits are necessary for that one missile, are they properly removed when the player fires the missiles in combat, how do they look in the player's ship info or pilotlog, and what other resources are needed to pull off the defection-enabling missile scenario I described?

You could have the player confronted with a mission when the enter a bar, then have the outift stripped away, but I don't know if there's any way to make the actual trade of an item an illegal activity.

I'm thinking that the biggest obstacle would be the price change, since rank discounts only effect ships/ship trade-in value. Here's what I would try:

Two outfits:
One missle ammo outfit which has cost of 0. (Outfit xxx)
Duplicate of above which has a cost. (Outfit yyy)

The duplicate will only be available (via tech level limitations) at the single spob where it can be sold. Max buy of 0, so the player can't buy any, just sell them.

One mission:
Invisible with a travel/return destination for the spob above. Set an NCB (Bzzz) On Success, and give it a one day advance. Have it restart itself On Success as well.

Two crons:
Both Iterative entry crons
First cron: Enable On = Oyyy
On Start = Dyyy Gxxx

Second cron:Enable On = Bzzz & Oxxx
On Start = Dxxx Gyyy
On End = !Bzzz

Basically, when the player lands on the spob, all of the valueless outfits will be taken away and replaced with the duplicate. They can then sell them, or not, or some of them... whatever they choose to do with them. When they take off, they will be switched back to the valueless version. The player will only have the duplicate at the planet they can be sold at.

I'll second slouch.

Though I think it might be better to make the second crön different, and add a third, as I am not sure whether the iterative character will produce the wanted effect here (if Bzzz and Oyyy, then Dxxx and !Bzzz => it would only work until the end of the first time the crön takes place because Bzzz disappears no?).
Of course, I am not a crön professional, so I may be completely wrong.

If indeed the second crön is faulty, then here's my solution:

Second crön:
Enable On = Bzzz & Oxxx
On Start = Dxxx Gyyy

Third crön:
Enable On = Bzzz & !Oxxx
On End = !Bzzz

Would that work better?

As long as the mission is properly restarting itself, Bzzz will be set everytime the player lands on the spob, and the crons will fire as expected.

I may be missing something really obvious, but I don't see why it needs to be that complicated. Here's how I would do it:

Two outfs:
xxx - the valueless weapon that you purchase. It is available at spobs of the player's govt. All name fields are blank, and all it does is Gyyy on purchase and Dyyy on sell (and control the misn below). Since the name is blank, the player never sees it.
yyy - the actual weapon that the player fires. It is not sellable except on the one enemy planet. Otherwise, it's handled through ouft xxx. Firing shouldn't be a problem, since the player never sees xxx anyway. Ugly but effective.

One misn:
The OnSell field of outf xxx will simultaneously start and abort this invisible mission. CompReward is 1 for the player's govt, and "-5x CompReward on Abort" flag is checked.
Dxxx should also be in there somewhere.

PBoat

This post has been edited by PBoat101 : 02 May 2005 - 05:55 PM

Yes, for a weapon it could be much more simple. But for ammo type outfits, you need to be able to account for the player using them, and possibly plundering them from AI ships. Since there is no 'On Fire' type of field to perform operations, a cron-based workaround might be necessary.

There are 2 possible flaws to my method:

  1. The one day advance. If the scenario has lots of missions with time limits, it could really screw the player if they don't realize that they lose an extra day by landing on the spob.

  2. Possible game lag. The max ammo for the outfit in question would need to be a reasonable amount, anything in the hundreds is acceptable. Once Nova has to do cron iterations in the thousands, there will be a noticable lag. The time will vary from machine to machine.

Won't the first cron need to test for Bzzz as well? And to make sure they don't run one after the other, the second should be IDed lower than the first.

This post has been edited by Guy : 02 May 2005 - 11:06 PM

It shouldn't be a problem. The first cron will only be eligible to run if the player has the duplicate version of the outfit, and the only way to get that is via the second cron, and only when landing on the spob.

So, when the player lands on the spob, the mission succeeds setting Bzzz, restarts itself, and advances one day. The second cron fires, removing all of outfit xxx, and replaces it with yyy, and unsets Bzzz. When the player takes off, th first cron fires, all of yyy is removed and is replaced with xxx. Bzzz is not set, so the second cron won't run again until the player lands on the spob.

This post has been edited by slouch : 03 May 2005 - 07:53 AM

Oh whoops, my bad. I got the two crons mixed up, thinking the first one ran first.

Simple solution, if possible:

  1. Create Outfit called Missile Sale Contract, with negative cost (so player gets money for buying it)

  2. On purchase of Outfit, link a mission that lowers govt standing and removes one missile.

Dunno it if that can be done, but if it can, it's the easy way.

Also, If they have none of these missiles, the first one would be most valuble (ie going from having none to having one is a much larger step than going from 1 to two, you know?)

So it might be best served with a mission, then. Well... yeah, its hard to say. I was thinking of having something like this in my plug, too. Im not so sure how to make it work, but I think crons are a little too valuble to me.

You could try having the enemy approach you and make the offer in the original mission (meaning when you go to the bar they tell you your mission you select yes/okay and then the enemy approaches you in the resulting screen) agent tells you to go to <planet> and meet a man there who will give you further instruction.

Then you are given a certain amount of time to travel to the system where your target is and destroy it.
Your governments target and system are in one direction with a fair amount of time for you to destroy it. The enemy planet you were told to go to is in the opposite direction and far away (so time must expire before you get there)
If failed the government will consider you defected and become hostile (should be explained in the original mission briefing). The failure will trigger the enemy mission which is available at the bar of whatever planet you have the original enemy agent tell you. He tells you that your government has followed you and that you must hurry and meet him at <planet2>, you leave your government assigned vehicle there (as has been tracked) and take off in your previously owned vessel (either the enemy stole it from the ports for you, or provided an exact replica as partial payment) when you reach <planet2> your mission is complete and they enemy then pays you for your trouble. more missions available from then on.

This would work.