Oolite Bulletins

For information and discussion about Oolite.
It is currently Tue Oct 24, 2017 7:39 am

All times are UTC




Post new topic  Reply to topic  [ 22 posts ]  Go to page 1 2 Next
Author Message
PostPosted: Wed Oct 28, 2015 4:22 pm 
Offline
Deadly
Deadly
User avatar

Joined: Sat Jan 25, 2014 2:35 am
Posts: 183
Location: floating the Blackfoot
I modified the manifest mfd code into the manifest scanner so it displays the manifest of a targeted ship.
Simply target a ship and the cargo space used is displayed, then use the 'n' key to display the contents of the hold:

Image Image
I did a fair amount of testing and it seems to be about 99.9% accurate, I did pick up a pod that had something that was not listed, but only once. The numbers for gold, platinum and gems are not always correct but sometimes there will be two pods containing these commodities so there is often more than the scanner listed. I guess some commanders are able to stash some of these commodities without adding the numbers to their manifest.

I'd like to add some more effects like a delay timer and maybe an energy drain, but I am no coder and I may never get around to it. It might also be interesting to add some AI effects, right now npcs don't respond to it in any way. I haven't got a lot of time for this right now but I wanted to get it out to the community. If anyone else is interested in adapting this have at it :D .

I have restricted it from 'safer' systems so you will only find it in anarchy-dictatorships.
Get it here:
https://app.box.com/s/s9jh5gb4xio4zc69c7h7dli1htiumlix

Many thanks to spara for the original manifest mfd code.

_________________
Realize collective conscious creation


Last edited by Stormrider on Tue Nov 10, 2015 3:52 pm, edited 1 time in total.

Top
   
PostPosted: Wed Oct 28, 2015 4:35 pm 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Tue Aug 28, 2012 8:05 pm
Posts: 485
Location: aboard the Laenina Crowne - Yasen-N class space freighter
heh, seems only fair, since NPCs pirates always seem to know my cargo I'm carrying which they say vital for the revolution or whatever.

_________________
Amah


Top
   
PostPosted: Thu Oct 29, 2015 2:33 am 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Sat Jun 11, 2011 6:07 am
Posts: 2161
Location: Western Australia
Code:
//Remove and fine if techies at mainstation find it in communist-corprate systems\ on second thought maybe not for now
/*
	if( equipment === "EQ_RENOVATION" && system.government > 4 && stn.allegiance == "galcop" && p.equipmentStatus("EQ_MANIF_SCANNER") == "EQUIPMENT_OK" || p.equipmentStatus("EQ_MANIF_SCANNER") == "EQUIPMENT_DAMAGED")
	{

		p.removeEquipment("EQ_MANIF_SCANNER");
		player.bounty += 25; // <------------------------ Nah!


	}
}
*/
Why is this commented out, is it buggy? I think it's a good idea. I wouldn't include a fine, just remove the offending item. This would be a good place to integrate with Email System OXP, too.


Top
   
PostPosted: Thu Oct 29, 2015 4:43 am 
Online
Commodore
Commodore
User avatar

Joined: Tue Jan 21, 2014 10:37 pm
Posts: 1750
Location: [p]laying [h]ard and [k]icking [b]utt somewhere in G7...
There's a small bug in the logic. It needs brackets around the "or" clause p.equipmentStatus("EQ_MANIF_SCANNER") == "EQUIPMENT_OK" || p.equipmentStatus("EQ_MANIF_SCANNER", like this:
Code:
//Remove and fine if techies at mainstation find it in communist-corprate systems\ on second thought maybe not for now
/*
   if( equipment === "EQ_RENOVATION" && system.government > 4 && stn.allegiance == "galcop" && (p.equipmentStatus("EQ_MANIF_SCANNER") == "EQUIPMENT_OK" || p.equipmentStatus("EQ_MANIF_SCANNER") == "EQUIPMENT_DAMAGED"))
   {

      p.removeEquipment("EQ_MANIF_SCANNER");
      player.bounty += 25; // <------------------------ Nah!


   }
}
*/

_________________
My OXP's


Top
   
PostPosted: Thu Oct 29, 2015 3:23 pm 
Offline
Deadly
Deadly
User avatar

Joined: Sat Jan 25, 2014 2:35 am
Posts: 183
Location: floating the Blackfoot
Quote:
Why is this commented out, is it buggy? I think it's a good idea. I wouldn't include a fine, just remove the offending item.
I thought it was a little drastic. I haven't set it up so the player is refunded for choosing to remove the scanner so the player would be pretty limited for maintenance. I also like the way phkb handles informing the player of equipment confiscation in the smugglers oxp, but I was worried about creating a conflict with smugglers if I did the same thing.

I'll see what I can come up with. I like the idea of integration with the Email System oxp, but I am not sure I've got the technology to do that soon.
Quote:
There's a small bug in the logic.
Thanks phkb, I thought it worked when I tested it but I never tested it with a damaged scanner :wink: .

_________________
Realize collective conscious creation


Top
   
PostPosted: Thu Oct 29, 2015 5:58 pm 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Wed Dec 04, 2013 12:34 pm
Posts: 925
Location: London, UK
If I ever feel like starting a career in piracy this will definitely be on my shopping list.

Out of interest, what happens when you scan e.g. an Anaconda? Logically they shouldn't be running without several hundred tons of cargo, but I've never seen anything that big break up and release more than a few tons.


Top
   
PostPosted: Thu Oct 29, 2015 6:37 pm 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Tue Aug 28, 2012 8:05 pm
Posts: 485
Location: aboard the Laenina Crowne - Yasen-N class space freighter
iirc the NPC annies have internally a reduced cargo hold (100t, 150, 200t ?) and just release even less on ship died.

_________________
Amah


Top
   
PostPosted: Thu Oct 29, 2015 7:23 pm 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Mon May 20, 2013 9:53 pm
Posts: 2408
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
Quote:
NPC annies have internally a reduced cargo hold
250t since Oolite 1.80 and after this dicussion. In my eyes player's Annie has a built-in version of [wiki]HyperCargo[/wiki] to get the additional 500t due to the hull volume is only about double than a Boa. Moreover the wiki say: "HyperCargo is a modernised and updated version of the cargo compression system famously used on larger ships like the Anaconda".

_________________
OXPs by Norby


Top
   
PostPosted: Fri Oct 30, 2015 6:50 pm 
Offline
Deadly
Deadly
User avatar

Joined: Sat Jan 25, 2014 2:35 am
Posts: 183
Location: floating the Blackfoot
I tried adding this bit of code:
Code:
	if( equipment === "EQ_RENOVATION" && system.government > 4 && stn.allegiance == "galcop" && (p.equipmentStatus("EQ_MANIF_SCANNER") == "EQUIPMENT_OK" || p.equipmentStatus("EQ_MANIF_SCANNER") == "EQUIPMENT_DAMAGED"))
	{

		p.removeEquipment("EQ_MANIF_SCANNER");
		mission.runScreen({title: "Equipment Confiscated", message: "It appears that your Manifest Scanner has been removed ", model: "police", background: "witchbarbg.png"});
It works, but if I have a smuggling compartment installed my message doesn't get displayed and the Ironhide Armour message offering to repair damaged armour doesn't get displayed either.
I don't know how exactly to get those other messages to to display first and still display mine after.
Quote:
Out of interest, what happens when you scan e.g. an Anaconda?
Well here is a shot of a fully loaded Boa and a partially loaded Annie:
Image Image

These larger ships do drop a lot of cargo but I don't think I've ever seen more than 20 pods and ships with less than 4 or 5 tons often drop nothing but scrap metal. It seems reasonable that most of the cargo is destroyed with the ship.
Quote:
If I ever feel like starting a career in piracy this will definitely be on my shopping list.
You could always be a self-appointed customs agent, seems like quit a few traders are carrying illicit cargo. :wink:
In my own defence I must insist that all those ships were destroyed purely in the interest of testing. I mean I always picked up their escape pods, if they manage to launch in time. :twisted:

_________________
Realize collective conscious creation


Top
   
PostPosted: Fri Oct 30, 2015 7:24 pm 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Mon May 20, 2013 9:53 pm
Posts: 2408
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
Quote:
my message doesn't get displayed
Try it in missionScreenOpportunity:
Code:
this.missionScreenOpportunity= function() {
    if(this._ScannerRemove) {
        this._ScannerRemove = false;
        player.ship.removeEquipment("EQ_MANIF_SCANNER");
        mission.runScreen({title: "Equipment Confiscated", message: "It appears that your Manifest Scanner has been removed ", model: "police", background: "witchbarbg.png"});
    }
}
...
   if( equipment === "EQ_RENOVATION" ...
   {
       this._ScannerRemove = true;
...

_________________
OXPs by Norby


Top
   
PostPosted: Sat Oct 31, 2015 5:06 pm 
Offline
Deadly
Deadly
User avatar

Joined: Sat Jan 25, 2014 2:35 am
Posts: 183
Location: floating the Blackfoot
Quote:
Try it in missionScreenOpportunity:
Thanks Norby that worked, but since missionScreenOpportunity doesn't fire after the purchase of a renovation on its own I had to create another message to make it fire if no other oxp ran a missionscreen after purchase.
Like this:
Code:
   if( equipment === "EQ_RENOVATION" ...
   {
       this._ScannerRemove = true;
mission.runScreen({title: "Suspicious Activity", message: "It appears that some of your equipment has been tampered with.", model: "station"});
}
this.missionScreenOpportunity= function() {

	if(this._ScannerRemove) {
    	this._ScannerRemove = false;
        mission.runScreen({title: "Equipment Confiscated", message: "Your Manifest Scanner is gone!", model: "police"});...
    }
}
Maybe not the best solution but it works.

Version 0.7 now available from link at the top.
Changes:
  • *Give the player a partial refund when they remove scanner.
    *Make removal option available anywhere.
    *Confiscate scanner if maintenance overhaul purchased at Communist-Corprate systems.
    *Added messages to inform player of confiscation.

_________________
Realize collective conscious creation


Top
   
PostPosted: Mon Nov 09, 2015 8:40 am 
Offline
---- E L I T E ----
---- E L I T E ----

Joined: Tue Nov 09, 2010 1:44 pm
Posts: 1393
Another OXP that I simply MUST grab when I get back to Oolite!


Top
   
PostPosted: Tue Nov 10, 2015 3:51 pm 
Offline
Deadly
Deadly
User avatar

Joined: Sat Jan 25, 2014 2:35 am
Posts: 183
Location: floating the Blackfoot
Quote:
Another OXP that I simply MUST grab when I get back to Oolite!
I've uploaded 1.0 to the manager so it will be easy to grab.
-just changed the manifest for the manager.

_________________
Realize collective conscious creation


Top
   
PostPosted: Wed Apr 06, 2016 4:31 am 
Offline
Deadly
Deadly

Joined: Sun Feb 24, 2013 11:52 am
Posts: 199
Quote:
Quote:
Another OXP that I simply MUST grab when I get back to Oolite!
I've uploaded 1.0 to the manager so it will be easy to grab.
-just changed the manifest for the manager.
How does it work? I've primed it and targeted a ship and I don't see any resulting display. Does that mean they have no cargo?


Top
   
PostPosted: Wed Apr 06, 2016 4:56 am 
Online
Commodore
Commodore
User avatar

Joined: Tue Jan 21, 2014 10:37 pm
Posts: 1750
Location: [p]laying [h]ard and [k]icking [b]utt somewhere in G7...
After you target a ship, I think you need to prime the Manifest Scanner with shift-N, then press "n" to activate it.

_________________
My OXP's


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 22 posts ]  Go to page 1 2 Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 14 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
cron
Powered by phpBB® Forum Software © phpBB Limited